The type of the output buffer associated with the file when encoding RLE data. More...
#include <pcx.hpp>
Public Types | |
typedef u_int_8 | pattern_type |
The typ of the output patterns. | |
Public Member Functions | |
file_output_buffer (std::ostream &os) | |
Constructor. | |
void | encode (unsigned int n, pattern_type pattern) |
Encode a pixel data. | |
template<typename Iterator > | |
void | raw (Iterator first, Iterator last) |
Write raw data int the stream. | |
unsigned int | min_interesting () const |
Get the minimum number of pixels needed for encoding. | |
unsigned int | max_encodable () const |
Get the maximum number of pixel a code can encode. | |
Private Attributes | |
std::ostream & | m_stream |
The stream in which we write. |
The type of the output buffer associated with the file when encoding RLE data.
Definition at line 311 of file pcx.hpp.
claw::graphic::pcx::writer::file_output_buffer::file_output_buffer | ( | std::ostream & | os | ) |
Constructor.
os | The stream in which we write the encoded data. |
Definition at line 38 of file pcx_writer.cpp.
: m_stream(os) { } // pcx::writer::file_output_buffer::file_output_buffer()
void claw::graphic::pcx::writer::file_output_buffer::encode | ( | unsigned int | n, | |
pattern_type | pattern | |||
) |
Encode a pixel data.
n | The number of time the pixel appears. | |
pattern | The data of the pixel. |
Definition at line 51 of file pcx_writer.cpp.
unsigned int claw::graphic::pcx::writer::file_output_buffer::max_encodable | ( | ) | const |
Get the maximum number of pixel a code can encode.
Definition at line 77 of file pcx_writer.cpp.
{ return 63; } // pcx::writer::file_output_buffer::max_encodable()
unsigned int claw::graphic::pcx::writer::file_output_buffer::min_interesting | ( | ) | const |
Get the minimum number of pixels needed for encoding.
Definition at line 67 of file pcx_writer.cpp.
{ return 1; } // pcx::writer::file_output_buffer::min_interesting()
void claw::graphic::pcx::writer::file_output_buffer::raw | ( | Iterator | first, | |
Iterator | last | |||
) |
Write raw data int the stream.
first | Iterator on the first data. | |
last | Iterator past the last data. |
Definition at line 40 of file pcx_writer.tpp.
References CLAW_ASSERT.
{ CLAW_ASSERT( false, "This method should not have been called" ); } // pcx::writer::file_output_buffer::raw()
std::ostream& claw::graphic::pcx::writer::file_output_buffer::m_stream [private] |