Getting the value of a GLSL program in a C++ program

I want to get the value of a GLSL variable (uniform or attrib) after GLSL program execution.
Is there any solution to do this ?

yes there are glGet … commands see the spec for detailed info

If you mean that the GLSL program should have changed the values of uniforms or attribs during it’s run, then no, this is not possible.
glGet commands get the current state, that is the state the user set last.
Final results of GLSL programs are color and depth buffer contents and you can read from there.

Thank you to this information.

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.