CoordinateSystem
¶
A class representing a 3d coordinate system.
Attributes:
Name | Type | Description |
---|---|---|
origin |
np.ndarray |
the origin of this coordinate system (relative to its parent) |
base |
np.ndarray |
the base of this coordinate system (relative to its parent) |
assume_base(self)
¶
Assumes the base of this segment if not enough base vectors are set. The assumption is based on the right-hand-rule cross product if two base vectors are given.
Source code in core/spatial/CoordinateSystem.py
51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 |
|
clear_base(self)
¶
Clears the base of this segment.
Source code in core/spatial/CoordinateSystem.py
44 45 46 47 48 49 |
|
rotate(self, rotation, inplace=False)
¶
Rotates the coordinate system according to the given rotation.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
rotation |
Rotation |
the rotation to apply |
required |
inplace |
bool |
flag, indicating whether to rotate in place or around its origin |
False |
Source code in core/spatial/CoordinateSystem.py
32 33 34 35 36 37 38 39 40 41 42 |
|
translate(self, vector)
¶
Translates the coordinate system by the given 3d vector.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
vector |
ndarray |
the translation vector to apply |
required |
Source code in core/spatial/CoordinateSystem.py
24 25 26 27 28 29 30 |
|