OpenGL core profile and auto shader generator

When using the Core profile of OpenGL (“gl-version 3 2” in prc) Panda no longer uses the shader generator on nodes with setShaderAuto() and instead seems to silently fall back to the fixed pipeline. Is that the expected behavior ?

I discovered this while testing p3d_TextureMatrix usage?, I wanted to see how the panda generated shaders worked with texture matrix and struggled a while to understand why no shaders were dumped.

Yes, and there’s unfortunately nothing we can do about this until we rewrite the shader generator not to rely on Cg, or implement the new shader pipeline and a way to transpile Cg to GLSL.

Note that it actually falls back to a default shader, which is much more restrictive in functionality than the fixed-function shading pipeline. That is the cost of asking for a core profile.

It’s not a problem for me as I’m mainly using my own shader generator and shaders, it’s only a problem on Mac where you have to activate core profile to have a decent version of GLSL which means I will not be able to use both kind of shaders in the same app.