Ignore:
Timestamp:
Apr 21, 2012, 9:49:26 PM (12 years ago)
Author:
Torben Dannhauer
Message:

DistortionManipulator? is working (alpha stadium)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • experimental/distortionNG/DistortionManipulator.h

    r349 r353  
    2121
    2222#include <osgGA/GUIEventHandler>
    23 #include<osg/Referenced>
     23#include <osg/Referenced>
     24#include <osg/Switch>
     25#include <osg/Geometry>
     26#include <osgUtil/IntersectionVisitor>
     27#include <osgUtil/LineSegmentIntersector>
     28
    2429#include "DistortionSet.h"
    2530
    2631
    2732namespace osgViewer {
     33
    2834
    2935class DistortionManipulator : public osgGA::GUIEventHandler
     
    5056
    5157
    52         DistortionManipulator();
     58        DistortionManipulator(DistortionSet* ds);
    5359        virtual ~DistortionManipulator();
    5460
     
    5864        void setDistortionSet(DistortionSet* ds) {_distortionSet = ds;}
    5965
     66       
     67
    6068private:
    6169        void resetIntensityMap();
     
    6371        void showDistortionMesh(bool show);
    6472        void showIntensityMap(bool show);
     73
     74        void computeSelectedVertex( osgUtil::LineSegmentIntersector::Intersection& result );
     75        void createVertexHighlighter();
    6576
    6677        SetupMode activeSetupMode;
     
    7081
    7182        osg::ref_ptr<DistortionSet> _distortionSet;
     83
     84
     85        osg::ref_ptr<osg::Geometry> _highlighter;
     86    osg::observer_ptr<osg::Camera> _camera;
     87        osg::Geometry* _distortionMesh;
     88        const osg::Vec4 _highlightColor;
    7289};
    7390
Note: See TracChangeset for help on using the changeset viewer.