Changeset 8788 for OpenSceneGraph/trunk/examples/osgvolume/osgvolume.cpp
- Timestamp:
- 08/25/08 13:37:53 (5 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
OpenSceneGraph/trunk/examples/osgvolume/osgvolume.cpp
r8787 r8788 1489 1489 } 1490 1490 1491 class TestSupportOperation: public osg::GraphicsOperation 1492 { 1493 public: 1494 1495 TestSupportOperation(): 1496 osg::GraphicsOperation("TestSupportOperation",false), 1497 supported(true), 1498 errorMessage(), 1499 maximumTextureSize(256) {} 1500 1501 virtual void operator () (osg::GraphicsContext* gc) 1502 { 1503 OpenThreads::ScopedLock<OpenThreads::Mutex> lock(mutex); 1504 1505 glGetIntegerv( GL_MAX_3D_TEXTURE_SIZE, &maximumTextureSize ); 1506 1507 osg::notify(osg::NOTICE)<<"Max texture size="<<maximumTextureSize<<std::endl; 1508 } 1509 1510 OpenThreads::Mutex mutex; 1511 bool supported; 1512 std::string errorMessage; 1513 GLint maximumTextureSize; 1514 }; 1515 1516 1517 1491 1518 int main( int argc, char **argv ) 1492 1519 { … … 1567 1594 while (arguments.read("--zMultiplier",zMultiplier)) {} 1568 1595 1596 osg::ref_ptr<TestSupportOperation> testSupportOperation = new TestSupportOperation; 1597 viewer.setRealizeOperation(testSupportOperation.get()); 1598 1599 viewer.realize(); 1600 1601 int maximumTextureSize = testSupportOperation->maximumTextureSize; 1569 1602 int s_maximumTextureSize = 256; 1570 1603 int t_maximumTextureSize = 256; 1571 1604 int r_maximumTextureSize = 256; 1572 int maximumTextureSize = 256;1573 1605 while(arguments.read("--maxTextureSize",maximumTextureSize)) 1574 1606 {
