TK_Ellipse

class TK_Ellipse

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.

Inherits from: BBaseOpcodeHandler

Methods

TK_Ellipse::TK_Ellipse(unsigned char opcode)

constructor

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

tk: A reference to the BStreamFileToolkit object.

Returns

The result of the function call.
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

tk: A reference to the BStreamFileToolkit object.

Returns

The result of the function call.
TK_Status TK_Ellipse::Clone(BStreamFileToolkit &tk, BBaseOpcodeHandler **handler) const

const virtual

Copies the opcode handler

Parameters

tk: A reference to the BStreamFileToolkit object.

handler: A pointer to the opcode handler object. Passed by reference.

Returns

The result of the function call.
TK_Status TK_Ellipse::ReadAscii(BStreamFileToolkit &tk)

Deprecated.

TK_Status TK_Ellipse::WriteAscii(BStreamFileToolkit &tk)

Deprecated.

void TK_Ellipse::SetCenter(float x, float y, float z)

Sets the center of the arc using discrete float values

void TK_Ellipse::SetCenter(float const s[])

Sets the center of the arc using a float triplet

float const *TK_Ellipse::GetCenter() const

const

Returns the center of the arc as the address of a float triplet

void TK_Ellipse::SetMajor(float x, float y, float z)

Sets the major axis of the arc using discrete float values

void TK_Ellipse::SetMajor(float const m[])

Sets the major axis of the arc using a float triplet

float const *TK_Ellipse::GetMajor() const

const

Returns the major axis of the arc as the address of a float triplet

void TK_Ellipse::SetMinor(float x, float y, float z)

Sets the minor axis of the arc using discrete float values

void TK_Ellipse::SetMinor(float const m[])

Sets the minor axis of the arc using a float triplet

float const *TK_Ellipse::GetMinor() const

const

Returns the minor axis of the arc as the address of a float triplet

void TK_Ellipse::SetDCenter(double x, double y, double z)

Sets the center of the arc using discrete double values

void TK_Ellipse::SetDCenter(double const s[])

Sets the center of the arc using a float triplet

double const *TK_Ellipse::GetDCenter() const

const

Returns the center of the arc as the address of a float triplet

void TK_Ellipse::SetDMajor(double x, double y, double z)

Sets the major axis of the arc using discrete float values

void TK_Ellipse::SetDMajor(double const m[])

Sets the major axis of the arc using a float triplet

double const *TK_Ellipse::GetDMajor() const

const

Returns the major axis of the arc as the address of a float triplet

void TK_Ellipse::SetDMinor(double x, double y, double z)

Sets the minor axis of the arc using discrete float values

void TK_Ellipse::SetDMinor(double const m[])

Sets the minor axis of the arc using a float triplet

double const *TK_Ellipse::GetDMinor() const

const

Returns the minor axis of the arc as the address of a float triplet

void TK_Ellipse::SetLimits(float s, float e)

Sets the parametric limits of the arc using discrete values

float const *TK_Ellipse::GetLimits() const

const

Returns the parametric limits of the arc as the address of a float pair

Variables

float TK_Ellipse::m_points[9]

protected

float

internal use; center point

double TK_Ellipse::m_dpoints[9]

protected

double

internal use; center point

float TK_Ellipse::m_limits[2]

protected

float

internal use; Parameterization values