33 typedef unsigned char uint8_t;
34 typedef unsigned int uint32_t;
35 #if defined(HOKUYOAIST_STATIC)
36 #define HOKUYOAIST_EXPORT
37 #elif defined(hokuyoaist_EXPORTS)
38 #define HOKUYOAIST_EXPORT __declspec(dllexport)
40 #define HOKUYOAIST_EXPORT __declspec(dllimport)
44 #define HOKUYOAIST_EXPORT
86 unsigned int ranges_length,
87 uint32_t*
const intensities_buffer=0,
88 unsigned int intensities_length=0);
102 {
return intensities_; }
160 bool include_intensities =
false);
Structure to store data returned from the laser scanner.
unsigned long long system_time_
std::string error_code_to_string(uint32_t error_code)
Return a string representing the error for the given error code.
ScanData & operator=(ScanData const &rhs)
Assignment operator.
const uint32_t * ranges() const
Return a pointer to array of range readings in millimetres.
unsigned int laser_time_stamp() const
Get the raw time stamp of the data in milliseconds.
ScanData(ScanData const &rhs)
This copy constructor performs a deep copy of present data.
unsigned int intensities_length() const
Get the number of intensity samples in the data.
void write_intensity(unsigned int index, uint32_t value)
void write_range(unsigned int index, uint32_t value)
LaserModel model() const
Get the model of the laser that produced this scan.
bool get_error_status() const
Indicates if one or more steps had an error.
bool buffers_provided() const
Check if the buffers are being provided instead of automatic.
ScanData(uint32_t *const ranges_buffer, unsigned int ranges_length, uint32_t *const intensities_buffer=0, unsigned int intensities_length=0)
This constructor uses a provided data buffer rather than allocating automatically.
void clean_up()
Force the data to clean up.
const uint32_t * intensities() const
Return a pointer to an array of intensity readings.
unsigned int intensities_length_
std::string as_string()
Format the entire object into a string.
uint32_t operator[](unsigned int index)
Subscript operator.
unsigned int ranges_length() const
Get the number of range samples in the data.
void allocate_data(unsigned int length, bool include_intensities=false)
unsigned int ranges_length_
unsigned long long system_time_stamp() const
Get the system time stamp of the data in milliseconds.
ScanData()
This constructor creates an empty ScanData with no data currently allocated.
Hokuyo laser scanner class.
#define HOKUYOAIST_EXPORT