Om
1.0.0
A universal framework for multimedia simulation
|
A class that handles encoding and decoding image data to/from the Truevision TGA format (.tga) More...
#include <omImagesTGATranscoder.h>
Public Member Functions | |
virtual const ResourceFormat & | getResourceFormat () const |
Return an object that represents the resource format that this transcoder can read and write. More... | |
virtual ImageFormat | getImageFormat () const |
Return an object that represents the format that this transcoder can encode and decode. More... | |
virtual Bool | canEncode (const Image &image) const |
Return whether or not the specified image can be encoded using this transcoder. More... | |
virtual Bool | encode (const Image &image, DataOutputStream &stream, const ResourceSet *resourceSet=((void *) 0), ResourceManager *manager=((void *) 0)) const |
Encode the specified image and send the output to the a data output stream. More... | |
virtual Bool | canDecode (const UByte *inputData, Size inputDataSizeInBytes) const |
Return whether or not the specified image data can be decoded using this transcoder. More... | |
virtual Bool | decode (DataInputStream &stream, Image &image, ResourceSet *resourceSet=((void *) 0), ResourceManager *manager=((void *) 0)) const |
Decode image data from the specified DataInputStream and return an image. More... | |
Public Member Functions inherited from om::images::io::ImageTranscoder | |
virtual Bool | encode (const ResourceID &identifier, const Image &image, const ResourceSet *resourceSet=((void *) 0), ResourceManager *manager=((void *) 0)) |
Save the specified image at the specified ID location. More... | |
virtual Bool | canDecode (const ResourceID &identifier) const |
Return whether or not the specified identifier refers to a valid image format for this transcoder. More... | |
Bool | decode (const UByte *inputData, Size inputDataSizeInBytes, Image &image, ResourceSet *resourceSet=((void *) 0), ResourceManager *manager=((void *) 0)) const |
Decode the data from the specified data pointer and return an image. More... | |
virtual Image * | decode (ResourceID &identifier, ResourceSet *resourceSet=((void *) 0), ResourceManager *manager=((void *) 0)) |
Load the image pointed to by the specified identifier. More... | |
Public Member Functions inherited from om::resources::ResourceTypeTranscoder< Image > | |
virtual const ResourceType & | getResourceType () const |
Return an object that represents the resource type that this transcoder can read and write. More... | |
virtual Bool | canEncode (const Image &resource) const =0 |
Return whether or not this transcoder is able to encode the specified resource. More... | |
virtual Bool | encode (const ResourceID &identifier, const Image &resource, const ResourceSet *resourceSet=((void *) 0), ResourceManager *manager=((void *) 0))=0 |
Save the specified resource object at the specified ID location. More... | |
Public Member Functions inherited from om::resources::ResourceTranscoder | |
virtual | ~ResourceTranscoder () |
Destroy a resource transcoder and release all of its resources. More... | |
A class that handles encoding and decoding image data to/from the Truevision TGA format (.tga)
|
virtual |
Return an object that represents the resource format that this transcoder can read and write.
Implements om::resources::ResourceTranscoder.
|
virtual |
Return an object that represents the format that this transcoder can encode and decode.
Implements om::images::io::ImageTranscoder.
Return whether or not the specified image can be encoded using this transcoder.
If TRUE is returned, the image is in a format that is compatible with this transcoder. Otherwise, the image is not compatible and cannot be encoded.
Implements om::images::io::ImageTranscoder.
|
virtual |
Encode the specified image and send the output to the a data output stream.
If the encoding succeeds, the encoded image data is sent to the data output stream and TRUE is returned. Otherwise, FALSE is returned and no data is sent to the stream.
Implements om::images::io::ImageTranscoder.
|
virtual |
Return whether or not the specified image data can be decoded using this transcoder.
The transcoder examines the data and determines if the data contains a valid image in the transcoder's format. If so, TRUE is returned. Otherwise, FALSE is returned.
Implements om::images::io::ImageTranscoder.
|
virtual |
Decode image data from the specified DataInputStream and return an image.
The image is returned in the output image reference.
If the decoding succeeds, the function creates an image and places it in the image output reference paramter and TRUE is returned. Otherwise, if the decoding fails, FALSE is returned.
Implements om::images::io::ImageTranscoder.