Show
Ignore:
Timestamp:
04/10/03 21:32:32 (11 years ago)
Author:
robert
Message:

Added tests for presense of extensions to osgcubemap, osgvertexproram and
osgmultitexture examples.

Added osg::VertexProgram::Extensions class to better handle multiple graphics
context vertex program extensions.

Files:
1 modified

Legend:

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

    r1844 r1856  
    102102    viewer.realize(); 
    103103 
     104    for(unsigned int contextID = 0;  
     105        contextID<viewer.getDisplaySettings()->getMaxNumberOfGraphicsContexts(); 
     106        ++contextID) 
     107    { 
     108        osg::Texture::Extensions* textExt = osg::Texture::getExtensions(contextID,false); 
     109        if (textExt) 
     110        { 
     111            if (!textExt->isMultiTexturingSupported()) 
     112            { 
     113                cout<<"Warning: texture_cube_map not supported by OpenGL drivers, unable to run application."<<std::endl; 
     114                return 1; 
     115            } 
     116        } 
     117    } 
     118 
    104119    while( !viewer.done() ) 
    105120    {