Euphoria
eu::mat4f Struct Reference

#include <mat4.h>

Public Member Functions

float * get_data_ptr ()
 
float * get_column_major ()
 
bool invert ()
 
float get (int row, int col) const
 
vec4f get_transform (const vec4f &p) const
 
vec3f get_transform (const vec3f &p, float w) const
 
vec3f get_transform_point (const vec3f &p) const
 
vec3f get_transform_vec (const vec3f &p) const
 
unit3f get_transform_vec (const unit3f &p) const
 
unit3f get_axis (int col) const
 
mat4f get_translated (const vec3f &t) const
 
mat4f get_rotated (const AxisAngle &aa) const
 
mat4f get_scaled (const Scale3f &scale) const
 
vec4f get_column (int c) const
 
vec4f get_row (int r) const
 
const float * get_column_major () const
 
const float * get_data_ptr () const
 
vec3f get_translation () const
 
vec4f get_major () const
 
unit3f get_x_axis () const
 
unit3f get_y_axis () const
 
unit3f get_z_axis () const
 
mat4f get_transposed () const
 
mat4f get_inverted () const
 
mat3f get_mat3 () const
 
void operator+= (const mat4f &rhs)
 
void operator-= (const mat4f &rhs)
 

Static Public Member Functions

static mat4f from_col_major (float t00, float t01, float t02, float t03, float t10, float t11, float t12, float t13, float t20, float t21, float t22, float t23, float t30, float t31, float t32, float t33)
 
constexpr static mat4f from_row_major (float t00, float t10, float t20, float t30, float t01, float t11, float t21, float t31, float t02, float t12, float t22, float t32, float t03, float t13, float t23, float t33)
 
static mat4f from_major (const vec4f &major)
 
static mat4f from_scale (const Scale3f &scale)
 
static mat4f from_translation (const vec3f &v)
 
static mat4f from_rot_x (const Angle &a)
 
static mat4f from_rot_y (const Angle &a)
 
static mat4f from_rot_z (const Angle &a)
 
static mat4f from_axis_angle (const AxisAngle &aa)
 
static mat4f create_ortho (float l, float r, float b, float t, float n, float f)
 
static mat4f create_perspective (const Angle &fov, float a, float near, float far)
 
constexpr static mat4f from_scalar (float scalar)
 

Detailed Description

Definition at line 13 of file mat4.h.

Member Function Documentation

◆ create_ortho()

mat4f eu::mat4f::create_ortho ( float  l,
float  r,
float  b,
float  t,
float  n,
float  f 
)
static

Definition at line 392 of file mat4.cc.

◆ create_perspective()

mat4f eu::mat4f::create_perspective ( const Angle fov,
float  a,
float  near,
float  far 
)
static

Definition at line 406 of file mat4.cc.

◆ from_axis_angle()

mat4f eu::mat4f::from_axis_angle ( const AxisAngle aa)
static

Definition at line 146 of file mat4.cc.

◆ from_col_major()

mat4f eu::mat4f::from_col_major ( float  t00,
float  t01,
float  t02,
float  t03,
float  t10,
float  t11,
float  t12,
float  t13,
float  t20,
float  t21,
float  t22,
float  t23,
float  t30,
float  t31,
float  t32,
float  t33 
)
static

Definition at line 11 of file mat4.cc.

◆ from_major()

mat4f eu::mat4f::from_major ( const vec4f major)
static

Definition at line 30 of file mat4.cc.

◆ from_rot_x()

mat4f eu::mat4f::from_rot_x ( const Angle a)
static

Definition at line 102 of file mat4.cc.

◆ from_rot_y()

mat4f eu::mat4f::from_rot_y ( const Angle a)
static

Definition at line 116 of file mat4.cc.

◆ from_rot_z()

mat4f eu::mat4f::from_rot_z ( const Angle a)
static

Definition at line 131 of file mat4.cc.

◆ from_row_major()

constexpr static mat4f eu::mat4f::from_row_major ( float  t00,
float  t10,
float  t20,
float  t30,
float  t01,
float  t11,
float  t21,
float  t31,
float  t02,
float  t12,
float  t22,
float  t32,
float  t03,
float  t13,
float  t23,
float  t33 
)
inlinestaticconstexpr

