Rogue Wave Views 5.6 |
Rogue Wave Views |
Rogue Wave Views Documentation Home |
Bitmap streamer base class. More...
#include <ilviews/bitmaps/streamer.h>
Public Member Functions | ||||
virtual void | callReadProgressCallback (IlUInt current, IlUInt max) | |||
Calls the callback for read progression. | ||||
virtual void | callWriteProgressCallback (IlUInt current, IlUInt max) | |||
Calls the callback for write progression. | ||||
virtual IlBoolean | canRead () const | |||
Indicates whether the instance can read from a stream. Default is IlFalse . | ||||
virtual IlBoolean | canWrite () const | |||
Indicates whether the instance can write to a stream. Default is IlFalse . | ||||
virtual IlBoolean | checkSignature (const IlUChar *data, IlUInt size)=0 | |||
Indicates whether the instance can handle the stream. | ||||
virtual const char * | getName () const | |||
Returns the internal name of the streamer. | ||||
IlvQuantizer * | getQuantizer () const | |||
Returns the quantizer used by this streamer. | ||||
virtual IlvBitmapData * | read (istream &stream) | |||
Reads from a stream. | ||||
virtual IlvBitmapInformation * | readInfo (istream &stream) | |||
Reads information from a stream. | ||||
void | setQuantizer (IlvQuantizer *quantizer) | |||
Sets the quantizer used (if needed) by this streamer. | ||||
virtual void | setReadProgressCallback (IlvProgressCallback rCallback, IlAny arg=0) | |||
Sets the callback for read progression. | ||||
virtual void | setWriteProgressCallback (IlvProgressCallback wCallback, IlAny arg=0) | |||
Sets the callback for write progression. | ||||
virtual IlBoolean | write (IlvBitmapData *bitmapData, ostream &stream) | |||
Writes an IlvBitmapData to a stream. | ||||
Static Public Member Functions | ||||
static void | Register (IlvBitmapStreamer *streamer) | |||
Registers the given streamer. | ||||
static IlBoolean | UnRegister (IlvBitmapStreamer *streamer) | |||
Unregisters the given streamer. | ||||
The name of the streamer. | ||||
Returns a streamer from its name.
| ||||
static IlIlvBitmapStreamersList * | _Streamers | |||
Returns the registered streamers. | ||||
IlAny | _argr | |||
Returns the registered streamers. | ||||
IlAny | _argw | |||
Returns the registered streamers. | ||||
IlvQuantizer * | _quantizer | |||
Returns the registered streamers. | ||||
IlvProgressCallback | _readProgressCallback | |||
Returns the registered streamers. | ||||
IlvProgressCallback | _writeProgressCallback | |||
Returns the registered streamers. | ||||
virtual | ~IlvBitmapStreamer () | |||
Returns the registered streamers. | ||||
static IlBoolean | CheckInModules (const IlUChar *sigbuffer, const IlUChar *filename=0) | |||
Returns the registered streamers. | ||||
static IlvBitmapStreamer * | Get (const char *name) | |||
Returns the registered streamers. | ||||
static IlvBitmapStreamer ** | GetRegisteredStreamers (IlUInt &count) | |||
Returns the registered streamers. | ||||
static IlvBitmap * | Read (IlvDisplay *display, istream &stream, const IlUChar *signature, IlUInt signatureLen) | |||
Reads a bitmap using the registered streamers. | ||||
static IlvBitmapData * | ReadBitmapData (istream &stream, const IlUChar *signature, IlUInt signatureLen) | |||
Reads bitmap data using the registered streamers. | ||||
static IlvBitmapInformation * | ReadInfo (istream &stream, const IlUChar *signature, IlUInt signatureLen) | |||
Reads bitmap information using the registered streamers. | ||||
IlvBitmapStreamer () | ||||
Returns the registered streamers. |
Bitmap streamer base class.
Library: display
This class provides methods to read/write IlvBitmapData
from/to a stream. This is a virtual class that must be subclassed. The stream can be checked for a specific format signature. A bitmap streamer can declare if it knows how to read or write. When reading or writing, callbacks can be called to indicate progression.
virtual IlvBitmapStreamer::~IlvBitmapStreamer | ( | ) | [virtual] |
Returns the registered streamers.
count | The number of registered streamers. |
IlvBitmapStreamer::IlvBitmapStreamer | ( | ) | [protected] |
Returns the registered streamers.
count | The number of registered streamers. |
Calls the callback for read progression.
current | The current read progress value. | |
max | The maximum read progress value. |
Calls the callback for write progression.
current | The current write progress value. | |
max | The maximum write progress value. |
virtual IlBoolean IlvBitmapStreamer::canRead | ( | ) | const [virtual] |
Indicates whether the instance can read from a stream. Default is IlFalse
.
IlTrue
if the instance can read from a stream. Reimplemented in IlvBMPStreamer, IlvJPGStreamer, IlvPNGStreamer, IlvPPMStreamer, IlvRGBStreamer, IlvTIFFStreamer, and IlvWBMPStreamer.
virtual IlBoolean IlvBitmapStreamer::canWrite | ( | ) | const [virtual] |
Indicates whether the instance can write to a stream. Default is IlFalse
.
IlTrue
if the instance can write to a stream. Reimplemented in IlvBMPStreamer, IlvJPGStreamer, IlvPNGStreamer, IlvPPMStreamer, IlvRGBStreamer, IlvTIFFStreamer, and IlvWBMPStreamer.
static IlBoolean IlvBitmapStreamer::CheckInModules | ( | const IlUChar * | sigbuffer, | |
const IlUChar * | filename = 0 | |||
) | [static] |
Returns the registered streamers.
count | The number of registered streamers. |
virtual IlBoolean IlvBitmapStreamer::checkSignature | ( | const IlUChar * | data, | |
IlUInt | size | |||
) | [pure virtual] |
Indicates whether the instance can handle the stream.
data | The stream signature. | |
size | The size of the stream signature. |
IlTrue
if the instance recognizes the signature. Implemented in IlvBMPStreamer, IlvJPGStreamer, IlvPNGStreamer, IlvPPMStreamer, IlvRGBStreamer, IlvTIFFStreamer, and IlvWBMPStreamer.
static IlvBitmapStreamer* IlvBitmapStreamer::Get | ( | const char * | name | ) | [static] |
Returns the registered streamers.
count | The number of registered streamers. |
virtual const char* IlvBitmapStreamer::getName | ( | ) | const [virtual] |
Returns the internal name of the streamer.
IlvQuantizer* IlvBitmapStreamer::getQuantizer | ( | ) | const |
Returns the quantizer used by this streamer.
static IlvBitmapStreamer** IlvBitmapStreamer::GetRegisteredStreamers | ( | IlUInt & | count | ) | [static] |
Returns the registered streamers.
count | The number of registered streamers. |
static IlvBitmap* IlvBitmapStreamer::Read | ( | IlvDisplay * | display, | |
istream & | stream, | |||
const IlUChar * | signature, | |||
IlUInt | signatureLen | |||
) | [static] |
Reads a bitmap using the registered streamers.
display | The display to use. | |
stream | The stream to read from. | |
signature | The first bytes of the stream. | |
signatureLen | The size of the signature. |
virtual IlvBitmapData* IlvBitmapStreamer::read | ( | istream & | stream | ) | [virtual] |
Reads from a stream.
stream | The stream to read from. |
IlvBitmapData
. Reimplemented in IlvPNGStreamer, and IlvRGBStreamer.
static IlvBitmapData* IlvBitmapStreamer::ReadBitmapData | ( | istream & | stream, | |
const IlUChar * | signature, | |||
IlUInt | signatureLen | |||
) | [static] |
Reads bitmap data using the registered streamers.
stream | The stream to read from. | |
signature | The first bytes of the stream. | |
signatureLen | The size of the signature. |
static IlvBitmapInformation* IlvBitmapStreamer::ReadInfo | ( | istream & | stream, | |
const IlUChar * | signature, | |||
IlUInt | signatureLen | |||
) | [static] |
Reads bitmap information using the registered streamers.
stream | The stream to read from. | |
signature | The first bytes of the stream. | |
signatureLen | The size of the signature. |
virtual IlvBitmapInformation* IlvBitmapStreamer::readInfo | ( | istream & | stream | ) | [virtual] |
Reads information from a stream.
stream | The stream to read from. |
IlvBitmapInformation
. static void IlvBitmapStreamer::Register | ( | IlvBitmapStreamer * | streamer | ) | [static] |
Registers the given streamer.
streamer | The streamer to register. |
void IlvBitmapStreamer::setQuantizer | ( | IlvQuantizer * | quantizer | ) |
Sets the quantizer used (if needed) by this streamer.
quantizer | The new quantizer. |
virtual void IlvBitmapStreamer::setReadProgressCallback | ( | IlvProgressCallback | rCallback, | |
IlAny | arg = 0 | |||
) | [virtual] |
Sets the callback for read progression.
The callback indicating read progression will be called. The arguments of the callback will be the current bitmap streamer, the current read progress value, the maximum read progress value, and a user-defined argument.
rCallback | The read progression callback. | |
arg | A user-defined argument. |
virtual void IlvBitmapStreamer::setWriteProgressCallback | ( | IlvProgressCallback | wCallback, | |
IlAny | arg = 0 | |||
) | [virtual] |
Sets the callback for write progression.
The callback will be called indicating write progression. The arguments to the callback will be the current bitmap streamer, the current write progress value, the maximum write progress value, and a user-defined argument.
wCallback | The write progression callback. | |
arg | A user-defined argument. |
static IlBoolean IlvBitmapStreamer::UnRegister | ( | IlvBitmapStreamer * | streamer | ) | [static] |
Unregisters the given streamer.
streamer | The streamer to unregister. |
virtual IlBoolean IlvBitmapStreamer::write | ( | IlvBitmapData * | bitmapData, | |
ostream & | stream | |||
) | [virtual] |
Writes an IlvBitmapData
to a stream.
bitmapData | The bitmap data to write. | |
stream | The stream to write to. |
IlTrue
if the bitmap data has been written. Reimplemented in IlvPNGStreamer, IlvRGBStreamer, and IlvWBMPStreamer.
IlAny IlvBitmapStreamer::_argr [protected] |
Returns the registered streamers.
count | The number of registered streamers. |
IlAny IlvBitmapStreamer::_argw [protected] |
Returns the registered streamers.
count | The number of registered streamers. |
IlvQuantizer* IlvBitmapStreamer::_quantizer [protected] |
Returns the registered streamers.
count | The number of registered streamers. |
IlvProgressCallback IlvBitmapStreamer::_readProgressCallback [protected] |
Returns the registered streamers.
count | The number of registered streamers. |
IlIlvBitmapStreamersList* IlvBitmapStreamer::_Streamers [static] |
Returns the registered streamers.
count | The number of registered streamers. |
IlvProgressCallback IlvBitmapStreamer::_writeProgressCallback [protected] |
Returns the registered streamers.
count | The number of registered streamers. |
© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.