[Liblas-commits] laszip: merge

liblas-commits at liblas.org liblas-commits at liblas.org
Tue Dec 14 10:46:48 EST 2010


changeset b33531f25c48 in /Volumes/Data/www/liblas.org/laszip
details: http://hg.liblas.orglaszip?cmd=changeset;node=b33531f25c48
summary: merge

diffstat:

 CMakeLists.txt                 |   204 +++---
 include/laszip/lasunzipper.hpp |    67 +-
 src/CMakeLists.txt             |   172 ++---
 src/bytestreamin_istream.hpp   |    80 +-
 src/lasunzipper.cpp            |    78 +-
 tools/lasdiff.cpp              |  1096 +++++++++++++++++++--------------------
 tools/laszip.cpp               |   866 +++++++++++++++---------------
 7 files changed, 1273 insertions(+), 1290 deletions(-)

diffs (truncated from 2670 to 300 lines):

diff -r abac5891d7de -r b33531f25c48 CMakeLists.txt
--- a/CMakeLists.txt	Tue Dec 14 03:36:54 2010 -0800
+++ b/CMakeLists.txt	Tue Dec 14 09:46:42 2010 -0600
@@ -1,96 +1,110 @@
-###############################################################################
-# Main CMake configuration file for laszip
-#
-# Author: Mateusz Loskot <mateusz at loskot.net>
-#
-#
-###############################################################################
-# laszip general settings
-project(laszip)
-
-# Name of C++ library
-set(LASZIP_LIB_NAME liblaszip)
-
-
-set(CMAKE_INCLUDE_DIRECTORIES_PROJECT_BEFORE ON)
-
-###############################################################################
-# CMake settings
-cmake_minimum_required(VERSION 2.6.0)
-
-set(CMAKE_COLOR_MAKEFILE ON)
-
-# Allow advanced users to generate Makefiles printing detailed commands
-mark_as_advanced(CLEAR CMAKE_VERBOSE_MAKEFILE )
-
-# Path to additional CMake modules
-set(CMAKE_MODULE_PATH ${laszip_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH})
-
-###############################################################################
-# General build settings
-
-# Default to release mode 
-if(NOT MSVC_IDE)
-  set(CMAKE_BUILD_TYPE Release CACHE STRING 
-    "Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel")
-endif()
-
-# TODO: Still testing the output paths --mloskot
-set(LASZIP_BUILD_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin/${CMAKE_BUILD_TYPE})
-
-# Output directory in which to build RUNTIME target files.
-set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${LASZIP_BUILD_OUTPUT_DIRECTORY})
-
-# Output directory in which to build LIBRARY target files
-set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${LASZIP_BUILD_OUTPUT_DIRECTORY})
-
-# Output directory in which to build ARCHIVE target files.
-set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${LASZIP_BUILD_OUTPUT_DIRECTORY}) 
-
-###############################################################################
-# Installation settings
-
-if(WIN32)
-  set(DEFAULT_LIB_SUBDIR lib)
-  set(DEFAULT_DATA_SUBDIR .)
-  set(DEFAULT_INCLUDE_SUBDIR include)
-
-  if (MSVC)
-    set(DEFAULT_BIN_SUBDIR bin)
-  else()
-    set(DEFAULT_BIN_SUBDIR .)
-  endif()
-else()
-  # Common locations for Unix and Mac OS X
-  set(DEFAULT_BIN_SUBDIR bin)
-  set(DEFAULT_LIB_SUBDIR lib)
-  set(DEFAULT_INCLUDE_SUBDIR include)
-endif()
-
-# Locations are changeable by user to customize layout of laszip installation
-# (default values are platform-specific)
-set(LASZIP_BIN_SUBDIR ${DEFAULT_BIN_SUBDIR} CACHE STRING
-  "Subdirectory where executables will be installed")
-set(LASZIP_LIB_SUBDIR ${DEFAULT_LIB_SUBDIR} CACHE STRING
-  "Subdirectory where libraries will be installed")
-set(LASZIP_INCLUDE_SUBDIR ${DEFAULT_INCLUDE_SUBDIR} CACHE STRING
-  "Subdirectory where header files will be installed")
-set(LASZIP_DATA_SUBDIR ${DEFAULT_DATA_SUBDIR} CACHE STRING
-  "Subdirectory where data will be installed")
-
-# Mark *_SUBDIR variables as advanced and dedicated to use by power-users only.
-mark_as_advanced(LASZIP_BIN_SUBDIR
-  LASZIP_LIB_SUBDIR LASZIP_INCLUDE_SUBDIR LASZIP_DATA_SUBDIR)
-
-# Full paths for the installation
-set(LASZIP_BIN_DIR ${LASZIP_BIN_SUBDIR})
-set(LASZIP_LIB_DIR ${LASZIP_LIB_SUBDIR})
-set(LASZIP_INCLUDE_DIR ${LASZIP_INCLUDE_SUBDIR})
-set(LASZIP_DATA_DIR ${LASZIP_DATA_SUBDIR})
-
-###############################################################################
-# Processing of project directories
-
-add_subdirectory(src)
-
+###############################################################################
+# Main CMake configuration file for laszip
+#
+# Author: Mateusz Loskot <mateusz at loskot.net>
+#
+#
+###############################################################################
+# laszip general settings
+project(laszip)
+
+# Name of C++ library
+set(LASZIP_LIB_NAME liblaszip)
+
+
+set(CMAKE_INCLUDE_DIRECTORIES_PROJECT_BEFORE ON)
+
+###############################################################################
+# CMake settings
+cmake_minimum_required(VERSION 2.6.0)
+
+set(CMAKE_COLOR_MAKEFILE ON)
+
+# Allow advanced users to generate Makefiles printing detailed commands
+mark_as_advanced(CLEAR CMAKE_VERBOSE_MAKEFILE )
+
+# Path to additional CMake modules
+set(CMAKE_MODULE_PATH ${laszip_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH})
+
+###############################################################################
+# General build settings
+
+# Default to release mode 
+if(NOT MSVC_IDE)
+  set(CMAKE_BUILD_TYPE Release CACHE STRING 
+    "Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel")
+endif()
+
+# TODO: Still testing the output paths --mloskot
+set(LASZIP_BUILD_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin/${CMAKE_BUILD_TYPE})
+
+# Output directory in which to build RUNTIME target files.
+set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${LASZIP_BUILD_OUTPUT_DIRECTORY})
+
+# Output directory in which to build LIBRARY target files
+set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${LASZIP_BUILD_OUTPUT_DIRECTORY})
+
+# Output directory in which to build ARCHIVE target files.
+set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${LASZIP_BUILD_OUTPUT_DIRECTORY}) 
+
+###############################################################################
+# Platform and compiler specific settings
+
+if(WIN32)
+  if (MSVC)
+    if (MSVC80 OR MSVC90 OR MSVC10)
+      add_definitions(-D_CRT_SECURE_NO_DEPRECATE)
+      add_definitions(-D_CRT_SECURE_NO_WARNINGS)
+      add_definitions(-D_CRT_NONSTDC_NO_WARNING)
+      add_definitions(-D_SCL_SECURE_NO_WARNINGS)
+    endif()
+  endif()
+endif()
+
+###############################################################################
+# Installation settings
+
+if(WIN32)
+  set(DEFAULT_LIB_SUBDIR lib)
+  set(DEFAULT_DATA_SUBDIR .)
+  set(DEFAULT_INCLUDE_SUBDIR include)
+
+  if (MSVC)
+    set(DEFAULT_BIN_SUBDIR bin)
+  else()
+    set(DEFAULT_BIN_SUBDIR .)
+  endif()
+else()
+  # Common locations for Unix and Mac OS X
+  set(DEFAULT_BIN_SUBDIR bin)
+  set(DEFAULT_LIB_SUBDIR lib)
+  set(DEFAULT_INCLUDE_SUBDIR include)
+endif()
+
+# Locations are changeable by user to customize layout of laszip installation
+# (default values are platform-specific)
+set(LASZIP_BIN_SUBDIR ${DEFAULT_BIN_SUBDIR} CACHE STRING
+  "Subdirectory where executables will be installed")
+set(LASZIP_LIB_SUBDIR ${DEFAULT_LIB_SUBDIR} CACHE STRING
+  "Subdirectory where libraries will be installed")
+set(LASZIP_INCLUDE_SUBDIR ${DEFAULT_INCLUDE_SUBDIR} CACHE STRING
+  "Subdirectory where header files will be installed")
+set(LASZIP_DATA_SUBDIR ${DEFAULT_DATA_SUBDIR} CACHE STRING
+  "Subdirectory where data will be installed")
+
+# Mark *_SUBDIR variables as advanced and dedicated to use by power-users only.
+mark_as_advanced(LASZIP_BIN_SUBDIR
+  LASZIP_LIB_SUBDIR LASZIP_INCLUDE_SUBDIR LASZIP_DATA_SUBDIR)
+
+# Full paths for the installation
+set(LASZIP_BIN_DIR ${LASZIP_BIN_SUBDIR})
+set(LASZIP_LIB_DIR ${LASZIP_LIB_SUBDIR})
+set(LASZIP_INCLUDE_DIR ${LASZIP_INCLUDE_SUBDIR})
+set(LASZIP_DATA_DIR ${LASZIP_DATA_SUBDIR})
+
+###############################################################################
+# Processing of project directories
+
+add_subdirectory(src)
+
 add_subdirectory(tools)
