openscenegraph
RotateCylinderDragger
Go to the documentation of this file.
1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
2 *
3 * This library is open source and may be redistributed and/or modified under
4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
5 * (at your option) any later version. The full license is in LICENSE file
6 * included with this distribution, and on the openscenegraph.org website.
7 *
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * OpenSceneGraph Public License for more details.
12*/
13//osgManipulator - Copyright (C) 2007 Fugro-Jason B.V.
14
15#ifndef OSGMANIPULATOR_ROTATECYLINDERDRAGGER
16#define OSGMANIPULATOR_ROTATECYLINDERDRAGGER 1
17
20
21namespace osgManipulator {
22
27{
28 public:
29
31
33
34
37 virtual bool handle(const PointerInfo& pi, const osgGA::GUIEventAdapter& ea, osgGA::GUIActionAdapter& us);
38
40 void setupDefaultGeometry();
41
43 inline void setColor(const osg::Vec4& color) { _color = color; setMaterialColor(_color,*this); }
44 inline const osg::Vec4& getColor() const { return _color; }
45
51 inline void setPickColor(const osg::Vec4& color) { _pickColor = color; }
52 inline const osg::Vec4& getPickColor() const { return _pickColor; }
53
54
55 protected:
56
58
60
62 osg::Matrix _startLocalToWorld, _startWorldToLocal;
64
67};
68
69
70}
71
72#endif
Definition Dragger:194
Definition Dragger:84
Definition RotateCylinderDragger:27
osg::Matrix _startLocalToWorld
Definition RotateCylinderDragger:62
void setPickColor(const osg::Vec4 &color)
Definition RotateCylinderDragger:51
const osg::Vec4 & getColor() const
Definition RotateCylinderDragger:44
osg::Vec3d _prevWorldProjPt
Definition RotateCylinderDragger:61
osg::Vec4 _pickColor
Definition RotateCylinderDragger:66
osg::Quat _prevRotation
Definition RotateCylinderDragger:63
META_OSGMANIPULATOR_Object(osgManipulator, RotateCylinderDragger) virtual bool handle(const PointerInfo &pi
const osg::Vec4 & getPickColor() const
Definition RotateCylinderDragger:52
osg::Vec4 _color
Definition RotateCylinderDragger:65
osg::ref_ptr< CylinderPlaneProjector > _projector
Definition RotateCylinderDragger:59
Definition Matrixd:27
Definition Quat:30
Definition Vec3d:30
Definition Vec4f:28
Definition ref_ptr:32
Definition Callback:21
Definition AntiSquish:23
void OSGMANIPULATOR_EXPORT setMaterialColor(const osg::Vec4 &color, osg::Node &node)
author: Julien Valentin 2017 (mp3butcher@hotmail.com)
Definition AlphaFunc:19
#define OSGMANIPULATOR_EXPORT
Definition osgManipulator/Export:27