Class SbSphereProjector
- java.lang.Object
-
- com.openinventor.inventor.Inventor
-
- com.openinventor.inventor.projectors.SbProjector
-
- com.openinventor.inventor.projectors.SbSphereProjector
-
- Direct Known Subclasses:
SbSphereSectionProjector
,SbSphereSheetProjector
public class SbSphereProjector extends SbProjector
Sphere projector.SbSphereProjector
is an abstract base class for projectors that use a sphere in their projection. Sphere projectors are typically used to write interactive 3D manipulators and viewers.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand
-
-
Field Summary
-
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SbRotation
getRotation(SbVec3f point1, SbVec3f point2)
Gets a rotation given two points on this sphere projector.SbSphere
getSphere()
Gets the sphere on which to project points.boolean
isFront()
Gets whether the projector should intersect the half of the sphere that faces the eye.boolean
isOrientToEye()
Gets whether the projector should always be oriented towards the eye.boolean
isPointInFront(SbVec3f point)
Gets whether the projector should intersect the half of the sphere that faces the eye.SbRotation
projectAndGetRotation(SbVec2f point)
Applies the projector using the given point, returning the point in three dimensions that it projects to.void
setFront(boolean inFront)
Sets whether the projector should intersect the half of the sphere that faces the eye.void
setOrientToEye(boolean orientToEye)
Sets whether the projector should always be oriented towards the eye.void
setSphere(SbSphere sph)
Sets the sphere on which to project points.-
Methods inherited from class com.openinventor.inventor.projectors.SbProjector
copy, getViewVolume, getWorkingSpace, intersect, project, setViewVolume, setWorkingSpace
-
Methods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
-
-
-
Method Detail
-
getRotation
public SbRotation getRotation(SbVec3f point1, SbVec3f point2)
Gets a rotation given two points on this sphere projector. The rotation will be on the surface of the sphere.
-
isOrientToEye
public boolean isOrientToEye()
Gets whether the projector should always be oriented towards the eye.
-
projectAndGetRotation
public SbRotation projectAndGetRotation(SbVec2f point)
Applies the projector using the given point, returning the point in three dimensions that it projects to. This also returns in rot a rotation on the surface of the sphere from the last projected point to this one. The passed point should be normalized (i.e. lie in the range [0.0,1.0]), with (0,0) at the lower-left.
-
getSphere
public SbSphere getSphere()
Gets the sphere on which to project points.
-
setFront
public void setFront(boolean inFront)
Sets whether the projector should intersect the half of the sphere that faces the eye. Set to false if the projector should intersect with the rear half.
-
setOrientToEye
public void setOrientToEye(boolean orientToEye)
Sets whether the projector should always be oriented towards the eye. Set to false if the tolerance should be evaluated in working space.
-
isPointInFront
public boolean isPointInFront(SbVec3f point)
Gets whether the projector should intersect the half of the sphere that faces the eye.
-
setSphere
public void setSphere(SbSphere sph)
Sets the sphere on which to project points. The default sphere has radius 1.0.
-
isFront
public boolean isFront()
Gets whether the projector should intersect the half of the sphere that faces the eye.
-
-