VisimBox 1.0 VisimBox 3d simulation and visualisation ToolBox

- Main Page
- Packages
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Properties | Events
VisiMath.ITransformation Interface Reference

Interface for transformations. Returns Matrix4x4 transformation, but information about transf. can be stored in any way. In some cases storing just the position is enough, or rotation can be used in different ways. It's also posible to create transformation with specified constraints on movement and rotation For the performance reasons it's important to select right type of transformation. For example if you'll be using RPY rotations alot, it's better to use RPY transfromation then generic which has to recalculate values on every request. Use one of the derived classes, for example Transformation. More...

Inheritance diagram for VisiMath.ITransformation:

List of all members.

## Public Member Functions
void | GetAll (out Vector3 pos, out Vector3 rot, out Vector3 scale, out float uniscale)
| Used to quickly get all of the properties with one call.
void | PushState ()
| Pushes current state of transformation to internal stack.
void | PopState ()
| Pops current state of transformation from internal state stack and sets it as current.
void | UndoPushState ()
| Pops state of transformation from internal stack.
void | Move (ref Vector3 movement)
| Move transformation in world coordinates (translation)
void | Move (Vector3 movement)
| Move transformation in world coordinates (translation)
void | Move (ref Quaternion q, float distance)
| Move transformation in world coordinates (translation) in specified angle and distance.
void | Move (ref Vector3 axis, float angle, float distance)
| Move transformation in world coordinates (translation) in specified angle and distance.
void | Move (ref Vector3 direction, float distance)
| Move transformation in world coordinates (translation) in directional vector and distance.
void | MoveLocal (ref Vector3 movement)
| Move transformation in local coordinates.
void | MoveLocal (ref Quaternion q, float distance)
| Move transformation in local coordinates (translation) in specified angle and distance.
void | MoveLocal (ref Vector3 axis, float angle, float distance)
| Move transformation in local coordinates (translation) in specified angle and distance.
void | MoveLocal (ref Vector3 direction, float distance)
| Move transformation in local coordinates (translation) in directional vector and distance.
void | Rotate (ref Quaternion q)
| Rotate whole transformation in world coordinates.
void | Rotate (ref Vector3 axis, float angle)
| Rotate whole transformation in world coordinates.
void | Rotate (ref Vector3 rpy)
| Rotate whole transformation in world coordinates.
void | Rotate (Vector3 rpy)
| Rotate whole transformation in world coordinates.
void | RotateLocal (ref Quaternion q)
| Rotate in local coordinates (around the local zero)
void | RotateLocal (ref Vector3 axis, float angle)
| Rotate in local coordinates (around the local zero)
void | RotateLocal (ref Vector3 rpy)
| Rotate in local coordinates (around the local zero)
void | RotateLocal (Vector3 rpy)
| Rotate in local coordinates (around the local zero)
void | Pitch (float angle)
| Rotate in local coordinates (changes pitch)
void | Yaw (float angle)
| Rotate in local coordinates (changes yaw)
void | Roll (float angle)
| Rotate in local coordinates (changes roll)
void | Rescale (float scalefactor)
| Rescale transformation by uniform number.
void | Rescale (ref Vector3 scalefactor)
| Rescale transformation by non-uniform vecotr.
void | RescaleLocal (float scalefactor)
| Local uniform rescale (changes basic scale of the transformation)
void | RescaleLocal (ref Vector3 scalefactor)
| Local non-uniform rescale (changes basic scale of the transformation)
Vector3 | GetPointInWorldSpace (Vector3 point)
| Returns location of point in local space to the world space.
ITransformation | GetCopy ()
| Returns copy of the transformation.
## Properties
Matrix4 | TransMatrix`[get, set]`
| Transformation matrix - Every derived class must return correct transformation matrix.
Vector3 | Position`[get, set]`
| Position in vector.
float | X`[get, set]`
| X position.
float | Y`[get, set]`
| Y position.
float | Z`[get, set]`
| Z position.
Quaternion | Rotation`[get, set]`
| Rotation in quaternion.
Vector3 | RPY`[get, set]`
| Rotation in roll-pitch-yaw format.
float | PitchAngle`[get, set]`
| Pitch rotation.
float | YawAngle`[get, set]`
| Yaw rotation.
float | RollAngle`[get, set]`
| Roll rotation.
float | UniformScale`[get, set]`
| Uniform scale if used - should return zero if scale is not uniform.
Vector3 | Scale`[get, set]`
| Scale in different axis.
bool | Movable`[get]`
| True if object supports movement.
bool | Rotable`[get]`
| True if object supports rotation.
bool | Scalable`[get]`
| True if object supports scaling.
## Events
TransformationCallback | ChangeCallback
| Callback for any transformation change.

