Show
Ignore:
Timestamp:
11/24/05 11:28:09 (9 years ago)
Author:
robert
Message:

Changed the default value of Texture::_resizeNonPowerOfTwoHint to true, to
improve the backwards compatibility of peformance on systems that have OpenGL2.0
drivers but without hardware that can't handle non power of two textures.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/examples/osgshaderterrain/osgshaderterrain.cpp

    r4627 r4837  
    534534    terrainTexture->setFilter(osg::Texture2D::MIN_FILTER, osg::Texture2D::NEAREST); 
    535535    terrainTexture->setFilter(osg::Texture2D::MAG_FILTER, osg::Texture2D::NEAREST); 
    536     //terrainTexture->setResizeNonPowerOfTwoHint(true); 
     536    terrainTexture->setResizeNonPowerOfTwoHint(false); 
    537537    stateset->setTextureAttributeAndModes(0,terrainTexture,osg::StateAttribute::ON); 
    538538 
     
    670670         
    671671    std::cout<<"done."<<std::endl; 
     672     
    672673#if 0 
    673674    std::cout<<"Creating tree locations...";std::cout.flush(); 
     
    687688    tex->setWrap( osg::Texture2D::WRAP_T, osg::Texture2D::CLAMP ); 
    688689    tex->setImage(osgDB::readImageFile("Images/tree0.rgba")); 
     690    tex->setResizeNonPowerOfTwoHint(false); 
    689691 
    690692    osg::StateSet *dstate = new osg::StateSet;