Added support for subsititing $VAR_NAME entries in shaders to enable writing shaders that work across GLSL versions.
This commit is contained in:
@@ -618,7 +618,7 @@ void Shader::PerContextShader::compileShader(osg::State& state)
|
||||
#endif
|
||||
|
||||
std::string source = _shader->getShaderSource();
|
||||
if (_shader->getType()==osg::Shader::VERTEX && (state.getUseVertexAttributeAliasing() || state.getUseModelViewAndProjectionUniforms()))
|
||||
// if (_shader->getType()==osg::Shader::VERTEX && (state.getUseVertexAttributeAliasing() || state.getUseModelViewAndProjectionUniforms()))
|
||||
{
|
||||
state.convertVertexShaderSourceToOsgBuiltIns(source);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user