A class for targa pictures. More...
#include <targa.hpp>
Classes | |
class | file_structure |
Tool class used for defining the structures of the datas stored in a targa file. More... | |
struct | pixel16 |
A pixel color in 16 bits in targa files. More... | |
struct | pixel8 |
A pixel color in 8 bits in targa files. More... | |
class | reader |
This class read data from a targa file and store it in an image. More... | |
class | writer |
This class write an image in a targa file. More... | |
Public Member Functions | |
targa (unsigned int w, unsigned int h) | |
Constructor. Creates an empty image. | |
targa (const image &that) | |
Copy constructor. | |
targa (std::istream &f) | |
Constructor. Load an image from a targa file. | |
void | save (std::ostream &os, bool rle) const |
Save the content of the image in a stream. | |
Private Types | |
typedef color_palette < rgba_pixel_8 > | color_palette32 |
A color palette of RGBA colors. |
A class for targa pictures.
Definition at line 48 of file targa.hpp.
typedef color_palette<rgba_pixel_8> claw::graphic::targa::color_palette32 [private] |
claw::graphic::targa::targa | ( | unsigned int | w, | |
unsigned int | h | |||
) |
Constructor. Creates an empty image.
w | Image's width. | |
h | Image's height. |
Definition at line 39 of file targa.cpp.
00040 : claw::graphic::image(w, h) 00041 { 00042 00043 } // targa::targa() [constructor]
claw::graphic::targa::targa | ( | const image & | that | ) |
Copy constructor.
that | Image to copy from. |
Definition at line 50 of file targa.cpp.
00051 : claw::graphic::image(that) 00052 { 00053 00054 } // targa::targa() [copy constructor]
claw::graphic::targa::targa | ( | std::istream & | f | ) |
void claw::graphic::targa::save | ( | std::ostream & | os, | |
bool | rle | |||
) | const |
Save the content of the image in a stream.
os | The stream in which we write. | |
rle | Tell if we must encode the data. |
Definition at line 72 of file targa.cpp.
Referenced by claw::graphic::targa::writer::writer().