Definition at line 23 of file mat4.h.

◆ from_scalar()

constexpr static mat4f eu::mat4f::from_scalar ( float  scalar)
inlinestaticconstexpr

Definition at line 49 of file mat4.h.

◆ from_scale()

mat4f eu::mat4f::from_scale ( const Scale3f scale)
static

Definition at line 44 of file mat4.cc.

◆ from_translation()

mat4f eu::mat4f::from_translation ( const vec3f v)
static

Definition at line 51 of file mat4.cc.

◆ get()

float eu::mat4f::get ( int  row,
int  col 
) const

Definition at line 452 of file mat4.cc.

◆ get_axis()

unit3f eu::mat4f::get_axis ( int  col) const

Definition at line 187 of file mat4.cc.

◆ get_column()

vec4f eu::mat4f::get_column ( int  c) const

Definition at line 458 of file mat4.cc.

◆ get_column_major() [1/2]

float * eu::mat4f::get_column_major ( )

Definition at line 6 of file mat4.cc.

◆ get_column_major() [2/2]

const float * eu::mat4f::get_column_major ( ) const

Definition at line 7 of file mat4.cc.

◆ get_data_ptr() [1/2]

float * eu::mat4f::get_data_ptr ( )

Definition at line 445 of file mat4.cc.

◆ get_data_ptr() [2/2]

const float * eu::mat4f::get_data_ptr ( ) const

Definition at line 439 of file mat4.cc.

◆ get_inverted()

mat4f eu::mat4f::get_inverted ( ) const

Definition at line 349 of file mat4.cc.

◆ get_major()

vec4f eu::mat4f::get_major ( ) const

Definition at line 181 of file mat4.cc.

◆ get_mat3()

mat3f eu::mat4f::get_mat3 ( ) const

Definition at line 358 of file mat4.cc.

◆ get_rotated()

mat4f eu::mat4f::get_rotated ( const AxisAngle aa) const

Definition at line 427 of file mat4.cc.

◆ get_row()

vec4f eu::mat4f::get_row ( int  r) const

Definition at line 471 of file mat4.cc.

◆ get_scaled()

mat4f eu::mat4f::get_scaled ( const Scale3f scale) const

Definition at line 433 of file mat4.cc.

◆ get_transform() [1/2]

vec3f eu::mat4f::get_transform ( const vec3f p,
float  w 
) const

Definition at line 71 of file mat4.cc.

◆ get_transform() [2/2]

vec4f eu::mat4f::get_transform ( const vec4f p) const

Definition at line 65 of file mat4.cc.

◆ get_transform_point()

vec3f eu::mat4f::get_transform_point ( const vec3f p) const

Definition at line 77 of file mat4.cc.

◆ get_transform_vec() [1/2]

unit3f eu::mat4f::get_transform_vec ( const unit3f p) const

Definition at line 89 of file mat4.cc.

◆ get_transform_vec() [2/2]

vec3f eu::mat4f::get_transform_vec ( const vec3f p) const

Definition at line 83 of file mat4.cc.

◆ get_translated()

mat4f eu::mat4f::get_translated ( const vec3f t) const

Definition at line 421 of file mat4.cc.

◆ get_translation()

vec3f eu::mat4f::get_translation ( ) const

Definition at line 95 of file mat4.cc.

◆ get_transposed()

mat4f eu::mat4f::get_transposed ( ) const

Definition at line 211 of file mat4.cc.

◆ get_x_axis()

unit3f eu::mat4f::get_x_axis ( ) const

Definition at line 193 of file mat4.cc.

◆ get_y_axis()

unit3f eu::mat4f::get_y_axis ( ) const

Definition at line 199 of file mat4.cc.

◆ get_z_axis()

unit3f eu::mat4f::get_z_axis ( ) const

Definition at line 205 of file mat4.cc.

◆ invert()

bool eu::mat4f::invert ( )

Definition at line 224 of file mat4.cc.

◆ operator+=()

void eu::mat4f::operator+= ( const mat4f rhs)

Definition at line 369 of file mat4.cc.

◆ operator-=()

void eu::mat4f::operator-= ( const mat4f rhs)

Definition at line 380 of file mat4.cc.


The documentation for this struct was generated from the following files: