Python Script Engine  8.3
GL Studio Editor Python Script API
GlsOdometer Class Reference
+ Inheritance diagram for GlsOdometer:

Public Types

enum  GlsOdometerBehaviorType_e {
  BEHAVIOR_ANALOG =0 ,
  BEHAVIOR_DIGITAL
}
 
enum  GlsOdometerGeometryType_e {
  GEOMETRY_2D =0 ,
  GEOMETRY_3D
}
 
- Public Types inherited from DisplayObject
enum  MemberAccess_e {
  PUBLIC ,
  PRIVATE ,
  PROTECTED
}
 
enum  PickableType_e {
  UNPICKABLE ,
  FIRST_PICK ,
  BEST_PICK ,
  ALWAYS_PICK
}
 
enum  PolygonClose_e {
  POLY_OPEN ,
  POLY_CLOSED
}
 
enum  PolygonMode_e {
  POLY_MODE_UNDEFINED ,
  POLY_MODE_POINTS ,
  POLY_MODE_OUTLINE ,
  POLY_MODE_FILLED ,
  POLY_MODE_FILL_AND_OUTLINE
}
 
enum  ShadingType_e {
  SHADING_FLAT ,
  SHADING_GOURAUD
}
 
enum  TextureMap_e {
  TEXTURE_MAP_MODULATE ,
  TEXTURE_MAP_DECAL ,
  TEXTURE_MAP_BLEND ,
  TEXTURE_MAP_REPLACE
}
 
enum  TextureFilter_e {
  TEXTURE_FILTER_NEAREST ,
  TEXTURE_FILTER_LINEAR ,
  TEXTURE_FILTER_NEAREST_MIPMAP_NEAREST ,
  TEXTURE_FILTER_LINEAR_MIPMAP_LINEAR ,
  TEXTURE_FILTER_NEAREST_MIPMAP_LINEAR ,
  TEXTURE_FILTER_LINEAR_MIPMAP_NEAREST
}
 
enum  TessellateType_e {
  TESSELLATE_UNION ,
  TESSELLATE_INTERSECT ,
  TESSELLATE_DIFFERENCE
}
 
enum  RotationAxis_e {
  X_AXIS ,
  Y_AXIS ,
  Z_AXIS
}
 
enum  LineStyle_e {
  SOLID_LINE_STYLE ,
  SMALL_DOTTED_LINE_STYLE ,
  DOTTED_LINE_STYLE ,
  DASHED_LINE_STYLE ,
  DOT_DASHED_LINE_STYLE ,
  SMALL_DASHED_LINE_STYLE
}
 
enum  AlphaMode_e {
  ALPHA_MODE_UNDEFINED ,
  ALPHA_MODE_OPAQUE ,
  ALPHA_MODE_2_LEVEL ,
  ALPHA_MODE_256_LEVEL
}
 

Public Member Functions

float GetInitalValue ()
 
None SetInitalValue (float val)
 
 GlsOdometer ()
 
 GlsOdometer (DisplayObjectArray *objs)
 
None SetMinValue (float val)
 
float GetMinValue ()
 
None SetMaxValue (float val)
 
float GetMaxValue ()
 
None SetInitialValue (float val)
 
float GetInitialValue ()
 
None SetBaseSystem (int val)
 
int GetBaseSystem ()
 
None BehaviorType (GlsOdometerBehaviorType_e value)
 
GlsOdometerBehaviorType_e BehaviorType ()
 
None GeometryType (GlsOdometerGeometryType_e value)
 
GlsOdometerGeometryType_e GeometryType ()
 
None TextureScaleOverride (bool &value)
 
bool TextureScaleOverride ()
 
None TextureScale (float &value)
 
float TextureScale ()
 
None DegreesPerDigitOverride (bool &value)
 
bool DegreesPerDigitOverride ()
 
None DegreesPerDigit (float &value)
 
float DegreesPerDigit ()
 
int OrderOfMagnitude ()
 
float RolloverThreshold ()
 
int NumberOfWheels ()
 
- Public Member Functions inherited from Group
 Group ()
 
 Group (DisplayObjectArray *objs)
 
None Ungroup ()
 
None InsertObject (DisplayObject *obj, bool reparent=true, bool recalculateBoundingbox=true, int loc=DEFAULT_GROUP_LOCATION, bool renameName=false)
 
None InsertObjectAllowDuplicateNames (DisplayObject *obj, bool reparent=true, bool recalculateBoundingbox=true, int loc=DEFAULT_GROUP_LOCATION)
 
