Grok 10.0.0
|
#include <IBufferedStream.h>
Public Member Functions | |
virtual | ~IBufferedStream ()=default |
virtual bool | supportsZeroCopy ()=0 |
virtual uint8_t * | getZeroCopyPtr ()=0 |
virtual size_t | read (uint8_t *buffer, size_t p_size)=0 |
Reads some bytes from the stream. More... | |
virtual bool | writeShort (uint16_t value)=0 |
virtual bool | write24 (uint32_t value)=0 |
virtual bool | writeInt (uint32_t value)=0 |
virtual bool | write64 (uint64_t value)=0 |
virtual bool | writeByte (uint8_t value)=0 |
virtual size_t | writeBytes (const uint8_t *buffer, size_t p_size)=0 |
Write bytes to the stream. More... | |
virtual bool | flush ()=0 |
Flush write stream to disk. More... | |
virtual bool | skip (int64_t p_size)=0 |
Skip bytes in stream, forward or reverse. More... | |
virtual uint64_t | tell (void)=0 |
Tell byte offset in stream (similar to ftell). More... | |
virtual uint64_t | numBytesLeft (void)=0 |
Get number of bytes left before end of the stream. More... | |
virtual bool | seek (uint64_t offset)=0 |
Seek to absolute offset in stream. More... | |
virtual bool | hasSeek ()=0 |
Check if stream is seekable. More... | |
|
virtualdefault |
|
pure virtual |
Flush write stream to disk.
Implemented in grk::BufferedStream.
Referenced by grk::CodeStreamCompress::write_eoc().
|
pure virtual |
Implemented in grk::BufferedStream.
Referenced by grk::TileProcessor::cacheTilePartPackets().
|
pure virtual |
Check if stream is seekable.
(A stdin/stdout stream is not seekable).
Implemented in grk::BufferedStream.
|
pure virtual |
Get number of bytes left before end of the stream.
Implemented in grk::BufferedStream.
Referenced by grk::TileProcessor::cacheTilePartPackets(), grk::CodeStreamDecompress::endOfCodeStream(), grk::CodeStreamDecompress::parseTileParts(), grk::CodeStreamDecompress::process_marker(), grk::FileFormatDecompress::read_box_hdr(), and grk::TileProcessor::setTilePartDataLength().
|
pure virtual |
Reads some bytes from the stream.
buffer | pointer to the data buffer that will receive the data. If null, then a zero copy read is performed |
p_size | number of bytes to read. |
Implemented in grk::BufferedStream.
Referenced by grk::TileProcessor::cacheTilePartPackets(), grk::CodeStreamDecompress::process_marker(), grk::FileFormatDecompress::read_box_hdr(), grk::CodeStreamDecompress::read_short(), and grk::CodeStreamDecompress::read_soc().
|
pure virtual |
Seek to absolute offset in stream.
offset | absolute offset in stream |
Implemented in grk::BufferedStream.
Referenced by grk::TileLengthMarkers::seek(), grk::CodeStreamInfo::seekFirstTilePart(), grk::SOTMarker::write_psot(), and grk::TileLengthMarkers::writeEnd().
|
pure virtual |
Skip bytes in stream, forward or reverse.
p_size | the number of bytes to skip. |
Implemented in grk::BufferedStream.
Referenced by grk::CodeStreamDecompress::parseTileParts(), and grk::TileLengthMarkers::writeBegin().
|
pure virtual |
Implemented in grk::BufferedStream.
Referenced by grk::TileProcessor::cacheTilePartPackets().
|
pure virtual |
Tell byte offset in stream (similar to ftell).
Implemented in grk::BufferedStream.
Referenced by grk::CodeStreamCompress::cacheEndOfHeader(), grk::TileProcessor::cacheTilePartPackets(), grk::T2Compress::compressPacket(), grk::CodeStreamDecompress::nextTLM(), grk::CodeStreamDecompress::parseTileParts(), grk::CodeStreamDecompress::read_soc(), grk::CodeStreamDecompress::read_unk(), grk::CodeStreamDecompress::readHeaderProcedureImpl(), grk::TileLengthMarkers::seek(), grk::CodeStreamCompress::updateRates(), grk::SOTMarker::write_psot(), grk::TileLengthMarkers::writeBegin(), grk::TileLengthMarkers::writeEnd(), and grk::CodeStreamCompress::writeTilePart().
|
pure virtual |
Implemented in grk::BufferedStream.
Referenced by grk::CodeStreamCompress::write_mcc_record().
|
pure virtual |
Implemented in grk::BufferedStream.
|
pure virtual |
Implemented in grk::BufferedStream.
Referenced by grk::T2Compress::compressPacket(), grk::SIZMarker::write(), grk::CodeStreamCompress::write_cbd(), grk::CodeStreamCompress::write_coc(), grk::CodeStreamCompress::write_cod(), grk::CodeStreamCompress::write_mcc_record(), grk::CodeStreamCompress::write_mco(), grk::CodeStreamCompress::write_qcc(), grk::CodeStreamCompress::write_rgn(), grk::CodeStreamCompress::write_SPCod_SPCoc(), grk::CodeStreamCompress::write_SQcd_SQcc(), grk::TileLengthMarkers::writeBegin(), grk::BitIO::writeByte(), and grk::CodeStreamCompress::writePoc().
|
pure virtual |
Write bytes to the stream.
buffer | pointer to the data buffer to be written. |
p_size | number of bytes to write. |
Implemented in grk::BufferedStream.
Referenced by grk::T2Compress::compressPacket(), grk::PLMarkerMgr::write(), grk::CodeStreamCompress::write_com(), and grk::CodeStreamCompress::write_mct_record().
|
pure virtual |
Implemented in grk::BufferedStream.
Referenced by grk::SIZMarker::write(), ojph::QuantizerOJPH::write(), openhtj2k::QuantizerOpenHTJ2K::write(), grk::SOTMarker::write_psot(), and grk::TileLengthMarkers::writeEnd().
|
pure virtual |
Implemented in grk::BufferedStream.
Referenced by grk::SIZMarker::write(), ojph::QuantizerOJPH::write(), openhtj2k::QuantizerOpenHTJ2K::write(), grk::PLMarkerMgr::write(), grk::CodeStreamCompress::write_cbd(), grk::CodeStreamCompress::write_coc(), grk::CodeStreamCompress::write_cod(), grk::CodeStreamCompress::write_com(), grk::CodeStreamCompress::write_eoc(), grk::CodeStreamCompress::write_mcc_record(), grk::CodeStreamCompress::write_mco(), grk::CodeStreamCompress::write_mct_record(), grk::CodeStreamCompress::write_qcc(), grk::CodeStreamCompress::write_qcd(), grk::CodeStreamCompress::write_rgn(), grk::CodeStreamCompress::write_soc(), grk::CodeStreamCompress::write_SQcd_SQcc(), grk::TileLengthMarkers::writeBegin(), grk::TileLengthMarkers::writeEnd(), grk::CodeStreamCompress::writePoc(), and grk::TileProcessor::writeTilePartT2().