TK_Heuristics

Detailed Description

class TK_Heuristics : public BBaseOpcodeHandler

Handles the TKE_Heuristics opcode.

TK_Heuristics provides support for writing/reading the TKE_Heuristics opcode object to/from an HSF file.

The HOOPS/3dGS scene-graph supports an attribute called Heuristics which provide instructions about scene-graph optimizations or required calculations

Subclassed by HTK_Heuristics

Public Functions

inline TK_Heuristics()

constructor

~TK_Heuristics()
virtual TK_Status Read(BStreamFileToolkit &tk)

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.
virtual TK_Status Write(BStreamFileToolkit &tk)

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.
virtual TK_Status Clone(BStreamFileToolkit &tk, BBaseOpcodeHandler **handler) const

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.

virtual void Reset()

Resets the current opcode handler. This is called by the toolkit when it is done processing an opcode. This method reinitializes any opcode handler variables and frees up temporary data.

TK_Status ReadAscii(BStreamFileToolkit &tk)

Deprecated.

TK_Status WriteAscii(BStreamFileToolkit &tk)

Deprecated.

inline void SetMask(int m)

Sets the mask indicating which heuristics have a setting. Options are specified by TKO_Heuristic_Bits.

inline int GetMask() const

Returns the mask indicating which heuristics have a setting. Options are specified by TKO_Heuristic_Bits.

inline void SetValue(int v)

Sets the mask indicating which heuristics are set on/active. Options are specified by TKO_Heuristic_Bits.

inline int GetValue() const

Returns the mask indicating which heuristics are set on/active. Options are specified by TKO_Heuristic_Bits.

inline void SetEMask(int m)

Sets the extended mask indicating which heuristics have a setting. Options are specified by TKO_Heuristic_Bits.

inline int GetEMask() const

Returns the extended mask indicating which heuristics have a setting. Options are specified by TKO_Heuristic_Bits.

inline void SetEValue(int v)

Sets the extended mask indicating which heuristics are set on/active. Options are specified by TKO_Heuristic_Bits.

inline int GetEValue() const

Returns the extended mask indicating which heuristics are set on/active. Options are specified by TKO_Heuristic_Bits.

inline void SetRelatedSelectionLimit(int r)

Sets the related selection limit

inline int GetRelatedSelectionLimit() const

Returns the related selection limit

inline void SetInternalSelectionLimit(int i)

Sets the internal selection limit

inline int GetInternalSelectionLimit() const

Returns the internal selection limit

inline void SetInternalShellSelectionLimit(int i)

Sets the internal shell selection limit

inline int GetInternalShellSelectionLimit() const

Returns the internal shell selection limit

inline void SetInternalPolylineSelectionLimit(int i)

Sets the internal polyline selection limit

inline int GetInternalPolylineSelectionLimit() const

Returns the internal polyline selection limit

inline void SetExtras(int e)

Sets the ‘extra’ bits. These bits are used to indicate an alternate form for some of the options.

inline int GetExtras() const

Returns the ‘extra’ bits.

inline void SetCulling(int c)

Sets the culling mode. These bits indicate forms of scene culling which may be used.

inline int GetCulling() const

Returns the culling mode.

inline void SetSelectionCulling(int c)

Sets the selection culling mode. These bits indicate forms of scene culling which may be used.

inline int GetSelectionCulling() const

Returns the culling mode.

inline void SetSelectionBias(int c)

Sets the selection bias mode. These bits indicate items to favor during selection.

inline int GetSelectionBias() const

Returns the selection bias mode.

inline void SetPixelThreshold(int c)

Sets the minimum number of pixels that must be touched under an occlusion culling node for it to be considered for drawing

inline int GetPixelThreshold() const

Gets the Pixel Threshold

inline void SetMaximumExtent(int c)

Sets the upper limit for extent culling

inline int GetMaximumExtent() const

Gets the Maximum Extent

inline int GetMaximumExtentMode() const

Gets the Maximum Extent Mode

inline void SetMaximumExtentMode(int c)

Sets the Maximum Extent Mode

inline int GetMaximumExtentLevel() const

Gets the Maximum Extent Level

inline void SetMaximumExtentLevel(int c)

Sets the Maximum Extent Level

inline void SetHardExtent(int c)

Sets the limit for hard extent culling

inline int GetHardExtent() const

Gets the Hard Extent

inline float const *GetVector() const

Gets the Culling Vector

inline void SetVector(float x, float y, float z)

Sets the Culling Vector using discrete values

inline void SetVector(float const v[])

Sets the Culling Vector using a float array

inline float GetVectorTolerance() const

Gets the Culling Vector Tolerance

inline void SetVectorTolerance(float tol)

Sets the Culling Vector Tolerance

inline void SetMaxDistance(float m)
inline float GetMaxDistance() const

Gets the Hard Extent

inline float const *GetViewVolume() const

Gets the Culling view volume

inline void SetViewVolume(float ax, float ay, float az, float bx, float by, float bz)

Sets the Culling view volume using discrete values

inline void SetViewVolume(float const v[])

Sets the Culling view volume using a float array

inline void SetOrderedWeightsMask(int c)

Sets the mask of drawing order weight values which are interesting

inline int GetOrderedWeightsMask() const

Gets the mask of drawing order weight values which are interesting

inline void SetOrderedWeight(int index, float weight)

Sets a specified drawing order weighting factor

inline float GetOrderedWeight(int index) const

Return a single drawing order weighting factor

inline float const *GetOrderedWeights() const

Returns the array of drawing order weighting factors

inline float *GetOrderedWeights()

Returns the array of drawing order weighting factors, which may be modified directly

inline void SetSelectionLevel(int l)

Sets the selection level mode.

inline int GetSelectionLevel() const

Returns the selection level mode.

inline void SetSelectionSorting(int s)

Sets the selection sorting mode.

inline int GetSelectionSorting() const

Returns the selection sorting mode.

inline void SetForceDefer(int l)

Sets the force defer level.

inline int GetForceDefer() const

Returns the force defer level.

inline void SetStaticOptions(int o)

Sets the static options (such as condition handling mode).

inline int GetStaticOptions() const

Returns the static options.