Alphabetical Class Index   Class Hierarchy   Compound Members   File Members   File List  

Public Member Functions | Protected Attributes
TK_Ellipse Class Reference

Handles the TKE_Ellipse and TKE_Elliptical_Arc opcodes. More...

#include <BOpcodeHandler.h>

List of all members.

Public Member Functions

TK_Status Clone (BStreamFileToolkit &tk, BBaseOpcodeHandler **handler) const
float const * GetCenter () const
float const * GetLimits () const
float const * GetMajor () const
float const * GetMinor () const
TK_Status Read (BStreamFileToolkit &tk) alter
TK_Status ReadAscii (BStreamFileToolkit &tk) alter
 Deprecated.
void SetCenter (float x, float y, float z) alter
void SetCenter (float const *s) alter
void SetLimits (float s, float e) alter
void SetMajor (float x, float y, float z) alter
void SetMajor (float const *m) alter
void SetMinor (float x, float y, float z) alter
void SetMinor (float const *m) alter
 TK_Ellipse (unsigned char opcode)
TK_Status Write (BStreamFileToolkit &tk) alter
TK_Status WriteAscii (BStreamFileToolkit &tk) alter
 Deprecated.

Protected Attributes

float m_center [3]
float m_limits [2]
float m_major [3]
float m_minor [3]

Detailed Description

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.


Constructor & Destructor Documentation

TK_Ellipse::TK_Ellipse ( unsigned char  opcode) [inline]

constructor


Member Function Documentation

TK_Status TK_Ellipse::Clone ( BStreamFileToolkit tk,
BBaseOpcodeHandler **  handler 
) const [virtual]

Copies the opcode handler

Parameters:
tkA reference to the BStreamFileToolkit object.
handlerA pointer to the opcode handler object. Passed by reference.
Returns:
The result of the function call.

Reimplemented from BBaseOpcodeHandler.

float const* TK_Ellipse::GetCenter ( ) const [inline]

Returns the center 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.

Parameters:
tkA reference to the BStreamFileToolkit object.
Returns:
The result of the function call.

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]

Sets the center of the arc using a float triplet

References SetCenter().

Referenced by SetCenter().

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.

Parameters:
tkA reference to the BStreamFileToolkit object.
Returns:
The result of the function call.

Implements BBaseOpcodeHandler.


Member Data Documentation

float TK_Ellipse::m_center[3] [protected]

internal use; center point

float TK_Ellipse::m_limits[2] [protected]

internal use; Parameterization values

float TK_Ellipse::m_major[3] [protected]

internal use; Major axis

float TK_Ellipse::m_minor[3] [protected]

internal use; Minor axis


The documentation for this class was generated from the following file: