Version: 2021.1

SystemInfo.SupportsVertexAttributeFormat

切换到手册
public static bool SupportsVertexAttributeFormat (Rendering.VertexAttributeFormat format, int dimension);

参数

format 要查找的 VertexAttributeFormat 格式。
dimension 要检查的顶点数据尺寸。

返回

bool 如果支持具有给定尺寸的格式,则返回 true。

描述

指示此设备上是否支持顶点属性格式和尺寸的给定组合。

并非所有 VertexAttributeFormat 和尺寸组合都受支持。 最常见的限制是格式和尺寸数据大小必须是 4 字节的倍数,因此, 例如不支持尺寸小于 4 的 VertexAttributeFormat.UNorm8。 某些平台或设备可能具有更多限制,例如 VertexAttributeFormat.Float16 不受某些手机支持。

另请参阅:VertexAttributeFormatVertexAttributeDescriptor