hugoam / two

c++ toolkit for rapid development of live graphical apps and games
zlib License
1.68k stars 92 forks source link

Example 07_gltf renders materials incorrectly #14

Closed hoelzl closed 5 years ago

hoelzl commented 5 years ago

When running example 07_gltf the materials appear very different from the ones in the WebGL version:

07_gltf_d_2019-01-09_18-58-33 07_gltf_d_2019-01-09_18-58-54 07_gltf_d_2019-01-09_18-59-12

(Built from the latest master (00fc8af) using VS2017 on Windows 10 Pro 64 bit with GeForce GTX 1080 graphics card, driver version 417.35, 4k monitor.)

hugoam commented 5 years ago

Strangely, this might be related to https://github.com/hugoam/mud/issues/11. In this one you don't get a crash, but it seems what's missing is the generation of the prefiltered environment map (which is precisely the shader that is crashing in https://github.com/hugoam/mud/issues/11). Maybe try running in D3D mode like I advised in the other issue so we can know more about this issue.

hoelzl commented 5 years ago

It seems you're right. When running in D3D mode the image looks perfect.

hugoam commented 5 years ago

Could you give me the logs for this one too ? I want to be sure that the cause is indeed related to the other issue.

hoelzl commented 5 years ago

It seems that this issue was solved by f38fdcfc88ff00e51352977de1dd8e0f47d70085 for OpenGL as well. Just in case they are still of interest to you I've attached logs for the latest version with the glitch (74a83bfd02b80b3865d0b95a2e34ac4e0863579f _old) and a post-fix build (_new).

07_gltf_console_output_old.txt 07_gltf_debug_output_old.txt

07_gltf_console_output_new.txt 07_gltf_debug_output_new.txt

hugoam commented 5 years ago

Oh, right, I just saw that I updated the shaders also in that commit, so if they were out-of-date that could explain all sorts of visual issues.