## Detailed Description

Interface for transformations. Returns Matrix4x4 transformation, but information about transf. can be stored in any way. In some cases storing just the position is enough, or rotation can be used in different ways. It's also posible to create transformation with specified constraints on movement and rotation For the performance reasons it's important to select right type of transformation. For example if you'll be using RPY rotations alot, it's better to use RPY transfromation then generic which has to recalculate values on every request. Use one of the derived classes, for example Transformation.

## Member Function Documentation

void VisiMath.ITransformation.GetAll | ( | out Vector3 | pos,
|  | out Vector3 | rot,
|  | out Vector3 | scale,
|  | out float | uniscale
| ) |  |

Used to quickly get all of the properties with one call.

Parameters:

  pos | Position vector
  rot | RPY rotation
  scale | Scale
  uniscale | Uniform Scale

Implemented in VisiMath.BaseTransformation, VisiMath.MoveTransformation, VisiMath.RPYTransformation, VisiMath.QTransformation, and VisiMath.Transformation.

ITransformation VisiMath.ITransformation.GetCopy | ( |  | ) |

Returns copy of the transformation.

Returns:

Implemented in VisiMath.BaseTransformation, VisiMath.MoveTransformation, VisiMath.RPYTransformation, VisiMath.QTransformation, VisiMath.Transformation, VisimBox.Renderer.StandardCamera, and VisimBox.Renderer.FPSCamera.

Vector3 VisiMath.ITransformation.GetPointInWorldSpace | ( | Vector3 | point | ) |

Returns location of point in local space to the world space.

Parameters:

  point | position in local space

Returns:
  position in world space

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Move | ( | ref Vector3 | movement | ) |

Move transformation in world coordinates (translation)

Parameters:

  movement | Translation vector

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Move | ( | ref Vector3 | axis,
|  | float | angle,
|  | float | distance
| ) |  |

Move transformation in world coordinates (translation) in specified angle and distance.

Parameters:

  axis | Rotation axis
  angle | Rotation angle
  distance | distance

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Move | ( | ref Vector3 | direction,
|  | float | distance
| ) |  |

Move transformation in world coordinates (translation) in directional vector and distance.

Parameters:

  direction | Directional vector (should be normalized)
  distance | distance

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Move | ( | ref Quaternion | q,
|  | float | distance
| ) |  |

Move transformation in world coordinates (translation) in specified angle and distance.

Parameters:

  q | rotation
  distance | distance

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Move | ( | Vector3 | movement | ) |

Move transformation in world coordinates (translation)

Parameters:

  movement | Translation vector

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.MoveLocal | ( | ref Vector3 | movement | ) |

Move transformation in local coordinates.

Parameters:

  movement | Translation vector

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.MoveLocal | ( | ref Quaternion | q,
|  | float | distance
| ) |  |

Move transformation in local coordinates (translation) in specified angle and distance.

Parameters:

  q | rotation
  distance | distance

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.MoveLocal | ( | ref Vector3 | axis,
|  | float | angle,
|  | float | distance
| ) |  |

Move transformation in local coordinates (translation) in specified angle and distance.

Parameters:

  axis | rotation axis
  angle | angle
  distance | distance

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.MoveLocal | ( | ref Vector3 | direction,
|  | float | distance
| ) |  |

Move transformation in local coordinates (translation) in directional vector and distance.

Parameters:

  direction | Directional vector (should be normalized)
  distance | distance

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Pitch | ( | float | angle | ) |

Rotate in local coordinates (changes pitch)

Parameters:

  angle | angle in radians

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.PopState | ( |  | ) |

Pops current state of transformation from internal state stack and sets it as current.

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.PushState | ( |  | ) |

Pushes current state of transformation to internal stack.

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Rescale | ( | ref Vector3 | scalefactor | ) |

Rescale transformation by non-uniform vecotr.

Parameters:

  scalefactor | Scales fo all three axis

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Rescale | ( | float | scalefactor | ) |

Rescale transformation by uniform number.

Parameters:

  scalefactor | uniform scale

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.RescaleLocal | ( | float | scalefactor | ) |

Local uniform rescale (changes basic scale of the transformation)

Parameters:

  scalefactor | uniform scale

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.RescaleLocal | ( | ref Vector3 | scalefactor | ) |

Local non-uniform rescale (changes basic scale of the transformation)

Parameters:

  scalefactor | Scales fo all three axis

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Roll | ( | float | angle | ) |

Rotate in local coordinates (changes roll)

Parameters:

  angle | angle in radians

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Rotate | ( | ref Vector3 | rpy | ) |

Rotate whole transformation in world coordinates.