\ No newline at end of file
diff -r abac5891d7de -r b33531f25c48 include/laszip/lasunzipper.hpp
--- a/include/laszip/lasunzipper.hpp	Tue Dec 14 03:36:54 2010 -0800
+++ b/include/laszip/lasunzipper.hpp	Tue Dec 14 09:46:42 2010 -0600
@@ -1,21 +1,21 @@
-/******************************************************************************
- *
- * Project:  integrating laszip into liblas - http://liblas.org -
- * Purpose:
- * Author:   Martin Isenburg
- *           isenburg at cs.unc.edu
- *
- ******************************************************************************
- * Copyright (c) 2010, Martin Isenburg
- *
- * This is free software; you can redistribute and/or modify it under
- * the terms of the GNU Lesser General Licence as published
- * by the Free Software Foundation.
- *
- * See the COPYING file for more information.
- *
- ****************************************************************************/
-
+/******************************************************************************
+ *
+ * Project:  integrating laszip into liblas - http://liblas.org -
+ * Purpose:
+ * Author:   Martin Isenburg
+ *           isenburg at cs.unc.edu
+ *
+ ******************************************************************************
+ * Copyright (c) 2010, Martin Isenburg
+ *
+ * This is free software; you can redistribute and/or modify it under
+ * the terms of the GNU Lesser General Licence as published
+ * by the Free Software Foundation.
+ *
+ * See the COPYING file for more information.
+ *
+ ****************************************************************************/
+
 /*
 ===============================================================================
 
@@ -39,37 +39,38 @@
   
   CHANGE HISTORY:
   
-    12 December 2010 -- created from LASwriter/LASreader after Howard got pushy (-;
+    12 December 2010 -- created from LASwriter/LASreader after Howard got pushy (-;
   
 ===============================================================================
 */
 #ifndef LAS_UNZIPPER_H
 #define LAS_UNZIPPER_H
 
-#include <stdio.h>
-#include <istream.h>
-
-#include "laszip.hpp"
+#include <stdio.h>
 
-class ByteStreamIn;
-class LASreadPoint;
-
+#include <fstream>
+
+#include "laszip.hpp"
+
+class ByteStreamIn;
+class LASreadPoint;
+
 class LASunzipper
 {
 public:
 
-  bool open(FILE* file, unsigned int num_items, const LASitem* items, unsigned int compression=0);
-  bool open(istream* stream, unsigned int num_items, const LASitem* items, unsigned int compression=0);
-  bool read(unsigned char** point);
-  bool close();
+  bool open(FILE* file, unsigned int num_items, const LASitem* items, unsigned int compression=0);
+  bool open(std::istream* stream, unsigned int num_items, const LASitem* items, unsigned int compression=0);
+  bool read(unsigned char** point);
+  bool close();
 
   LASunzipper();
   ~LASunzipper();
 
-private:
+private:
   int count;


More information about the Liblas-commits mailing list