Matrix4x4¶
Inheritance diagram¶
Classes¶
Matrix4x4¶
-
class
ORSModel.ors.Matrix4x4¶ Bases:
ORSModel.ors.Unmanagedbrief_description: A wrapper to a 3D matrix. author: Eric Fournier. All other members of ORS participated. version: 1.0 date: Jan 2005
-
asRotationMatrix(self, inputVector: ORSModel.ors.Vector3) → None¶ As rotation matrix from quaternion.
Parameters: inputVector (ORSModel.ors.Vector3) –
-
copy(self) → Matrix4x4¶ Gets a copy.
Returns: output (ORSModel.ors.Matrix4x4) –
-
createFromPythonRepresentation(aPythonRepresentation: str) → Matrix4x4¶ Create a Matrix from a python representation static method.
Parameters: aPythonRepresentation (str) – aPythonRepresentation (an wstring) Returns: output (ORSModel.ors.Matrix4x4) – a Matrix4x4 (Matrix4x4)
-
getClassNameStatic() → str¶ getClassNameStatic
Returns: output (str) –
-
getInverted(self) → Matrix4x4¶ Gets an inverted matrix.
Note
The receiver is not affected.
Returns: output (ORSModel.ors.Matrix4x4) – an inverted matrix (an Matrix4x4)
-
getIsEqualTo(self, aMatrix4x4: ORSModel.ors.Matrix4x4) → bool¶ Checks for equality to another matrix.
Parameters: aMatrix4x4 (ORSModel.ors.Matrix4x4) – a matrix (a Matrix4x4) Returns: output (bool) – TRUE if the matrices are equal, FALSE otherwise
-
getIsIdentity(self) → bool¶ Tests for identity.
Returns: output (bool) –
-
getMultiply(self, IMatrix: ORSModel.ors.Matrix4x4) → Matrix4x4¶ Matrix4x4 product.
Parameters: IMatrix (ORSModel.ors.Matrix4x4) – Returns: output (ORSModel.ors.Matrix4x4) –
-
getScale(self) → Vector3¶ Returns: output (ORSModel.ors.Vector3) –
-
getTransformedBoundedPlane(self, inputBoundedPlane: ORSModel.ors.Rectangle) → Rectangle¶ Applies a matrix transformation to a bounded plane.
Parameters: inputBoundedPlane (ORSModel.ors.Rectangle) – Returns: output (ORSModel.ors.Rectangle) –
-
getTransformedBox(self, inputBox: ORSModel.ors.Box) → Box¶ Applies a matrix transformation to a box.
Parameters: inputBox (ORSModel.ors.Box) – Returns: output (ORSModel.ors.Box) –
-
getTransformedCoordinate(self, inputCoordinate: ORSModel.ors.Vector3) → Vector3¶ Applies a matrix transformation to an augmented vector ([x, y, z, 1]).
Parameters: inputCoordinate (ORSModel.ors.Vector3) – Returns: output (ORSModel.ors.Vector3) –
-
getTransformedLine(self, inputLine: ORSModel.ors.Line) → Line¶ Applies a matrix transformation to a line.
Parameters: inputLine (ORSModel.ors.Line) – Returns: output (ORSModel.ors.Line) –
-
getTransformedLineSegment(self, inputLineSegment: ORSModel.ors.LineSegment) → LineSegment¶ Applies a matrix transformation to a line segment.
Parameters: inputLineSegment (ORSModel.ors.LineSegment) – Returns: output (ORSModel.ors.LineSegment) –
-
getTransformedOrientedPlane(self, inputOrientedPlane: ORSModel.ors.OrientedPlane) → OrientedPlane¶ Applies a matrix transformation to an oriented plane.
Parameters: inputOrientedPlane (ORSModel.ors.OrientedPlane) – Returns: output (ORSModel.ors.OrientedPlane) –
-
getTransformedPlane(self, inputPlane: ORSModel.ors.Plane) → Plane¶ Applies a matrix transformation to a plane.
Parameters: inputPlane (ORSModel.ors.Plane) – Returns: output (ORSModel.ors.Plane) –
-
getTransformedVector(self, inputVector: ORSModel.ors.Vector3) → Vector3¶ Applies a matrix transformation to an augmented vector ([x, y, z, 0]).
Parameters: inputVector (ORSModel.ors.Vector3) – Returns: output (ORSModel.ors.Vector3) –
-
getTranslation(self) → Vector3¶ Gets the translation vector.
Returns: output (ORSModel.ors.Vector3) –
-
getTransposed(self) → Matrix4x4¶ Gets the transpose of the matrix.
Returns: output (ORSModel.ors.Matrix4x4) –
-
getValue(self, row: int, column: int) → float¶ Gets a value from the matrix.
Note
Row and column are both between 0 and 3.
Parameters: - row (int) – row (an int)
- column (int) – column (an int)
Returns: output (float) – a double
-
multiply(self, IMatrix: ORSModel.ors.Matrix4x4) → None¶ Multiplies the matrix by another matrix.
Note
The receiver is modified.
Parameters: IMatrix (ORSModel.ors.Matrix4x4) – a matrix to multiply with (an Matrix4x4)
-
setAsRotation(self, axisOfRotation: ORSModel.ors.Vector3, angleInRadian: float) → None¶ As rotation matrix from rotation axis and angle.
Parameters: - axisOfRotation (ORSModel.ors.Vector3) –
- angleInRadian (float) –
-
setScale(self, scaleVector: ORSModel.ors.Vector3) → None¶ Sets the scale vector.
Parameters: scaleVector (ORSModel.ors.Vector3) –
-
setTranslation(self, translation: ORSModel.ors.Vector3) → None¶ Sets the translation vector.
Parameters: translation (ORSModel.ors.Vector3) –
-
setValue(self, row: int, column: int, value: float) → None¶ Sets a value in the matrix.
Note
Row and column are both between 0 and 3.
Parameters: - row (int) – row (an int)
- column (int) – column (an int)
- value (float) – a double value
-
setValues(self, values: float) → None¶ Sets the matrix values from an array of doubles.
Note
The array of doubles should contain 16 double (4 rows X 4 colums).
Parameters: values (float) – an array of 16 float values (a doublePtr)
-
setupAsIdentity(self) → None¶ Initializes the matrix.
-
Unmanaged¶
-
class
ORSModel.ors.Unmanaged Bases:
ORSModel.ors.ORSBaseClassbrief_description: Abstract class for objects that are not managed by the core library. author: Eric Fournier. All other members of ORS participated. version: 1.0 date: Jan 2005
-
atomicLoad(sFilename: str) → Unmanaged Creates an object from a file where an object was saved.
Parameters: sFilename (str) – path of the file to load Returns: output (Unmanaged) – a managed object, or none() if the load fails
-
atomicSave(self, aFilename: str) → int Saves the object to a file.
Parameters: aFilename (str) – path of the file to save Returns: output (int) – 0 if successful, otherwise an error code
-
createFromPythonRepresentation(aPythonRepresentation: str) → Unmanaged Create aUnmanaged Object from a python representation a static method.
Parameters: aPythonRepresentation (str) – Returns: output (ORSModel.ors.Unmanaged) –
-
fromPythonRepresentation(self, aPythonRepresentation: str) → bool Create aUnmanaged object from a Python string representation.
Parameters: aPythonRepresentation (str) – a Python evaluable string representation (a string) Returns: output (bool) – TRUE if parsing worked, FALSE otherwise (a bool)
-
classmethod
getAllSubclasses(outputCollection=None)
-
classmethod
getClassDenomination()
-
static
getClassFromProgId(progId)
-
getClassName(self) → str Retrieves the class name of the core object wrapped by this Interface object.
Returns: output (str) –
-
getClassNameStatic() → str getClassNameStatic
Returns: output (str) –
-
getDataChecksum(self) → str Returns: output (str) –
-
getIsInstanceOf(self, pProgId: str) → bool Queries the object to know if it is an instance of a certain class.
Parameters: pProgId (str) – Returns: output (bool) –
-
classmethod
getIsSubclassOf(parentClass)
-
getPythonRepresentation(self) → str Gets a Python evaluable string representation.
Returns: output (str) –
-
isNone(self) → bool Checks if the receiver is none.
Returns: output (bool) –
-
isNotNone(self) → bool Checks if the receiver is not none.
Returns: output (bool) –
-
none() → Unmanaged Returns: output (Unmanaged) –
-
ORSBaseClass¶
-
class
ORSModel.ors.ORSBaseClass brief_description: An abstract class from which all objects issued from the author: Eric Fournier. All other members of ORS participated. version: 1.0 date: Jan 2005
-
getPythonTraceBack() → typing.List[str] Set the python traceback for a call from python.
Returns: output (typing.List[str]) –
-
isManaged(self) → bool Returns: output (bool) –
-
isNone(self) → bool Returns: output (bool) –
-
setPythonTraceBack(tb: ORSModel.ors.typing.List[str]) → None Set the python traceback for a call from python.
Parameters: tb (typing.List[str]) –
-