| 3045 | } |
| 3046 | |
| 3047 | void Demo::update_data_buffer(void *uniform_memory_ptr) { |
| 3048 | mat4x4 VP; |
| 3049 | mat4x4_mul(VP, projection_matrix, view_matrix); |
| 3050 | |
| 3051 | // Rotate around the Y axis |
| 3052 | mat4x4 Model; |
| 3053 | mat4x4_dup(Model, model_matrix); |
| 3054 | mat4x4_rotate_Y(model_matrix, Model, static_cast<float>(degreesToRadians(spin_angle))); |
| 3055 | mat4x4_orthonormalize(model_matrix, model_matrix); |
| 3056 | |
| 3057 | mat4x4 MVP; |
| 3058 | mat4x4_mul(MVP, VP, model_matrix); |
| 3059 | |
| 3060 | memcpy(uniform_memory_ptr, (const void *)&MVP[0][0], sizeof(MVP)); |
| 3061 | } |
| 3062 | |
| 3063 | /* Convert ppm image data from header file into RGBA texture image */ |
| 3064 | #ifdef TEXTURE_PPM_H |
nothing calls this directly
no test coverage detected