Skip to content
Permalink
Browse files

[processing] improved lidar provider (contributed by Martin Isenburg)

  • Loading branch information
volaya committed Sep 24, 2013
1 parent 9d9d60a commit 1ad2334dbe0c0249bcaa402e654a81c57d4f8d06
Showing with 2,142 additions and 332 deletions.
  1. +41 −18 python/plugins/processing/lidar/LidarToolsAlgorithmProvider.py
  2. +3 −2 python/plugins/processing/lidar/fusion/FusionUtils.py
  3. +1 −1 python/plugins/processing/lidar/fusion/OpenViewerAction.py
  4. +257 −29 python/plugins/processing/lidar/lastools/LasToolsAlgorithm.py
  5. +7 −7 python/plugins/processing/lidar/lastools/LasToolsUtils.py
  6. +69 −0 python/plugins/processing/lidar/lastools/blast2dem.py
  7. +76 −0 python/plugins/processing/lidar/lastools/blast2iso.py
  8. +37 −23 python/plugins/processing/lidar/lastools/las2dem.py
  9. +39 −28 python/plugins/processing/lidar/lastools/las2iso.py
  10. +68 −0 python/plugins/processing/lidar/lastools/las2las.py
  11. +60 −0 python/plugins/processing/lidar/lastools/las2las_filter.py
  12. +72 −0 python/plugins/processing/lidar/lastools/las2las_transform.py
  13. +31 −22 python/plugins/processing/lidar/lastools/las2shp.py
  14. +58 −0 python/plugins/processing/lidar/lastools/las2txt.py
  15. +25 −24 python/plugins/processing/lidar/lastools/lasboundary.py
  16. +109 −0 python/plugins/processing/lidar/lastools/lascanopy.py
  17. +18 −19 python/plugins/processing/lidar/lastools/lasclassify.py
  18. +40 −22 python/plugins/processing/lidar/lastools/lasclip.py
  19. +71 −0 python/plugins/processing/lidar/lastools/lascontrol.py
  20. +68 −0 python/plugins/processing/lidar/lastools/lasduplicate.py
  21. +32 −25 python/plugins/processing/lidar/lastools/lasgrid.py
  22. +35 −26 python/plugins/processing/lidar/lastools/lasground.py
  23. +25 −23 python/plugins/processing/lidar/lastools/lasheight.py
  24. +54 −0 python/plugins/processing/lidar/lastools/lasindex.py
  25. +17 −21 python/plugins/processing/lidar/lastools/lasinfo.py
  26. +87 −0 python/plugins/processing/lidar/lastools/lasmerge.py
  27. +77 −0 python/plugins/processing/lidar/lastools/lasnoise.py
  28. +69 −0 python/plugins/processing/lidar/lastools/lasoverage.py
  29. +81 −0 python/plugins/processing/lidar/lastools/lasoverlap.py
  30. +19 −23 python/plugins/processing/lidar/lastools/lasprecision.py
  31. +57 −0 python/plugins/processing/lidar/lastools/lassort.py
  32. +18 −19 python/plugins/processing/lidar/lastools/lassplit.py
  33. +67 −0 python/plugins/processing/lidar/lastools/lasthin.py
  34. +66 −0 python/plugins/processing/lidar/lastools/lastile.py
  35. +49 −0 python/plugins/processing/lidar/lastools/lasvalidate.py
  36. +50 −0 python/plugins/processing/lidar/lastools/lasview.py
  37. +53 −0 python/plugins/processing/lidar/lastools/laszip.py
  38. +62 −0 python/plugins/processing/lidar/lastools/shp2las.py
  39. +74 −0 python/plugins/processing/lidar/lastools/txt2las.py
