Changeset 392 for experimental/distortionNG/extViewer.cpp
- Timestamp:
- Jun 30, 2012, 5:25:38 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
experimental/distortionNG/extViewer.cpp
r381 r392 364 364 osg::Program* IntensityMapProgram = new osg::Program; 365 365 IntensityMapProgram->setName( "intensityMapBlending" ); 366 osg::Shader* shaderVert = osg::Shader::readShaderFile( osg::Shader::VERTEX, "shader.vert" ); 367 shaderVert->setName("shaderVert"); 366 368 osg::Shader* shaderIntensityMap = osg::Shader::readShaderFile( osg::Shader::FRAGMENT, "shaderIntensityMap.frag" ); 367 369 shaderIntensityMap->setName("shaderIntensityMap"); 370 368 371 _distortionSet->setShaderIntensityMap( shaderIntensityMap ); 369 372 370 if ( shaderIntensityMap ) 371 { 373 if ( shaderVert && shaderIntensityMap ) 374 { 375 IntensityMapProgram->addShader( shaderVert ); 372 376 IntensityMapProgram->addShader( shaderIntensityMap ); 373 377 stateset->addUniform( new osg::Uniform("sceneTexture", (int)_distortionSet->getTexUnitScene()) );
Note: See TracChangeset
for help on using the changeset viewer.