Overload  1.1
Game engine with editor
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
OvMaths::FMatrix3 Struct Reference

#include <FMatrix3.h>

Public Member Functions

 FMatrix3 ()
 
 FMatrix3 (float p_value)
 
 FMatrix3 (float p_element1, float p_element2, float p_element3, float p_element4, float p_element5, float p_element6, float p_element7, float p_element8, float p_element9)
 
 FMatrix3 (const FMatrix3 &p_other)
 
FMatrix3operator= (const FMatrix3 &p_other)
 
bool operator== (const FMatrix3 &p_other)
 
FMatrix3 operator+ (const FMatrix3 &p_other) const
 
FMatrix3operator+= (const FMatrix3 &p_other)
 
FMatrix3 operator- (const FMatrix3 &p_other) const
 
FMatrix3operator-= (const FMatrix3 &p_other)
 
FMatrix3 operator* (float p_scalar) const
 
FMatrix3operator*= (float p_scalar)
 
FVector3 operator* (const FVector3 &p_vector) const
 
FMatrix3 operator* (const FMatrix3 &p_other) const
 
FMatrix3operator*= (const FMatrix3 &p_other)
 
FMatrix3 operator/ (float p_scalar) const
 
FMatrix3operator/= (float p_scalar)
 
FMatrix3 operator/ (const FMatrix3 &p_other) const
 
FMatrix3operator/= (const FMatrix3 &p_other)
 
float & operator() (uint8_t p_row, uint8_t p_column)
 

Static Public Member Functions

static bool AreEquals (const FMatrix3 &p_left, const FMatrix3 &p_right)
 
static FMatrix3 Add (const FMatrix3 &p_left, float p_scalar)
 
static FMatrix3 Add (const FMatrix3 &p_left, const FMatrix3 &p_right)
 
static FMatrix3 Subtract (const FMatrix3 &p_left, float p_scalar)
 
static FMatrix3 Subtract (const FMatrix3 &p_left, const FMatrix3 &p_right)
 
static FMatrix3 Multiply (const FMatrix3 &p_left, float p_scalar)
 
static FVector3 Multiply (const FMatrix3 &p_matrix, const FVector3 &p_vector)
 
static FMatrix3 Multiply (const FMatrix3 &p_left, const FMatrix3 &p_right)
 
static FMatrix3 Divide (const FMatrix3 &p_left, float p_scalar)
 
static FMatrix3 Divide (const FMatrix3 &p_left, const FMatrix3 &p_right)
 
static bool IsIdentity (const FMatrix3 &p_matrix)
 
static float Determinant (const FMatrix3 &p_matrix)
 
static FMatrix3 Transpose (const FMatrix3 &p_matrix)
 
static FMatrix3 Cofactor (const FMatrix3 &p_matrix)
 
static FMatrix3 Minor (const FMatrix3 &p_matrix)
 
static FMatrix3 Adjoint (const FMatrix3 &p_other)
 
static FMatrix3 Inverse (const FMatrix3 &p_matrix)
 
static FMatrix3 Translation (const FVector2 &p_translation)
 
static FMatrix3 Translate (const FMatrix3 &p_matrix, const FVector2 &p_translation)
 
static FMatrix3 Rotation (float p_rotation)
 
static FMatrix3 Rotate (const FMatrix3 &p_matrix, float p_rotation)
 
static FMatrix3 Scaling (const FVector2 &p_scale)
 
static FMatrix3 Scale (const FMatrix3 &p_matrix, const FVector2 &p_scale)
 
static FVector3 GetRow (const FMatrix3 &p_matrix, uint8_t p_row)
 
static FVector3 GetColumn (const FMatrix3 &p_matrix, uint8_t p_column)
 

Public Attributes

float data [9]
 

Static Public Attributes

static const FMatrix3 Identity
 

Detailed Description

Mathematic representation of a 3x3 Matrix of floats

Constructor & Destructor Documentation

◆ FMatrix3() [1/4]

OvMaths::FMatrix3::FMatrix3 ( )

Default constructor

◆ FMatrix3() [2/4]

OvMaths::FMatrix3::FMatrix3 ( float  p_value)

Set all elements to value

Parameters
p_value

◆ FMatrix3() [3/4]

