Naga specific WGSL extensions #4410
Labels
area: naga back-end
Outputs of naga shader conversion
area: naga front-end
lang: WGSL
WebGPU Shading Language
naga
Shader Translator
Milestone
naga_ext_push_constants
push_constant
Address Spacenaga_ext_f64
f64
typenaga_ext_early_depth_test
@early_depth_test
attributenaga_ext_multiview
(ornaga_ext_view_index
?)@builtin(view_index)
builtinnaga_ext_primitive_index
@builtin(primitive_index)
builtinnaga_ext_binding_array
(this will end up having 8Capabilities
see Updatebinding_array
relatedCapabilities
#4407)binding_array
typeAll of these have their own Capabilities therefore the validator is already aware of those non-standard items but I think we should still have our own set of extensions so that it's obvious when a shader uses those items.
Introducing a
strict_extensions: bool
field for theParser
will limit the extensions to only those defined by the spec (for now onlyf16
).Relevant errors should be different based on the
strict_extensions
field. Example: using anf64
type withstrict_extensions: true
should yield an error that informs the user that there is no such type; on the other hand, ifstrict_extensions
werefalse
, the error should inform the user that thenaga_ext_f64
extension is required.The text was updated successfully, but these errors were encountered: