Coder Social home page Coder Social logo

domlysz / blendergis Goto Github PK

View Code? Open in Web Editor NEW
7.3K 262.0 1.3K 3.94 MB

Blender addons to make the bridge between Blender and geographic data

License: GNU General Public License v3.0

Python 100.00%
blender addon geospatial gis shapefile delaunay-triangulation raster openstreetmap python dem

blendergis's Introduction

Blender GIS

Blender minimum version required : v2.83

Note : Since 2022, the OpenTopography web service requires an API key. Please register to opentopography.org and request a key. This service is still free.

Functionalities overview

GIS datafile import : Import in Blender most commons GIS data format : Shapefile vector, raster image, geotiff DEM, OpenStreetMap xml.

There are a lot of possibilities to create a 3D terrain from geographic data with BlenderGIS, check the Flowchart to have an overview.

Exemple : import vector contour lines, create faces by triangulation and put a topographic raster texture.

Grab geodata directly from the web : display dynamics web maps inside Blender 3d view, requests for OpenStreetMap data (buildings, roads ...), get true elevation data from the NASA SRTM mission.

And more : Manage georeferencing informations of a scene, compute a terrain mesh by Delaunay triangulation, drop objects on a terrain mesh, make terrain analysis using shader nodes, setup new cameras from geotagged photos, setup a camera to render with Blender a new georeferenced raster.

blendergis's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

blendergis's Issues

Place the Georef Cam higher

Sometimes I get black holes when I render the image:

screen shot 2016-05-30 at 21 25 32

This happens when there is a single peak that is higher than surrounding terrain. Is it possible to have the camera higher by default, so it's above all parts of the DEM?

only connect verts with different heights in delaunay triangulation

Hi Domlysz,
At the moment, the Delaunay triangulation sometime gives plateaus were there shouldn't be one. It is due to the fact that verts of the same height are taken as candidates, even if edges are already present. Here is a blend showing the problem and what "bridge edge loops" does. Would it be possible to have an option 'ignore verts of the same height' or better, ignore them automatically when verts are in an edge?

[enhancement] Move selection (offset to georef)

Hi,
I've some files with objects allready georeferenced, and would like to be able to append them to current scene.

In such scenario, linked objects are imported with current scene origin offset added.
It could be usefull to offset selection from current scene georeference.
Maybe 2 small buttons (add and remove offset) could do the trick.

3/5 add-ons don't show up in Blender v2.69

Greetings,

I'm having some trouble installing BlenderGIS in Blender v2.69. The "Set reference cam" and "Import raster georeferenced with world file" add-ons appear and install just fine (see picture), but the other three add-ons in the BlenderGIS package (io_shapefile, terrain_analysis, and delaunay_voronoi) do not.

I looked at the "init.py" for the "io_shapefile" add-on, and nothing in the "# Register in File > Import menu" section looked drastically different from the same section in the working "io_import_georaster.py" script, so I can't identify the problem that prevents Blender from adding io_shapefile to the add-ons list.

The only thing I noticed that all the non-working add-ons have in common is that they are in folders with multiple scripts, whereas the working add-ons are standalone scripts.

Any insight would be most appreciated!

bgis_add-ons

[feature] Import / export gps path for drones

Hi,
Currently working to implement io for gps based path to setup (dji phantom like) drones fly path (kml, kmz) right in blender.

Got a rougth implementation reading kmz (path only) from earth and kml export still needing some love (especially altitude as relative ones instead of absolutes - we do have to make some more tests).

The export has proven to be a pretty good basis to setup fly, and tracked movie resulting path show a realy small derivation in xy coords of 0.3m only (with a constant 3m +- 0.5 on z axis mostly due to setup error). So it's working like a charm.

Adding Mac OSX & Linux support in documentation

Hi Dominique,

