Further compression and png work.
This commit is contained in:
parent
318b481ccc
commit
9c8faa534b
34 changed files with 1164 additions and 203 deletions
35
src/core/streams/InputBitStream.cpp
Normal file
35
src/core/streams/InputBitStream.cpp
Normal file
|
@ -0,0 +1,35 @@
|
|||
#include "InputBitStream.h"
|
||||
|
||||
InputBitStream::InputBitStream(std::basic_istream<unsigned char>* stream)
|
||||
: BitStream(),
|
||||
mStream(stream)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
bool InputBitStream::isFinished() const
|
||||
{
|
||||
return mStream->good();
|
||||
}
|
||||
|
||||
std::vector<unsigned char> InputBitStream::peekNextNBytes(unsigned n) const
|
||||
{
|
||||
return {};
|
||||
}
|
||||
|
||||
std::optional<unsigned char> InputBitStream::readNextByte()
|
||||
{
|
||||
if (mStream->good())
|
||||
{
|
||||
return mStream->get();
|
||||
}
|
||||
else
|
||||
{
|
||||
return std::nullopt;
|
||||
}
|
||||
}
|
||||
|
||||
void InputBitStream::writeByte(unsigned char data)
|
||||
{
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue