图形缓冲区(GraphicsBuffer、ComputeBuffer、顶点/索引缓冲区等)的最大大小,以字节为单位(只读)。
任何 GPU 缓冲区(GraphicsBuffer、ComputeBuffer 或 Mesh 使用的顶点/索引缓冲区)都不能大于此字节数。
using UnityEngine;
public class ExampleScript : MonoBehaviour { void Start() { // prints maximum graphics buffer size, in megabytes var maxSizeMb = SystemInfo.maxGraphicsBufferSize / 1024 / 1024; Debug.Log($"Maximum graphics buffer size is {maxSizeMb} MB"); } }