Introduce Math.hpp and use typedef to make replacing glm with something else in the future simpler

This commit is contained in:
2020-10-27 23:25:26 +01:00
parent c219fc3778
commit 78d24fbe41
16 changed files with 268 additions and 181 deletions

View File

@@ -7,7 +7,7 @@
#pragma once
#include "InputDevice.hpp"
#include "glm/vec2.hpp"
#include "../Math/Math.hpp"
namespace openVulkanoCpp
{
@@ -100,7 +100,7 @@ namespace openVulkanoCpp
return GetAxis(InputKey::Mouse::Axis::AXIS_WHEEL_Y);
}
[[nodiscard]] glm::vec2 GetMousePosition() const
[[nodiscard]] Math::Vector2d GetMousePosition() const
{
return { mousePosX, mousePosY };
}
@@ -111,7 +111,7 @@ namespace openVulkanoCpp
posY = mousePosY;
}
glm::vec2 GetMousePosition(const IWindow* window) const
[[nodiscard]] Math::Vector2d GetMousePosition(const IWindow* window) const
{
if (window == lastWindow)
{