| 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 asc_camera_s { |
38 struct asc_camera_s { |
| 39 asc_mat4f projection; |
39 asc_mat4f projection; |
| 40 asc_mat4f view; |
40 asc_mat4f view; |
| |
41 /** |
| |
42 * Does not need to be initialized. |
| |
43 * Will be updated every frame. |
| |
44 */ |
| 41 asc_rect viewport; |
45 asc_rect viewport; |
| 42 /** |
46 /** |
| 43 * Function that gets invoked whenever the window sized changed. |
47 * Function that gets invoked whenever the window sized changed. |
| 44 * Calculates the new drawing viewport. |
48 * Calculates the new drawing viewport. |
| 45 * If @c NULL, the entire window will be used. |
49 * If @c NULL, the entire window will be used. |