GLCORE osgEarth 2.10

classic Classic list List threaded Threaded
7 messages Options
DC DC
Reply | Threaded
Open this post in threaded view
|

GLCORE osgEarth 2.10

Hello,

I'm running GLCORE profile. I have verified that osgearth_version --caps sets Core Profile = yes and OSG (3.6.4) is compiled Core.

With rex engine, gl_ModelViewMatrix, gl_NormalMatrix, etc. are still defined in the shaders. They have not been replaced by osg_ModelViewMatrix, etc.

What am I doing wrong?

Thanks,
DC
Andreas Roth Andreas Roth
Reply | Threaded
Open this post in threaded view
|

Re: GLCORE osgEarth 2.10

Hi,

OSG allows to use the "old" (gl_*) names by creating an alias. The gl_* variables are automatically converted to osg_* names when the shader code is "uploaded" to the GPU.

Andreas
DC DC
Reply | Threaded
Open this post in threaded view
|

Re: GLCORE osgEarth 2.10

I do have the correct aliasing and flags set to replace deprecated uniforms/attributes, but I see when the Earth programs hit, the uniform flag is reset to false.

At least I know where to look now.

Thank you.

gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: GLCORE osgEarth 2.10

Are you getting shader compile errors?
Glenn Waldron / Pelican Mapping
DC DC
Reply | Threaded
Open this post in threaded view
|

Re: GLCORE osgEarth 2.10

Yes. I get deprecated gl usage errors when compiling.

I do set up all of my aliasings and set the flags (setUseModelViewProjectionUniforms, etc) to true.
When the Earth shaders are compiled. the _useModelViewProjectionUniforms flag has been reset to false (but _useVertexAttributeAliasing is still 'true').

I'm in the process of tracking that down.
gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: GLCORE osgEarth 2.10

Maybe your GLCORE build didn't quite go as planned. OSG is kind of finicky w.r.t. a GL3/CORE build.
Check against these instructions:

https://gist.github.com/gwaldron/a56b0e77e7fa8587b698717d21f9366d

Glenn Waldron / Pelican Mapping
DC DC
Reply | Threaded
Open this post in threaded view
|

Re: GLCORE osgEarth 2.10

In reply to this post by DC
I found it. It was on my end :(