The base class for reading image data. More...
#include <GnashImage.h>
Public Member Functions | |
| ImageInput (boost::shared_ptr< IOChannel > in) | |
| Construct an ImageInput object to read from an IOChannel. | |
| virtual | ~ImageInput () |
| virtual void | read ()=0 |
| Begin processing the image data. | |
| virtual size_t | getHeight () const =0 |
| Get the image's height in pixels. | |
| virtual size_t | getWidth () const =0 |
| Get the image's width in pixels. | |
| virtual size_t | getComponents () const =0 |
| Get number of components (channels). | |
| virtual void | readScanline (unsigned char *rgbData)=0 |
| Read a scanline's worth of image data into the given buffer. | |
| ImageType | imageType () |
| Get the ImageType of the image. | |
Static Public Member Functions | |
| static DSOEXPORT std::auto_ptr < ImageRGBA > | readSWFJpeg3 (boost::shared_ptr< gnash::IOChannel > in) |
| For reading SWF JPEG3-style image data, like ordinary JPEG, but stores the data in ImageRGBA format. | |
| static DSOEXPORT std::auto_ptr < GnashImage > | readImageData (boost::shared_ptr< gnash::IOChannel > in, FileType type) |
| Read image data from an IOChannel into an GnashImage. | |
Protected Attributes | |
| boost::shared_ptr< IOChannel > | _inStream |
| ImageType | _type |
The base class for reading image data.
| gnash::ImageInput::ImageInput | ( | boost::shared_ptr< IOChannel > | in | ) | [inline] |
Construct an ImageInput object to read from an IOChannel.
| in | The stream to read data from. Ownership is shared between caller and ImageInput, so it is freed automatically when the last owner is destroyed. |
| virtual gnash::ImageInput::~ImageInput | ( | ) | [inline, virtual] |
| virtual size_t gnash::ImageInput::getComponents | ( | ) | const [pure virtual] |
Get number of components (channels).
Implemented in gnash::GifImageInput, and gnash::JpegImageInput.
| virtual size_t gnash::ImageInput::getHeight | ( | ) | const [pure virtual] |
Get the image's height in pixels.
Implemented in gnash::GifImageInput, gnash::JpegImageInput, and gnash::PngImageInput.
| virtual size_t gnash::ImageInput::getWidth | ( | ) | const [pure virtual] |
Get the image's width in pixels.
Implemented in gnash::GifImageInput, gnash::JpegImageInput, and gnash::PngImageInput.
| ImageType gnash::ImageInput::imageType | ( | ) | [inline] |
| virtual void gnash::ImageInput::read | ( | ) | [pure virtual] |
Begin processing the image data.
Implemented in gnash::GifImageInput, gnash::JpegImageInput, and gnash::PngImageInput.
| static DSOEXPORT std::auto_ptr<GnashImage> gnash::ImageInput::readImageData | ( | boost::shared_ptr< gnash::IOChannel > | in, | |
| FileType | type | |||
| ) | [static] |
Read image data from an IOChannel into an GnashImage.
| in | The IOChannel to read the image from. | |
| type | The type of image to read. |
| virtual void gnash::ImageInput::readScanline | ( | unsigned char * | rgbData | ) | [pure virtual] |
Read a scanline's worth of image data into the given buffer.
| rgbData | The buffer for writing raw RGB data to. |
Implemented in gnash::GifImageInput, gnash::JpegImageInput, and gnash::PngImageInput.
| static DSOEXPORT std::auto_ptr<ImageRGBA> gnash::ImageInput::readSWFJpeg3 | ( | boost::shared_ptr< gnash::IOChannel > | in | ) | [static] |
boost::shared_ptr<IOChannel> gnash::ImageInput::_inStream [protected] |
ImageType gnash::ImageInput::_type [protected] |
Referenced by imageType(), and gnash::JpegImageInput::read().
1.7.1