[Liblas-commits] hg: 2 new changesets

liblas-commits at liblas.org liblas-commits at liblas.org
Fri Jun 18 15:30:04 EDT 2010


changeset 2e4c937ff0a0 in /Volumes/Data/www/liblas.org/hg
details: http://hg.liblas.orghg?cmd=changeset;node=2e4c937ff0a0
summary: Cast 0 to std::ios::pos_type to satisfy msvc

changeset 0e15eff44abc in /Volumes/Data/www/liblas.org/hg
details: http://hg.liblas.orghg?cmd=changeset;node=0e15eff44abc
summary: clean up dependency organization

diffstat:

 cmake/modules/BuildOSGeo4W.cmake |  8 ++++----
 src/detail/writer/header.cpp     |  2 +-
 src/detail/writer/point.cpp      |  6 ++++++
 3 files changed, 11 insertions(+), 5 deletions(-)

diffs (67 lines):

diff -r 3f33bd428201 -r 0e15eff44abc cmake/modules/BuildOSGeo4W.cmake
--- a/cmake/modules/BuildOSGeo4W.cmake	Fri Jun 18 11:38:55 2010 -0500
+++ b/cmake/modules/BuildOSGeo4W.cmake	Fri Jun 18 13:29:43 2010 -0600
@@ -35,7 +35,7 @@
 add_custom_target(make_osgeo4w_directories
   COMMAND ${CMAKE_COMMAND} -E echo "Building OSGeo4W install directories")
 
-add_dependencies(  make_osgeo4w_directories las2oci2  )
+add_dependencies(  make_osgeo4w_directories las2las2  )
 
 macro (make_directories)
     add_custom_command(
@@ -58,7 +58,7 @@
 
 
 add_custom_target(copy ALL COMMENT "Copying OSGeo4W files")
-add_dependencies( copy make_osgeo4w_directories   )
+add_dependencies( copy las2las2  )
 
 
 macro(copy_files GLOBPAT DESTINATION  )
@@ -80,7 +80,7 @@
 
 add_custom_target(tar
   COMMAND ${CMAKE_COMMAND} -E echo "Tarring OSGeo4W install")
-add_dependencies( tar copy   )
+add_dependencies( tar las2las2  )
 
 macro (tar_directories source destination base_path)
 
@@ -116,7 +116,7 @@
     )
 add_dependencies( osgeo4w tar   )
 
-add_dependencies( las2las2 osgeo4w   )
+add_dependencies(  osgeo4w  las2las2 )
 
 
 
diff -r 3f33bd428201 -r 0e15eff44abc src/detail/writer/header.cpp
--- a/src/detail/writer/header.cpp	Fri Jun 18 11:38:55 2010 -0500
+++ b/src/detail/writer/header.cpp	Fri Jun 18 13:29:43 2010 -0600
@@ -92,7 +92,7 @@
     // std::ios::in *and* std::ios::out, otherwise it should return false 
     // and we won't adjust the point count.
     
-    if ((beginning != end) && (end != 0)) {
+    if ((beginning != end) && (end != static_cast<std::ios::pos_type>(0))) {
         liblas::uint32_t& cnt =  GetPointCount();
         cnt = static_cast<liblas::uint32_t>(count);
         SetPointCount(cnt);
diff -r 3f33bd428201 -r 0e15eff44abc src/detail/writer/point.cpp
--- a/src/detail/writer/point.cpp	Fri Jun 18 11:38:55 2010 -0500
+++ b/src/detail/writer/point.cpp	Fri Jun 18 13:29:43 2010 -0600
@@ -48,6 +48,12 @@
 
 #include <sstream> 
 
+// From http://stackoverflow.com/questions/485525/round-for-float-in-c
+double round(double r) {
+    return (r > 0.0) ? floor(r + 0.5) : ceil(r - 0.5);
+}
+
+
 namespace liblas { namespace detail { namespace writer {
 
 void Point::setup()


More information about the Liblas-commits mailing list