Antiprism 0.23

- Main Page
- Classes
- Files

- File List
- File Members

Classes | Functions

# base/mat3d.h File Reference

Matrix transformations for 3D geometry. More...

`#include <math.h>`
`#include <vector>`
`#include "vec3d.h"`
`#include "vec4d.h"`
Include dependency graph for mat3d.h:
This graph shows which files directly or indirectly include this file:

## Classes
class | mat3d
| Matrix for transformations in 3D. More...
## Functions
vec3d | operator* (const mat3d &mat, const vec3d &v)
| Transform a column vector.
vec3d | operator* (const vec3d &v, const mat3d &mat)
| Transform a row vector.
mat3d | operator* (const mat3d &m1, const mat3d &m2)
| Multiply two matrices.
void | transform (vector< vec3d > &vecs, const mat3d &mat)
| Transform a set of vectors.

## Detailed Description

Matrix transformations for 3D geometry.

## Function Documentation

vec3d operator* | ( | const mat3d & | mat,
|  | const vec3d & | v
| ) |  |

Transform a column vector.

Parameters:

  mat | the transformation matrix.
  v | the column vector.

Returns:
  The transformed vector (left-multiplied by the matrix).

vec3d operator* | ( | const vec3d & | v,
|  | const mat3d & | mat
| ) |  | `[inline]`

Transform a row vector.

Parameters:

  v | the column vector.
  mat | the transformation matrix.

Returns:
  The transformed vector (right-multiplied by the matrix).

mat3d operator* | ( | const mat3d & | m1,
|  | const mat3d & | m2
| ) |  | `[inline]`

Multiply two matrices.

Parameters:

  m1 | the first matrix.
  m2 | the second matrix.

Returns:
  The result of the first matrix multiplying the second.

void transform | ( | vector< vec3d > & | vecs,
|  | const mat3d & | mat
| ) |  | `[inline]`

Transform a set of vectors.

Parameters:

  vecs | the (column) vectors to transform.
  mat | the matrix transformation.