[Liblas-devel] libLAS in Java

Mateusz Loskot mateusz at loskot.net
Tue Jul 14 11:35:05 EDT 2009


Patel, Ronak Avinash (US SSA) wrote:
> Hi,
> 
> I was wondering if anyone could educate me what the exact bit structure
> is arranged for entering Coordinate System information into a LAS file.
> 
> The LAS spec says that it is located inside of the Variable Length
> Record section. Could anyone point me to any information about this?

Ronak,

I'd be happy if SRS handling in LAS was as easy as juggling some bits,
unfortunately it is not.

In libLAS, we employ GeoTIFF engine to handle SRS information:
- first, check record class

http://liblas.org/browser/trunk/include/liblas/lasvariablerecord.hpp
http://liblas.org/browser/trunk/src/lasvariablerecord.cpp

- next, check this class - it's a kind of a specialized type of 
variable-length record - it wraps SRS logic

http://liblas.org/browser/trunk/include/liblas/lasspatialreference.hpp

- finally, check how SRS is read and write using the two above:

http://liblas.org/browser/trunk/src/detail/writer.cpp#L130
http://liblas.org/browser/trunk/src/detail/reader.cpp#L156

I'd be happy to provide you with simpler or even Java-oriented
explanation, but I am not aware of any. I hope this will help.

Best regards,
-- 
Mateusz Loskot, http://mateusz.loskot.net


More information about the Liblas-devel mailing list