I saw your great Wiki and the installation for gdal python bindings inside blender ont this page : https://github.com/domlysz/BlenderGIS/wiki/How-to-install-GDAL
It's very helpfull but there is windows only installation. I don't use Windows. According to you, I would want to add other plateform to your wiki.

Mac Osx
Tested on Yosemite 10.10 and Blender 2.74
1) Install Xcode and Macports from this link :
https://www.macports.org/install.php

2) Install gdal and gdal python bindings
Open a terminal from spotlight or from Applications => Utilities => Terminal
Then type with administratives rights :

sudo port install gdal py34-gdal

3) Copy osgeo folder from python bindings to blender

cp -rf /opt/local/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/osgeo /where_you_put_blender_on_your_mac/Blender/blender.app/Contents/Resources/2.74/scripts/modules/

Replace where_you_put_blender_on_your_mac with the path where you run or install Blender

Test it in Blender Python console like windows installation.


I think there is a mistake in the wiki with this :
Finally, to get GDAL working in Blender, just copy osgeo folder in Python tree folder of Blender (C:\Program Files\Blender Foundation\Blender\2.70\python\lib\site-packages).
If I put the osgeo folder in the same path like you recommand (python/lib/site-packages), I'm not able to launch gdal from blender. When I put osgeo in blender's module folder, It works !

Sorry for my poor english, I'm french ...

Sincerely,

Sylvain

Problem install complements os x 10.10 blender

Hi, i'm new in this.
When i try install complements in blender i can't, and appear a message saying Traceback (Most recent call last):

File"/" applications/blender.app/contents/MacOs/2.71/scripts/addons/basemaps/init.py",line 45,in <module form.mapviewer import*>

