Question

How do you populate a point cloud geometry in a custom reader

  • 31 January 2018
  • 4 replies
  • 0 views

I'm writing a custom format reader to read our custom point cloud format. The sdk is not clear on how to add points to a point cloud. I only have 4 components x, y, z & intensity.


4 replies

Badge

Hi @ma2cdw

have you tried FME PointCloud XYZ Reader? Can it be used to read your custom point cloud format?

Hi @ma2cdw

have you tried FME PointCloud XYZ Reader? Can it be used to read your custom point cloud format?

Hi @LenaAtSafe,

 

Thanks for the suggestion. I have tried that, unfortunately, the files store several blocks of scaled offsets. The origins and scales for each block are stored on an SQLite database along with the index of the start point and the number of points in the block.

 

 

Badge
Hi @LenaAtSafe,

 

Thanks for the suggestion. I have tried that, unfortunately, the files store several blocks of scaled offsets. The origins and scales for each block are stored on an SQLite database along with the index of the start point and the number of points in the block.

 

 

Would you have a small data sample? I don't think I fully understand your data.

 

Would maybe PointCloudTransformationApplier be helpful?

 

 

Would you have a small data sample? I don't think I fully understand your data.

 

Would maybe PointCloudTransformationApplier be helpful?

 

 

To read the data you need to select the blocks from the SQLite database (*.os3d6)

 

 

SELECT DISTINCT BLOCKIDX, LASERBLOCK.LASERID, X, Y, Z, SCALE, NAME, FIRSTPOINT, NUMPOINTS, LINREF FROM LASERBLOCK JOIN FILE ON LASERBLOCK.FILEID = FILE.ID JOIN LASERLOD ON LASERLOD.LOD = LASERBLOCK.LOD WHERE LASERBLOCK.LOD = 4 ORDER BY LASERBLOCK.LASERID,LASERBLOCK.BLOCKIDX

 

 

Each block gives you a filename, a point index where the block starts within the file and how many points there are within the block, the centre of the block in real-world coordinates and a scale factor for the x,y&z; offsets from the block centre stored in the laser6 files.

 

 

The laser6 files are not straightforward XYZ files so I have attached some c++ code for reading them. If it's of any help.

 

 

fme-os3d6-reader.zip

 

 

The PointCloudTransformationApplier could be useful if we can pass the centre coordinates and scale to it.

 

Reply