OvMaths::FMatrix3::FMatrix3 ( float  p_element1,
float  p_element2,
float  p_element3,
float  p_element4,
float  p_element5,
float  p_element6,
float  p_element7,
float  p_element8,
float  p_element9 
)

Constructor

Parameters
p_element1
p_element2
p_element3
p_element4
p_element5
p_element6
p_element7
p_element9
p_element8

◆ FMatrix3() [4/4]

OvMaths::FMatrix3::FMatrix3 ( const FMatrix3 p_other)

Copy constructor

Parameters
p_other

Member Function Documentation

◆ Add() [1/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::Add ( const FMatrix3 p_left,
const FMatrix3 p_right 
)
static

Element-wise addition

Parameters
p_left
p_right

◆ Add() [2/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::Add ( const FMatrix3 p_left,
float  p_scalar 
)
static

Element-wise addition

Parameters
p_left
p_scalar

◆ Adjoint()

OvMaths::FMatrix3 OvMaths::FMatrix3::Adjoint ( const FMatrix3 p_other)
static

Return Adjoint matrix

Parameters
p_other

◆ AreEquals()

bool OvMaths::FMatrix3::AreEquals ( const FMatrix3 p_left,
const FMatrix3 p_right 
)
static

Check if elements are equals

Parameters
p_left
p_right

◆ Cofactor()

OvMaths::FMatrix3 OvMaths::FMatrix3::Cofactor ( const FMatrix3 p_matrix)
static

Return Cofactor matrix

Parameters
p_matrix

◆ Determinant()

float OvMaths::FMatrix3::Determinant ( const FMatrix3 p_matrix)
static

Compute matrix determinant

Parameters
p_matrix

◆ Divide() [1/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::Divide ( const FMatrix3 p_left,
const FMatrix3 p_right 
)
static

Matrix Division

Parameters
p_left
p_right

◆ Divide() [2/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::Divide ( const FMatrix3 p_left,
float  p_scalar 
)
static

Scalar Division

Parameters
p_left
p_scalar

◆ GetColumn()

OvMaths::FVector3 OvMaths::FMatrix3::GetColumn ( const FMatrix3 p_matrix,
uint8_t  p_column 
)
static

Get Column

Parameters
p_column

◆ GetRow()

OvMaths::FVector3 OvMaths::FMatrix3::GetRow ( const FMatrix3 p_matrix,
uint8_t  p_row 
)
static

Get row

Parameters
p_row

◆ Inverse()

OvMaths::FMatrix3 OvMaths::FMatrix3::Inverse ( const FMatrix3 p_matrix)
static

Return inverse matrix

Parameters
p_matrix

◆ IsIdentity()

bool OvMaths::FMatrix3::IsIdentity ( const FMatrix3 p_matrix)
static

Compare to Identity matrix

Parameters
p_matrix

◆ Minor()

OvMaths::FMatrix3 OvMaths::FMatrix3::Minor ( const FMatrix3 p_matrix)
static

Return Minor matrix

Parameters
p_matrix

◆ Multiply() [1/3]

OvMaths::FMatrix3 OvMaths::FMatrix3::Multiply ( const FMatrix3 p_left,
const FMatrix3 p_right 
)
static

Matrix Product

Parameters
p_left
p_right

◆ Multiply() [2/3]

OvMaths::FMatrix3 OvMaths::FMatrix3::Multiply ( const FMatrix3 p_left,
float  p_scalar 
)
static

Scalar Product

Parameters
p_left
p_scalar

◆ Multiply() [3/3]

OvMaths::FVector3 OvMaths::FMatrix3::Multiply ( const FMatrix3 p_matrix,
const FVector3 p_vector 
)
static

Vector Product

Parameters
p_matrix
p_vector

◆ operator()()

float & OvMaths::FMatrix3::operator() ( uint8_t  p_row,
uint8_t  p_column 
)

Get element at index (row,column)

Parameters
p_row
p_column

◆ operator*() [1/3]

OvMaths::FMatrix3 OvMaths::FMatrix3::operator* ( const FMatrix3 p_other) const

Matrix Product

Parameters
p_other

◆ operator*() [2/3]

OvMaths::FVector3 OvMaths::FMatrix3::operator* ( const FVector3 p_vector) const

Vector Product

Parameters
p_vector

◆ operator*() [3/3]

OvMaths::FMatrix3 OvMaths::FMatrix3::operator* ( float  p_scalar) const

Scalar Product

Parameters
p_scalar

◆ operator*=() [1/2]

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator*= ( const FMatrix3 p_other)

Matrix Product

Parameters
p_other

◆ operator*=() [2/2]

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator*= ( float  p_scalar)

Scalar Product

Parameters
p_scalar

◆ operator+()

OvMaths::FMatrix3 OvMaths::FMatrix3::operator+ ( const FMatrix3 p_other) const

Element-wise addition

Parameters
p_other

◆ operator+=()

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator+= ( const FMatrix3 p_other)

Element-wise addition

Parameters
p_other

◆ operator-()

OvMaths::FMatrix3 OvMaths::FMatrix3::operator- ( const FMatrix3 p_other) const

Element-wise subtraction

Parameters
p_other

◆ operator-=()

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator-= ( const FMatrix3 p_other)

Element-wise subtraction

Parameters
p_other

◆ operator/() [1/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::operator/ ( const FMatrix3 p_other) const

Matrix Division

Parameters
p_other

◆ operator/() [2/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::operator/ ( float  p_scalar) const

Scalar Division

Parameters
p_scalar

◆ operator/=() [1/2]

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator/= ( const FMatrix3 p_other)

Matrix Division

Parameters
p_other

◆ operator/=() [2/2]

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator/= ( float  p_scalar)

Scalar Division

Parameters
p_scalar

◆ operator=()

OvMaths::FMatrix3 & OvMaths::FMatrix3::operator= ( const FMatrix3 p_other)

Copy assignment

Parameters
p_other

◆ operator==()

bool OvMaths::FMatrix3::operator== ( const FMatrix3 p_other)

Check if elements are equals

Parameters
p_other

◆ Rotate()

OvMaths::FMatrix3 OvMaths::FMatrix3::Rotate ( const FMatrix3 p_matrix,
float  p_rotation 
)
static

Rotate matrix in 2D

Parameters
p_matrix
p_rotationangle in radians

◆ Rotation()

OvMaths::FMatrix3 OvMaths::FMatrix3::Rotation ( float  p_rotation)
static

Return 2D rotation matrix

Parameters
p_rotationangle in radians

◆ Scale()

OvMaths::FMatrix3 OvMaths::FMatrix3::Scale ( const FMatrix3 p_matrix,
const FVector2 p_scale 
)
static

Scale matrix in 2D

Parameters
p_matrix
p_scale

◆ Scaling()

OvMaths::FMatrix3 OvMaths::FMatrix3::Scaling ( const FVector2 p_scale)
static

Return 2D scaling matrix

Parameters
p_scale

◆ Subtract() [1/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::Subtract ( const FMatrix3 p_left,
const FMatrix3 p_right 
)
static

Element-wise subtractions

Parameters
p_left
p_right

◆ Subtract() [2/2]

OvMaths::FMatrix3 OvMaths::FMatrix3::Subtract ( const FMatrix3 p_left,
float  p_scalar 
)
static

Element-wise subtraction

Parameters
p_left
p_scalar

◆ Translate()

OvMaths::FMatrix3 OvMaths::FMatrix3::Translate ( const FMatrix3 p_matrix,
const FVector2 p_translation 
)
static

Translate matrix in 2D

Parameters
p_matrix
p_translation

◆ Translation()

OvMaths::FMatrix3 OvMaths::FMatrix3::Translation ( const FVector2 p_translation)
static

Return 2D translation matrix

Parameters
p_translation

◆ Transpose()

OvMaths::FMatrix3 OvMaths::FMatrix3::Transpose ( const FMatrix3 p_matrix)
static

Return transposed matrix

Parameters
p_matrix

Member Data Documentation

◆ data

float OvMaths::FMatrix3::data[9]

◆ Identity

const OvMaths::FMatrix3 OvMaths::FMatrix3::Identity
static
Initial value:
= OvMaths::FMatrix3(1.0f, 0.0f, 0.0f,
0.0f, 1.0f, 0.0f,
0.0f, 0.0f, 1.0f)

@project: Overload

Author
: Overload Tech. @restrictions: This software may not be resold, redistributed or otherwise conveyed to a third party.

The documentation for this struct was generated from the following files:
OvMaths::FMatrix3
Definition: FMatrix3.h:20