Show
Ignore:
Timestamp:
09/20/06 17:48:27 (8 years ago)
Author:
robert
Message:

Updated positions of the text labels to make them move obvious on start up

Files:
1 modified

Legend:

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

    r5580 r5582  
    134134    unsigned int numLat = 15; 
    135135    unsigned int numLong = 20; 
    136     double latitude = 50.0; 
    137     double longitude = 0.0; 
     136    double latitude = 0.0; 
     137    double longitude = -100.0; 
    138138    double deltaLatitude = 1.0f; 
    139139    double deltaLongitude = 1.0f; 
     
    142142    for(unsigned int i = 0; i < numLat; ++i, latitude += deltaLatitude) 
    143143    { 
    144         longitude = 0.0; 
    145         for(unsigned int j = 0; j < numLong; ++j, ++t, longitude += deltaLongitude) 
    146         { 
    147             geode->addDrawable( createText( ellipsoid, latitude, longitude, 0, textList[t % textList.size()]) ); 
     144        double lgnt = longitude; 
     145        for(unsigned int j = 0; j < numLong; ++j, ++t, lgnt += deltaLongitude) 
     146        { 
     147            geode->addDrawable( createText( ellipsoid, latitude, lgnt, 0, textList[t % textList.size()]) ); 
    148148        } 
    149149    }