[Liblas-devel] Point implementation proposal
mateusz at loskot.net
Sun Jul 25 19:20:00 EDT 2010
On Wed, 2010-06-30 at 16:04 -0500, Howard Butler wrote:
> I would like to propose that we (well, I rather) re-engineer the internal workings of the liblas::Point class to do the following:
> * carry around its raw data in the form of a boost::array
> * interpret its raw data *on-the-fly* for each fixed attribute call (GetIntensity, GetX, GetClassification, etc) we currently support.
> * provide a method for fetching the complete uninterpreted data array on liblas::Point
> * optionally carry a pointer to a liblas::Header for scaling and schema information. Points read off of a file, for example, will have a back reference to their header
> * provide (some day) a generic schema-aware interface for fetching interpreted data from the point. The first pass implementation is going to leave it to the developer to read the schema and interpret the data
> A related item of this work would be beefing up the liblas::PointFormat class (this hadn't been released yet, but existed in the unreleased repository code), renaming it to liblas::Schema, and adding reader/writer support to store these things in libLAS-only VLRs.
Sounds good to me.
A variation of this could be to physically separate responsibilities.
By default, I/O operation could be performed on raw data, without any
interpretation. Interpretation is left to user.
User has liberty to choose to use point interpreter provided by libLAS
or to implement his own.
A point interpreter could be passed to reader for better, seamless
Mateusz Loskot, http://mateusz.loskot.net
Charter Member of OSGeo, http://osgeo.org
More information about the Liblas-devel