Skip to content
Permalink
Browse files

[pointclouds] add basic structure for PDAL layer

  • Loading branch information
PeterPetrik authored and wonder-sk committed Nov 4, 2020
1 parent b725a04 commit 3dec432cb69a3e32a3a46b8e7e7471a165569cb7
Showing with 1,889 additions and 32 deletions.
  1. +9 −0 CMakeLists.txt
  2. +62 −0 cmake/FindPDAL.cmake
  3. +4 −0 images/images.qrc
  4. +221 −0 images/themes/default/mActionAddEntwineLayer.svg
  5. +294 −0 images/themes/default/mActionAddPdalLayer.svg
  6. +191 −0 images/themes/default/mIconEntwineLayer.svg
  7. +262 −0 images/themes/default/mIconPdalLayer.svg
  8. +0 −5 python/core/auto_generated/pointcloud/qgspointclouddataprovider.sip.in
  9. +0 −10 src/core/pointcloud/qgspointclouddataprovider.cpp
  10. +2 −5 src/core/pointcloud/qgspointclouddataprovider.h
  11. +1 −1 src/core/pointcloud/qgspointcloudlayer.cpp
  12. +5 −0 src/core/pointcloud/qgspointcloudrenderer.cpp
  13. +1 −0 src/core/providers/ept/qgseptdataitems.cpp
  14. +1 −1 src/gui/providers/ept/qgseptdataitemguiprovider.h
  15. +4 −4 src/gui/providers/ept/qgseptproviderguimetadata.cpp
  16. +2 −2 src/gui/providers/ept/qgseptsourceselect.h
  17. +4 −0 src/providers/CMakeLists.txt
  18. +73 −0 src/providers/pdal/CMakeLists.txt
  19. +33 −0 src/providers/pdal/qgspdaldataitemguiprovider.cpp
  20. +33 −0 src/providers/pdal/qgspdaldataitemguiprovider.h
  21. +79 −0 src/providers/pdal/qgspdaldataitems.cpp
  22. +49 −0 src/providers/pdal/qgspdaldataitems.h
  23. +35 −0 src/providers/pdal/qgspdalgresprovidergui.h
  24. +151 −0 src/providers/pdal/qgspdalprovider.cpp
  25. +65 −0 src/providers/pdal/qgspdalprovider.h
  26. +61 −0 src/providers/pdal/qgspdalprovidergui.cpp
  27. +35 −0 src/providers/pdal/qgspdalprovidergui.h
  28. +54 −0 src/providers/pdal/qgspdalsourceselect.cpp
  29. +46 −0 src/providers/pdal/qgspdalsourceselect.h
  30. +4 −4 src/ui/pointcloud/{qgspointcloudsourceselectbase.ui → qgseptsourceselectbase.ui}
  31. +108 −0 src/ui/pointcloud/qgspdalsourceselectbase.ui
@@ -237,6 +237,11 @@ IF(WITH_CORE)
SET(ORACLE_LIBDIR "" CACHE STRING "Path to OCI libraries")
ENDIF(WITH_ORACLE)

SET (WITH_PDAL FALSE CACHE BOOL "Determines whether PDAL support should be built")
IF(WITH_PDAL)
SET(HAVE_PDAL TRUE)
ENDIF(WITH_PDAL)

#BUILD WITH QtMobility by default on android only. Other platform can force it
IF (ANDROID)
SET (DEFAULT_WITH_QTMOBILITY TRUE)
@@ -390,6 +395,10 @@ IF(WITH_CORE)
MESSAGE(STATUS "Qt WebKit support DISABLED.")
ENDIF(WITH_QTWEBKIT)

IF (WITH_PDAL)
FIND_PACKAGE(PDAL) # PDAL provider
ENDIF (WITH_PDAL)

#############################################################
# search for Qt5
SET(QT_MIN_VERSION 5.9.0)
@@ -0,0 +1,62 @@
# Find PDAL
# ~~~~~~~~~~
# Copyright (c) 2020, Peter Petrik <zilolv at gmail.com>
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
#
# CMake module to search for PDAL library
#
# If it's found it sets PDAL_FOUND to TRUE
# and following variables are set:
# PDAL_INCLUDE_DIR
# PDAL_LIBRARIES

# FIND_PATH and FIND_LIBRARY normally search standard locations
# before the specified paths. To search non-standard paths first,
# FIND_* is invoked first with specified paths and NO_DEFAULT_PATH
# and then again with no specified paths to search the default
# locations. When an earlier FIND_* succeeds, subsequent FIND_*s
# searching for the same item do nothing.
FIND_PATH(PDAL_INCLUDE_DIR pdal.hpp
"$ENV{LIB_DIR}/include/"
"$ENV{LIB_DIR}/include/pdal"
c:/msys/local/include
NO_DEFAULT_PATH
)
FIND_PATH(PDAL_INCLUDE_DIR pdal.hpp)

