From 01695ba1d57bb6bc5c11fc09c58f564a084158d8 Mon Sep 17 00:00:00 2001 From: cignoni Date: Thu, 21 Dec 2006 00:13:27 +0000 Subject: [PATCH] Corrected a syntax error detected only by gcc. Corrected the order of initialization in the constructor to match the declaration order --- vcg/math/camera.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/vcg/math/camera.h b/vcg/math/camera.h index b522daff..aefc81fa 100644 --- a/vcg/math/camera.h +++ b/vcg/math/camera.h @@ -23,6 +23,9 @@ /**************************************************************************** History $Log: not supported by cvs2svn $ +Revision 1.27 2006/12/18 16:02:55 matteodelle +minor eroor correction on variable names + Revision 1.26 2006/12/18 09:46:38 callieri camera+shot revamp: changed field names to something with more sense, cleaning of various functions, correction of minor bugs/incongruences, removal of the infamous reference in shot. @@ -138,10 +141,11 @@ public: typedef S ScalarType; Camera(): - FocalMm(0.f),PixelSizeMm(vcg::Point2(0.0,0.0)), + FocalMm(0.f), + ViewportPx(vcg::Point2(0,0)), + PixelSizeMm(vcg::Point2(0.0,0.0)), CenterPx(vcg::Point2(0.0,0.0)), DistorCenterPx(vcg::Point2(0.0,0.0)), - ViewportPx(vcg::Point2(0,0)), cameraType(0) {} @@ -160,7 +164,7 @@ public: void SetOrtho(S dist) { cameraType = ORTHO; - ViewportPx = ( ((ViewportPx[0] * PixelSizeMm[0]) * (ViewportPx[1] * PixelSizeMm[1])) / f ) * dist; + ViewportPx = ( ((ViewportPx[0] * PixelSizeMm[0]) * (ViewportPx[1] * PixelSizeMm[1])) / FocalMm ) * dist; }; bool IsOrtho() const