Parameters:

  RPY | Roll-pitch-yaw rotation

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Rotate | ( | ref Quaternion | q | ) |

Rotate whole transformation in world coordinates.

Parameters:

  q | rotation

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Rotate | ( | Vector3 | rpy | ) |

Rotate whole transformation in world coordinates.

Parameters:

  RPY | Roll-pitch-yaw rotation

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Rotate | ( | ref Vector3 | axis,
|  | float | angle
| ) |  |

Rotate whole transformation in world coordinates.

Parameters:

  axis | rotation axis
  angle | angle in radians

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.RotateLocal | ( | ref Quaternion | q | ) |

Rotate in local coordinates (around the local zero)

Parameters:

  q | rotation

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.RotateLocal | ( | ref Vector3 | axis,
|  | float | angle
| ) |  |

Rotate in local coordinates (around the local zero)

Parameters:

  axis | rotation axis
  angle | angle in radians

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.RotateLocal | ( | ref Vector3 | rpy | ) |

Rotate in local coordinates (around the local zero)

Parameters:

  rpy | rotation in roll-pitch-yaw

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.RotateLocal | ( | Vector3 | rpy | ) |

Rotate in local coordinates (around the local zero)

Parameters:

  rpy | rotation in roll-pitch-yaw

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.UndoPushState | ( |  | ) |

Pops state of transformation from internal stack.

Implemented in VisiMath.BaseTransformation.

void VisiMath.ITransformation.Yaw | ( | float | angle | ) |

Rotate in local coordinates (changes yaw)

Parameters:

  angle | angle in radians

Implemented in VisiMath.BaseTransformation.

## Property Documentation

bool VisiMath.ITransformation.Movable`[get]`

True if object supports movement.

Implemented in VisiMath.BaseTransformation, and VisiMath.MoveTransformation.

float VisiMath.ITransformation.PitchAngle`[get, set]`

Pitch rotation.

Implemented in VisiMath.BaseTransformation.

Vector3 VisiMath.ITransformation.Position`[get, set]`

Position in vector.

Implemented in VisiMath.BaseTransformation, and VisiMath.MoveTransformation.

float VisiMath.ITransformation.RollAngle`[get, set]`

Roll rotation.

Implemented in VisiMath.BaseTransformation.

bool VisiMath.ITransformation.Rotable`[get]`

True if object supports rotation.

Implemented in VisiMath.BaseTransformation, VisiMath.RPYTransformation, and VisiMath.QTransformation.

Quaternion VisiMath.ITransformation.Rotation`[get, set]`

Rotation in quaternion.

Implemented in VisiMath.BaseTransformation, VisiMath.MoveTransformation, VisiMath.RPYTransformation, VisiMath.QTransformation, and VisimBox.Renderer.FPSCamera.

Vector3 VisiMath.ITransformation.RPY`[get, set]`

Rotation in roll-pitch-yaw format.

Implemented in VisiMath.BaseTransformation, VisiMath.MoveTransformation, VisiMath.RPYTransformation, and VisiMath.QTransformation.

bool VisiMath.ITransformation.Scalable`[get]`

True if object supports scaling.

Implemented in VisiMath.BaseTransformation, and VisiMath.Transformation.

Vector3 VisiMath.ITransformation.Scale`[get, set]`

Scale in different axis.

Implemented in VisiMath.BaseTransformation, VisiMath.MoveTransformation, and VisiMath.Transformation.

Matrix4 VisiMath.ITransformation.TransMatrix`[get, set]`

Transformation matrix - Every derived class must return correct transformation matrix.

Implemented in VisiMath.BaseTransformation, and VisiMath.MoveTransformation.

float VisiMath.ITransformation.UniformScale`[get, set]`

Uniform scale if used - should return zero if scale is not uniform.

Implemented in VisiMath.BaseTransformation, VisiMath.MoveTransformation, and VisiMath.Transformation.

float VisiMath.ITransformation.X`[get, set]`

X position.

Implemented in VisiMath.BaseTransformation.

float VisiMath.ITransformation.Y`[get, set]`

Y position.

Implemented in VisiMath.BaseTransformation.

float VisiMath.ITransformation.YawAngle`[get, set]`

Yaw rotation.

Implemented in VisiMath.BaseTransformation.

float VisiMath.ITransformation.Z`[get, set]`

Z position.

Implemented in VisiMath.BaseTransformation.

## Event Documentation

TransformationCallback VisiMath.ITransformation.ChangeCallback

Callback for any transformation change.

Implemented in VisiMath.BaseTransformation.

The documentation for this interface was generated from the following file:

- ITransformation.cs

All Classes Namespaces Files Functions Variables Enumerations Properties Events