Skip to content

Instantly share code, notes, and snippets.

View jasonbeverage's full-sized avatar

Jason Beverage jasonbeverage

View GitHub Profile
@1papaya
1papaya / gdal_ecw.sh
Last active June 13, 2024 18:04
Install GDAL 2.3 with ECW support on Ubuntu 18.04
#!/bin/bash
##
## Tested on: Ubuntu 18.04 & ECW 5.4 & GDAL 2.3.1
##
## Download the ERDAS ECW JP2 SDK v5.4 Linux
## https://download.hexagongeospatial.com/downloads/ecw/erdas-ecw-jp2-sdk-v5-4-linux
## Download GDAL v2.3 Source (ex. 2.3.1)
@jasonbeverage
jasonbeverage / gist:4d277a96e9e86f198f9eee8789fd2903
Last active November 22, 2019 15:03
Build osg and osgearth against vcpkg for my machine
# Build osg with vcpkg
cmake .. -G "Visual Studio 15 2017 Win64" -DCMAKE_TOOLCHAIN_FILE=d:\dev\vcpkg\scripts\buildsystems\vcpkg.cmake -DWIN32_USE_MP=ON -DCMAKE_INSTALL_PREFIX=d:\dev\Installs\OpenSceneGraph -DCMAKE_BUILD_TYPE=Release
cmake --build . --target INSTALL --config Release
# Build osgearth with vcpkg and local osg
cmake .. -G "Visual Studio 15 2017 Win64" -DOSG_DIR=d:\dev\Installs\OpenSceneGraph -DWIN32_USE_MP=ON -DCMAKE_TOOLCHAIN_FILE=d:\dev\vcpkg\scripts\buildsystems\vcpkg.cmake -DWIN32_USE_MP=ON -DCMAKE_INSTALL_PREFIX=d:\dev\Installs\osgEarth -DCMAKE_BUILD_TYPE=Release
cmake --build . --target INSTALL --config Release
@YKCzoli
YKCzoli / Lidar_walkthrough.md
Last active November 15, 2023 18:35
Lidar_walkthrough

Processing LiDAR to extract building heights

Walk through

Detailed walk through of building extraction using postgis

First lets pull a data layer from of openstreetmap. You can do this any which way you’d like, as there are a variety of methods for pulling openstreetmap data from their database. Check the [wiki] (http://wiki.openstreetmap.org/wiki/Downloading_data) for a comprehensive list. My favourite method thus far is pulling the data straight into QGIS using the open layers plugin. For those who may want to explore this method, check [this tutorial] (http://www.qgistutorials.com/en/docs/downloading_osm_data.html). For building extraction you only need building footprints, and include the building tags. Not all polygons are of type building in OSM, so we can download all the polygons, and then filter the layer for only polygons tagged as buildings.

LiDAR data was pulled from USGS via the Earth Explorer site. [Here] (http://earthobservatory.nasa.gov/blogs/ele