OpenCOVER
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
OSGVruiHit.h
Go to the documentation of this file.
1 /* This file is part of COVISE.
2 
3  You can use it under the terms of the GNU Lesser General Public License
4  version 2.1 or later, see lgpl-2.1.txt.
5 
6  * License: LGPL 2+ */
7 
8 #ifndef OSG_VRUI_HIT_H
9 #define OSG_VRUI_HIT_H
10 
12 
13 #include <osgUtil/IntersectionVisitor>
14 #include <osgUtil/LineSegmentIntersector>
15 
16 namespace vrui
17 {
18 
19 class vruiNode;
20 
21 class OSGVRUIEXPORT OSGVruiHit : public vruiHit
22 {
23 
24 public:
25  OSGVruiHit(const osgUtil::LineSegmentIntersector::Intersection &isect, bool mouseHit);
26  virtual ~OSGVruiHit();
27 
28  virtual coVector &getLocalIntersectionPoint() const;
29  virtual coVector &getWorldIntersectionPoint() const;
30  virtual coVector &getWorldIntersectionNormal() const;
31  virtual bool isMouseHit() const;
32 
33  vruiNode *getNode();
34 
35  const osgUtil::LineSegmentIntersector::Intersection &getHit() const;
36 
37 private:
38  osgUtil::LineSegmentIntersector::Intersection hit;
39  bool mouseHit;
40 
41  mutable coVector *isecLocalPoint;
42  mutable coVector *isecWorldPoint;
43  mutable coVector *isecNormal;
44  mutable vruiNode *node;
45 };
46 }
47 #endif
Definition: vruiHit.h:20
Definition: vruiNode.h:21
Definition: OSGVruiHit.h:21