Changeset 1968


Ignore:
Timestamp:
Oct 24, 2005, 1:05:06 PM (20 years ago)
Author:
darran
Message:
  • Setting SWOLLEN_BINDIR environmental variable allows swollen to locate needed texture maps
Location:
Swollen/swollen
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • Swollen/swollen/main.cpp

    r132 r1968  
    1616#include <osg/StateAttribute>
    1717#include <osgDB/FileNameUtils>
     18#include <osgDB/FileUtils>
    1819
    1920#include <animation.h>
     
    141142
    142143
    143    // relative directory to swollen binary
    144    if( osgDB::getFilePath(argv[0]) == "" )
     144   // need swollen binary directory which contains resource images
     145   char *ptr;
     146   if( (ptr = getenv( "SWOLLEN_BINDIR" )) )
     147      sww->setSwollenDir( std::string(ptr) );
     148   else if( osgDB::getFilePath(argv[0]) == "" )
    145149      sww->setSwollenDir( std::string(".") );
    146150   else
    147151      sww->setSwollenDir( osgDB::getFilePath(argv[0]) );
     152   std::cout << sww->getSwollenDir() << std::endl;
    148153
    149154
  • Swollen/swollen/version.cpp

    r1965 r1968  
    1 const char* version() { const char* s = "Revision: 1844M"; return s; }
     1const char* version() { const char* s = "Revision: 1966M"; return s; }
Note: See TracChangeset for help on using the changeset viewer.