[pdal] Reading and Writing outside of a stage

Jason Beverage jasonbeverage at gmail.com
Mon Jul 17 19:29:40 PDT 2017


Hi all,

I'm new to PDAL and I'm currently porting an existing point cloud tookit we
have at Pelican Mapping to use PDAL instead of LASTools and I had a couple
of questions.

Our toolkit is similar to Entwine in that it takes a large number of input
points from LAS/LAZ files and chops them up into tiled LAZ files with the
goal of displaying them in OpenSceneGraph and osgEarth based applications.

Since we're dealing with a huge number of points, I'm making heavy use of
streaming so I can avoid keeping the entire dataset in memory.

For reading, I found the StreamCallbackFilter so I can intercept the points
coming from a stage and process them one by one as I was doing before, so I
think that will work for my case.

For writing however, I'm running into a bit of snag probably due to my lack
of understanding of the streaming API.

We basically have an algorithm that does something like this:

for each point in all the input points:
    // Figure out which output file to write the point to based on it's
location.
    Writer* writer = getWriter(point);
    writer->writePoint(writer);

So we create a bunch of output writers (using LASTools) based on an octree
split, and for each point we determine which writer to write to and write
the incoming point to the appropriate output file.

Is there a simple way to write points interactively to a Writer?  It seems
like if the write functions of Writer were public that it would be fairly
easy to implement something like that.

Thanks!

Jason
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/pdal/attachments/20170718/67f76529/attachment.html>


More information about the pdal mailing list