Change typenames. Bug in hlsl builtins
This commit is contained in:
@@ -50,8 +50,8 @@ Typenames :: string.[
|
|||||||
"half" ,
|
"half" ,
|
||||||
"float" ,
|
"float" ,
|
||||||
"double" ,
|
"double" ,
|
||||||
"texture2D",
|
"Texture2D",
|
||||||
"sampler" ,
|
"Sampler" ,
|
||||||
];
|
];
|
||||||
|
|
||||||
Type_Variable :: struct {
|
Type_Variable :: struct {
|
||||||
@@ -902,9 +902,9 @@ declare_struct :: (checker : *Semantic_Checker, node : *AST_Node, name : string)
|
|||||||
if child.kind == .FieldList {
|
if child.kind == .FieldList {
|
||||||
for field : child.children {
|
for field : child.children {
|
||||||
type_var := check_node(checker, field);
|
type_var := check_node(checker, field);
|
||||||
h2tv(checker, type_var).scope = scope_handle;
|
|
||||||
|
|
||||||
if type_var > 0 {
|
if type_var > 0 {
|
||||||
|
h2tv(checker, type_var).scope = scope_handle;
|
||||||
add_child(checker, handle, type_var);
|
add_child(checker, handle, type_var);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -259,6 +259,8 @@ int4x4 :: struct {
|
|||||||
#foreign atan2 :: (float2, float2) -> float2;
|
#foreign atan2 :: (float2, float2) -> float2;
|
||||||
#foreign atan2 :: (float3, float3) -> float3;
|
#foreign atan2 :: (float3, float3) -> float3;
|
||||||
#foreign atan2 :: (float4, float4) -> float4;
|
#foreign atan2 :: (float4, float4) -> float4;
|
||||||
#foreign atan2 :: (float4x4, float4x4) -> float4x4;
|
#foreign atan2 :: (float4x4, float4x4) -> float4x4;
|
||||||
|
|
||||||
|
#foreign sample :: (texture : Texture2D, uv : float2, sampler : Sampler) -> float4;
|
||||||
|
|
||||||
DONE
|
DONE
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
p :: properties {
|
p :: properties {
|
||||||
texture : texture2D;
|
texture : Texture2D;
|
||||||
sampler : sampler;
|
sampler : Sampler;
|
||||||
}
|
}
|
||||||
|
|
||||||
PS_Input :: struct {
|
PS_Input :: struct {
|
||||||
|
|||||||
Reference in New Issue
Block a user