Buffer
Just a good old buffer. All other messages derive from theBuffer class.Reference
class
dai::Buffer
variable
int64_t sequenceNum
variable
Timestamp ts
variable
Timestamp tsDevice
function
Buffer()function
Buffer(size_t size)function
Buffer(long fd)function
Buffer(long fd, size_t size)function
~Buffer()function
void serialize(std::vector< std::uint8_t > & metadata, DatatypeEnum & datatype)function
span< uint8_t > getData()function
span< const uint8_t > getData()function
void setData(const std::vector< std::uint8_t > & data)Parameters
- data: Copies data to internal buffer
function
void setData(const long fd)function
void setData(std::vector< std::uint8_t > && data)Parameters
- data: Moves data to internal buffer
function
std::chrono::time_point< std::chrono::steady_clock, std::chrono::steady_clock::duration > getTimestamp()Retrieves timestamp related to dai::Clock::now()
function
std::chrono::time_point< std::chrono::steady_clock, std::chrono::steady_clock::duration > getTimestampDevice()Retrieves timestamp directly captured from device's monotonic clock, not synchronized to host time. Used mostly for debugging
function
void setTimestamp(std::chrono::time_point< std::chrono::steady_clock, std::chrono::steady_clock::duration > timestamp)Sets image timestamp related to dai::Clock::now()
function
void setTimestampDevice(std::chrono::time_point< std::chrono::steady_clock, std::chrono::steady_clock::duration > timestamp)Sets image timestamp related to dai::Clock::now()
function
int64_t getSequenceNum()Retrieves image sequence number
function
void setSequenceNum(int64_t sequenceNum)Sets image sequence number
function
span< const uint8_t > getRecordData()function
dai::VisualizeType getVisualizationMessage()Get visualizable message
Returns
function
DEPTHAI_SERIALIZE(Buffer, sequenceNum, ts, tsDevice)Need assistance?
Head over to Discussion Forum for technical support or any other questions you might have.