Friction, velocity, rendering

This commit is contained in:
YourWishes committed 2025-10-09 09:44:17 -05:00
1 parent c31bcf7f6a
commit 7622f81309
7 files changed
+93 -75

No files matched your search

+7
View File
@@ -63,6 +63,7 @@ void cameraPushMatrix(camera_t *camera) {
);
break;
case CAMERA_PROJECTION_TYPE_PERSPECTIVE_FLIPPED:
case CAMERA_PROJECTION_TYPE_PERSPECTIVE:
const float_t aspect = (
(float_t)frameBufferGetWidth(FRAMEBUFFER_BOUND) /
@@ -75,6 +76,12 @@ void cameraPushMatrix(camera_t *camera) {
camera->farClip,
projection
);
if(camera->projType == CAMERA_PROJECTION_TYPE_PERSPECTIVE_FLIPPED) {
// Flip Y axis
projection[1][1] *= -1;
}
break;
}
switch(camera->viewType) {
+1
View File
@@ -13,6 +13,7 @@
typedef enum {
CAMERA_PROJECTION_TYPE_PERSPECTIVE,
CAMERA_PROJECTION_TYPE_PERSPECTIVE_FLIPPED,
CAMERA_PROJECTION_TYPE_ORTHOGRAPHIC
} cameraprojectiontype_t;