Mat.translate

Applies a 3D translation to this matrix.

  1. Mat!(T, N, N) translate(T dx, T dy)
  2. Mat!(T, N, N) translate(T dx, T dy, T dz)
    struct Mat(T, size_t rowCount, size_t colCount)
    ref
    static if(rowCount == colCount)
    static if(N == 4 && isFloatingPoint!T)
    Mat!(T, N, N)
    translate
    (
    T dx
    ,
    T dy
    ,
    T dz
    )
    if (
    isNumeric!T &&
    rowCount > 0
    &&
    colCount > 0
    )

Parameters

dx T

The translation on the x-axis.

dy T

The translation on the y-axis.

dz T

The translation on the z-axis.

Return Value

Type: Mat!(T, N, N)

A reference to this matrix, for method chaining.

Meta