working on function calls; ci skip
All checks were successful
Build / build (push) Has been skipped
Test / build (push) Has been skipped

This commit is contained in:
2026-01-17 02:05:52 +01:00
parent 076abf5d6a
commit db82448ac0
7 changed files with 309 additions and 224 deletions

View File

@@ -1,24 +1,21 @@
[nzsl_version("1.1")]
[feature(float64)]
module;
struct FragOut
{
[location(0)] color: vec4[f32]
}
[nzsl_version("1.1")]
[feature(float64)]
module;
[entry(frag)]
fn main() -> FragOut
{
let op1: f64 = 0.0;
let op2: f64 = 9.0;
let color: f32;
if (op1 == op2)
color = f32(op1);
else
color = f32(op2);
struct FragOut
{
[location(0)] color: vec4[f32]
}
let output: FragOut;
output.color = vec4[f32](color, color, color, color);
return output;
}
fn computeColor() -> f32
{
return 1.0;
}
[entry(frag)]
fn main() -> FragOut
{
let output: FragOut;
output.color = vec4[f32](computeColor(), computeColor(), computeColor(), computeColor());
return output;
}