Fixed the textures problem but it's still not amazing.
This commit is contained in:
parent
2ce7375233
commit
d03afb31e1
8 changed files with 11 additions and 25 deletions
|
|
@ -2,17 +2,12 @@
|
|||
#include "dbc.hpp"
|
||||
#include <math.h>
|
||||
|
||||
void Scene::updateDelta() {
|
||||
void Scene::update() {
|
||||
float currentFrame = glfwGetTime();
|
||||
deltaTime = currentFrame - lastFrame;
|
||||
lastFrame = currentFrame;
|
||||
}
|
||||
|
||||
void Scene::configure() {
|
||||
// REFACTOR: really this should be done somewhere else
|
||||
for(auto& [name, model] : models) {
|
||||
model.connect_shader(shader);
|
||||
}
|
||||
camera.update(deltaTime);
|
||||
}
|
||||
|
||||
void Scene::draw_model(Model& scene_model, Material& material, glm::mat4& projection, glm::mat4& view, glm::vec3& position)
|
||||
|
|
@ -38,8 +33,6 @@ void Scene::render(GLFWwindow* window) {
|
|||
// time is used for fake 3d rotation
|
||||
float time = glfwGetTime();
|
||||
|
||||
camera.update(deltaTime);
|
||||
|
||||
glm::mat4 view = camera.look_at();
|
||||
glm::mat4 projection = glm::mat4(1.0f);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue