Click or drag to resize
SoModelScaleElement Class

Stores the current model scale.

Inheritance Hierarchy

Namespace: OIV.Inventor.Elements
Assembly: OIV.Inventor (in OIV.Inventor.dll) Version: 2024.2.2.0 (10.16.2.0)
Syntax
public class SoModelScaleElement : SoModelMatrixElement

The SoModelScaleElement type exposes the following members.

Methods
  NameDescription
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodStatic memberGetClassStackIndex Obsolete.

Returns the stack id for this element.

Public methodGetHashCode
Overrides GetHashCode().
(Inherited from SoNetBase.)
Public methodGetScaleFactor

Returns the of this element model scale - if the overall SoModelMatrix is diagonazible Not all the SoModelMatrix are diagonalizable because a OIV.Inventor.Nodes.SoMatrixTransform or a direct set of the SoModelMatrix with a not diagonalizable matrix, so the getScaleFactor can return a vector containing one or more NaN or zeros.

Public methodStatic memberGetScaleFactor(SoState)

Returns current model scale - if the overall SoModelMatrix is diagonazible Not all the SoModelMatrix are diagonalizable because a OIV.Inventor.Nodes.SoMatrixTransform or a direct set of the SoModelMatrix with a not diagonalizable matrix, so the getScaleFactor can return a vector containing one or more NaN or zeros.

Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodPop

Pops element.

(Inherited from SoElement.)
Public methodPush

Overrides OIV.Inventor.Elements.SoModelMatrixElement.Push(OIV.Inventor.Misc.SoState) method to copy values from next instance in the stack.

(Inherited from SoModelMatrixElement.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Remarks

This is just to redefine the match method to track just the scale portion of the model matrix and to use this element to filter changes not related to scaling. Not all the SoModelMatrix are diagonalizable because a OIV.Inventor.Nodes.SoMatrixTransform or a direct set of the SoModelMatrix with a not diagonalizable matrix, so the getScaleFactor can return a vector containing one or more NaN or zeros. This element has some limitation related to the way transformation also rigid ones are accumulated. So please use it with attention also because for the moment the SbMatrix.getTransform method does not return any status

This element stores just the scale pportion of the current model matrix the cumulative transformation applied to subsequent shapes. Because the matrix is cumulative, this class is derived from OIV.Inventor.Elements.SoAccumulatedElement. The OIV.Inventor.Elements.SoModelMatrixElement.Set(OIV.Inventor.Misc.SoState, OIV.Inventor.Nodes.SoNode, OIV.Inventor.SbMatrix, System.Boolean) method replaces the current matrix, while all the others (OIV.Inventor.Elements.SoModelMatrixElement.Mult(OIV.Inventor.Misc.SoState, OIV.Inventor.Nodes.SoNode, OIV.Inventor.SbMatrix), OIV.Inventor.Elements.SoModelMatrixElement.TranslateBy(OIV.Inventor.Misc.SoState, OIV.Inventor.Nodes.SoNode, OIV.Inventor.SbVec3f), etc.) multiply into it. Node id's of the nodes that affect the element are accumulated properly.

See Also