FIND_LIBRARY(PDAL_CPP_LIBRARY NAMES pdalccpp libpdalcpp PATHS
"$ENV{LIB_DIR}/lib"
c:/msys/local/lib
NO_DEFAULT_PATH
)
FIND_LIBRARY(PDAL_CPP_LIBRARY NAMES pdalcpp libpdalcpp)

FIND_LIBRARY(PDAL_UTIL_LIBRARY NAMES pdal_util libpdal_util PATHS
"$ENV{LIB_DIR}/lib"
c:/msys/local/lib
NO_DEFAULT_PATH
)
FIND_LIBRARY(PDAL_UTIL_LIBRARY NAMES pdal_util libpdal_util)


IF (PDAL_INCLUDE_DIR AND PDAL_CPP_LIBRARY AND PDAL_UTIL_LIBRARY)
SET(PDAL_FOUND TRUE)
SET(PDAL_LIBRARIES ${PDAL_CPP_LIBRARY} ${PDAL_UTIL_LIBRARY})
ENDIF (PDAL_INCLUDE_DIR AND PDAL_CPP_LIBRARY AND PDAL_UTIL_LIBRARY)

IF (PDAL_FOUND)
IF (NOT PDAL_FIND_QUIETLY)
MESSAGE(STATUS "Found PDAL: ${PDAL_LIBRARIES}")
ENDIF (NOT PDAL_FIND_QUIETLY)

