From: Mikko Rasa Date: Thu, 16 Oct 2014 09:07:57 +0000 (+0300) Subject: Initialize camera matrices in constructor X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=e66511d118f702928c9649bb802a7a2faf0b5c11;p=libs%2Fgl.git Initialize camera matrices in constructor --- diff --git a/source/camera.cpp b/source/camera.cpp index 0202bedf..fca3ea33 100644 --- a/source/camera.cpp +++ b/source/camera.cpp @@ -15,7 +15,10 @@ Camera::Camera(): position(0, 0, 0), look_dir(0, 0, -1), up_dir(0, 1, 0) -{ } +{ + update_projection_matrix(); + update_object_matrix(); +} void Camera::set_field_of_view(const Geometry::Angle &f) {