comparison tests/test_materials.nim @ 334:2533f524bdb6

fix: remaining tests and an issue with updating uniforms
author Sam <sam@basx.dev>
date Mon, 04 Sep 2023 00:48:00 +0700
parents e4528d97a687
children b83b3a1ccb05
comparison
equal deleted inserted replaced
333:27aaf43e18b4 334:2533f524bdb6
36 intermediates=[ 36 intermediates=[
37 attr[Vec2f]("uvout"), 37 attr[Vec2f]("uvout"),
38 ], 38 ],
39 uniforms=[attr[float32]("test2", arrayCount=2)], 39 uniforms=[attr[float32]("test2", arrayCount=2)],
40 samplers = @[ 40 samplers = @[
41 attr[Sampler2DType]("tex1", arrayCount=2), 41 attr[Texture]("tex1", arrayCount=2),
42 attr[Sampler2DType]("tex2", arrayCount=2), 42 attr[Texture]("tex2", arrayCount=2),
43 ], 43 ],
44 outputs=[attr[Vec4f]("color")], 44 outputs=[attr[Vec4f]("color")],
45 vertexCode=""" 45 vertexCode="""
46 gl_Position = vec4(position.x, position.y + sin(Uniforms.test2[1]) / Uniforms.test2[1] * 0.5, position.z, 1.0); 46 gl_Position = vec4(position.x, position.y + sin(Uniforms.test2[1]) / Uniforms.test2[1] * 0.5, position.z, 1.0);
47 uvout = uv;""", 47 uvout = uv;""",