Handles the TKE_Ellipse and TKE_Elliptical_Arc opcodes. More...
#include <BOpcodeHandler.h>
Public Member Functions | |
TK_Status | Clone (BStreamFileToolkit &tk, BBaseOpcodeHandler **handler) const |
float const * | GetCenter () const |
double const * | GetDCenter () const |
double const * | GetDMajor () const |
double const * | GetDMinor () const |
float const * | GetLimits () const |
float const * | GetMajor () const |
float const * | GetMinor () const |
TK_Status | Read (BStreamFileToolkit &tk) |
TK_Status | ReadAscii (BStreamFileToolkit &tk) |
Deprecated. | |
void | SetCenter (float x, float y, float z) |
void | SetCenter (float const s[]) |
void | SetDCenter (double x, double y, double z) |
void | SetDCenter (double const s[]) |
void | SetDMajor (double x, double y, double z) |
void | SetDMajor (double const m[]) |
void | SetDMinor (double x, double y, double z) |
void | SetDMinor (double const m[]) |
void | SetLimits (float s, float e) |
void | SetMajor (float x, float y, float z) |
void | SetMajor (float const m[]) |
void | SetMinor (float x, float y, float z) |
void | SetMinor (float const m[]) |
TK_Ellipse (unsigned char opcode) | |
TK_Status | Write (BStreamFileToolkit &tk) |
TK_Status | WriteAscii (BStreamFileToolkit &tk) |
Deprecated. | |
Protected Attributes | |
double | m_dpoints [9] |
float | m_limits [2] |
float | m_points [9] |
Handles the TKE_Ellipse and TKE_Elliptical_Arc opcodes.
TK_Ellipse provides support for writing/reading the TKE_Ellipse and TKE_Elliptical_Arc opcode objects to/from an HSF file.
The HOOPS/3dGS scene-graph can contain 'ellipse' and 'elliptical arc' primitives which are defined by center, major and minor points, as well as two parameterization values in the case of an elliptical arc.
TK_Ellipse::TK_Ellipse | ( | unsigned char | opcode | ) | [inline] |
constructor
TK_Status TK_Ellipse::Clone | ( | BStreamFileToolkit & | tk, |
BBaseOpcodeHandler ** | handler | ||
) | const [virtual] |
Copies the opcode handler
tk | A reference to the BStreamFileToolkit object. |
handler | A pointer to the opcode handler object. Passed by reference. |
Reimplemented from BBaseOpcodeHandler.
float const* TK_Ellipse::GetCenter | ( | ) | const [inline] |
Returns the center of the arc as the address of a float triplet
double const* TK_Ellipse::GetDCenter | ( | ) | const [inline] |
Returns the center of the arc as the address of a float triplet
double const* TK_Ellipse::GetDMajor | ( | ) | const [inline] |
Returns the major axis of the arc as the address of a float triplet
double const* TK_Ellipse::GetDMinor | ( | ) | const [inline] |
Returns the minor axis of the arc as the address of a float triplet
float const* TK_Ellipse::GetLimits | ( | ) | const [inline] |
Returns the parametric limits of the arc as the address of a float pair
float const* TK_Ellipse::GetMajor | ( | ) | const [inline] |
Returns the major axis of the arc as the address of a float triplet
float const* TK_Ellipse::GetMinor | ( | ) | const [inline] |
Returns the minor axis of the arc as the address of a float triplet
TK_Status TK_Ellipse::Read | ( | BStreamFileToolkit & | tk | ) | [virtual] |
Reads data from the toolkit buffer, decodes/decompresses it, and maps it to the opcode handlers data members. User-defined classes which need to write out custom data should utilize one of the available GetData() methods.
tk | A reference to the BStreamFileToolkit object. |
Implements BBaseOpcodeHandler.
void TK_Ellipse::SetCenter | ( | float | x, |
float | y, | ||
float | z | ||
) | [inline] |
Sets the center of the arc using discrete float values
void TK_Ellipse::SetCenter | ( | float const | s[] | ) | [inline] |
void TK_Ellipse::SetDCenter | ( | double | x, |
double | y, | ||
double | z | ||
) | [inline] |
Sets the center of the arc using discrete double values
void TK_Ellipse::SetDCenter | ( | double const | s[] | ) | [inline] |
Sets the center of the arc using a float triplet
References SetDCenter().
Referenced by SetDCenter().
void TK_Ellipse::SetDMajor | ( | double | x, |
double | y, | ||
double | z | ||
) | [inline] |
Sets the major axis of the arc using discrete float values
void TK_Ellipse::SetDMajor | ( | double const | m[] | ) | [inline] |
Sets the major axis of the arc using a float triplet
References SetDMajor().
Referenced by SetDMajor().
void TK_Ellipse::SetDMinor | ( | double | x, |
double | y, | ||
double | z | ||
) | [inline] |
Sets the minor axis of the arc using discrete float values
void TK_Ellipse::SetDMinor | ( | double const | m[] | ) | [inline] |
Sets the minor axis of the arc using a float triplet
References SetDMinor().
Referenced by SetDMinor().
void TK_Ellipse::SetLimits | ( | float | s, |
float | e | ||
) | [inline] |
Sets the parametric limits of the arc using discrete values
void TK_Ellipse::SetMajor | ( | float | x, |
float | y, | ||
float | z | ||
) | [inline] |
Sets the major axis of the arc using discrete float values
void TK_Ellipse::SetMajor | ( | float const | m[] | ) | [inline] |
Sets the major axis of the arc using a float triplet
References SetMajor().
Referenced by SetMajor().
void TK_Ellipse::SetMinor | ( | float | x, |
float | y, | ||
float | z | ||
) | [inline] |
Sets the minor axis of the arc using discrete float values
void TK_Ellipse::SetMinor | ( | float const | m[] | ) | [inline] |
Sets the minor axis of the arc using a float triplet
References SetMinor().
Referenced by SetMinor().
TK_Status TK_Ellipse::Write | ( | BStreamFileToolkit & | tk | ) | [virtual] |
Encodes/compresses data and writes data to the toolkit buffer. User-defined classes which need to write out custom data should utilize one of the available PutData() methods, and first write out the opcode associated with the group of binary data followed by the data itself.
tk | A reference to the BStreamFileToolkit object. |
Implements BBaseOpcodeHandler.
double TK_Ellipse::m_dpoints[9] [protected] |
internal use; center point
float TK_Ellipse::m_limits[2] [protected] |
internal use; Parameterization values
float TK_Ellipse::m_points[9] [protected] |
internal use; center point