Debian Codegraph @

doc/man/man3/ivm/draggers/SoTabBoxDragger.ivm

raw
1 NAME SoTabBoxDragger SoTabBoxDrag "" { cubic object you can translate and scale by dragging with the mouse }
2
3 INCLUDE draggers/SoTabBoxDragger.h
4
5 DESC { \cSoTabBoxDragger\.
6 is a composite dragger shaped like a box.
7 Inside it are six \cSoTabPlaneDraggers\. which the dragger positions
8 and orients to form a cube.
9 The operations available in an \cSoTabPlaneDragger\. (translation,
10 1D scaling and 2D scaling) are available on each face of the cube.
11 Since they each move in their local space, the dragger may be easily
12 translated or scaled in any direction.
13 \p
14 As a composite dragger, this class makes sure that when
15 one plane is dragged, the entire box moves together.
16 \p
17 As each sub-dragger is moved, the \cSoTabBoxDragger\. updates
18 its \vscaleFactor\. and \vtranslation\. fields.
19 As with all draggers, if you change a field the dragger will
20 move to match the new settings.
21 \p
22 \eRemember:\. This is \enot\. an \cSoTransform!\..
23 If you want to move other objects with this dragger, you can either:
24 \p
25 [a] Use an \cSoTabBoxManip\., which is subclassed from \cSoTransform\..
26 It creates one of
27 these draggers and uses it as the interface to change its fields.
28 (see the \cSoTabBoxManip\. man page).
29 \p
30 [b] Use field-to-field connections to connect the fields of this dragger to
31 those of any \cSoTransformation\. node.
32 \p
33 You can change the parts in any instance of this dragger using
34 \m\+setPart()\.\-SoDraggerSetPart()\.\.. The default part geometries
35 are defined as resources for this \cSoTabBoxDragger\. class. They are
36 detailed below in the Dragger Resources section of the online reference
37 page for this class. You can make your program use different default
38 resources for the parts by copying the file
39 \v/usr/share/data/draggerDefaults/tabBoxDragger.iv\. into your own
40 directory, editing the file, and then setting the environment variable
41 \vSO_DRAGGER_DIR\. to be a path to that directory.
42 }
43
44 METHOD "" SoTabBoxDragger() {
45 Constructor.
46 }
47
48 METHOD "" void adjustScaleTabSize() {
49 Cause the scale tab sizes to be re-adjusted on all 6 \cSoTabPlaneDragger\.s
50 so that they remain a near constant screen space size.
51 This happens automatically upon dragger finish.
52 Call this to adjust the scale tab sizes at other times, for instance
53 after the camera has changed in a viewer finish callback.
54 }
55
56 METHOD getClassNkitCat static
57 const SoNodekitCatalog *getClassNodekitCatalog() const
58 { Returns an \cSoNodekitCatalog\. for this class }
59
60 METHOD "" static SoType getClassTypeId() {
61 Returns type identifier for this class.
62 }
63
64
65
66 FIELD scaleFactor { Scale of the dragger. }
67 FIELD translation { Position of the dragger. }
68
69
70 DRAGGER_RESOURCE {
71 tabBoxTranslator,
72 tabPlane1.translator
73 tabPlane2.translator
74 tabPlane3.translator
75 tabPlane4.translator
76 tabPlane5.translator
77 tabPlane6.translator,
78 "Outline of a Square. The region within is pickable",
79 "Begins translation within the plane.
80 The tabBox places and orients each tabPlane so that these squares form
81 a box."
82 }
83
84 DRAGGER_RESOURCE {
85 tabBoxScaleTabMaterial,
86 tabPlane1.scaleTabMaterial
87 tabPlane2.scaleTabMaterial
88 tabPlane3.scaleTabMaterial
89 tabPlane4.scaleTabMaterial
90 tabPlane5.scaleTabMaterial
91 tabPlane6.scaleTabMaterial,
92 "Green - half diffuse, half emissive.",
93 "Used as material for scaling tabs."
94 }
95
96 DRAGGER_RESOURCE {
97 tabBoxScaleTabHints,
98 tabPlane1.scaleTabHints
99 tabPlane2.scaleTabHints
100 tabPlane3.scaleTabHints
101 tabPlane4.scaleTabHints
102 tabPlane5.scaleTabHints
103 tabPlane6.scaleTabHints,
104 "shapeHints node:COUNTERCLOCKWISE/SOLID/CONVEX",
105 "Property for the tab nodes."
106 }
107
108 DRAGGER_RESOURCE {
109 tabBoxBoxGeom,
110 boxGeom,
111 "Unpickable grey outline of a box.",
112 "Just feedback.."
113 }
114
115 ALSO {
116 SoInteractionKit,
117 SoDragger,
118 SoCenterballDragger,
119 SoDirectionalLightDragger,
120 SoDragPointDragger,
121 SoHandleBoxDragger,
122 SoJackDragger,
123 SoPointLightDragger,
124 SoRotateCylindricalDragger,
125 SoRotateDiscDragger,
126 SoRotateSphericalDragger,
127 SoScale1Dragger,
128 SoScale2Dragger,
129 SoScale2UniformDragger,
130 SoScaleUniformDragger,
131 SoSpotLightDragger,
132 SoTabPlaneDragger,
133 SoTrackballDragger,
134 SoTransformBoxDragger,
135 SoTransformerDragger,
136 SoTranslate1Dragger,
137 SoTranslate2Dragger
138 }
139