HOpCreateSphere
Functions
char const * |
|
int |
|
Detailed Description
-
class HOpCreateSphere : public HOpConstructSphere
The HOpCreateSphere class provides support for constructing a sphere and inserting it into the model.
HOpCreateSphere uses event information to draw a sphere. This class provides the basic functionality for drawing a three-dimensional, tesselated sphere. The operation consists of the following steps:
Left Button Down: Registers the center point of the sphere.
Left Button Down and Drag: Rubberbands the sphere to the desired circumference.
Left Button Up: Circumference is finalized, clears the scene and inserts a sphere into the HOOPS data base. The operation ends.
Public Functions
-
HOpCreateSphere(HBaseView *view, int DoRepeat = 0, int DoCapture = 1)
Constructs an HOpCreateSphere object.
- Parameters:
view – A pointer to an HBaseView object.
DoRepeat – An integer denoting whether this is a repeatable operator. This parameter has been deprecated.
DoCapture – An integer denoting whether the mouse state should be captured, which means that all mouse events should be received after a mousedown, even if it leaves the window. This parameter has been deprecated.
-
virtual ~HOpCreateSphere()
-
virtual char const *GetName()
- Returns:
A pointer to a character string denoting the name of the operator, which is ‘HOpCreateSphere’.
-
virtual int OnLButtonUp(HEventInfo &hevent)
OnLButtonUp finalizes the size of the sphere and inserts that sphere into the HOOPS database as a shell. Note that most of the work in this function is done by a call to the public function HUtilityGeometryCreation::CreateSphere.
- Parameters:
hevent – An HEventInfo object containing information about the current event.
- Returns:
An HOperatorReturn indicating the status of the event.
-
virtual HBaseOperator *Clone()
Creates a new operator which is a copy of the current operator. The user is responsible for deleting the newly created operator.
- Returns:
A pointer to the newly created HOpCreateSphere object.