None MoveObjectToGroup (DisplayObject *obj, bool recalculateBoundingbox=true, int loc=DEFAULT_GROUP_LOCATION, bool renameName=false)
 
None MoveObjectToGroupAllowDuplicateNames (DisplayObject *obj, bool recalculateBoundingbox=true, int loc=DEFAULT_GROUP_LOCATION)
 
None ReorderObject (int oldIndex, int newIndex)
 
DisplayObjectArrayGetObjectList ()
 
DisplayObjectGetObjectByIndex (int index)
 
int Count ()
 
None CalculateTextureCoordinates (None)
 
None SetGroupLocation (Vertex &v)
 
None CalculateBoundingBox ()
 
int GetCount ()
 
- Public Member Functions inherited from DisplayObject
bool isNULL ()
 
str GetName ()
 
str SetName (str name)
 
None SetProtectionMode (DisplayObject::MemberAccess_e mode)
 
DisplayObject::MemberAccess_e GetProtectionMode (None)
 
None SetLocked (bool val)
 
bool GetLocked (None)
 
bool GetGenerateMemberVariable ()
 
None SetGenerateMemberVariable (bool b)
 
bool GetAntiAliasing ()
 
None SetAntiAliasing (bool antiAliasing)
 
bool GetBlinking ()
 
None SetBlinking (bool blinking)
 
float GetBlinkRate ()
 
None SetBlinkRate (float rate)
 
int GetAlphaMode ()
 
None SetAlphaMode (int mode)
 
bool GetCullBackFaces ()
 
None SetCullBackFaces (bool cullFaces)
 
bool GetZBufferTestedFlag ()
 
None SetZBufferTestedFlag (bool tested)
 
bool GetAffectZBufferFlag ()
 
None SetAffectZBufferFlag (bool affect)
 
bool GetLightingEnabledFlag ()
 
None SetLightingEnabledFlag (bool enabled)
 
DisplayObject::PickableType_e GetPickMode ()
 
None SetPickMode (DisplayObject::PickableType_e mode)
 
bool GetVisibilityFlag ()
 
None SetVisibilityFlag (bool visible)
 
PolygonClose_e GetClosePolygonFlag ()
 
None SetClosePolygonFlag (PolygonClose_e closePolygon)
 
PolygonMode_e GetPolygonMode ()
 
None SetPolygonMode (PolygonMode_e polygonMode)
 
ShadingType_e GetShadingMode ()
 
None SetShadingMode (ShadingType_e shadingMode)
 
Vertex GetLocation ()
 
None SetLocation (Vertex loc)
 
Vertex GetRotationPoint ()
 
None SetRotationPoint (Vertex rotPoint)
 
GlsMatrixAffineGetDcsMatrix ()
 
None SetDcsMatrix (GlsMatrixAffine *matrix)
 
int GetMaterialIndex ()
 
None SetMaterialIndex (int matIndex)
 
str GetObjectClassName ()
 
int GetTextureIndex ()
 
None SetTextureIndex (int texIndex)
 
TextureMap_e GetTextureMappingTechnique ()
 
None SetTextureMappingTechnique (TextureMap_e mappingTechnique)
 
bool GetTextureRepeat ()
 
None SetTextureRepeat (bool repeat)
 
disti::GlsColor GetBlendingColor ()
 
None SetBlendingColor (GlsColor blendColor)
 
DisplayObject::TextureFilter_e GetTextureMagnificationFilter ()
 
None SetTextureMagnificationFilter (DisplayObject::TextureFilter_e filter)
 
DisplayObject::TextureFilter_e GetTextureMinificationFilter ()
 
None SetTextureMinificationFilter (DisplayObject::TextureFilter_e filter)
 
list GetTextureCoordinates ()
 
None SetTextureCoordinates (list &texVerts)
 
None GetTextureCoordinates (VertexArray *texVerts)
 
None SetTextureCoordinates (VertexArray &texVerts)
 
None GetTexturePoints (VertexArray *texVerts)
 
None SetTexturePoints (VertexArray &texVerts)
 
None SetTexturePoints (list &texVerts)
 
list GetTexturePoints ()
 
None GetVertices (VertexArray *verts)
 
None SetVertices (VertexArray &verts)
 
str GetInitialization ()
 
None SetInitialization (str initCode)
 
str GetCallbackCode ()
 
None SetCallbackCode (str cbCode)
 
DisplayObjectDuplicateObject (Document *doc=NULL)
 
DisplayObjectTessellateObject ()
 
DisplayObjectExtrudeObject (float amount)
 
None RotateObject (float amount, RotationAxis_e axis)
 
None TranslateObject (float x, float y, float z)
 
