Skip to content
Snippets Groups Projects
Commit df122221 authored by JonShard's avatar JonShard
Browse files

Romved aspect ratio as an attribute loaded from the scene.

parent 14435f1c
Branches
No related tags found
No related merge requests found
...@@ -7,7 +7,6 @@ camera: maincam ...@@ -7,7 +7,6 @@ camera: maincam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: orbital mode: orbital
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: 4000 farClip: 4000
......
...@@ -7,7 +7,6 @@ camera: mainCam ...@@ -7,7 +7,6 @@ camera: mainCam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: orbital mode: orbital
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: 800 farClip: 800
...@@ -18,7 +17,6 @@ camera: mainCam ...@@ -18,7 +17,6 @@ camera: mainCam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: orbital mode: orbital
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: 800 farClip: 800
...@@ -29,7 +27,6 @@ camera: mainCam ...@@ -29,7 +27,6 @@ camera: mainCam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: freelook mode: freelook
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: 800 farClip: 800
...@@ -40,7 +37,6 @@ camera: mainCam ...@@ -40,7 +37,6 @@ camera: mainCam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: freelook mode: freelook
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: 800 farClip: 800
...@@ -51,7 +47,6 @@ camera: mainCam ...@@ -51,7 +47,6 @@ camera: mainCam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: orbital mode: orbital
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: 1000 farClip: 1000
......
...@@ -7,7 +7,6 @@ camera: maincam ...@@ -7,7 +7,6 @@ camera: maincam
angleVelocity: 0 0 0 angleVelocity: 0 0 0
mode: freelook mode: freelook
fov: 90 fov: 90
aspectRatio: 1.25
nearClip: 0.1 nearClip: 0.1
farClip: -100 farClip: -100
......
...@@ -65,7 +65,6 @@ int Scene::m_lightsCount; ...@@ -65,7 +65,6 @@ int Scene::m_lightsCount;
glm::vec3 angVel; glm::vec3 angVel;
CameraMode camMode = FREELOOK; CameraMode camMode = FREELOOK;
float camFov = 0; float camFov = 0;
float aspect = 0;
float nearClip = 0; float nearClip = 0;
float farClip = 0; float farClip = 0;
...@@ -157,17 +156,6 @@ int Scene::m_lightsCount; ...@@ -157,17 +156,6 @@ int Scene::m_lightsCount;
LOG_INFO("%s: %f",key.data(), camFov); LOG_INFO("%s: %f",key.data(), camFov);
} }
// float aspectRatio.
if (auto[key, aspectRatio, err] = p.keyFloat("aspectRatio"); err)
{
LOG_ERROR("%s error on camera aspect ratio key --> %s...", filestring.c_str(), key.data());
}
else
{
aspect = aspectRatio;
LOG_INFO("%s: %f",key.data(), aspect);
}
// float nearClip. // float nearClip.
if (auto[key, _nearClip, err] = p.keyFloat("nearClip"); err) if (auto[key, _nearClip, err] = p.keyFloat("nearClip"); err)
{ {
...@@ -198,7 +186,7 @@ int Scene::m_lightsCount; ...@@ -198,7 +186,7 @@ int Scene::m_lightsCount;
angVel, angVel,
camMode, camMode,
camFov, camFov,
aspect, C::AspectRatio,
nearClip, nearClip,
farClip); farClip);
Scene::addEntity(camEntity); Scene::addEntity(camEntity);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment