new engine

This commit is contained in:
Antoine
2021-05-19 02:52:15 +02:00
parent c6181c96fe
commit e78b680389
11 changed files with 138 additions and 129 deletions

View File

@ -0,0 +1,28 @@
package engine.math;
import engine.math.Vector3f;
public class Primitive {
public static float[] createRectangle(float x, float y, float z, float w, float h){
return new float[] {
x , y , z,
x + w, y , z,
x + w, y - h, z,
x , y - h, z
};
}
public static float[] stdTexWrap = new float[] {
1.0f, 1.0f,
1.0f, 0.0f,
0.0f, 0.0f,
0.0f, 1.0f
};
public static byte[] rectangle_indices = new byte[] {
0, 1, 3,
1, 2, 3
};
}