Advertisement

osg学习(57)重复声明gles osg_ModelViewProjectionMatrix

阅读量:

osg state convertVertexShaderSourceToOsgBuiltIns inserts these and the double declaration is causing an error in gles

复制代码
 osgEarth/ShaderUtils.cpp

    
 void applySupportForNoFFPImpl(GLSLChunker::Chunks& chunks)
    
     {
    
 #if !defined(OSG_GL_FIXED_FUNCTION_AVAILABLE) && !defined(OSG_GLES3_AVAILABLE) //osg state convertVertexShaderSourceToOsgBuiltIns inserts these and the double declaration is causing an error in gles
    
 }
    
    
    
    

针对gles的着色器程序,osgEarth所提供的着色器框架会在每个着色器文件版本号之后插入若干行代码,具体如下:

uniform mat4 osg_ModelViewMatrix;
uniform mat4 osg_ProjectionMatrix;
uni

全部评论 (0)

还没有任何评论哟~