Cross product
Compute distance between 2 points.
Dot product
Return 1 if parallell, -1 if anti-parallell and 0 if not parallell.
Return 1 if perpendicular and 0 if not perpendicular.
Create a vector perpendicular to v
AABBox(min=(-0.5, -0.5, -0.5), max=(0.5, 0.5, 0.5))
Class representing an Axis Aligned Bounding Box
Adjust bounds to include point.
Adjust bounds to include point.
Set bounding box in invalid state.
Check if point is inside box.
Check validity
Return a new bounding box which is a union of the arguments.
x.__eq__(y) <==> x==y
x.__ge__(y) <==> x>=y
x.__gt__(y) <==> x>y
x.__init__(...) initializes x; see help(type(x)) for signature
x.__le__(y) <==> x<=y
x.__lt__(y) <==> x<y
x.__ne__(y) <==> x!=y
Return string representation of a box.
Return string representation of a box.
Calculate center of box
Return diagonal as a vector
max: geotools.Point
min: geotools.Point
Return radius of the sphere enclosing the box
Calculate volume of box
Camera(projection=PARALLEL)
Modify the loc, dir & up variables and then call updateFrame to set the up the camera frame vectors.
Projection : | PARALLEL or PROJECTED projection type |
---|---|
Loc : | camera location |
Dir : | from camera towards view (nonzero and not parallel to up) |
Up : | (nonzero and not parallel to dir) |
X : | camera frame X vector |
Y : | camera frame Y vector |
Z : | camera frame Z vector |
Target : | fixed point used in camera rotations and camera dolly operations. |
Get camera dolly vector for the given screen coordinates
Pan camera due to mouse motion.
Rotate camera and update frame.
Rotate camera according to dx, dy mouse motion.
setFrustumAspect() changes the larger of the frustum’s widht/height so that the resulting value of width/height matches the requested aspect. The camera angle is not changed. If you change the shape of the view port with a call setViewportSize(), then you generally want to call SetFrustumAspect().
Location of viewport in pixels. These are provided so you can set the port you are using and get the appropriate transformations to and from screen space.
X: geotools.Vector
Y: geotools.Vector
Z: geotools.Vector
x.__init__(...) initializes x; see help(type(x)) for signature
dir: geotools.Vector
fvBottom: ‘double’
fvFar: ‘double’
fvLeft: ‘double’
fvNear: ‘double’
fvRight: ‘double’
fvTop: ‘double’
loc: geotools.Point
projection: ‘int’
scrBottom: ‘int’
scrFar: ‘double’
scrLeft: ‘int’
scrNear: ‘double’
scrRight: ‘int’
scrTop: ‘int’
target: geotools.Point
up: geotools.Vector
Plane(origin=<???>, xaxis=<???>, yaxis=<???>)
Class representing a mathematical infinite plane.
Return closest point on plane
Signed distance from plane to pnt
Flip direction of normal
Find intersection with line defined by the points start and end
Transform plane
a: ‘double’
b: ‘double’
c: ‘double’
d: ‘double’
origin: geotools.Point
xaxis: geotools.Vector
yaxis: geotools.Vector
zaxis: geotools.Vector
Point(*args)
Class representing a 3D point in space
Compute distance between 2 points.
Check if arg is all zeros.
Set one or more coordinates. accept both multiple argument and sequence like arguments.
Return absolute value of point: abs(v)
Point addition The arguments must be of same length
Point division by scalar.
x.__eq__(y) <==> x==y
x.__ge__(y) <==> x>=y
Override the list __getitem__ function to return a new point rather than a list.
x.__gt__(y) <==> x>y
Inline Point addition ( p1 += p2) The arguments must be of same length
Inline Point division by scalar. (p1 /= 2.)
Inline Point multiplication (v1 *= s1) We accept multiplication by scalar and a 4x4 transformation matrix.
We accept both multiple argument and sequence like arguments.
Inline Point subtraction ( p1 -= p2) The arguments must be of same length
x.__le__(y) <==> x<=y
Length of sequence
x.__lt__(y) <==> x<y
Point multiplication We accept multiplication by a scalar, and a 4x4 transformation matrix.
x.__ne__(y) <==> x!=y
Return negated value of point: -v
Return positive value of point: +v
x.__radd__(y) <==> y+x
x.__rdiv__(y) <==> y/x
Return string representation of a point.
x.__rmul__(y) <==> y*x
x.__rsub__(y) <==> y-x
Return string representation of a point.
Point subtraction The arguments must be of same length
x: ‘double’
y: ‘double’
z: ‘double’
Quaternion(*args)
Class representing a quaternion usefull for rotation transformations.
Inverse rotation. We accept point as multiple argument, sequence like arguments and sequence of multiple points.
Rotation. We accept point as multiple argument, sequence like arguments and sequence of multiple points.
Set one or more coordinates. accept both multiple argument and sequence like arguments.
x.__getitem__(y) <==> x[y]
x.__imul__(y) <==> x*=y
We accept both multiple argument and sequence like arguments.
Length of sequence
x.__mul__(y) <==> x*y
Return string representation of a Quaternion.
x.__rmul__(y) <==> y*x
Return string representation of a Quaternion.
Calculate lenght of Quaternion
Calculate squared lenght of Quaternion
create the coresponding transformation matrix
w: ‘double’
x: ‘double’
y: ‘double’
z: ‘double’
Transform(*args)
Matrix of 4x4 size. Typical 3D transformation matrix.
Determinand of matrix
set identity matrix
Inverse of matrix
We accept point as multiple argument, sequence like arguments and sequence of multiple points.
Construct 4x4 rotation matrix.
We accept both multiple argument and sequence like arguments.
We accept both multiple argument and sequence like arguments.
We accept both multiple argument and sequence like arguments.
We accept both multiple argument and sequence like arguments.
We accept 16 arguments setting all values. Sequence of sequence of size 3x3 setting all values.
m11 m12 m13 m14
We accept both multiple argument and sequence like arguments.
Transpose of matrix
set all values to zero
Return absolute value of matrix: abs(m)
Matrix addition They must be of same shape.
Matrix division We accept only division by a scalar.
Return rows as a tuple object
Inline Matrix addition ( m1 += m2) They must be of same shape.
Matrix multiplication We accept both multiplication by a scalar and a other matrix. This is the matrix multiplication known from linear algebra.
We accept 16 arguments setting all values. Sequence of sequence of size 3x3 setting all values.
m11 m12 m13 m14
Inline Matrix subtraction ( m1 -= m2) They must be of same shape.
We have 4 rows
Matrix multiplication We accept both multiplication by a scalar and a other matrix. This is the matrix multiplication known from linear algebra. See the Matrix.dot function for this.
Return negated value of matrix: -v
Return positive value of matrix: +v
x.__radd__(y) <==> y+x
x.__rdiv__(y) <==> y/x
Return string representation of a matrix.
x.__rmul__(y) <==> y*x
x.__rsub__(y) <==> y-x
Return string representation of a matrix.
Matrix subtraction They must be of same shape.
Compute distance between 2 points.
Check if arg is all zeros.
Set one or more coordinates. accept both multiple argument and sequence like arguments.
Normalize the vector (arg.lenght = 1.)
Calculate lenght of vector
Calculate squared lenght of vector
x: ‘double’
y: ‘double’
z: ‘double’