fiasco_image_new, fiasco_image_delete, fiasco_image_get_width, fiasco_image_get_height, fiasco_image_is_color − handle FIASCO image objects
#include <fiasco.h>
fiasco_image_t *
fiasco_image_new (const char * filename);
void
fiasco_image_delete (fiasco_image_t * image);
unsigned
fiasco_image_get_width (const fiasco_image_t * image);
unsigned
fiasco_image_get_height (const fiasco_image_t * image);
int
fiasco_image_is_color (const fiasco_image_t * image);
The fiasco_image_new() function reads the given image file and allocates and initializes a FIASCO image object. Use the function fiasco_renderer_new(3) to create a renderer object that converts the FIASCO image to the desired image format.
The function fiasco_image_delete() deletes the image object and frees the image buffer.
Image geometry and type are accessible through member functions fiasco_image_get_width(), fiasco_image_get_height(), and fiasco_image_is_color().
image |
The image "class" encapsulates the FIASCO image object. It is used to store the pixel values of the decoded or read image. |
filename
Image filename to process. If filename is "-" or a NULL pointer then the image is read from standard input. If a filename is a relative path then the images are searched for in the current directory and in the (colon-separated) list of directories given by the environment variable FIASCO_IMAGES.
The function fiasco_image_new() returns a pointer to the newly allocated image object. If an error has been catched, a NULL pointer is returned.
The function fiasco_image_get_width() returns the width of the image. If an error has been catched, 0 is returned.
The function fiasco_image_get_height() returns the height of the image. If an error has been catched, 0 is returned.
The function fiasco_image_is_color() returns 0 if the image object is a grayscale image, otherwise a non-zero value is returned.
In case of an error in one of the above functions, use the function fiasco_get_error_message(3) to get a string with the last error message of FIASCO.
fiasco_decoder_get_frame(3), fiasco_get_error_message(3) fiasco_renderer_new(3)
Ullrich Hafner, Juergen Albert, Stefan Frank, and Michael Unger. Weighted Finite Automata for Video Compression, IEEE Journal on Selected Areas In Communications, January 1998
Ullrich Hafner. Low Bit-Rate Image and Video Coding with Weighted Finite Automata, Ph.D. thesis, Mensch & Buch Verlag, ISBN 3-89820-002-7, October 1999.
Ullrich Hafner <hafner AT bigfoot DOT de>