28 #ifndef ASCENSION_CAMERA_H |
28 #ifndef ASCENSION_CAMERA_H |
29 #define ASCENSION_CAMERA_H |
29 #define ASCENSION_CAMERA_H |
30 |
30 |
31 #include "datatypes.h" |
31 #include "datatypes.h" |
32 |
32 |
33 typedef struct AscCamera AscCamera; |
33 typedef struct asc_camera_s AscCamera; |
34 |
34 |
35 typedef asc_recti(*asc_camera_viewport_update_func)(asc_vec2u window_size); |
35 typedef asc_recti(*asc_camera_viewport_update_func)(asc_vec2u window_size); |
36 typedef void(*asc_camera_projection_update_func)(AscCamera*, asc_vec2u window_size); |
36 typedef void(*asc_camera_projection_update_func)(AscCamera*, asc_vec2u window_size); |
37 |
37 |
38 struct AscCamera { |
38 struct asc_camera_s { |
39 asc_mat4f projection; |
39 asc_mat4f projection; |
40 asc_mat4f view; |
40 asc_mat4f view; |
41 asc_recti viewport; |
41 asc_recti viewport; |
42 /** |
42 /** |
43 * Function that gets invoked whenever the window sized changed. |
43 * Function that gets invoked whenever the window sized changed. |