Documentation ¶
Overview ¶
Package las implements read access to LASF style lidar files. All header versions (0, 1, 2, 3, 4) are supported.
Index ¶
Constants ¶
const ( LASF_OK = iota LASF_CANTOPEN LASF_CANTREAD LASF_INVALIDHANDLE LASF_INVALIDINDEX LASF_INVALIDPOINT LASF_ERROR )
Variables ¶
var ErrInvalidFormat = errors.New("Invalid point record format")
var ErrInvalidIndex = errors.New("Invalid point record index")
Functions ¶
func LasfPointX ¶
func LasfPointY ¶
func LasfPointZ ¶
func LasfReadNextPoint ¶
Types ¶
type GpsTimePacket ¶
type GpsTimePacket float64
Base types
func (GpsTimePacket) GpsTime ¶
func (gps GpsTimePacket) GpsTime() float64
func (*GpsTimePacket) SetGpsTime ¶
func (gps *GpsTimePacket) SetGpsTime(t float64)
type Lasf ¶
type Lasf struct {
// contains filtered or unexported fields
}
func Open ¶
Open attempts to open filename and read the LASF header. If the file is not a valid LASF file, or it cannot be opened, nil and the associated error is returned.
func (*Lasf) BuildQuadTree ¶
func (las *Lasf) BuildQuadTree()
BuildQuadTree creates a simple spatial index to potentially speed up filtered reads using GetNextPoint.
func (*Lasf) ClearFilter ¶
func (las *Lasf) ClearFilter()
ClearFilter clears the spatial filter. Rewind() is called and sequential reading is reset.
func (*Lasf) GetNextPoint ¶
GetNextPoint reads the next point in the file. After the file is opened and any VLRs are read into memory, the file pointer is set to the first point. Each call to GetNextPoint returns the next point in the file. This sequence is interupted if GetPoint is explicitly called. This means GetNextPoint returns point n, then a call GetPoint(m), GetNextPoint will return point at m+1, not n+1. If there is an error reading the point, or if we seek past the end of the points, nil and error are returned.
type Pointer ¶
type Pointer interface { RecordFormat() uint8 X() float64 Y() float64 Z() float64 Intensity() uint16 RetNum() uint8 RetCount() uint8 ScanFlag() uint8 Edge() uint8 Classification() uint8 //ClassificationString string ScanAngle() int16 UserData() uint8 PointSourceID() uint16 GpsTime() float64 Red() uint16 Green() uint16 Blue() uint16 NIR() uint16 WavePacketDesc() uint8 WaveOffset() uint64 WaveSize() uint32 //ReturnPointWaveLoc uint32 X_t() float32 Y_t() float32 Z_t() float32 }
type TextAreaDescVlr ¶
type TextAreaDescVlr struct { }