DanTDBV
Member
Updated 31/1-2017. Comments about experience's with exported mesh added. Tutorial is finished.
This is to keep others from having as bumpy, a ride into this as i have had. Many frustrations.
Finding the right way into LIDAR point clouds, is like navigating a dense jungle.
There are so many purposes and ways to use LIDAR data, that we have acces to a forest full of free and paid for software, plus lots of file formats. Ad to that, all the things you can do to those files.
Created with CloudCompare 2.6.2 and Blender 2.76b
A heartfelt thankyou to Daniel Girardeau-Montaut, the creator of Cloudcompare. For creating the software and the pointers, that made this tutorial better.
What is LIDAR?
Lidar (also written LIDAR, LiDAR or LADAR) is a remote sensing technology that measures distance by illuminating a target with a laser and analyzing the reflected light. Although thought by some to be an acronym of Light Detection And Ranging, the term lidar was actually created as a portmanteau of "light" and "radar". Lidar is popularly used as a technology to make high-resolution maps, with applications in geodesy, geomatics,archaeology, geography, geology, geomorphology, seismology, forestry, remote sensing, atmospheric physics, airborne laser swath mapping (ALSM), laser altimetry, and contour mapping. (From Wikipedia).
Getting LIDAR data.
This is somewhat beyond the scope off this tutorial, but searching for geodata or height model, together with the country, should be a good starting point.
Software needed
CloudCompare
It is Open Source and can be downloaded here:
http://www.danielgm.net/cc/
CloudCompare supports import of 27 different file formats. There is a pretty fair chance, it will eat your file.
Before we start, a copyright notice needed for the data used.
Copyright notice Bellahøj Park Point cloud and Ortho photo
As required, according to this site: (In Danish)
http://download.kortforsyningen.dk/content/vilk%C3%A5r-og-betingelser
Contains data from Geodatastyrelsen and Danske kommuner Fot-data
Ekstracted lokation : Bellahøj Park Copenhagen
DHM/Point cloud
DLD 30/10-2015 Punktsky_617_72_LAZ_UTM32-ETRS89
Ekstracted lokation : Nisseringen Næstved
DHM/Point cloud
DLD 14/11-2015 Punktsky_612_68_LAZ_UTM32-ETRS89
http://download.kortforsyningen.dk/content/geodataprodukter
DLD = Download date
DanTDBV D@nN (My photo and film signature)
My experience's with exported mesh.
I have found that Blender, does not like the mesh, that comes out from CloudCompare.
I am now using MeshMixer to reduce the mesh. Erase & Fill, Reduce and Smooth are the tools I use.
Retopoflow and the Knive tool, are not working as expected. The creator of Retopoflow, has looked at it and he says, that it is behaving strangely.
Upon import in Blender, I am now moving the Origin, to somewhere inside the model. It does give a better behavier, but not much. I have decided, that I am capable of lining up parts manually. When using obj, it needs a 90 degree flip on the X axis.
Conclusion:
If stl or obj is the right choise, I really don't know, but Retopoflow is behaving a little better with obj.
Current way I do it.
Apply Global shift/scale upon import
Export full area, reduce in MeshMixer, that does not worry about reference/anchor/pivot point. Import in Blender, move origin to model, center it, then cut it to pieces.
On to the regular show
How do you do, you do, you do
I use LAZ files in this case. LAZ is a compressed LAS file.
Merge and select
I usually do a fast selection, of a wider area than needed and save that, before refining the area further.
After Segment out selection
Go and have a break. Do what you do to relax and refresh.
Welcome back. Are you ready?
Reference/anchor/pivot point.
Remember all the big numbers in the Global shift/scale dialog?
The numbers in the big box, is the placement of the reference/anchor/pivot point, in the file you open.
The numbers in the small box, is the placement of the reference/anchor/pivot point, in the file while you work.
The Global shift information is discarded, when exporting to .stl, so the reference/anchor/pivot point, coordinates will be the numbers from the little box.
Abandonned earlier conclusion.
For landscapes I prefer to have the pivot point, in the center of the model. It makes it easier to cut the model into managable pieces and reassemble them.
Moving reference/anchor/pivot point.
When you have it right, do another backup.
Very important!
Whenever you reload your centered cloud, do NOT! Shift the global scale!
Abandonned earlier conclusion.
I found that in cleaning a full res mesh in Meshmixer, I was reducing the areas I worked with about 70-90%. It is much easier to reduce the cloud, before creating the mesh.
This however have the disadvantage, that the terrain details is washed out. (Not as sharp as with the full resolution cloud).
I have decided to keep the full poly mesh and creating a low poly mesh over that.
It does however slows down the PC.
My solution is to cut the full poly mesh, into chunks that I work on seperatly. This is way more easier in than in Blender. At least from what I know. More about this below.
How I do it now
I export the full res mesh. Using Meshmixer's Erase & Fill, Reduce and Smooth tools as approriate.
Creating a reduced resolution Mesh
Cutting a mesh into chunks
Delete everything in CloudCompare. Or as I do, close and reopen CloudCompare. (You did remember to save your progress?)
Open the .stl file you created above.
I have used the resulting files in Meshlab, Meshmixer and Blender.
I would advise to lock the Location:, Rotation: and Scale: settings in Blender.
You are should now be ready, to continue in your favorite 3D program.
Some Blender information
Moving view close to the 3D cursor
I have kept this as it is usefull for other offcenter models.
When importing the mesh in Blender, you might find that the placement is off, to way off.
Chosing Yes to All for Global shift/scale, have seriosly reduced, the placement being off problem.
The following example, was with No to Global shift/scale.
This is not happening in Meshlab or Meshmixer, only in Blender.
One example is the model in the picture. Blenderunits from scene center:
Transform
Location
X=684203.25000
Y=6123295.5000
Z=55.56239
There are 6 cars in this picture, can you spot them?
The reason for this, is the Anchor/Pivot point of the model.
The Location coordinates tells, where in the world the Anchor/Pivot point is.
Move the pivot point into the model
The first step, is to get the 3D cursor, out to the model.
I had some trouble doing this. The 3D cursor would just not appear, when clicking close to the mesh. With the view back, on the center of the world, the cursor worked as advertised.
This is how I got it to work:
A fast way to move the model, is to change the Transform/Location values.
Transform
Location
X:684203.25000
Y:6123295.5000
Z:55.56239
Center of the world
X:0
Y:0
Z:0
To the best of my knowledge, I consider this tutorial finished.
Thank you for your patience. ;-)
Good luck.
If you have any questions, then do not hesitate to ask and I will do my best to answer.
Keep in mind that English, is not my first language.
Update history
Updated 31/1-2017. Comments about experience's with exported mesh added. Tutorial is finished.
27/1-2016. Software versions added. Tutorial is finished.
24/1-2016. Important note added to, Move reference/anchor/pivot point section.
23/1-2016. Move reference/anchor/pivot point + splitting mesh in CloudCompare sections added.
18/1-2016. Found a quicker way to do it.
This is to keep others from having as bumpy, a ride into this as i have had. Many frustrations.
Finding the right way into LIDAR point clouds, is like navigating a dense jungle.
There are so many purposes and ways to use LIDAR data, that we have acces to a forest full of free and paid for software, plus lots of file formats. Ad to that, all the things you can do to those files.
Created with CloudCompare 2.6.2 and Blender 2.76b
A heartfelt thankyou to Daniel Girardeau-Montaut, the creator of Cloudcompare. For creating the software and the pointers, that made this tutorial better.
What is LIDAR?
Lidar (also written LIDAR, LiDAR or LADAR) is a remote sensing technology that measures distance by illuminating a target with a laser and analyzing the reflected light. Although thought by some to be an acronym of Light Detection And Ranging, the term lidar was actually created as a portmanteau of "light" and "radar". Lidar is popularly used as a technology to make high-resolution maps, with applications in geodesy, geomatics,archaeology, geography, geology, geomorphology, seismology, forestry, remote sensing, atmospheric physics, airborne laser swath mapping (ALSM), laser altimetry, and contour mapping. (From Wikipedia).
Getting LIDAR data.
This is somewhat beyond the scope off this tutorial, but searching for geodata or height model, together with the country, should be a good starting point.
Software needed
CloudCompare
It is Open Source and can be downloaded here:
http://www.danielgm.net/cc/
CloudCompare supports import of 27 different file formats. There is a pretty fair chance, it will eat your file.
Before we start, a copyright notice needed for the data used.
Copyright notice Bellahøj Park Point cloud and Ortho photo
As required, according to this site: (In Danish)
http://download.kortforsyningen.dk/content/vilk%C3%A5r-og-betingelser
Contains data from Geodatastyrelsen and Danske kommuner Fot-data
Ekstracted lokation : Bellahøj Park Copenhagen
DHM/Point cloud
DLD 30/10-2015 Punktsky_617_72_LAZ_UTM32-ETRS89
Ekstracted lokation : Nisseringen Næstved
DHM/Point cloud
DLD 14/11-2015 Punktsky_612_68_LAZ_UTM32-ETRS89
http://download.kortforsyningen.dk/content/geodataprodukter
DLD = Download date
DanTDBV D@nN (My photo and film signature)
My experience's with exported mesh.
I have found that Blender, does not like the mesh, that comes out from CloudCompare.
I am now using MeshMixer to reduce the mesh. Erase & Fill, Reduce and Smooth are the tools I use.
Retopoflow and the Knive tool, are not working as expected. The creator of Retopoflow, has looked at it and he says, that it is behaving strangely.
Upon import in Blender, I am now moving the Origin, to somewhere inside the model. It does give a better behavier, but not much. I have decided, that I am capable of lining up parts manually. When using obj, it needs a 90 degree flip on the X axis.
Conclusion:
If stl or obj is the right choise, I really don't know, but Retopoflow is behaving a little better with obj.
Current way I do it.
Apply Global shift/scale upon import
Export full area, reduce in MeshMixer, that does not worry about reference/anchor/pivot point. Import in Blender, move origin to model, center it, then cut it to pieces.
On to the regular show
How do you do, you do, you do
I use LAZ files in this case. LAZ is a compressed LAS file.
- Open CloudCompare
- Open the file you wish to use. Select multiple files with Shift and Control
- Open LAS File Chose Apply all
- Global shift/scale Yes to All
- Navigation: Left mousebutton Rotate, Scroll wheel Zoom, Right mouse button Move
- You always need to select the file/s You want to work with.
Select each file in turn (In DB Tree chose the filename) - Change active Scalar Fields to Classification (This is the one I prefer to use)
Merge and select
I usually do a fast selection, of a wider area than needed and save that, before refining the area further.
- Control select all files (Same as above)
- Click Merge multiple clouds button in Top ToolBar (TTB)
- Adjust the view, until the desired area is visible
- Click Segment button in TTB (scissors)
- (Opens Segment toolbar. Hover mouse over tools for tool tips)
- Select area of cloud to keep. For an irregular area, use Polygonal selection
- If you are satisfied Hit Confirm segmentation. If you are not hit Clear segmentation. Cancel to quit
In DB Tree chose the parts, of the cloud you wish to discard. (I clear the checkmarks, from the parts I want to keep) Hit Delete - Select resulting file and save a backup. I have good experience with exporting as LAZ. I chose Highest resolution. LAS/LAZ comparison: LAS 287 MB, LAZ 40,6 MB.
- Now use the Segment tool, to remove the areas not visible from the track.
- Polygon selection makes it possible to do complex selections.
After Segment out selection
- Save another backup
Go and have a break. Do what you do to relax and refresh.
Welcome back. Are you ready?
Reference/anchor/pivot point.
Remember all the big numbers in the Global shift/scale dialog?
The numbers in the big box, is the placement of the reference/anchor/pivot point, in the file you open.
The numbers in the small box, is the placement of the reference/anchor/pivot point, in the file while you work.
The Global shift information is discarded, when exporting to .stl, so the reference/anchor/pivot point, coordinates will be the numbers from the little box.
Abandonned earlier conclusion.
For landscapes I prefer to have the pivot point, in the center of the model. It makes it easier to cut the model into managable pieces and reassemble them.
Moving reference/anchor/pivot point.
- Select the file
- Chose Edit
- Chose Edit global shift and scale
- Change X, Y, Z values to zero. Keep the scale.
- Hit yes
- Click Point picking in TTB
- Click on the point in the cloud, where you want the center to be.
- Write down X, Y, Z values. Click discard
- Select the file
- Chose Edit
- Chose Apply transformation
- Go to Axis, Angle pane
- Enter your written values, in the Translation section. You may need to check Apply inverse transformation.
- Hit Ok
- Select the file
- Chose Edit
- Chose Mesh
- Chose Delaunay 2.5D (XY plane) (Until now I have left Max egde length at default)
- Select the file
- Save as Binary .stl file.
When you have it right, do another backup.
Very important!
Whenever you reload your centered cloud, do NOT! Shift the global scale!
Your choise should be:- Global shift/scale No
- Select the file
- In the DB Tree Properties SF display params window, You can play around with the 2 circles until you only have the ground. (With the files I have, 2 is the ground)
- I find it easier to uncheck, show NaN/out of range values in grey, on the parameters pane.
- Chose Filter points by value in TTB
- Change both fields to your SF display params ground value
- Hit Ok
- Select Mesh and save. (I usually ad the levels to the name)
- Select the file
- Chose Edit
- Chose Mesh
- Chose Delaunay 2.5D (XY plane) (Until now I have left Max egde length at default)
- Select the file
- Save as Binary .stl file.
Abandonned earlier conclusion.
I found that in cleaning a full res mesh in Meshmixer, I was reducing the areas I worked with about 70-90%. It is much easier to reduce the cloud, before creating the mesh.
This however have the disadvantage, that the terrain details is washed out. (Not as sharp as with the full resolution cloud).
I have decided to keep the full poly mesh and creating a low poly mesh over that.
It does however slows down the PC.
My solution is to cut the full poly mesh, into chunks that I work on seperatly. This is way more easier in than in Blender. At least from what I know. More about this below.
How I do it now
I export the full res mesh. Using Meshmixer's Erase & Fill, Reduce and Smooth tools as approriate.
Creating a reduced resolution Mesh
- Select the file
- Chose Edit
- Chose Subsample
- Move the slider from small towards large, remember your setting, hit ok
- You can delete the resulting layer, without touching the base layer.
- Play around with this until you, are sattisfied with the cloud density.
- Select the file
- Chose Mesh
- Chose Delaunay 2.5D (XY plane) (Until now I have left Max egde length at default)
- Select the file
- Save as Binary .stl file.
Cutting a mesh into chunks
Delete everything in CloudCompare. Or as I do, close and reopen CloudCompare. (You did remember to save your progress?)
Open the .stl file you created above.
- Select the file
- Now use the Segment tool, to cut the mesh into managable chunks
- Keep only the parts you are working with visible
- If you have cut something, that should not have been, use the merge tool
- Save each part as you go
- Always uncheck the parts, you have exported
I have used the resulting files in Meshlab, Meshmixer and Blender.
I would advise to lock the Location:, Rotation: and Scale: settings in Blender.
You are should now be ready, to continue in your favorite 3D program.
Some Blender information
Moving view close to the 3D cursor
- Hit Alt/Home
I have kept this as it is usefull for other offcenter models.
When importing the mesh in Blender, you might find that the placement is off, to way off.
Chosing Yes to All for Global shift/scale, have seriosly reduced, the placement being off problem.
The following example, was with No to Global shift/scale.
This is not happening in Meshlab or Meshmixer, only in Blender.
One example is the model in the picture. Blenderunits from scene center:
Transform
Location
X=684203.25000
Y=6123295.5000
Z=55.56239
There are 6 cars in this picture, can you spot them?
The reason for this, is the Anchor/Pivot point of the model.
The Location coordinates tells, where in the world the Anchor/Pivot point is.
Move the pivot point into the model
The first step, is to get the 3D cursor, out to the model.
I had some trouble doing this. The 3D cursor would just not appear, when clicking close to the mesh. With the view back, on the center of the world, the cursor worked as advertised.
This is how I got it to work:
- Make sure that the model is selected
- Chose View Selected
- Change to Edit mode
- Hit A to deselect all
- Select a Vertex
- Change to Object mode
- Place the 3D cursor, where you want the Pivot point to be.
- Chose Object/Transform/Origin to 3D Cursor.
A fast way to move the model, is to change the Transform/Location values.
Transform
Location
X:684203.25000
Y:6123295.5000
Z:55.56239
Center of the world
X:0
Y:0
Z:0
To the best of my knowledge, I consider this tutorial finished.
Thank you for your patience. ;-)
Good luck.
If you have any questions, then do not hesitate to ask and I will do my best to answer.
Keep in mind that English, is not my first language.
Update history
Updated 31/1-2017. Comments about experience's with exported mesh added. Tutorial is finished.
27/1-2016. Software versions added. Tutorial is finished.
24/1-2016. Important note added to, Move reference/anchor/pivot point section.
23/1-2016. Move reference/anchor/pivot point + splitting mesh in CloudCompare sections added.
18/1-2016. Found a quicker way to do it.
Last edited: