#include "ellipsoidTechnique.h" #include ellipsoidTechnique::ellipsoidTechnique() { } ellipsoidTechnique::~ellipsoidTechnique() { } void ellipsoidTechnique::modifyHeightfield(osg::HeightField* h, double lat_min, double lat_max, double lon_min, double lon_max) { OSG_NOTIFY( osg::ALWAYS ) << "ellipsoidTechnique::modifyHeightfield()" << std::endl; OSG_NOTIFY( osg::ALWAYS ) << "LAT: " << lat_min << " | " << lat_max << std::endl; OSG_NOTIFY( osg::ALWAYS ) << "LON: " << lon_min << " | " << lon_max << std::endl; int rows = h->getNumRows(); int cols = h->getNumColumns(); // calculate colum start/end and row start/end of affected vertices int startX=0,startY=0,endX=cols,endY=rows; // modify height value of affected vertices h->setHeight( 0,0, 600); //OSG_NOTIFY( osg::ALWAYS ) << "Origin: " << h->getOrigin()[0] << " | " << h->getOrigin()[1] << std::endl; //OSG_NOTIFY( osg::ALWAYS ) << "X-Intervall: " << h->getXInterval() << std::endl; //OSG_NOTIFY( osg::ALWAYS ) << "Y-Intervall: " << h->getYInterval() << std::endl; //if(dest_lat_min<=lat_min && lat_max<=dest_lat_max && dest_lon_min<=lon_min && lon_max<=dest_lon_max) //{ // OSG_NOTIFY( osg::ALWAYS ) << "ModificationVisitor::modifyTile() :: affected Tile" << std::endl; // OSG_NOTIFY( osg::ALWAYS ) << "LAT: " << lat_min << " | " << lat_max << std::endl; // OSG_NOTIFY( osg::ALWAYS ) << "LON: " << lon_min << " | " << lon_max << std::endl; // h->setHeight( 0,0, 1000); //} //OpenThreads::Thread::microSleep( 50000 ); }