[Liblas-commits] hg: 2 new changesets
liblas-commits at liblas.org
liblas-commits at liblas.org
Wed Oct 27 12:22:50 EDT 2010
changeset 785c93c6a621 in /Volumes/Data/www/liblas.org/hg
details: http://hg.liblas.orghg?cmd=changeset;node=785c93c6a621
summary: debug typo
changeset 30ed9749c198 in /Volumes/Data/www/liblas.org/hg
details: http://hg.liblas.orghg?cmd=changeset;node=30ed9749c198
summary: merge
diffstat:
CMakeLists.txt | 6 ++--
apps/CMakeLists.txt | 8 +++++-
apps/las2oci.cpp | 2 +-
apps/ts2las.cpp | 22 ++++++++---------
apps/ts2las.hpp | 49 +++++++++++++++++++--------------------
cmake/modules/BuildOSGeo4W.cmake | 15 +++++++++++-
6 files changed, 59 insertions(+), 43 deletions(-)
diffs (239 lines):
diff -r 18dceb43a3dc -r 30ed9749c198 CMakeLists.txt
--- a/CMakeLists.txt Wed Oct 27 10:48:13 2010 -0500
+++ b/CMakeLists.txt Wed Oct 27 11:22:31 2010 -0500
@@ -335,6 +335,6 @@
add_custom_target(dist COMMAND ${CMAKE_MAKE_PROGRAM} package_source)
-#if (WIN32)
-# include(BuildOSGeo4W)
-#endif(WIN32)
+if (WIN32)
+ include(BuildOSGeo4W)
+endif(WIN32)
diff -r 18dceb43a3dc -r 30ed9749c198 apps/CMakeLists.txt
--- a/apps/CMakeLists.txt Wed Oct 27 10:48:13 2010 -0500
+++ b/apps/CMakeLists.txt Wed Oct 27 11:22:31 2010 -0500
@@ -21,6 +21,7 @@
set(LAS2LAS_OLD las2las-old)
set(LAS2TXT las2txt)
set(TXT2LAS txt2las)
+set(TS2LAS ts2las)
set(LASBLOCK lasblock )
set(BIGFILE_TEST bigfile_test)
@@ -43,7 +44,7 @@
set(LIBLAS_UTILITIES
${LASINFO_OLD} ${LASINFO} ${LASMERGE} ${LAS2LAS} ${LAS2TXT} ${TXT2LAS}
- ${LAS2OGR} ${LAS2OCI} ${LAS2LAS} ${LAS2LAS_OLD} ${LASBLOCK} )
+ ${LAS2OGR} ${LAS2OCI} ${LAS2LAS} ${LAS2LAS_OLD} ${LASBLOCK} ${TS2LAS} )
# TODO: Experimental and requires testing --mloskot
# Generate user-specific settings for Visual Studio project
@@ -109,6 +110,11 @@
target_link_libraries(${TXT2LAS} ${LIBLAS_C_LIB_NAME})
endif()
+if(TS2LAS)
+ add_executable(${TS2LAS} ts2las.cpp )
+ target_link_libraries(${TS2LAS} ${APPS_CPP_DEPENDENCIES} )
+endif()
+
# Build lasmerge
if(LASMERGE)
set(LASMERGE_SRC lascommon.c ${LASMERGE}.c)
diff -r 18dceb43a3dc -r 30ed9749c198 apps/las2oci.cpp
--- a/apps/las2oci.cpp Wed Oct 27 10:48:13 2010 -0500
+++ b/apps/las2oci.cpp Wed Oct 27 11:22:31 2010 -0500
@@ -934,7 +934,7 @@
}
if (verbose)
if (!used_file)
- std::cout << "Setting output post-sql to: " << pre_sql << std::endl;
+ std::cout << "Setting output post-sql to: " << post_sql << std::endl;
else
std::cout << "Setting output post-sql to: " << sql << std::endl; // Tell filename instead
}
diff -r 18dceb43a3dc -r 30ed9749c198 apps/ts2las.cpp
--- a/apps/ts2las.cpp Wed Oct 27 10:48:13 2010 -0500
+++ b/apps/ts2las.cpp Wed Oct 27 11:22:31 2010 -0500
@@ -120,7 +120,6 @@
return false;
}
- return true;
}
bool WritePoints(liblas::Writer* writer, std::istream* strm, ScanHdr* hdr)
@@ -136,9 +135,9 @@
{
// std::cout << "stream position is: " << strm->tellg() << std::endl;
if (hdr->HdrVersion == 20020715) {
- detail::read_n(*point, *strm, sizeof(ScanPnt));
+ liblas::detail::read_n(*point, *strm, sizeof(ScanPnt));
} else{
- detail::read_n(*row, *strm, sizeof(ScanRow));
+ liblas::detail::read_n(*row, *strm, sizeof(ScanRow));
point->Pnt.x = row->x;
point->Pnt.y = row->y;
point->Pnt.z = row->z;
@@ -149,8 +148,7 @@
}
Point p;
- p.SetCoordinates(writer->GetHeader(),
- point->Pnt.x,
+ p.SetCoordinates( point->Pnt.x,
point->Pnt.y,
point->Pnt.z);
@@ -160,8 +158,8 @@
p.SetClassification(point->Code);
p.SetIntensity(point->Intensity);
if (hdr->Time) {
- liblas::uint32_t t = 0xFFFFFFFF;
- detail::read_n(t, *strm, sizeof(t));
+ boost::uint32_t t = 0xFFFFFFFF;
+ liblas::detail::read_n(t, *strm, sizeof(t));
// Time stamps are assumed to be GPS week seconds. The
// storage format is a 32 bit unsigned integer where
@@ -170,15 +168,15 @@
p.SetTime(t*0.0002);
}
if (hdr->Color) {
- liblas::uint8_t r, g, b, a = 0;
+ boost::uint8_t r, g, b, a = 0;
liblas::Color color;
- detail::read_n(r, *strm, sizeof(r));
- detail::read_n(b, *strm, sizeof(b));
- detail::read_n(g, *strm, sizeof(g));
+ liblas::detail::read_n(r, *strm, sizeof(r));
+ liblas::detail::read_n(b, *strm, sizeof(b));
+ liblas::detail::read_n(g, *strm, sizeof(g));
// TS .bin says to read 4 bytes here for some reason. Maybe
// this is an alpha value or something
- detail::read_n(a, *strm, sizeof(a));
+ liblas::detail::read_n(a, *strm, sizeof(a));
color.SetGreen(g);
color.SetBlue(b);
diff -r 18dceb43a3dc -r 30ed9749c198 apps/ts2las.hpp
--- a/apps/ts2las.hpp Wed Oct 27 10:48:13 2010 -0500
+++ b/apps/ts2las.hpp Wed Oct 27 11:22:31 2010 -0500
@@ -2,9 +2,8 @@
#include <liblas/detail/private_utility.hpp>
-#include <liblas/laswriter.hpp>
-#include <liblas/laspoint.hpp>
-#include <liblas/lascolor.hpp>
+#include <liblas/liblas.hpp>
+
#include <iostream>
#ifdef _WIN32
#define compare_no_case(a,b,n) _strnicmp( (a), (b), (n) )
@@ -25,13 +24,13 @@
z(0)
{}
- liblas::uint8_t Code;
- liblas::uint8_t Line;
- liblas::uint16_t EchoInt;
+ boost::uint8_t Code;
+ boost::uint8_t Line;
+ boost::uint16_t EchoInt;
- liblas::int32_t x;
- liblas::int32_t y;
- liblas::int32_t z;
+ boost::int32_t x;
+ boost::int32_t y;
+ boost::int32_t z;
};
@@ -44,9 +43,9 @@
z(0)
{}
- liblas::int32_t x;
- liblas::int32_t y;
- liblas::int32_t z;
+ boost::int32_t x;
+ boost::int32_t y;
+ boost::int32_t z;
};
@@ -62,12 +61,12 @@
{}
Point3d Pnt;
- liblas::uint8_t Code;
- liblas::uint8_t Echo;
- liblas::uint8_t Flag;
- liblas::uint8_t Mark;
- liblas::uint16_t Line;
- liblas::uint16_t Intensity;
+ boost::uint8_t Code;
+ boost::uint8_t Echo;
+ boost::uint8_t Flag;
+ boost::uint8_t Mark;
+ boost::uint16_t Line;
+ boost::uint16_t Intensity;
};
@@ -87,17 +86,17 @@
Color(0)
{}
- liblas::int32_t HdrSize;
- liblas::int32_t HdrVersion;
- liblas::int32_t Tunniste;
+ boost::int32_t HdrSize;
+ boost::int32_t HdrVersion;
+ boost::int32_t Tunniste;
char Magic[4];
- liblas::int32_t PntCnt;
- liblas::int32_t Units;
+ boost::int32_t PntCnt;
+ boost::int32_t Units;
double OrgX;
double OrgY;
double OrgZ;
- liblas::int32_t Time;
- liblas::int32_t Color;
+ boost::int32_t Time;
+ boost::int32_t Color;
//
// int HdrSize;
diff -r 18dceb43a3dc -r 30ed9749c198 cmake/modules/BuildOSGeo4W.cmake
--- a/cmake/modules/BuildOSGeo4W.cmake Wed Oct 27 10:48:13 2010 -0500
+++ b/cmake/modules/BuildOSGeo4W.cmake Wed Oct 27 11:22:31 2010 -0500
@@ -113,7 +113,20 @@
endmacro(tar_directories)
make_directories()
-copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/*.exe ${OSGEO4W_BIN_DIR}/ )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/lasinfo.exe ${OSGEO4W_BIN_DIR}/lasinfo.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/lasinfo-old.exe ${OSGEO4W_BIN_DIR}/lasinfo-old.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/las2las.exe ${OSGEO4W_BIN_DIR}/las2las.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/las2las-old.exe ${OSGEO4W_BIN_DIR}/las2las-old.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/las2ogr.exe ${OSGEO4W_BIN_DIR}/las2ogr.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/las2oci.exe ${OSGEO4W_BIN_DIR}/las2oci.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/las2txt.exe ${OSGEO4W_BIN_DIR}/las2txt.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/lasblock.exe ${OSGEO4W_BIN_DIR}/lasblock.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/lasmerge.exe ${OSGEO4W_BIN_DIR}/lasmerge.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/txt2las.exe ${OSGEO4W_BIN_DIR}/txt2las.exe )
+copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/ts2las.exe ${OSGEO4W_BIN_DIR}/ts2las.exe )
+
+
+
copy_files(${LIBLAS_BUILD_OUTPUT_DIRECTORY}/liblas_c.dll ${OSGEO4W_BIN_DIR}/ )
copy_files(${libLAS_SOURCE_DIR}/liblas-osgeo4w-start.bat.tmpl ${OSGEO4W_BIN_DIR}/liblas.bat.tmpl )
copy_files(${libLAS_SOURCE_DIR}/liblas-osgeo4w-init.bat ${OSGEO4W_ETC_INI_DIR}/liblas.bat )
More information about the Liblas-commits
mailing list