 |
raylib-cpp
C++ object-oriented wrapper library for raylib.
|
1 #ifndef RAYLIB_CPP_MATRIX_HPP_
2 #define RAYLIB_CPP_MATRIX_HPP_
8 #ifndef RAYLIB_CPP_NO_MATH
15 #include "./raylib-cpp-utils.hpp"
16 #ifndef RAYLIB_CPP_NO_MATH
27 Matrix(
float M0 = 0,
float M1 = 0,
float M2 = 0,
float M3 = 0,
float M4 = 0,
float M5 = 0,
float M6 = 0,
float M7 = 0,
float M8 = 0,
float M9 = 0,
float M10 = 0,
float M11 = 0,
float M12 = 0,
float M13 = 0,
float M14 = 0,
float M15 = 0) {
65 GETTERSETTER(
float,M0,m0)
66 GETTERSETTER(
float,M1,m1)
67 GETTERSETTER(
float,M2,m2)
68 GETTERSETTER(
float,M3,m3)
69 GETTERSETTER(
float,M4,m4)
70 GETTERSETTER(
float,M5,m5)
71 GETTERSETTER(
float,M6,m6)
72 GETTERSETTER(
float,M7,m7)
73 GETTERSETTER(
float,M8,m8)
74 GETTERSETTER(
float,M9,m9)
75 GETTERSETTER(
float,M10,m10)
76 GETTERSETTER(
float,M11,m11)
77 GETTERSETTER(
float,M12,m12)
78 GETTERSETTER(
float,M13,m13)
79 GETTERSETTER(
float,M14,m14)
80 GETTERSETTER(
float,M15,m15)
112 ::SetMatrixProjection(*
this);
117 ::SetMatrixModelview(*
this);
122 return ::GetMatrixModelview();
126 return ::GetMatrixProjection();
129 #ifndef RAYLIB_CPP_NO_MATH
131 return ::MatrixTrace(*
this);
134 return ::MatrixTranspose(*
this);
137 return ::MatrixInvert(*
this);
140 return ::MatrixNormalize(*
this);
143 return ::MatrixIdentity();
146 return ::MatrixAdd(*
this, right);
149 return ::MatrixAdd(*
this, matrix);
152 return ::MatrixSubtract(*
this, right);
155 return ::MatrixSubtract(*
this, matrix);
158 return ::MatrixTranslate(x, y, z);
161 return ::MatrixRotate(axis, angle);
164 return ::MatrixRotateXYZ(angle);
167 return ::MatrixRotateX(angle);
170 return ::MatrixRotateY(angle);
173 return ::MatrixRotateZ(angle);
176 return ::MatrixScale(x, y, z);
179 return ::MatrixMultiply(*
this, right);
182 return ::MatrixMultiply(*
this, matrix);
185 static Matrix Frustum(
double left,
double right,
double bottom,
double top,
double near,
double far) {
186 return ::MatrixFrustum(left, right, bottom, top, near, far);
190 return ::MatrixPerspective(fovy, aspect, near, far);
193 static Matrix Ortho(
double left,
double right,
double bottom,
double top,
double near,
double far) {
194 return ::MatrixOrtho(left, right, bottom, top, near, far);
198 return ::MatrixLookAt(eye, target, up);
202 return ::MatrixToFloatV(*
this);
Provides all the classes associated with raylib-cpp.
Matrix operator*(const Matrix &matrix)
static Matrix Frustum(double left, double right, double bottom, double top, double near, double far)
Matrix Add(::Matrix right)
static Matrix RotateXYZ(Vector3 angle)
static Matrix Scale(float x, float y, float z)
static Matrix Translate(float x, float y, float z)
static Matrix Rotate(Vector3 axis, float angle)
static Matrix RotateZ(float angle)
Matrix operator-(const Matrix &matrix)
Matrix & operator=(const Matrix &matrix)
static Matrix RotateX(float angle)
static Matrix Perspective(double fovy, double aspect, double near, double far)
Matrix Subtract(::Matrix right)
static Matrix GetModelview()
Matrix(float M0=0, float M1=0, float M2=0, float M3=0, float M4=0, float M5=0, float M6=0, float M7=0, float M8=0, float M9=0, float M10=0, float M11=0, float M12=0, float M13=0, float M14=0, float M15=0)
static Matrix LookAt(Vector3 eye, Vector3 target, Vector3 up)
static Matrix RotateY(float angle)
Matrix Multiply(Matrix right)
bool operator==(const Matrix &other)
static Matrix GetProjection()
Matrix operator+(const Matrix &matrix)
static Matrix Ortho(double left, double right, double bottom, double top, double near, double far)