None ScaleObject (float x, float y, float z, Vertex *anchor=NULL)
 
None LineWidth (float width)
 
float LineWidth ()
 
LineStyle_e LineStyle ()
 
None LineStyle (LineStyle_e style)
 
GlsColor LineColor ()
 
None LineColor (GlsColor color)
 
GlsColor FillColor ()
 
None FillColor (GlsColor color)
 
None GetExtents (Vector &min, Vector &max)
 
bool HasUserDefinedAttribute (str attribName)
 
std::map< str, str > GetUserDefinedAttributes ()
 
UserDefinedValueAttributeList GetAllUserDefinedAttributes ()
 
str GetUserDefinedAttributeValue (str attribName)
 
 typemap (check) str attribName
 
None SetUserDefinedAttributeValue (str attribName, str value)
 
DisplayObjectGetParent ()
 
DocumentGetDocument ()
 
str AlternateClassName ()
 
None AlternateClassName (str name)
 
str GetAlternateClassHeaderFile ()
 
None SetAlternateClassHeaderFile (str name)
 
str GetResources ()
 
str GetRuntimeResources (bool recursive)
 
str GetAttributeType (str attribName)
 
str GetAttributeValuestr (str attribName)
 
None SetAttributeValuestr (str attribName, str value)
 
int RegisterObserver (str attribName, PyObject *pyfunc)
 
None UnregisterObserver (str attribName, int id)
 
list GetNormals ()
 
None SetNormals (list &normals)
 
list GetExtraAttributes ()
 
DisplayObjectCloneObject ()
 
None CopyProperties (DisplayObject *sourceObj)
 
None SetLocation (Vector loc)
 
GlsMatrixAffine GetObjectCoordinatesTransform (DisplayObject *targetObject)
 
None CalculateParentBoundingBox ()
 
None SetOrigin (Vertex &vert)
 

Static Public Member Functions

static GlsOdometerCastToGlsOdometer (DisplayObject *obj)
 
- Static Public Member Functions inherited from Group
static GroupCastToGroup (DisplayObject *obj)
 

Additional Inherited Members

- Static Public Attributes inherited from Group
static int DEFAULT_GROUP_LOCATION = -1
 
- Static Public Attributes inherited from DisplayObject
static int TEXTURE_INDEX_NONE = -1
 

Detailed Description

Plug-in used to create Odometers in GL Studio.

Member Enumeration Documentation

◆ GlsOdometerBehaviorType_e

Enumerator
BEHAVIOR_ANALOG 
  • Wheels will roll between numbers based on the RolloverThreshold
BEHAVIOR_DIGITAL 
  • Wheels will display only whole numbers.

◆ GlsOdometerGeometryType_e

Enumerator
GEOMETRY_2D 
  • Texture is translated on the object based on the TextureScale.
GEOMETRY_3D 
  • The wheels are rotated about the Y-AXIS of the DCS based on the value of DegreesPerDigit.

Constructor & Destructor Documentation

◆ GlsOdometer() [1/2]

GlsOdometer::GlsOdometer ( )

Creates an empty odometer.

◆ GlsOdometer() [2/2]

GlsOdometer::GlsOdometer ( DisplayObjectArray objs)

Creates an odometer using the supplied objects.

Parameters
objsObjects to be used to create the odometer

Member Function Documentation

◆ BehaviorType() [1/2]

GlsOdometerBehaviorType_e GlsOdometer::BehaviorType ( )

Get the Behavior Type controls the "Rollover" behavior of the odometer.

Returns
GlsOdometerBehaviorType_e the current behavior type of the odometer

◆ BehaviorType() [2/2]

None GlsOdometer::BehaviorType ( GlsOdometerBehaviorType_e  value)

Set the Behavior Type controls the "Rollover" behavior of the odometer.

BEHAVIOR_ANALOG - Wheels will roll between numbers based on the RolloverThreshold BEHAVIOR_DIGITAL - Wheels will display only whole numbers.

Parameters
valueBehavior Type to be used with this odometer

◆ CastToGlsOdometer()

static GlsOdometer * GlsOdometer::CastToGlsOdometer ( DisplayObject obj)
static

Casts a DisplayObject to a GlsOdometer NOTE: Be sure to check if the returned class !isNull, to see if the cast was successful.

Parameters
objthe DisplayObject to be cast to an Odometer

◆ DegreesPerDigit() [1/2]

float GlsOdometer::DegreesPerDigit ( )

Get the current degrees per digit for the odometer.

Returns
float the current degrees per digit of the odometer

◆ DegreesPerDigit() [2/2]

None GlsOdometer::DegreesPerDigit ( float &  value)

