gpu: add FeatureName enum
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
45704d990e
commit
c38edecf2f
2 changed files with 18 additions and 19 deletions
|
|
@ -1,24 +1,5 @@
|
||||||
typedef uint32_t WGPUFlags;
|
typedef uint32_t WGPUFlags;
|
||||||
|
|
||||||
typedef enum WGPUFeatureName {
|
|
||||||
WGPUFeatureName_Undefined = 0x00000000,
|
|
||||||
WGPUFeatureName_DepthClipControl = 0x00000001,
|
|
||||||
WGPUFeatureName_Depth32FloatStencil8 = 0x00000002,
|
|
||||||
WGPUFeatureName_TimestampQuery = 0x00000003,
|
|
||||||
WGPUFeatureName_PipelineStatisticsQuery = 0x00000004,
|
|
||||||
WGPUFeatureName_TextureCompressionBC = 0x00000005,
|
|
||||||
WGPUFeatureName_TextureCompressionETC2 = 0x00000006,
|
|
||||||
WGPUFeatureName_TextureCompressionASTC = 0x00000007,
|
|
||||||
WGPUFeatureName_IndirectFirstInstance = 0x00000008,
|
|
||||||
WGPUFeatureName_DepthClamping = 0x000003E8,
|
|
||||||
WGPUFeatureName_DawnShaderFloat16 = 0x000003E9,
|
|
||||||
WGPUFeatureName_DawnInternalUsages = 0x000003EA,
|
|
||||||
WGPUFeatureName_DawnMultiPlanarFormats = 0x000003EB,
|
|
||||||
WGPUFeatureName_DawnNative = 0x000003EC,
|
|
||||||
WGPUFeatureName_ChromiumExperimentalDp4a = 0x000003ED,
|
|
||||||
WGPUFeatureName_Force32 = 0x7FFFFFFF
|
|
||||||
} WGPUFeatureName;
|
|
||||||
|
|
||||||
typedef enum WGPUFilterMode {
|
typedef enum WGPUFilterMode {
|
||||||
WGPUFilterMode_Nearest = 0x00000000,
|
WGPUFilterMode_Nearest = 0x00000000,
|
||||||
WGPUFilterMode_Linear = 0x00000001,
|
WGPUFilterMode_Linear = 0x00000001,
|
||||||
|
|
|
||||||
|
|
@ -110,6 +110,24 @@ pub const ErrorType = enum(u32) {
|
||||||
device_lost = 0x00000004,
|
device_lost = 0x00000004,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
pub const FeatureName = enum(u32) {
|
||||||
|
undef = 0x00000000,
|
||||||
|
depth_clip_control = 0x00000001,
|
||||||
|
depth32_float_stencil8 = 0x00000002,
|
||||||
|
timestamp_query = 0x00000003,
|
||||||
|
pipeline_statistics_query = 0x00000004,
|
||||||
|
texture_compression_bc = 0x00000005,
|
||||||
|
texture_compression_etc2 = 0x00000006,
|
||||||
|
texture_compression_astc = 0x00000007,
|
||||||
|
indirect_first_instance = 0x00000008,
|
||||||
|
depth_clamping = 0x000003e8,
|
||||||
|
dawn_shader_float16 = 0x000003e9,
|
||||||
|
dawn_internal_usages = 0x000003ea,
|
||||||
|
dawn_multi_planar_formats = 0x000003eb,
|
||||||
|
dawn_native = 0x000003ec,
|
||||||
|
chromium_experimental_dp4a = 0x000003ed,
|
||||||
|
};
|
||||||
|
|
||||||
test "BackendType name" {
|
test "BackendType name" {
|
||||||
try testing.expectEqualStrings("Vulkan", BackendType.vulkan.name());
|
try testing.expectEqualStrings("Vulkan", BackendType.vulkan.name());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue