Fix position output hint.

This commit is contained in:
2024-09-11 12:42:59 +02:00
parent 5b237d34de
commit 6eba51cc8c
2 changed files with 24 additions and 0 deletions

View File

@@ -1,3 +1,12 @@
/////////////////////////////////////
//~ nbr:
//
/////////////////////////////////////
//~ nbr: Codegen TODOs
//
// [ ] Prefix output of property values with __PROPERTIES so we don't get name clashes
Output_Language :: enum {
HLSL;
GLSL; // @Incomplete
@@ -111,6 +120,8 @@ emit_field :: (state : *Codegen_State, node : *AST_Node, indentation : int) {
append(*state.builder, " : POSITION");
} else if hint.ident_value == "uv" {
append(*state.builder, " : TEXCOORD0");
} else if hint.ident_value == "outposition" {
append(*state.builder, " : SV_POSITION");
}
}
}