ELSE (PDAL_FOUND)
IF (PDAL_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find PDAL")
ELSE (PDAL_FIND_REQUIRED)
IF (NOT PDAL_FIND_QUIETLY)
MESSAGE(STATUS "Could not find PDAL")
ENDIF (NOT PDAL_FIND_QUIETLY)
ENDIF (PDAL_FIND_REQUIRED)

ENDIF (PDAL_FOUND)
@@ -240,6 +240,8 @@
<file>themes/default/mActionAddXyzLayer.svg</file>
<file>themes/default/mActionAddVectorTileLayer.svg</file>
<file>themes/default/mActionAddPointCloudLayer.svg</file>
<file>themes/default/mActionAddPdalLayer.svg</file>
<file>themes/default/mActionAddEntwineLayer.svg</file>
<file>themes/default/mActionAddGeonodeLayer.svg</file>
<file>themes/default/mActionAddDelimitedTextLayer.svg</file>
<file>themes/default/mActionAddVirtualLayer.svg</file>
@@ -538,6 +540,8 @@
<file>themes/default/mIconVector.svg</file>
<file>themes/default/mIconVectorTileLayer.svg</file>
<file>themes/default/mIconPointCloudLayer.svg</file>
<file>themes/default/mIconEntwineLayer.svg</file>
<file>themes/default/mIconPdalLayer.svg</file>
<file>themes/default/mIconVirtualLayer.svg</file>
<file>themes/default/mIconWcs.svg</file>
<file>themes/default/mIconWfs.svg</file>
@@ -0,0 +1,221 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:i="&amp;ns_ai;"
xmlns:x="adobe:ns:meta/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
inkscape:version="1.0beta2 (2b71d25, 2019-12-03)"
height="23"
width="23"
sodipodi:docname="mActionAddEntwineLayer.svg"
xml:space="preserve"
viewBox="0 0 23 23"
y="0px"
x="0px"
id="Layer_1"
version="1.1"><defs
id="defs881" /><sodipodi:namedview
inkscape:current-layer="g857"
inkscape:window-maximized="0"
inkscape:window-y="23"
inkscape:window-x="0"
inkscape:cy="12.188549"
inkscape:cx="10.660205"
inkscape:zoom="18.9168"
showgrid="false"
id="namedview879"
inkscape:window-height="737"
inkscape:window-width="1415"
inkscape:pageshadow="2"
inkscape:pageopacity="0"
guidetolerance="10"
gridtolerance="10"
objecttolerance="10"
borderopacity="1"
inkscape:document-rotation="0"
bordercolor="#666666"
pagecolor="#ffffff" />
<metadata
id="metadata833"><?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
<x:xmpmeta
x:xmptk="Adobe XMP Core 5.6-c067 79.157747, 2015/03/30-23:40:42 ">

<metadata><rdf:RDF>
<rdf:Description
rdf:about="" />
<cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata></x:xmpmeta>





















<?xpacket end="w"?></metadata>
<style
id="style835"
type="text/css">
.st0{clip-path:url(#SVGID_2_);fill:#39B54A;}
.st1{clip-path:url(#SVGID_2_);fill:none;stroke:#FFFFFF;stroke-width:6.2024;stroke-miterlimit:10;}
.st2{clip-path:url(#SVGID_2_);}
.st3{fill:#FFFFFF;}
.st4{fill:#39B44A;}
.st5{fill:#192854;}
</style>
<switch
transform="translate(-198.69999,-262.09999)"
id="switch876">
<foreignObject
height="1"
width="1"
y="0"
x="0"
requiredExtensions="http://ns.adobe.com/AdobeIllustrator/10.0/">

</foreignObject>
<g
id="g874"
i:extraneous="self">
<g
id="g865">
<g
id="g857">
<defs
id="defs838">
<circle
r="41.700001"
cy="303.79999"
cx="240.39999"
id="SVGID_1_" />
</defs>
<clipPath
id="SVGID_2_">
<use
height="100%"
width="100%"
y="0"
x="0"
id="use840"
style="overflow:visible"
xlink:href="#SVGID_1_" />
</clipPath>
<circle
transform="matrix(0.27577937,0,0,0.27577937,143.90263,189.81822)"
id="circle843"
clip-path="url(#SVGID_2_)"
r="41.900002"
cy="303.79999"
cx="240.39999"
class="st0" />
<circle
transform="matrix(0.27577937,0,0,0.27577937,143.90263,189.81822)"
id="circle845"
clip-path="url(#SVGID_2_)"
r="24.700001"
cy="303.79999"
cx="240.5"
class="st1" />
<g
transform="matrix(0.27577937,0,0,0.27577937,143.90263,189.81822)"
id="g851"
clip-path="url(#SVGID_2_)"
class="st2">
<path
inkscape:connector-curvature="0"
id="path847"
d="m 233.9,346.3 c 5.9,-28.3 -4.4,-36.5 -4.5,-36.6 l -13.2,-9.9 15.5,5.9 c 0.4,0.1 7.3,2.9 10.5,10.6 1.6,-1.9 4,-3.7 7.6,-4.2 l 11.8,-1.6 -10.4,5.9 c 0,0 -8,5.4 -3.3,29.5 l 0.5,2.7 -15.1,0.6 z"
class="st3" />
<path
inkscape:connector-curvature="0"
id="path849"
d="m 230.8,307.9 c 0,0 9.6,3.7 10.5,15.1 0,0 1.5,-7.6 8.7,-8.6 0,0 -9.6,5.5 -4.4,32 l -9.4,0.4 c 6.3,-30.2 -5.4,-38.9 -5.4,-38.9 m -36.6,-18.9 33.7,22.6 c 0.3,0.3 2.4,2.3 3.8,6.9 1.5,4.8 2.8,13.5 -0.1,27.3 l -1.2,5.9 6,-0.3 9.4,-0.4 5.4,-0.2 -1,-5.3 c -4.2,-21.5 2.1,-27 2.2,-27.1 l 20.8,-11.8 -23.7,3.2 c -2.7,0.4 -4.9,1.4 -6.6,2.7 -3.9,-6.4 -10,-8.8 -10.3,-8.9 z"
class="st4" />
</g>
<path
transform="matrix(0.27577937,0,0,0.27577937,143.90263,189.81822)"
inkscape:connector-curvature="0"
id="path853"
clip-path="url(#SVGID_2_)"
d="m 216,306.7 c -1.6,-13.5 8,-25.8 21.6,-27.4 13.5,-1.6 25.8,8 27.4,21.6"
class="st1" />
<path
transform="matrix(0.27577937,0,0,0.27577937,143.90263,189.81822)"
inkscape:connector-curvature="0"
id="path855"
clip-path="url(#SVGID_2_)"
d="m 223,286.3 c 9.6,-9.6 25.3,-9.6 34.9,0 9.6,9.6 9.6,25.3 0,34.9"
class="st1" />
<g
transform="matrix(0.6923,0,0,0.6923,199.42945,262.68233)"
id="g2197"><rect
fill="#5a8c5a"
height="13"
rx="2.615"
width="13"
x="19"
y="19"
id="rect2189" /><g
fill-rule="evenodd"
id="g2195"><path
inkscape:connector-curvature="0"
d="m 21.6,25.5 h 7.8 m -3.9,3.9 v -7.8"
fill="#fff"
stroke="#fff"
stroke-linecap="round"
stroke-linejoin="round"
stroke-width="2.6"
id="path2191" /><path
inkscape:connector-curvature="0"
d="m 20.3,25.5 h 10.4 v -2.6 c 0,-2.6 -0.65,-2.6 -5.2,-2.6 -4.55,0 -5.2,0 -5.2,2.6 z"
fill="#fcffff"
opacity=".3"
id="path2193" /></g></g></g>
<g
transform="matrix(0.27577937,0,0,0.27577937,143.90263,189.81822)"
id="g863">
<circle
id="circle859"
r="10.9"
cy="290.89999"
cx="258.10001"
class="st4" />
<path
inkscape:connector-curvature="0"
id="path861"
d="m 258.1,304.1 c -7.3,0 -13.2,-5.9 -13.2,-13.2 0,-7.3 5.9,-13.2 13.2,-13.2 7.3,0 13.2,5.9 13.2,13.2 0,7.3 -6,13.2 -13.2,13.2 z m 0,-21.8 c -4.7,0 -8.6,3.8 -8.6,8.6 0,4.8 3.8,8.6 8.6,8.6 4.8,0 8.6,-3.8 8.6,-8.6 0,-4.8 -3.9,-8.6 -8.6,-8.6 z"
class="st3" />
</g>
</g>







</g>
</switch>

</svg>

0 comments on commit 3dec432

Please sign in to comment.
You can’t perform that action at this time.