Set the DegreesPerDigit which is the number of degrees the wheels should be rotated for each digit.


This value is only used when GeometryType == GEOMETRY_3D.

Parameters
valuedegrees per digit to be used with this odometer

◆ DegreesPerDigitOverride() [1/2]

bool GlsOdometer::DegreesPerDigitOverride ( )

Get the degrees per digit override flag state of the odometer.

Returns
bool the degrees per digit override state of the odometer

◆ DegreesPerDigitOverride() [2/2]

None GlsOdometer::DegreesPerDigitOverride ( bool &  value)

Set the degrees per digit override flag state of the odometer.

Parameters
valuethe new degrees per digit override state of the odometer

◆ GeometryType() [1/2]

GlsOdometerGeometryType_e GlsOdometer::GeometryType ( )

Get the GeometryType of the odometer.

Returns
GlsOdometerGeometryType_e the current geometry type of the odometer

◆ GeometryType() [2/2]

None GlsOdometer::GeometryType ( GlsOdometerGeometryType_e  value)

Set the GeometryType controls the method used to "move" the wheels.

GEOMETRY_2D - Texture is translated on the object based on the TextureScale. GEOMETRY_3D - The wheels are rotated about the Y-AXIS of the DCS based on the value of DegreesPerDigit.

Parameters
valueGeometry Type to be used with this odometer

◆ GetBaseSystem()

int GlsOdometer::GetBaseSystem ( )

Gets the base system of the odometer.

Returns
int value of the base system

◆ GetInitalValue()

float GlsOdometer::GetInitalValue ( )

Deprecated in favor of GetInitialValue.

This property is here for backwards compatibility.

Returns
float value of the initial value
Deprecated:
Use GetInitialValue()

◆ GetInitialValue()

float GlsOdometer::GetInitialValue ( )

Gets the initial value of the odometer.

Returns
float value of the initial value

◆ GetMaxValue()

float GlsOdometer::GetMaxValue ( )

Gets the maximum value of the odometer.

Returns
float value of the maximum value

◆ GetMinValue()

float GlsOdometer::GetMinValue ( )

Gets the minimum value of the odometer.

Returns
float value of the minimum value

◆ NumberOfWheels()

int GlsOdometer::NumberOfWheels ( )

Get the current number of wheels for the odometer.

Returns
int the current number of wheels for the odometer

◆ OrderOfMagnitude()

int GlsOdometer::OrderOfMagnitude ( )

Get the current order of magnitude for the odometer.

Returns
int the current order of magnitude of the odometer

◆ RolloverThreshold()

float GlsOdometer::RolloverThreshold ( )

Get the current rollover threshold for the odometer.

Returns
float the current rollover threshold of the odometer

◆ SetBaseSystem()

None GlsOdometer::SetBaseSystem ( int  val)

Sets the base system for the odometer.

The default is base 10.

Parameters
valvalue to set as the base system

◆ SetInitalValue()

None GlsOdometer::SetInitalValue ( float  val)

Deprecated in favor of SetInitialValue.

This property is here for backwards compatibility.

Parameters
valvalue to set as the initial value
Deprecated:
Use SetInitialValue(float val)

◆ SetInitialValue()

None GlsOdometer::SetInitialValue ( float  val)

Sets the initial value of the odometer.

Parameters
valvalue to set as the initial value

◆ SetMaxValue()

None GlsOdometer::SetMaxValue ( float  val)

Sets the maximum value of the odometer.

Parameters
valvalue to set as the maximum value

◆ SetMinValue()

None GlsOdometer::SetMinValue ( float  val)

Sets the minimum value of the odometer.

Parameters
valvalue to set as the minimum value

◆ TextureScale() [1/2]

float GlsOdometer::TextureScale ( )

Get the current TextureScale for the odometer.

Returns
float the current texture scale of the odometer

◆ TextureScale() [2/2]

None GlsOdometer::TextureScale ( float &  value)

Set the TextureScale which is the amount that the texture should move for each digit.

The formula to determine this is: (Pixels per digit)/(Texture height). This value is only used when GeometryType == GEOMETRY_2D.

Parameters
valueTexture scale to be used with this odometer

◆ TextureScaleOverride() [1/2]

bool GlsOdometer::TextureScaleOverride ( )

Get the texture scale override flag state of the odometer.

Returns
bool the texture scale override state of the odometer

◆ TextureScaleOverride() [2/2]

None GlsOdometer::TextureScaleOverride ( bool &  value)

Set the texture scale override flag state of the odometer.

Parameters
valuethe new texture scale override state of the odometer

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