Debian Codegraph @

doc/man/man3/ivm/projectors/SbSphereSectionProjector.ivm

raw
1 NAME SbSphereSectionProjector "SbSphSectProj" "" { sphere-section projector }
2
3 INCLUDE projectors/SbSphereSectionProjector.h
4
5 DESC { \cSbSphereSectionProjector\.
6 projects a window space point (usually based on the mouse location)
7 onto the section of a sphere that has been sliced by a plane.
8 Two projected points can produce a rotation
9 about the sphere's center.
10 The tolerance slice can be specified as a fraction of the radius
11 of the sphere. The projection point will not extend beyond the
12 sliced portion of the sphere.
13 \p
14 Incremental changes (delta rotation) can be computed during
15 interactive sessions. Sphere projectors are typically used to write
16 interactive 3D manipulators and viewers.
17 }
18
19 METHOD "" SbSphereSectionProjector(float edgeTol = .9, SbBool orientToEye = TRUE) {}
20 METHOD "createSph" SbSphereSectionProjector( const SbSphere &sph,
21 float edgeTol = .9, SbBool orientToEye = TRUE) {
22 Constructors. The first uses a default sphere centered at the origin
23 with radius 1.0; the sphere is supplied in the second.
24 The position of the plane which slices the sphere into
25 a section is specified as a fraction of the sphere radius
26 with the parameter \vedgeTol\..
27 A tolerance value of 1.0 positions the plane
28 down the center of the sphere. A tolerance value of 0.5 defines
29 the longitudinal plane halfway between the center and the outside
30 edge of the sphere. The default value is .9, so that almost
31 half the sphere is in front of the plane.
32 The \vorientToEye\.
33 parameter determines whether the plane is perpendicular to the
34 eye, or perpendicular to the sphere's Z axis. Setting that parameter to TRUE
35 (the default) specifies that the plane be perpendicular to the
36 eye, which is most often the desired behavior.
37 \p
38 The default view volume is undefined, and the working space is identity.
39 }
40
41 METHOD "" ~SbSphereSectionProjector() { Destructor. }
42
43 METHOD "setTol" void setTolerance(float edgeTol) {}
44 METHOD "getTol" float getTolerance() const {
45 Set and get the edge tolerance as a fraction of the
46 radius of the sphere. If this is 1.0, the projector is a
47 hemisphere. If this is .1, the projector is a slice of
48 the sphere with radius .1*radius. Default is .9.
49 }
50
51 METHOD "" void setRadialFactor(float radialFactor = 0.0) {}
52 METHOD "" float getRadialFactor() const {
53 Set and get the radial rotation factor.
54 When the mouse is dragged off the edge of the sphere, the mouse
55 motion can be classified as either tangential (moving in a circle
56 around the sphere) or radial (moving toward or away from the center).
57 The tangential motion will always map to a rotation around the center,
58 (like the hands of a clock).
59 The radial motion, by default, has no effect. But if you set the
60 \vradialFactor\. to be > 0.0, this motion will make the sphere rotate
61 as if the mouse is pulling the top of the sphere out toward the
62 mouse.
63 If \vradialFactor\. = 1.0, then pulling has a `normal' feel (that is, the
64 mouse motion causes the same amount of rotation as if you had rotated
65 by hitting the actual surface of the sphere).
66 Default is 0.0
67 }
68
69 METHOD "isWithinTol" SbBool isWithinTolerance(const SbVec3f &point) {
70 Find whether this point on the sphere or tolerance
71 plane is within tolerance.
72 }
73
74 ALSO {
75 SbCylinderProjector,
76 SbCylinderSectionProjector,
77 SbCylinderPlaneProjector,
78 SbCylinderSheetProjector,
79 SbLineProjector,
80 SbPlaneProjector,
81 SbSpherePlaneProjector,
82 SbSphereSheetProjector
83 }
84
85
86