[Liblas-commits] r1017 - branches/1.0/src

liblas-commits at liblas.org liblas-commits at liblas.org
Wed Feb 11 21:23:30 EST 2009


Author: hobu
Date: Wed Feb 11 21:23:30 2009
New Revision: 1017
URL: http://liblas.org/changeset/1017

Log:
fix #94, point xyz data loosing sign

Modified:
   branches/1.0/src/laswriter.cpp

Modified: branches/1.0/src/laswriter.cpp
==============================================================================
--- branches/1.0/src/laswriter.cpp	(original)
+++ branches/1.0/src/laswriter.cpp	Wed Feb 11 21:23:30 2009
@@ -82,9 +82,9 @@
     }
 
     // TODO: Move composition of point record deep into writer implementation
-    m_record.x = static_cast<uint32_t>((point.GetX() - m_header.GetOffsetX()) / m_header.GetScaleX());
-    m_record.y = static_cast<uint32_t>((point.GetY() - m_header.GetOffsetY()) / m_header.GetScaleY());
-    m_record.z = static_cast<uint32_t>((point.GetZ() - m_header.GetOffsetZ()) / m_header.GetScaleZ());
+    m_record.x = static_cast<int32_t>((point.GetX() - m_header.GetOffsetX()) / m_header.GetScaleX());
+    m_record.y = static_cast<int32_t>((point.GetY() - m_header.GetOffsetY()) / m_header.GetScaleY());
+    m_record.z = static_cast<int32_t>((point.GetZ() - m_header.GetOffsetZ()) / m_header.GetScaleZ());
     m_record.intensity = point.GetIntensity();
     m_record.flags = point.GetScanFlags();
     m_record.classification = point.GetClassification();


More information about the Liblas-commits mailing list