Enum FxParseErrorCode
- Namespace
- ShadowDusk.HLSL
- Assembly
- ShadowDusk.HLSL.dll
Diagnostic codes emitted by the FX9 pre-parser.
public enum FxParseErrorCode
Fields
DuplicatePassName = 6FX0006: Two or more passes within a technique share the same name.
DuplicateTechniqueName = 5FX0005: Two or more techniques share the same name.
MalformedCompileExpression = 3FX0003: A compile() expression was malformed (unexpected tokens inside argument list).
MissingSemicolon = 8FX0008: A required semicolon is missing after a statement.
UnclosedAnnotationBlock = 7FX0007: An annotation block was opened but never closed.
UnclosedSamplerBlock = 9FX0009: A sampler_state block was opened but never closed.
UnexpectedEof = 2FX0002: The source ended before the current construct was closed.
UnexpectedToken = 1FX0001: An unexpected token was encountered during parsing.
UnknownCharacter = 11FX0011: A character the lexer does not recognize appeared outside any token.
UnrecognizedRenderStateKey = 10FX0010: A render-state key is not recognized (non-fatal warning).
UnrecognizedShaderProfile = 4FX0004: The shader profile string is not a recognized profile name.
UnsupportedLegacyIntrinsic = 12FX0012: A legacy D3D9 sampling intrinsic (e.g.
tex2Dlod) whose argument list does not map 1:1 onto a modernTexture2Dmethod, so it cannot be rewritten forward for DXC. (The FNA target compiles these natively and never raises this.)UnsupportedShaderStage = 14FX0014: A pass assigns a shader stage the consumer runtime has no place to put:
HullShader,DomainShader,GeometryShader, orComputeShader. MonoGame's and KNI'sEffectmodel exactly two stages (MonoGame stores the stage as a single bool, KNI as a two-value byte with a throwingdefault), so no compiler can produce a loadable effect containing one of these — it is a runtime limit, not a gap in ShadowDusk. Raised instead of letting the assignment fall through to render-state parsing, which blamed a missing semicolon (FX0008) on a file that had none.UnsupportedSm4TypeForFx2 = 13FX0013: An SM4+ resource/sampler type appeared in a shader targeting FNA's D3D9
fx_2_0profile, where no SM1-3 lowering exists. Raised BEFORE the source reaches vkd3d, which does not reject these cleanly — aSamplerComparisonStatemakes its SM1 lowering hit "Unreachable code reached" and take the whole process down with an access violation, so the user would get a crash instead of a diagnostic.