@@ -7,6 +7,10 @@
Date : August 2012
Copyright : (C) 2012 by Victor Olaya
Email : volayaf at gmail dot com
---------------------
Date : September 2013
Copyright : (C) 2013 by Martin Isenburg
Email : martin near rapidlasso point com
***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
@@ -26,22 +30,44 @@
import os
from PyQt4.QtCore import *
from PyQt4.QtGui import *
from processing.core.ProcessingConfig import ProcessingConfig, Setting
from processing.tools.system import isWindows
from processing.lidar.lastools.LAStoolsUtils import LAStoolsUtils
from processing.core.AlgorithmProvider import AlgorithmProvider
from processing.tools.system import *
from processing.lidar.lastools.LasToolsUtils import LasToolsUtils
from processing.core.ProcessingConfig import Setting, ProcessingConfig
from processing.lidar.lastools.las2dem import las2dem
from processing.lidar.lastools.las2iso import las2iso
from processing.lidar.lastools.las2shp import las2shp
from processing.lidar.lastools.lasboundary import lasboundary
from processing.lidar.lastools.lasgrid import lasgrid
from processing.lidar.lastools.lasground import lasground
from processing.lidar.lastools.lasheight import lasheight
from processing.lidar.lastools.lasclassify import lasclassify
from processing.lidar.lastools.laszip import laszip
from processing.lidar.lastools.lasindex import lasindex
from processing.lidar.lastools.lasclip import lasclip
from processing.lidar.lastools.lasheight import lasheight
from processing.lidar.lastools.lasthin import lasthin
from processing.lidar.lastools.lasnoise import lasnoise
from processing.lidar.lastools.lassort import lassort
from processing.lidar.lastools.lastile import lastile
from processing.lidar.lastools.lasgrid import lasgrid
from processing.lidar.lastools.lasview import lasview
from processing.lidar.lastools.lasboundary import lasboundary
from processing.lidar.lastools.lasinfo import lasinfo
from processing.lidar.lastools.las2dem import las2dem
from processing.lidar.lastools.blast2dem import blast2dem
from processing.lidar.lastools.las2iso import las2iso
from processing.lidar.lastools.las2las_filter import las2las_filter
from processing.lidar.lastools.las2las_transform import las2las_transform
from processing.lidar.lastools.blast2iso import blast2iso
from processing.lidar.lastools.lasprecision import lasprecision
from processing.lidar.lastools.lasvalidate import lasvalidate
from processing.lidar.lastools.lasduplicate import lasduplicate
from processing.lidar.lastools.las2txt import las2txt
from processing.lidar.lastools.txt2las import txt2las
from processing.lidar.lastools.las2shp import las2shp
from processing.lidar.lastools.shp2las import shp2las
from processing.lidar.lastools.lasmerge import lasmerge
from processing.lidar.lastools.lassplit import lassplit
from processing.lidar.lastools.lascanopy import lascanopy
from processing.lidar.lastools.lasoverage import lasoverage
from processing.lidar.lastools.lasoverlap import lasoverlap
"""
"""
from processing.lidar.fusion.OpenViewerAction import OpenViewerAction
from processing.lidar.fusion.CanopyMaxima import CanopyMaxima
from processing.lidar.fusion.CanopyModel import CanopyModel
@@ -55,20 +81,18 @@
from processing.lidar.fusion.FilterData import FilterData
from processing.lidar.fusion.FusionUtils import FusionUtils


class LidarToolsAlgorithmProvider(AlgorithmProvider):

def __init__(self):
AlgorithmProvider.__init__(self)
self.activate = False
self.algsList = []
if isWindows():
lastools = [las2shp(), lasboundary(), las2dem(), las2iso(), lasgrid(), lasground(),
lasinfo(), lasheight(), lasprecision(), lassplit(), lasclassify(), lasclip()]
lastools = [lasground(), lasheight(), lasclassify(), lasclip(), lastile(), lasgrid(), las2dem(), blast2dem(), las2iso(), blast2iso(), lasview(), lasboundary(), lasinfo(), lasprecision(), lasvalidate(), lasduplicate(), las2txt(), txt2las(), laszip(), lasindex(), lasthin(), lassort(), lascanopy(), lasmerge(), las2shp(), shp2las(), lasnoise(), lassplit(), las2las_filter(), las2las_transform(), lasoverage(), lasoverlap()]
else:
lastools = [lasinfo(), lasprecision()]
lastools = [lasinfo(), lasprecision(), lasvalidate(), las2txt(), txt2las(), laszip(), lasindex(), lasmerge(), las2las_filter(), las2las_transform()]
for alg in lastools:
alg.group = "LASTools"
alg.group = "LAStools"
self.algsList.extend(lastools)

if isWindows():
@@ -81,9 +105,8 @@ def __init__(self):

def initializeSettings(self):
AlgorithmProvider.initializeSettings(self)
ProcessingConfig.addSetting(Setting(self.getDescription(), LasToolsUtils.LASTOOLS_FOLDER, "LASTools folder", LasToolsUtils.LasToolsPath()))
ProcessingConfig.addSetting(Setting(self.getDescription(), FusionUtils.FUSION_FOLDER, "Fusion folder",
FusionUtils.FusionPath()))
ProcessingConfig.addSetting(Setting(self.getDescription(), LAStoolsUtils.LASTOOLS_FOLDER, "LAStools folder", LAStoolsUtils.LAStoolsPath()))
ProcessingConfig.addSetting(Setting(self.getDescription(), FusionUtils.FUSION_FOLDER, "Fusion folder", FusionUtils.FusionPath()))

def getName(self):
return "lidartools"
@@ -98,4 +121,4 @@ def _loadAlgorithms(self):
self.algs = self.algsList

def getSupportedOutputTableExtensions(self):
return ["csv"]
return ["csv"]
@@ -17,19 +17,20 @@
***************************************************************************
"""


__author__ = 'Victor Olaya'
__date__ = 'August 2012'
__copyright__ = '(C) 2012, Victor Olaya'
# This will get replaced with a git SHA1 when you do a git archive
__revision__ = '$Format:%H$'

import os
from PyQt4.QtCore import *
from PyQt4.QtGui import *
import subprocess
from processing.core.ProcessingLog import ProcessingLog
from processing.core.ProcessingConfig import ProcessingConfig
import os
from processing.tools.system import *
from processing.tools.system import userFolder

class FusionUtils():

@@ -43,4 +43,4 @@ def execute(self):
if os.path.exists(f):
subprocess.Popen(f)
else:
QtGui.QMessageBox.critical(None, "Unable to open viewer", "The current Fusion folder does not contain the viewer executable.\nPlease check the configuration in the processing settings dialog.")
QtGui.QMessageBox.critical(None, "Unable to open viewer", "The current Fusion folder does not contain the viewer executable.\nPlease check the configuration in the Processing settings dialog.")

0 comments on commit 1ad2334

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