From 0e7d48c8e78b8c4e68664035fc84cebf9149b844 Mon Sep 17 00:00:00 2001 From: Josh Morgenstern <josh@morgenstern.dev> Date: Tue, 15 Jun 2021 00:29:14 +0200 Subject: [PATCH] [#42] remove camera and window from controller --- .../src/vkcv/camera/CameraController.cpp | 26 +++++-------------- 1 file changed, 7 insertions(+), 19 deletions(-) diff --git a/modules/camera/src/vkcv/camera/CameraController.cpp b/modules/camera/src/vkcv/camera/CameraController.cpp index 477d9380..94f8d6ce 100644 --- a/modules/camera/src/vkcv/camera/CameraController.cpp +++ b/modules/camera/src/vkcv/camera/CameraController.cpp @@ -1,29 +1,17 @@ #include "vkcv/camera/CameraController.hpp" +#include <iostream> namespace vkcv { - - Camera& CameraController::getCamera() { - return *m_camera; - } - - void CameraController::setCamera(Camera &camera) { - m_camera = &camera; + + void CameraController::updateCamera(double deltaTime, Camera &camera) { } - void CameraController::setWindow(Window &window) { - m_window = &window; - m_lastX = m_window->getWidth() / 2.0; - m_lastY = m_window->getHeight() / 2.0; - } - - void CameraController::updateCamera(double deltaTime) {} - - void CameraController::keyCallback(int key, int scancode, int action, int mods) {} + void CameraController::keyCallback(int key, int scancode, int action, int mods, Camera &camera) {} - void CameraController::scrollCallback( double offsetX, double offsetY) {} + void CameraController::scrollCallback( double offsetX, double offsetY, Camera &camera) {} - void CameraController::mouseMoveCallback(double offsetX, double offsetY) {} + void CameraController::mouseMoveCallback(double offsetX, double offsetY, Camera &camera) {} - void CameraController::mouseButtonCallback(int button, int action, int mods) {} + void CameraController::mouseButtonCallback(int button, int action, int mods, Camera &camera) {} } \ No newline at end of file -- GitLab