|
Uranium
Application Framework
|
Simple 3D-vector class based on numpy arrays. More...
Public Member Functions | |
| def | __init__ |
| Initialize a new vector. More... | |
| def | getData (self) |
| Get numpy array with the data. More... | |
| def | setRoundDigits |
| def | x (self) |
| Return the x component of this vector. | |
| def | y (self) |
| Return the y component of this vector. | |
| def | z (self) |
| Return the z component of this vector. | |
| def | set |
| def | angleToVector |
| Get the angle from this vector to another. | |
| def | normalized (self) |
| def | length (self) |
| def | dot (self, other) |
| def | cross (self, other) |
| def | multiply |
| def | preMultiply |
| def | scale |
| Scale a vector by another vector. More... | |
| def | __eq__ (self, other) |
| def | equals |
| Compares this vector to another vector. More... | |
| def | __add__ (self, other) |
| def | __iadd__ (self, other) |
| def | __sub__ (self, other) |
| def | __isub__ (self, other) |
| def | __mul__ (self, other) |
| def | __imul__ (self, other) |
| def | __rmul__ (self, other) |
| def | __truediv__ (self, other) |
| def | __itruediv__ (self, other) |
| def | __rtruediv__ (self, other) |
| def | __neg__ (self) |
| def | __repr__ (self) |
| def | __str__ (self) |
| def | __lt__ (self, other) |
| def | __gt__ (self, other) |
| def | __le__ (self, other) |
| def | __ge__ (self, other) |
Public Attributes | |
| round_digits | |
Static Public Attributes | |
| Null = None | |
| Unit_X = None | |
| Unit_Y = None | |
| Unit_Z = None | |
Simple 3D-vector class based on numpy arrays.
This class represents an immutable 3-dimensional vector.
| def UM.Math.Vector.Vector.__init__ | ( | self, | |
| x | |||
| ) |
Initialize a new vector.
| x | X coordinate of vector. |
| y | Y coordinate of vector. |
| z | Z coordinate of vector. |
| def UM.Math.Vector.Vector.equals | ( | self, | |
| other | |||
| ) |
Compares this vector to another vector.
| epsilon | optional tolerance value for the comparision. |
| def UM.Math.Vector.Vector.getData | ( | self, | |
| numpy, | |||
| ndarray | |||
| ) |
Get numpy array with the data.
| def UM.Math.Vector.Vector.scale | ( | self, | |
| other | |||
| ) |
Scale a vector by another vector.
This will do a component-wise multiply of the two vectors.