summaryrefslogtreecommitdiff
path: root/gfx/gl
diff options
context:
space:
mode:
Diffstat (limited to 'gfx/gl')
-rw-r--r--gfx/gl/bufferedLocation.cpp4
-rw-r--r--gfx/gl/camera.cpp4
-rw-r--r--gfx/gl/shadowMapper.cpp2
3 files changed, 5 insertions, 5 deletions
diff --git a/gfx/gl/bufferedLocation.cpp b/gfx/gl/bufferedLocation.cpp
index d6a63b9..f1bedfe 100644
--- a/gfx/gl/bufferedLocation.cpp
+++ b/gfx/gl/bufferedLocation.cpp
@@ -25,7 +25,7 @@ BufferedLocation::position() const
return loc.pos;
}
-Position3D
+Rotation3D
BufferedLocation::rotation() const
{
return loc.rot;
@@ -41,7 +41,7 @@ BufferedLocation::setPosition(GlobalPosition3D p, bool update)
}
void
-BufferedLocation::setRotation(Position3D r, bool update)
+BufferedLocation::setRotation(Rotation3D r, bool update)
{
loc.rot = r;
if (update) {
diff --git a/gfx/gl/camera.cpp b/gfx/gl/camera.cpp
index 9f40998..d362b94 100644
--- a/gfx/gl/camera.cpp
+++ b/gfx/gl/camera.cpp
@@ -17,14 +17,14 @@ Ray
Camera::unProject(const ScreenRelCoord & mouse) const
{
static constexpr const glm::vec4 screen {0, 0, 1, 1};
- const auto mouseProjection = glm::lookAt(::origin, forward, up);
+ const auto mouseProjection = glm::lookAt({}, forward, up);
return {position, glm::normalize(glm::unProject(mouse || 1.F, mouseProjection, projection, screen))};
}
void
Camera::updateView()
{
- viewProjection = projection * glm::lookAt(origin, forward, up);
+ viewProjection = projection * glm::lookAt({}, forward, up);
inverseViewProjection = glm::inverse(viewProjection);
}
diff --git a/gfx/gl/shadowMapper.cpp b/gfx/gl/shadowMapper.cpp
index 6c8400e..1498bb0 100644
--- a/gfx/gl/shadowMapper.cpp
+++ b/gfx/gl/shadowMapper.cpp
@@ -130,7 +130,7 @@ ShadowMapper::update(const SceneProvider & scene, const Direction3D & dir, const
glClear(GL_DEPTH_BUFFER_BIT);
glCullFace(GL_FRONT);
- const auto lightViewDir = glm::lookAt(origin, dir, up);
+ const auto lightViewDir = glm::lookAt({}, dir, up);
const auto lightViewPoint = camera.getPosition();
const auto bandViewExtents = getBandViewExtents(camera, lightViewDir);