Flipped UI, minor changes

Flipped UI, removed extra Batch2D, added comments and minor changes
This commit is contained in:
MihailRis
2022-06-29 14:03:36 +03:00
committed by GitHub
parent c3b4357852
commit 88c1695903
7 changed files with 67 additions and 66 deletions
+6 -6
View File
@@ -74,13 +74,13 @@ void Batch2D::rect(float x, float y, float w, float h){
void Batch2D::rect(float x, float y, float w, float h,
float u, float v, float tx, float ty,
float r, float g, float b, float a){
vertex(x, y, u, v, r,g,b,a);
vertex(x+w, y+h, u+tx, v+ty, r,g,b,a);
vertex(x, y+h, u, v+ty, r,g,b,a);
vertex(x, y, u, v+ty, r,g,b,a);
vertex(x+w, y+h, u+tx, v, r,g,b,a);
vertex(x, y+h, u, v, r,g,b,a);
vertex(x, y, u, v, r,g,b,a);
vertex(x+w, y, u+tx, v, r,g,b,a);
vertex(x+w, y+h, u+tx, v+ty, r,g,b,a);
vertex(x, y, u, v+ty, r,g,b,a);
vertex(x+w, y, u+tx, v+ty, r,g,b,a);
vertex(x+w, y+h, u+tx, v, r,g,b,a);
}
void Batch2D::render() {