Index: trunk/MagicSoft/Mars/manalysis/MCerPhotPix.cc
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MCerPhotPix.cc	(revision 5977)
+++ trunk/MagicSoft/Mars/manalysis/MCerPhotPix.cc	(revision 6031)
@@ -68,4 +68,6 @@
     fIsSaturated(kFALSE), fIsHGSaturated(kFALSE)
 {
+    MMath::TruncatePrecision(fPhot);
+    MMath::TruncatePrecision(fErrPhot);
 } 
 
@@ -78,5 +80,5 @@
 //
 // Here:
-//  Index numbers are compared
+//  Index numbers are compared --> This allows sorting by index
 //
 Int_t MCerPhotPix::Compare(const TObject *o) const
Index: trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h	(revision 5977)
+++ trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h	(revision 6031)
@@ -5,5 +5,5 @@
 #include "MParContainer.h"
 #endif
-
+#include "MMath.h"
 class MCerPhotPix : public MParContainer
 {
@@ -45,7 +45,7 @@
     Bool_t  IsPixelCore() const         { return fIsCore;  }
 
-    void    SetNumPhotons(Float_t f)    { fPhot    = f; }
-    void    SetErrorPhot(Float_t f)     { fErrPhot = f; }
-    void    Set(Float_t np, Float_t ep) { fPhot = np; fErrPhot = ep; }
+    void    SetNumPhotons(Float_t f)    { MMath::TruncatePrecision(f); fPhot     = f; }
+    void    SetErrorPhot(Float_t f)     { MMath::TruncatePrecision(f); fErrPhot = f; }
+    void    Set(Float_t np, Float_t ep) { MMath::TruncatePrecision(np); MMath::TruncatePrecision(ep);  fPhot = np; fErrPhot = ep; }
 
     void    SetPixelSaturated()         { fIsSaturated = kTRUE; }
