In file mydocsrc/iml_file.h:

class iml_image_file

This is the class used to manage n-dimensional images stored on disk

Public Methods

IML_SINT close_file (void)
Explicitly close the file that is currently open
IML_SINT create_file (const char *FileName)
Explicitly attempt to create a new image file on the disk
iml_image_file (void)
A no-argument constructor
IML_SINT load_raw_pixels (iml_image IML_REF Image, IML_LINT SkipHeader=0)
Read raw image-pixel values into an image from disk
IML_SINT open_file (const char *FileName)
Explicitly attempt to open a file that already exists on the disk
iml_image* read_image (void)
Read an image from disk and allocate an image of the appropriate type and size
IML_SINT write_image (iml_image IML_REF Image, IML_LINT Format=IML_IML_FORMAT)
Write an image to disk

Documentation

This is the class used to manage n-dimensional images stored on disk. It provides byte-order independent, hyperplane aware storage and retrieval of the image classes defined in iml_ndim.h. The image file manager only manages one file at a time. If you wish to have multiple open image files, then either open them sequentially, loading them one at a time, or use multiple iml_image_file instances.
IML_SINT close_file(void)
Explicitly close the file that is currently open. If no file is open no action is taken. Returns TRUE if the close process was successful, FALSE if it was not.

IML_SINT open_file(const char *FileName)
Explicitly attempt to open a file that already exists on the disk. If another file is already open that file is first closed. Returns TRUE if the open process was successful, FALSE if it was not.

IML_SINT create_file(const char *FileName)
Explicitly attempt to create a new image file on the disk. If another file is already open that file is first closed. Returns TRUE if the creation process was successful, FALSE if it was not.

IML_SINT write_image(iml_image IML_REF Image, IML_LINT Format=IML_IML_FORMAT)
Write an image to disk. Assumes that a file has already been opened. The default format is the native image format (a header format defined in this library, using a data directory to store image attributes and pixel values). The image can also be stored as IML_IML_RAW format, or just raw pixel values with no header information. Returns TRUE if the write process was successful, FALSE if it was not.

iml_image* read_image(void)
Read an image from disk and allocate an image of the appropriate type and size. The function returns a pointer to a base image class, iml_image. The user can determine the image type with the image class function image_type() and then cast the returned pointer to the correct type. Normally, however, the user will know what type of image is supposed to be obtained from the file and only use image_type() to make sure that the image is of the correct type. Returns a NULL pointer if the image could not be read from the file.

IML_SINT load_raw_pixels(iml_image IML_REF Image, IML_LINT SkipHeader=0)
Read raw image-pixel values into an image from disk. The user allocates an image of the appropriate type and size in the program, then uses this function to read the raw pixels into that image's memory space. The function returns a non-zero number if the read went without a hitch. This function is primarily to allow portability of other images into and out of the image file format native to this library.


This class has no child classes.

alphabetic index hierarchy of classes


generated by doc++