Changeset 340 for experimental/distortionNG/distortionNG.cpp
- Timestamp:
- Mar 24, 2012, 10:00:11 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
experimental/distortionNG/distortionNG.cpp
r339 r340 52 52 if ( viewer ) 53 53 { 54 osg::ref_ptr<osgUtil::LineSegmentIntersector> intersector = new osgUtil::LineSegmentIntersector(osgUtil::Intersector::WINDOW, ea.getX(), ea.getY()); 54 osg::notify(osg::ALWAYS)<<std::endl<<"Intersection:"<<std::endl<<"ea.getX()="<<ea.getX()<<std::endl; 55 osg::notify(osg::ALWAYS)<<"ea.getY()="<<ea.getY()<<std::endl; 56 osg::ref_ptr<osgUtil::LineSegmentIntersector> intersector = new osgUtil::LineSegmentIntersector(osgUtil::Intersector::PROJECTION, ea.getX(), ea.getY()); 55 57 osgUtil::IntersectionVisitor iv( intersector.get() ); 56 58 //viewer->getCamera()->accept( iv ); … … 67 69 if ( ea.getEventType() == osgGA::GUIEventAdapter::DRAG ) 68 70 { 69 osg::notify(osg::ALWAYS)<<std::endl<<"ea.getGraphicsContext()="<<ea.getGraphicsContext()<<std::endl;71 osg::notify(osg::ALWAYS)<<std::endl<<"Drag:"<<std::endl<<"ea.getGraphicsContext()="<<ea.getGraphicsContext()<<std::endl; 70 72 osg::notify(osg::ALWAYS)<<"ea.getXnormalized()="<<ea.getXnormalized()<<std::endl; 71 73 osg::notify(osg::ALWAYS)<<"ea.getYnormalized()="<<ea.getYnormalized()<<std::endl; … … 112 114 closestVertexIndex = result.indexList[i]; 113 115 } 114 //OSG_NOTIFY(osg::ALWAYS)<<"maxRatio="<<maxRatio<<std::endl;115 //OSG_NOTIFY(osg::ALWAYS)<<"closestVertexIndex="<<closestVertexIndex<<std::endl;116 OSG_NOTIFY(osg::ALWAYS)<<"maxRatio="<<maxRatio<<std::endl; 117 OSG_NOTIFY(osg::ALWAYS)<<"closestVertexIndex="<<closestVertexIndex<<std::endl; 116 118 } 117 119 OSG_NOTIFY(osg::ALWAYS)<<"nearest vertex: X="<<(*vertices)[closestVertexIndex].x()<<" Y="<<(*vertices)[closestVertexIndex].y()<<" Z="<<(*vertices)[closestVertexIndex].z()<<std::endl;
Note: See TracChangeset
for help on using the changeset viewer.