mreutegg / laszip4j

The LASzip library ported to Java
GNU Lesser General Public License v2.1
34 stars 15 forks source link

Request for example code or use information #1

Closed gwlucastrig closed 7 years ago

gwlucastrig commented 7 years ago

First off, let me say that I am very pleased to see this project. I have been thinking about implementing a LAZ file decoder for months, and was daunted by the complexity of the implementation.

Would it be possible to post example code showing how to read data from an LAZ file? Perhaps it could go on the wiki page. I would like to integrate the LAZ library into an application that reads and displays lidar files. It already handles LAS files, but I would like to extend it to read LAZ files. I spent a couple of hours reading through your code, but am not sure of the best way to proceed.

Also, is there a discussion forum or group for this project?

Thanks again and good luck with your project.

mreutegg commented 7 years ago

Thanks for your interest in laszip4j. As you noticed already, the current state of the library is not that user friendly. Right now it's simply an incomplete Java port of the LASzip and LAStools libraries. I'll update this issue when I have examples ready that are more useful. In the meantime you could try the main Laszip class as used by the example in the README.md.

gwlucastrig commented 7 years ago

Thanks for the advice. I will follow your suggestions.

I look forward to seeing the progress of laszip4j in the future. Your software has a great deal of potential application in my own github Tinfour project and I am sure other developers will find it valuable as well.

mreutegg commented 7 years ago

I just added some convenience classes that make it easier to read point data from LAZ files. See the updated README. The changes are not yet released but you can still try them by building and using current master branch.

gwlucastrig commented 7 years ago

Thanks, Marcel. I'll let you know how it goes.

gwlucastrig commented 7 years ago

Marcel,

Did a quick experimental integration of your code into the Tinfour viewer. Downloaded an LAZ file from the Canton of Zurich website you referenced and was able to plot it. The only difficult part was reading German :-)

tinfourcantonofzurich

gwlucastrig commented 7 years ago

As I mentioned in my last post, I was able to integrate support for LAZ files in an experimental version of my Tinfour viewer. I would like to add this capability to the version I distribute through the Tinfour Project. Do you feel that your library is ready to be distributed as part of a separate application? Would doing so be okay with you?

If you would prefer to discuss this matter separately from this tracker item, my email information is given in my github profile.

Thanks again for your excellent work!

gwlucastrig commented 7 years ago

Have a question about your API. I don't seem to be able to get access to a LAS "withheld" status in the LASpoint class. Is there a way to do that? Does the LASReader iterator automatically screen out withheld samples?

Thanks.

mreutegg commented 7 years ago

You are right. Some flags were missing in the LASPoint class. I added accessors for "Synthetic", "Key-point" and "Withheld" flags and released laszip4j 0.3.

I'm not sure about the withheld samples, but I think the reader does not automatically filters them out.

gwlucastrig commented 7 years ago

Thanks

On Feb 10, 2017 2:33 PM, "Marcel Reutegger" notifications@github.com wrote:

You are right. Some flags were missing in the LASPoint class. I added accessors for "Synthetic", "Key-point" and "Withheld" flags and released laszip4j 0.3.

I'm not sure about the withheld samples, but I think the reader does not automatically filters them out.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/mreutegg/laszip4j/issues/1#issuecomment-279043634, or mute the thread https://github.com/notifications/unsubscribe-auth/ASyR4WLt43-eMTLu1FWu7qcQvuVdSg_Eks5rbLuRgaJpZM4LXkDH .

gwlucastrig commented 7 years ago

Marcel,

Is there a way to get a point value for a record in the LAZ file by record number or index. In my application, I have a function that lets the user get the sample closest to a particular pair of points. To build the display, I only retain a partial set of data (raw x, y, z, and index) and use a random-access operation to pull up the full set of data for the sample selected by the user (intensity, return number, time stamp, etc.). I can do this with a LAS file and it looks like Martin Isenburg's design is intended to support random access. Has that been implemented in the laszip4j API?

Thanks.

mreutegg commented 7 years ago

The LASReader now has additional methods to restrict the returned points to a tile, rectangle or circle. Those are the same as available for LAStools. An index file created by lasindex will speed up access. See also https://www.cs.unc.edu/~isenburg/lastools/download/lasindex_README.txt