2#ifndef _CO_VR_3D_SCALE_GIZMO
3#define _CO_VR_3D_SCALE_GIZMO
15 bool _scaleXonly{
false}, _scaleYonly{
false}, _scaleZonly{
false}, _scaleAll{
false};
16 osg::Vec3 _startHitPos_o;
19 osg::ref_ptr<osg::MatrixTransform> axisTransform;
20 osg::ref_ptr<osg::MatrixTransform> xAxisTransform;
21 osg::ref_ptr<osg::MatrixTransform> yAxisTransform;
22 osg::ref_ptr<osg::MatrixTransform> zAxisTransform;
23 osg::ref_ptr<osg::MatrixTransform> xSphereTransform;
24 osg::ref_ptr<osg::MatrixTransform> ySphereTransform;
25 osg::ref_ptr<osg::MatrixTransform> zSphereTransform;
35 osg::ref_ptr<osg::Geode> sphereGeode;
36 osg::ref_ptr<osg::Geode> scaleXaxisGeode;
37 osg::ref_ptr<osg::Geode> scaleYaxisGeode;
38 osg::ref_ptr<osg::Geode> scaleZaxisGeode;
39 osg::ref_ptr<osg::Geode> scaleXSphereGeode;
40 osg::ref_ptr<osg::Geode> scaleYSphereGeode;
41 osg::ref_ptr<osg::Geode> scaleZSphereGeode;
43 std::unique_ptr<opencover::coLine> _line;
45 osg::Vec3 calculatePointOfShortestDistance(
const osg::Vec3& lp0,
const osg::Vec3& lp1, osg::Vec3 axis_o)
const;
59 coVR3DScaleGizmo(osg::Matrix m,
float s, coInteraction::InteractionType type,
const char *iconName,
const char *interactorName, coInteraction::InteractionPriority priority,
coVR3DGizmo* gizmoPointer =
nullptr);
Definition: ARToolKit.h:33
Definition: coVR3DGizmo.h:20
Definition: coVR3DGizmoType.h:22
Definition: coVR3DScaleGizmo.h:13
const osg::Matrix & getMatrix() const
Definition: coVR3DScaleGizmo.h:74
int hit(vrui::vruiHit *hit) override
virtual ~coVR3DScaleGizmo()
virtual void startInteraction() override
float calcScale(osg::Vec3 axis)
virtual void createGeometry() override
virtual void updateTransform(osg::Matrix m) override
coVR3DScaleGizmo(osg::Matrix m, float s, coInteraction::InteractionType type, const char *iconName, const char *interactorName, coInteraction::InteractionPriority priority, coVR3DGizmo *gizmoPointer=nullptr)
osg::Matrix getMoveMatrix_o() const override
virtual void resetState() override
virtual void doInteraction() override
vrb::SharedState< osg::Matrix > SharedMatrix
Definition: coVR3DScaleGizmo.h:53
virtual void stopInteraction() override