An image description structure contains information that defines the characteristics of a compressed image or sequence. Data in the image description structure indicates the type of compression that was used, the size of the image when displayed, the resolution at which the image was captured, and so on. One image description structure may be associated with one or more compressed frames.
The ImageDescription data type defines the layout of an image description structure. In addition, an image description structure may contain additional data in extensions and custom color tables. The Image Compression Manager provides functions that allow you to get and set the data in image description structure extensions and custom color tables.
See “Working With Images” for more information about the functions GetImageDescriptionCTable and SetImageDescriptionCTable, which allow you to work with custom color tables in image description structures.
See the GetImageDescriptionExtension, SetImageDescriptionExtension, RemoveImageDescriptionExtension, CountImageDescriptionExtensionType, and GetNextImageDescriptionExtensionType functions, which allow you to work with image description structure extensions.
struct ImageDescription { |
long idSize; /* total size of this structure */ |
CodecType cType; /* compressor creator type */ |
long resvd1; /* reserved--must be set to 0 */ |
short resvd2; /* reserved--must be set to 0 */ |
short dataRefIndex; /* reserved--must be set to 0 */ |
short version; /* version of compressed data */ |
short revisionLevel; /* compressor that created data */ |
long vendor; /* compressor developer that created data */ |
CodecQ temporalQuality; |
/* degree of temporal compression */ |
CodecQ spatialQuality; |
/* degree of spatial compression */ |
short width; /* width of source image in pixels */ |
short height; /* height of source image in pixels */ |
Fixed hRes; /* horizontal resolution of source image */ |
Fixed vRes; /* vertical resolution of source image */ |
long dataSize; /* size in bytes of compressed data */ |
short frameCount; /* number of frames in image data */ |
Str31 name; /* name of compression algorithm */ |
short depth; /* pixel depth of source image */ |
short clutID; /* ID number of the color table for image */ |
}; |
typedef struct ImageDescription ImageDescription; |
typedef ImageDescription *ImageDescriptionPtr, **ImageDescriptionHandle; |
Field |
Description |
|---|---|
|
Defines the total size of this image description structure with extra data including color lookup tables and other per sequence data. |
|
Indicates the type of compressor component that created this compressed image data. The value of this field indicates the compression algorithm supported by the component. The |
|
Reserved for Apple. This field must be set to 0. |
|
Reserved for Apple. This field must be set to 0. |
|
Reserved for Apple. This field must be set to 0. |
|
Indicates the version of the compressed data. The contents of this field should indicate the version of the compression algorithm that was used to create the compressed data. By examining this field, decompressors that support many versions of an algorithm can determine the proper way to decompress the image. |
|
Indicates the version of the compressor that created the compressed image. Developers of compressors and decompressors assign these version numbers. |
|
Identifies the developer of the compressor that created the compressed image. |
|
Indicates the degree of temporal compression performed on the image data associated with this description. This field is valid only for sequences. |
|
Indicates the degree of spatial compression performed on the image data associated with this description. This field is valid for sequences and still images. |
|
Contains the width of the source image, in pixels. |
|
Contains the height of the source image, in pixels. |
|
Contains the horizontal resolution of the source image, in dots per inch. |
|
Contains the vertical resolution of the source image, in dots per inch. |
|
Indicates the size of the compressed image, in bytes. This field is valid only for still images. Set this field to 0 if the size is unknown. |
|
Contains the number of frames in the image data associated with this description. |
|
Indicates the compression algorithm used to create the compressed data. This algorithm is stored in Pascal string format. It always takes up 32 bytes no matter how long the string is. The 32 bytes consist of 31 bytes plus one length byte. The value of this field should correspond to the compressor type specified by the |
|
Contains the pixel depth specified for the compressed image. Values of 1, 2, 4, 8, 16, 24, and 32 indicate the depth of color images. Values of 34, 36, and 40 indicate 2-bit, 4-bit, and 8-bit grayscale, respectively, for grayscale images. |
|
Contains the ID of the color table for the compressed image, or other special values. If this field is set to 0, then a custom color table is defined for the compressed image. You can use the |
See “Compression Quality Constants” for a list of available values for the temporalQuality and spatialQuality fields.
Last updated: 2006-01-10