Class ZPngLidarFrameEncoder¶
Defined in File zpng_lidarframe_encoder.h
Inheritance Relationships¶
Base Type¶
public ouster::sdk::osf::LidarFrameEncoderClass LidarFrameEncoder
Class Documentation¶
-
class ZPngLidarFrameEncoder : public ouster::sdk::osf::LidarFrameEncoder¶
Zlib-compressed PNG encoder for lidar frame fields.
This is a more performant variant of `PngLidarFrameEncoder.
Public Functions
-
inline ZPngLidarFrameEncoder(int compression_amount)¶
Construct a ZPngLidarFrameEncoder with a specified compression level.
- Parameters:
compression_amount[in] Compression level passed to zlib (0 = none, 9 = max).
-
virtual FrameChannelData encode_field(const ouster::sdk::core::Field &field, const std::vector<int> &px_offset = {}) const override¶
This method encodes a field, if px_offset is provided it is destaggered before encoding.
- Parameters:
field[in] The field to encode (e.g., RANGE, SIGNAL).
px_offset[in] Optional pixel offsets for destaggering the data.
- Throws:
std::runtime_error – If encoding fails (e.g., invalid field shape, unsupported field type, or backend encoding errors).
- Returns:
Encoded binary data representing the field.
-
inline ZPngLidarFrameEncoder(int compression_amount)¶