AcademySoftwareFoundation / MaterialX

MaterialX is an open standard for the exchange of rich material and look-development content across applications and renderers.
http://www.materialx.org/
Apache License 2.0
1.87k stars 353 forks source link

GLSL ShaderGen: `time_float` and `frame_float` do not have any effect #1952

Open hybridherbst opened 3 months ago

hybridherbst commented 3 months ago

Related to #1951

I believe the attached file should have some animation based on application time, however it just stays still in MaterialXWebViewer. marbleTime.mtlx.zip

image
hybridherbst commented 3 months ago

Edit: in some applications the time nodes show up as not connected, this one here should work: myFile2.mtlx.zip

kwokcb commented 3 months ago

There is no "play" functionality here nor in the desktop viewer. For the hardware case the u_frame shader uniform needs to be updated and bound as mentioned here

hybridherbst commented 3 months ago

Please consider it a feature request :)

jstone-lucasfilm commented 3 months ago

Thanks for this feature request, @hybridherbst, and I've just updated the title to clarify that this feature is missing in our GLSL shader generation, which both the Viewer and Graph Editor leverage for rendering

hybridherbst commented 3 months ago

Thanks @jstone-lucasfilm! I think in addition to the shader generation, the host application also needs to updates the uniforms, right?

jstone-lucasfilm commented 3 months ago

Good point, @hybridherbst, and indeed those updates should be made to the Viewer and Graph Editor when this feature is added.