Codec Components API

This chapter lists the data structures and functions that support codec components in QuickTime.

Data Structures

The following data structures are defined in the QuickTime API Reference:

Functions

This section lists the functions that image compressor components must support. It also lists the utility functions that the Image Compression Manager provides for use by compressors and decompressors. For details of these functions, see the QuickTime API Reference.

The function list is divided into two parts. Direct Functions lists image compressor component functions that are called by the Image Compression Manager in response to application requests. Indirect Functions lists image compressor component functions that may be called by the Image Compression Manager at any time. The next section, Image Compression Manager Utility Functions lists Image Compression Manager utility functions that are available to image compressor components.

You can use the following constants to refer to the request codes for each of the functions that your component must support.

#define kImageCodecGetCodecInfoSelect             0x00   
#define kImageCodecGetCompressionTimeSelect       0x01   
#define kImageCodecGetMaxCompressionSizeSelect    0x02   
#define kImageCodecPreCompressSelect              0x03   
#define kImageCodecBandCompressSelect             0x04   
#define kImageCodecPreDecompressSelect            0x05   
#define kImageCodecBandDecompressSelect           0x06  
#define kImageCodecBusySelect                     0x07   
#define kImageCodecGetCompressedImageSizeSelect   0x08   
#define kImageCodecGetSimilaritySelect            0x09   
#define kImageCodecTrimImageSelect                0x0A  

Direct Functions

These functions are invoked by the Image Compression Manager in direct response to application functions:

  • ImageCodecGetCodecInfo

  • ImageCodecGetMaxCompressionSize

  • ImageCodecGetCompressionTime

  • ImageCodecGetSimilarity

  • ImageCodecGetCompressedImageSize

  • ImageCodecTrimImage

  • ImageCodecBusy

Indirect Functions

This section describes functions that are invoked by the Image Compression Manager but do not correspond to functions called by applications. The Image Compression Manager may call these functions at any time:

  • ImageCodecPreCompress

  • ImageCodecBandCompress

  • ImageCodecPreDecompress

  • ImageCodecBandDecompress

Image Compression Manager Utility Functions

The Image Compression Manager provides a number of utility functions for use by your compressor component. These utility functions allow compressor components to manipulate the Image Compression Manager’s image description structures:

  • SetImageDescriptionExtension

  • GetImageDescriptionExtension

  • RemoveImageDescriptionExtension

  • CountImageDescriptionExtensionType

  • GetNextImageDescriptionExtensionType

  • ICMShieldSequenceCursor

  • ICMDecompressComplete