and other similar messages, i don`t know, any help me please?.

Operate System: Os X 10.10
Blender 2.7

Thanks!

Off by half pixel when importing geo-referenced raster images

Hi,

Thanks for developing this add-on, it helped me a lot.

The issue is I think related that the export code of QGIS (and maybe other programs) specifies the world coordinates for the center of the corner pixels, not the corners of the image. It is particularly visible when importing images that should tile perfectly (and do tile perfectly when importing in QGIS), when importing them in Blender there is a small gap between each tile image.

importing OSM fails

Hi Domlysz,
"path to long for windows, overpass request failed" is printed in the console output.
Regards

Pyproj not defined when opening user preference dialog on windows 10

Hi,
When i do open the user prefs dialog to setup a CRS, i get the following error :

Traceback (most recent call last):
File "C:\Program Files\Blender Foundation\Blender\2.77\scripts\startup\bl_ui\space_userpref.py", line 1437, in draw
draw(context)
File "C:\Users\stephen\AppData\Roaming\Blender Foundation\Blender\2.77\scripts\addons\BlenderGIS-master\prefs.py", line 96, in draw
elif pyproj:
NameError: name 'pyproj' is not defined

Seem to be a lower case error in pyproj. replace by PYPROJ fix this issue.

field selection options do not show up in Ubuntu 16.04 LTS when importing SHP file

Hi I have blender 2.77a installed on Ubuntu 16.04 along with your great add on. Unfortunately I have not been able to successfully use it on linux (although I have tried on Windows 7 and it worked fine). What Im getting when importing a SHP file is after checking the box next to either "Elevation from field", or "Extrusion from field", no dropdown appears with field options.

Thanks!

fail to enable in blender 2.77

Hello
i can install the addon without any problems but when i try to enable it blender complain about numpy, i copy the traceback bellow
its only ocuur in blender 2.77
in blender 2.74 it work like a charm
tnaks Claudio
Traceback (most recent call last):
File "/usr/share/blender/2.77/scripts/modules/addon_utils.py", line 330, in enable
mod = import(module_name)
File "/home/claudio/.config/blender/2.77/scripts/addons/BlenderGIS-master/init.py", line 43, in
from .basemaps import mapviewer
File "/home/claudio/.config/blender/2.77/scripts/addons/BlenderGIS-master/basemaps/mapviewer.py", line 36, in
from .mapservice import MapService, PILLOW
File "/home/claudio/.config/blender/2.77/scripts/addons/BlenderGIS-master/basemaps/mapservice.py", line 41, in
import numpy as np
File "/usr/lib/python3/dist-packages/numpy/init.py", line 153, in
from . import add_newdocs
File "/usr/lib/python3/dist-packages/numpy/add_newdocs.py", line 13, in
from numpy.lib import add_newdoc
File "/usr/lib/python3/dist-packages/numpy/lib/init.py", line 8, in
from .type_check import *
File "/usr/lib/python3/dist-packages/numpy/lib/type_check.py", line 11, in
import numpy.core.numeric as _nx
File "/usr/lib/python3/dist-packages/numpy/core/init.py", line 6, in
from . import multiarray
ImportError: cannot import name 'multiarray'

Problem with instalation

When testing the instalation runing "from osgeo import gdal", i get this error (see image). Also when i try to enable the Add-ons "3D View: [bigs] Basemaps" & "Node Editor: [bigs] Terrain analysis" i get an error (also shown in image at the top).

I'm running 2.77 on windows 7
error blender

Thanks!

Add compatibility with Blender-geo

https://github.com/vvoovv/blender-geo

It use transverse Mercator projection (not UTM) with dynamically calculated central meridian to minimize distortions. The central meridian comes through the center of the imported area.

https://github.com/vvoovv/blender-geo/wiki/Georeferenced-Blender-Scene

proj4 string equivalent:

+a=6378137 +b=6378137 +proj=tmerc +lat_0=0 +lon_0=6 +k_0=1 +x_0=0 +y_0=0 +units=m
with lon_0 = central meridian (here 6°)

To get this compatibility reprojection capability is needed with consequences :

  • more dependencies (pyproj, proj4, gdal ...)
  • why reimplementing a complex task like reprojection through a Blender addon while dedicated software like QGIS can do it in a more efficient way ?
  • need to store projection definition in scene (proj4 string or EPSG code)
  • determine input projection from user or from data isn't always an easy task...

Cache Folder?

"Please define a valid cache folder path ... " when I try to use this. Serveral path I did enter but the message appears ever.

Bmesh does not exist before Blender 2.63

Hi, thanks for your great tool.

I was unable to use the 3D viewer with my default ubuntu packaged blender (v 2.62, for ubuntu 12.04 LTS) because you import bmesh, which is included from 2.63. My advice is:
a) in the readme (or wiki) add a compatibility issue and tell to use v>=2.63
or
b) fix it ;) (painfully?)

cheers

Consider importing 3D buildings

I have just imported an osm file and works great (love the filter per key type). However I thought buildings would be in 3D but they are "only" flat elements.

According to this OSM's wiki on 3D buildings, OSM offers some tags that are used to store information about buildings that could be used to generate 3D meshes instead of flat ones.

Amongst others, I find these ones could be interesting to be imported:

  • building:levels (as there are many more buildings that have this information instead of this one building:height
  • roof:shape (which can be flat, skillion, gabled, half-hipped, hipped, pyramidal, gambrel, mansard, dome, onion,round, saltbox )
  • roof:orientation=along/across
  • roof:direction=*

Additionally, these ones could be considered too:

  • roof:height
  • roof:angle

About compatibility with dxf export

Bonjour Dominique,

J'ai une question sur les exports, je souhaiterais exporter en dxf, ce qui est possible dans Blender d'origine (qui produit d'ailleurs un résultat très propre d'un DEM en TIN) mais je perds mon géoréférencement. Du coup, ma question porte sur "comment ça fonctionne" pour réexporter en conservant le géoréfrencement.

Si je me réfère à ça
if "Georef X" in scn and "Georef Y" in scn:
dx, dy = scn["Georef X"], scn["Georef Y"]
else:
dx, dy = (0, 0)
Le dx et dy correspond au centre de l'objet importé ou centre de la scene ? Je pense que c'est l'objet et du coup je pourrais exporter en DXF géoréférencé en déplaçant mon objet avant de l'exporter grâce à bpy.data.scenes['Scene']['Georef X'] et bpy.data.scenes['Scene']['Georef Y'] que j'ai pu récupéré dans la console python

Du coup un simple déplacement devrait suffir pour que ce soit efficace avec :
bpy.ops.transform.translate(value=dx, dy, 0)

J'ai testé dans la console python puis export et ouverture dans Draftsight, ça fonctionne. Il faut que je scripte tout ça maintenant. Serais-tu intéressé pour l'intégrer dans le projet BlenderGIS ?

Cdt,

Sylvain

Handle null values when getting object's names from field

I must say that this plugin is one of the best I've ever seen. What huge potential here, thank you for working so hard on it.

I have quite a few attributes in my shapefile (.dbf?) such as building names. Is there anyway to map them to each 3d item as well? If not perhaps this can be another enhancement opportunity to map attributes with to each Blender item created. Thanks again.

Saving blend file with GeoTIFF as plane and DEM "forgets" settings

I have an odd problem. I create a new blender project with a GeoTIFF DEM added as plane and then again as DEM. I add a geo-referenced camera and have everything setup to render a lovely hill-shaded image. If I render the image after saving project and without closing the project I get the expected output. If I save the project, close it and then re-open it I get a flat grey image without any of the relief. All the settings are saved as set.

Any suggestions as to what might be happening here? I have 91 tiles to render and would like to batch process them by setting up the .blend files and letting them run overnight instead of having to manually run each one.

Image created without closing Blender file
Image created after saving, closing and re-opening Blender file

This happens on both Windows 7 64bit and Linux Mint 18 64bit with the Blender GIS extension added. Other Blender projects created without using the extension reopen correctly. I have attached the Blender file that create the first image above: 8_3.zip

And the GeoTIFF: int_tiff.zip

Suggestion: Elevation from Nasa SRTM

Hi,
The nasa with it's SRTM data is I think the best source of elevation data that is freely accessible. Would it be possible to download the right SRTM data for the zone we work on and use the greyscale data in the displace modifier?

Applying a rotation transformation to a Shapefile mesh can cause errors in the TIN

This quirk isn't a big deal, but it caught me out, so I thought I'd raise it as an issue...

After importing a Shapefile, if you rotate the mesh and apply the transformation before using the Delaunay triangulation utility, the TIN will have errors in it. For example:

TIN created by rotating Shapefile mesh without applying the rotation:

screen shot 2016-12-14 at 20 41 44

TIN created by rotating Shapefile mesh and applying the rotation:

screen shot 2016-12-14 at 20 48 46

Constraint delaunay triangulation to inside

Hi,

Do someone know if there is a way to constraint delaunay trinagulation to inside of a polygon or point ? Or a way to clean the mesh after triangulation.

Points over the mesh
capture du 2016-06-27 15-04-45

Orange edges are unwanted
capture du 2016-06-27 15-10-11

Sincerely,

Sylvain

Georeferencing

Hello, sorry if my question sounds easy, but I'm new in this.

I am trying to use BlenderGIS to georefence a 3D model in Blender. I managed to install the addon, but i can't find any CRS in Geoscene preferences. I want to use Lambert-93 (EPSG:2154 with transformation : 1671, according to epsg.io). I tryed to type these different codes in the Query, but keyword searh doesn't seem to work ...

What can I do ?
Thank you

Handle missing values when extruding shapes

I'm processing a shapefile that has missing values for the variable I'm using to extrude shapes. The values were generated by the QGIS zonal statistics plugin which produces a value of all asterisks, in this case, e.g.:

Id         : 0D4F7142E65527B3E050A00A568A259B
Featcode   : 15014
mean       : ************************

The version of pyshp bundled here doesn't handle this properly. The latest version at (https://github.com/GeospatialPython/pyshp) returns a value of None in this case.

But this still causes BlenderGIS to error. It would be better to handle these explicitly in your code, e.g. by setting the value to 0 for if the field value is None.

The bundled version of the shapefile library is also two years old so this should be updated too.

shape file are too small after import

Hi Domlysz,
When I import one of the files included in http://download.geofabrik.de/europe/germany/baden-wuerttemberg/freiburg-regbez-latest.shp.zip , although I added the epsg code you gave in the dxf thread in user prefs and I used it on import, it is too small (the whole region is smaller than the default cube). When I import the SHP after importing the DXF it works like a charm.
The console output:

Read shapefile...
Feature type : PolyLine
0%, 10%, 20%, 30%, 40%, 50%, 60%, 70%, 80%, 90%, 100%
Imported mesh had some problem, check the result!
PyContext 'window' not found
PyContext 'window' not found
PyContext 'scene' not found
PyContext 'screen' not found
PyContext 'screen' not found
PyContext 'gpencil_data' not found
PyContext 'screen' not found
PyContext 'screen' not found
PyContext 'edit_object' not found
PyContext 'screen' not found
PyContext 'screen' not found
PyContext 'window' not found

Problem importing raster DEM

I highly doubt this is a bug, but I hope somebody can give me guidance. When I attempt to import a 16-bit raster DEM in tif format, I get very unusual results. See graphic at this link:
http://www.sco.wisc.edu/images/stories/download/blender2.png

However, the DEM looks as expected in QGIS:
http://www.sco.wisc.edu/images/stories/download/qgis.png

The process I used in Blender after installing BlenderGIS: file... import... georeferenced raster... Mode as DEM. Did not apply on an existing mesh.

Any thoughts on where I am going wrong? The process to import a DEM seems very straightforward.

Extrusion always occurs along "local" z axis

As stated,when you set an attribute for "extrusion from field" while importing shapefile, extrusion always happens along the normal of the face (in a polygon). If your polygon has a non-horizontal base but you still want to just extrude it along the global z axis, you can't achieve the result

screen
screen_extr

gdal and basemap make blender crash on windows 7 x64

With latest buildbot and Gdal installed as you say in the docs (really good quality doc, I hope more plugins devs would document their addon like you). But I get following error and crash: http://www.pasteall.org/69995
I took gdal 2.0.2 and had to update numpy to 1.10.4, just like in your doc also. Note that the crash also happened before updating Numpy, so it's not due to Numpy I guess.
The tests from gdal import ... all work correctly in the python console without error.

Zoom to mouse position breaks alignement of 3D data and basemap if not over (0,0,0)

When zooming in the viewport after aligning the 3D datas and the basemaps, the alignment is lost. It looks like the basemap is being zoomed to mouse position, but not the 3D view, which is zoomed toward 0,0,0. (even when zoom to mouse position is activated in the Blender's user prefs)
Zooming when the mouse is over 0,0,0 works great.

Improve shp importer performance

Currently shp importer is terribly slow with large or even intermediate dataset especially with extrusion and separate object options.

Test file submitted by BenRacicot :
pvd-shp.zip

Currently the code extensively use list comprehension with all dataset in memory. Using iterator/generator can help to not overloading memory.
http://gis.stackexchange.com/questions/148834/creating-a-really-large-shapefile-without-eating-all-the-virtual-memory
https://github.com/mlaloux/PyShp-as-Fiona--with-geo_interface-

However it doesn't seems to be the real limitation here, Python can handle very large dataset with decent performance while Blender's 3d view can really be slow down with too many object or large mesh.

Profiling the code show that separate objects performance drop down is caused by implicit scene updates calls through repetitive operators executions inside place obj function
more infos and possible workaround : http://blender.stackexchange.com/questions/7358/python-performance-with-blender-operators.
In our case we need to find an alternative to bpy.ops for setting objects origin to geometry

For extrusion, bmesh.ops.extrude_face_region is the most cumbersome operation, it seems more tricky to find a workaround here

Basemaps plugin giving an error

when I try to enable the Basemaps plugin from the add-ons panel, i get an error (see attached image). I'm running 2.77.

image

Thanks all.

Warning on console in windows

When Blender starts, their is a warning regarding geoscene:

Warning: addon-module 'geoscene' found module but without addon_enabled field, possible name collision from file: 'C:\Users\test\AppData\Roaming\Blender Foundation\Blender\2.77\scripts\addons\geoscene*init*.py'
module changed on disk: C:\Users\test\AppData\Roaming\Blender Foundation\Blender\2.77\scripts\addons\geoscene__init__.py reloading...

2.78 map viewer

Hi,
Map viewer fails to download background images under windows 10 and 2.78a
Have to setup :

  • GDAL-2.0.3-cp35-cp35m-win_amd64.whl
  • numpy-1.11.2+mkl-cp35-cp35m-win_amd64.whl

Basemap is 1.477x to big?

Hi Domlysz,
First of all, your addon is really impressive and useful!
I tried to get the basemap align with the 3D DTM from maperitive. But somehow, there is a light scale difference. The 3D model from maperitive aligns perfectly with .osm datas downloaded from the overpass API of openstreetmap.
What I've tried so far to solve the problem:

  • set blender to metric system
  • Set the right CRS system for the location
    But even with those 2 options, the basemap is bigger. I tried to find the factor by scaling the OSM import and I found it to be around 1.477.
    Would it be possible to have the basemap have the real scale?

Segmentation fault when importing Shapefile the second time

When calling the BlenderGIS addon from my own script, I'm getting a segmentation fault when importing a Shapefile for the second time (it works fine the first time).

Here's a minimal example:

import bpy
from os.path import abspath, dirname
from bpy import context

bpy.ops.importgis.shapefile("INVOKE_DEFAULT", filepath = abspath(dirname(__file__))+"/shapefile.shp", shpCRS="EPSG:27700", fieldElevName="ELEV", separateObjects = False) # Works fine

bpy.ops.importgis.shapefile("INVOKE_DEFAULT", filepath = abspath(dirname(__file__))+"/shapefile.shp", shpCRS="EPSG:27700", fieldElevName="ELEV", separateObjects = False) # Causes Blender to crash

I'm using Blender 2.78 on Mac OS 10.12.1. Here's the terminal output:

Jamies-MBP:Documents jamie$ /Applications/blender.app/Contents/MacOS/blender -b -noaudio -P Minimal.py
Read new prefs: /Users/jamie/Library/Application Support/Blender/2.78/config/userpref.blend
found bundled python: /Applications/blender.app/Contents/MacOS/../Resources/2.78/python
Exception in module register(): '/Users/jamie/Library/Application Support/Blender/2.78/scripts/addons/BlenderGIS-master/__init__.py'
Traceback (most recent call last):
  File "/Applications/blender.app/Contents/MacOS/../Resources/2.78/scripts/modules/addon_utils.py", line 349, in enable
    mod.register()
  File "/Users/jamie/Library/Application Support/Blender/2.78/scripts/addons/BlenderGIS-master/__init__.py", line 131, in register
    km = wm.keyconfigs.active.keymaps['3D View']
AttributeError: 'NoneType' object has no attribute 'keymaps'
Read shapefile...
Feature type : PolyLine
0%, 10%, 20%, 30%, 40%, 50%, 60%, 70%, 80%, 90%, 100%
Build in 0.404313 seconds
Read shapefile...
Feature type : PolyLine
0%, 10%, 20%, 30%, 40%, 50%, 60%, 70%, 80%, 90%, 100%
Build in 1.482001 seconds
Writing: /var/folders/c2/wz9svkyd1qv1lpnzbcpvbxlr0000gn/T/blender.crash.txt
Segmentation fault: 11

blender.crash.txt is attached, along with a zip of the Shapefile (I get the same error with various Shapefiles).

Moving images to the wiki repo

I would suggest to move images to the wiki repo:
[email protected]:domlysz/BlenderGIS.wiki.git

Each wiki forms a separate git repo. One can work with it like with a usual git repo.

To clone the wiki just execute:
git clone [email protected]:domlysz/BlenderGIS.wiki.git

Then move images to the wiki repo, commit and push them back

Import failed for attached file

When I try to import shp file from this archive:
BD3_Bero00_polygonZ.zip
script crashes with following error:

Traceback (most recent call last):
  File "/home/disnel/.config/blender/2.77/scripts/addons/io_shapefile/op_import_shp.py", line 300, in execute
    for i, feat in enumerate(shpIter):
  File "/home/disnel/.config/blender/2.77/scripts/addons/io_shapefile/shapefile.py", line 437, in iterShapes
    yield self.__shape()    
  File "/home/disnel/.config/blender/2.77/scripts/addons/io_shapefile/shapefile.py", line 357, in __shape
    (mmin, mmax) = unpack("<2d", f.read(16))
struct.error: unpack requires a bytes object of length 16

location: <unknown location>:-1

location: <unknown location>:-1

When I try to comment out lines 356 - 364, file is imported fine, but it probably breaks something else.

Also, I experienced Blender crashes on files imported from SHP, here is related bugreport:

https://developer.blender.org/T48239

Don't know, if it is related to SHP importer or not. These crashes occurs with or without commented lines in script, however.

UPDATE: Importer produces inccorect mesh for this (and similar) file. Instructed by Campbell Barton from BF I added mesh validation into script as temporary fix. Will make pull request for it. This does not solve original problem, however.

UPDATE 2: According to SHP spec on wiki (https://en.wikipedia.org/wiki/Shapefile#Shapefile_shape_format_.28.shp.29), M range values are optional but import script is expecting them in all cases. Will try to fix it.

roadmap

  • Make first consistent release tagged 1.0

  • doc
    add gdal_data path info

  • ui
    update enum index after adding a new crs

  • geoscene
    ensure scale support
    geo append functionnality

  • prefs
    vector import (shp & osm) >> remove double option

  • reproj
    epsg.io limit to 100 features or 1000 points
    builtin reproj table 3857>4326 & 4326>UTM >> 3857>UTM

  • basemaps
    add option for setting storage days
    background image layer manager >> reorder, view on/off, opacity
    when panning, update all existing bkg images location (send a list as parameter)
    split getimage() to have a dedicated seedCache(bbox) function

  • georaster
    reproj via uv mapping or gdal
    read crs from geotags

  • shp import
    attribute data support at import and export
    read proj from *.prj using http://prj2epsg.org/apidocs.html service
    select & import multiple files
    check geom
    progress bar
    test recent pyshp speed up PR

  • shp export
    performance tests

  • OSM import
    extrude or flat option
    get height from MNS
    interpret roof shape
    fix separate objects origin

  • terrain analysis
    svg ramp parse error (see BA thread)

  • georef cam
    cam z position parameter

  • exif cam

  • lib Tyf
    read crs from geotags (see georaster)
    harmonize jpeg and tiff, implement iter, dumps to dict

  • Utils tools
    drop to ground
    display geocoords for selected vertex in edit mode

  • SRTM online downloader
    http://www.opentopography.org/developers
    http://elevation.bopen.eu/en/stable/quickstart.html

  • LIDAR
    best lib ?
    pure python laspy (must be updated to py3)
    libLAS python binding
    pylidar, lot of py deps and rely on lastools
    PDAL ?
    extrude building footprint with height value from lidar data

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.