Friction, velocity, rendering
This commit is contained in:
@@ -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) {
|
||||
|
@@ -13,6 +13,7 @@
|
||||
|
||||
typedef enum {
|
||||
CAMERA_PROJECTION_TYPE_PERSPECTIVE,
|
||||
CAMERA_PROJECTION_TYPE_PERSPECTIVE_FLIPPED,
|
||||
CAMERA_PROJECTION_TYPE_ORTHOGRAPHIC
|
||||
} cameraprojectiontype_t;
|
||||
|
||||
|
Reference in New Issue
Block a user