From b441009e15d9e6635e05d7a96660288a38562287 Mon Sep 17 00:00:00 2001 From: cignoni Date: Thu, 21 May 2009 23:04:09 +0000 Subject: [PATCH] added an invalid method that says if a shot is "reasonable" or not. A shot is valid if its Intrinsics are valid. --- vcg/math/shot.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/vcg/math/shot.h b/vcg/math/shot.h index e992661d..96631e4c 100644 --- a/vcg/math/shot.h +++ b/vcg/math/shot.h @@ -231,6 +231,11 @@ public: note: it is up to the caller to check the the matrix passed is a pure rototraslation */ void MultSimilarity( const Similarity & s){ MultMatrix(s.Matrix());} + + bool IsValid() const + { + return Intrinsics.PixelSizeMm[0]>0 && Intrinsics.PixelSizeMm[1]>0; + } }; // end class definition