Thursday, October 12, 2017

debugging - How can I debug shader programs?


I'm in the process of debugging GLSL vertex shaders and I can't shake the feeling that I'm doing it wrong.


In general I have two strategies to make up for the lack of tracing




  • I stuff values into a debug color varying that I pass to the fragment shader and then try to interpret the colors.

  • I change the vertex shader code and see what happens.


I'm thinking that ideally I could make up for the lack of tracing by writing values to a texture somehow, reading the texture from the GPU and printed the values stuffed in the texture.


My guess is that there might be way better ways. Any suggestions?




No comments:

Post a Comment

Simple past, Present perfect Past perfect

Can you tell me which form of the following sentences is the correct one please? Imagine two friends discussing the gym... I was in a good s...