Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

Next Page > Hide TOC

Image Codec Reference for QuickTime

Framework
Frameworks/QuickTime.framework
Declared in
Components.h
ImageCodec.h

Overview

An image codec (or image compressor component) is a code resource that provides QuickTime with compression or decompression services for image data.

Functions by Task

Base Image Decompressor Functions

Low-Level Effects Functions

Vector Codec Component Functions

Supporting Functions

Functions

CurveAddAtomToVectorStream

Adds an atom to a vector data stream.

ComponentResult CurveAddAtomToVectorStream (
   ComponentInstance effect,
   OSType atomType,
   Size atomSize,
   void *pAtomData,
   Handle vectorStream
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

atomType

The type of atom to add to the vector data stream.

atomSize

The size of the data for the atom.

pAtomData

A pointer to the data for the atom.

vectorStream

A handle to the vector data stream to which to add the atom.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function adds the atom to the end of the specified vector data stream and resizes the vector data stream handle.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveAddPathAtomToVectorStream

Adds a path to a vector data stream.

ComponentResult CurveAddPathAtomToVectorStream (
   ComponentInstance effect,
   Handle pathData,
   Handle vectorStream
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

pathData

A handle to the data for the path.

vectorStream

A handle to the vector data stream to which to add the path.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function adds the path to the end of the specified vector data stream and resizes the vector data stream handle.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveAddZeroAtomToVectorStream

Adds a kCurveEndAtom to a vector data stream; this atom marks the end of the vector data stream,

ComponentResult CurveAddZeroAtomToVectorStream (
   ComponentInstance effect,
   Handle vectorStream
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

vectorStream

A handle to the vector data stream to which to add the kCurveEndAtom atom.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function adds a kCurveEndAtom atom to the end of the specified vector data stream and resizes the vector data stream handle. The kCurveEndAtom atom is required at the end of a vector data stream, and there may be only one kCurveEndAtom atom in the stream.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveCountPointsInPath

Counts the points along either one of a path's contours or all of its contours.

ComponentResult CurveCountPointsInPath (
   ComponentInstance effect,
   gxPaths *aPath,
   unsigned long contourIndex,
   unsigned long *pCount
);

Parameters
effect

The instance of the QuickTime vector codec component for the request.

aPath

A pointer to the path.

contourIndex

The index of the contour to be counted.

pCount

A pointer to a field that is to receive the number of points in the contour or path.

Return Value

See Error Codes. Returns noErr if there is no error.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveCreateVectorStream

Creates a new, empty vector data stream.

ComponentResult CurveCreateVectorStream (
   ComponentInstance effect,
   Handle *pStream
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

pStream

A pointer to the handle that is to receive the newly created vector data stream.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

The caller is responsible for disposing of the stream when finished with it. This can be done by calling DisposeHandle.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveGetAtomDataFromVectorStream

Finds the first atom of a specified type within a vector data stream and get its data.

ComponentResult CurveGetAtomDataFromVectorStream (
   ComponentInstance effect,
   Handle vectorStream,
   long atomType,
   long *dataSize,
   Ptr *dataPtr
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

vectorStream

A handle to the vector data stream from which to get the atom.

atomType

The type of atom to find.

dataSize

A pointer to a field that is to receive the size of the atom's data.

dataPtr

A pointer to a pointer to a field that is to receive the atom's data.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

Before calling this function, your software must lock the handle for the vector data stream (with Macintosh, by calling HLock). This prevents the handle from being moved, which could invalidate the pointer to the atom data before your software gets the data.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveGetLength

Calculates the length of one of a path's contours or the sum of the lengths of all of its contours.

ComponentResult CurveGetLength (
   ComponentInstance effect,
   gxPaths *target,
   long index,
   wide *wideLength
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

target

A pointer to the path.

index

Contains the index of the contour whose length is to be calculated or, if the value is 0, specifies to calculate the lengths of all of the path's contours and return the sum of the lengths.

wideLength

A pointer to a field that is to receive the length.

Return Value

See Error Codes. Returns noErr if there is no error.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveGetNearestPathPoint

Finds the closest point on a path to a specified point.

ComponentResult CurveGetNearestPathPoint (
   ComponentInstance effect,
   gxPaths *aPath,
   FixedPoint *thePoint,
   unsigned long *contourIndex,
   unsigned long *pointIndex,
   Fixed *theDelta
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

aPath

A pointer to the path.

thePoint

A pointer to a point for which to find the closest point on the path.

contourIndex

A pointer to a field that is to receive the index of the contour that contains the closest point.

pointIndex

A pointer to a field that is to receive the index of the closest point.

theDelta

A pointer to a field that is to receive the distance between the specified point and the closest point in the contour to it.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

In programs where users directly manipulate curves, you can use this function to determine the closest control point to a given point.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveGetPathPoint

Obtains a point from a path and to find out if the point is on the curve.

ComponentResult CurveGetPathPoint (
   ComponentInstance effect,
   gxPaths *aPath,
   unsigned long contourIndex,
   unsigned long pointIndex,
   gxPoint *thePoint,
   Boolean *ptIsOnPath
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

aPath

A pointer to the path.

contourIndex

The index of the contour from which to get the point.

pointIndex

The index of the point to get.

thePoint

A pointer to a field that is to receive the point.

ptIsOnPath

A pointer to a field that is to receive a Boolean value that, if TRUE, specifies that the point is on the curve.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function lets programs get a single point from a path without walking the path data.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveInsertPointIntoPath

Adds a new point to a path.

ComponentResult CurveInsertPointIntoPath (
   ComponentInstance effect,
   gxPoint *aPoint,
   Handle thePath,
   unsigned long contourIndex,
   unsigned long pointIndex,
   Boolean ptIsOnPath
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

aPoint

A pointer to the point to add to the path.

thePath

A handle to the path to which to add the point.

contourIndex

The index of the path contour to which to add the point.

pointIndex

The index of the point to add.

ptIsOnPath

If TRUE, specifies that the new point is to be on the path.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function is best for adding a single point to a path rather than large numbers of points.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveLengthToPoint

Obtains the point at a specified distance along a curve.

ComponentResult CurveLengthToPoint (
   ComponentInstance effect,
   gxPaths *target,
   long index,
   Fixed length,
   FixedPoint *location,
   FixedPoint *tangent
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

target

A pointer to the path.

index

The index of the path contour from which to get the point.

length

The distance along the curve at which to find the point.

location

A pointer to a field that is to receive the point.

tangent

A pointer to a field that is to receive a point that is tangent to the point at the specified distance.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function is useful for converting a value to a point, such as when creating an animation that follows a curve.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveNewPath

Creates a new path.

ComponentResult CurveNewPath (
   ComponentInstance effect,
   Handle *pPath
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

pPath

A pointer to a handle that is to receive the new path.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

The path created by this function contains one contour and no points. The caller must dispose of the handle when it is finished with it (with Macintosh, by calling DisposeHandle).

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurvePathPointToLength

Obtains the length of a path between specified starting and ending distances that is nearest a point.

ComponentResult CurvePathPointToLength (
   ComponentInstance ci,
   gxPaths *aPath,
   Fixed startDist,
   Fixed endDist,
   FixedPoint *thePoint,
   Fixed *pLength
);

Parameters
ci

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

aPath

A pointer to the path.

startDist

The distance along the path at which to start measuring the path's length.

endDist

The distance along the path at which to stop measuring the path's length.

thePoint

A pointer to a point; the function measures the path closest to this point.

pLength

A pointer to a field that is to receive the length of the specified part of the path.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

You can use this function to test if the user has clicked on the specified portion of the curve.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

CurveSetPathPoint

Changes the location of a point in a path.

ComponentResult CurveSetPathPoint (
   ComponentInstance effect,
   gxPaths *aPath,
   unsigned long contourIndex,
   unsigned long pointIndex,
   gxPoint *thePoint,
   Boolean ptIsOnPath
);

Parameters
effect

The instance of the QuickTime vector codec component for the request. Your software obtains this reference when calling the Component Manager's OpenComponent or OpenDefaultComponent function.

aPath

A pointer to the path.

contourIndex

The index of the path contour that contains the point to change.

pointIndex

The index of the point to change.

thePoint

A pointer to the new value for the point.

ptIsOnPath

If TRUE, specifies that the new point is to be on the path.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function edits an existing point location within a path. The function that you call to send the interpolated value to the receiving track is defined as a universal procedure in systems that support the Macintosh Code Fragment Manager (CFM) or is defined as a data procedure for non-CFM systems. With Macintosh, the TweenerDataUPP function pointer specifies the function the tween component calls with the value generated by the tween operation. A tween component calls this function from its implementation of the TweenerDoTween function. You call this function by invoking the function specified in the tween record's dataProc field.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

DisposeImageCodecDrawBandCompleteUPP

Disposes of an ImageCodecDrawBandCompleteUPP pointer.

void DisposeImageCodecDrawBandCompleteUPP (
   ImageCodecDrawBandCompleteUPP userUPP
);

Parameters
userUPP

An ImageCodecDrawBandCompleteUPP pointer. See Universal Procedure Pointers.

Version Notes

Introduced in QuickTime 5.

Availability
Declared In
ImageCodec.h

DisposeImageCodecMPDrawBandUPP

Disposes of an ImageCodecMPDrawBandUPP pointer.

void DisposeImageCodecMPDrawBandUPP (
   ImageCodecMPDrawBandUPP userUPP
);

Parameters
userUPP

An ImageCodecMPDrawBandUPP pointer. See Universal Procedure Pointers.

Version Notes

Introduced in QuickTime 4.1.

Availability
Declared In
ImageCodec.h

DisposeImageCodecTimeTriggerUPP

Disposes of an ImageCodecTimeTriggerUPP pointer.

void DisposeImageCodecTimeTriggerUPP (
   ImageCodecTimeTriggerUPP userUPP
);

Parameters
userUPP

An ImageCodecTimeTriggerUPP pointer. See Universal Procedure Pointers.

Return Value

You can access this function's error returns through GetMoviesError and GetMoviesStickyError.

Version Notes

Introduced in QuickTime 4.1.

Availability
Declared In
ImageCodec.h

ImageCodecBandCompress

Asks your component to compress an image or a band of an image.

ComponentResult ImageCodecBandCompress (
   ComponentInstance ci,
   CodecCompressParams *params
);

Parameters
ci

An image decompressor component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

params

A pointer to a CodecCompressParams structure. The Image Compression Manager places the appropriate parameter information in that structure.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

The image being compressed may be part of a sequence.

Special Considerations

Only compressors receive this request.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecBandDecompress

Asks your component to decompress a frame.

ComponentResult ImageCodecBandDecompress (
   ComponentInstance ci,
   CodecDecompressParams *params
);

Parameters
ci

An image decompressor component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

params

A pointer to a CodecDecompressParams structure. The Image Compression Manager places the appropriate parameter information in that structure.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

For scheduled asynchronous decompression operations, the Image Compression Manager supplies a reference to an ICMFrameTimeRecord structure in this function's CodecDecompressParams structure parameter. The ICMFrameTimeRecord structure contains time information governing the scheduled decompression operation, including the time at which the frame must be displayed. For synchronous or immediate asynchronous decompress operations, the frame time is set to NIL.

When your component has finished the decompression operation, it must call the completion function. In the past, for asynchronous operations, your component called that function directly. For scheduled asynchronous decompression operations, your component should call ICMDecompressComplete.

If your component sets the codecCanAsyncWhen flag in predecompress but cannot support scheduled asynchronous decompression for a given frame, it must return an error code of codecCantWhenErr. If your component's queue is full, it should return an error code of codecCantQueueErr. Only decompressors receive these requests.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecBeginBand

Called before drawing a band or frame; it allows your image decompressor component to save information about a band before decompressing it.

ComponentResult ImageCodecBeginBand (
   ComponentInstance ci,
   CodecDecompressParams *params,
   ImageSubCodecDecompressRecord *drp,
   long flags
);

Parameters
ci

An image codec component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

params

A pointer to a CodecDecompressParams structure.

drp

A pointer to an ImageSubCodecDecompressRecord structure.

flags

Currently unused; set to 0.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

Your image decompressor component receives the address of the destination pixel map in the baseAddr field of the drp parameter. This address includes an adjustment for the offset. Note that if the bit depth of the pixel map is less than 8, your image decompressor component must adjust for the bit offset.

The codecData field of the drp parameter contains a pointer to the compressed video data. The userDecompressRecord field of the drp parameter contains a pointer to storage for the decompression operation. The storage is allocated by the base image decompressor after it calls the ImageCodecInitialize function. The size of the storage is determined by the decompressRecordSize field of the ImageSubCodecDecompressCapabilities structure that is returned by ImageCodecInitialize. Your image decompressor component should use this storage to store any additional information needed about the frame in order to decompress it.

Changes your image decompressor component makes to the ImageSubCodecDecompressRecord or CodecDecompressParams structures are preserved by the base image decompressor. For example, if your component does not need to decompress all of the data, it can change the pointer to the data to be decompressed that is stored in the codecData field of the ImageSubCodecDecompressRecord structure.

Special Considerations

Your component must implement this function. Also, the base image decompressor never calls ImageCodecBeginBand at interrupt time. If your component supports asynchronous scheduled decompression, it may receive more than one ImageCodecBeginBand call before receiving an ImageCodecDrawBand call.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecBeginPass

Notifies the compressor that it should operate in multipass mode and use the given multipass storage.

ComponentResult ImageCodecBeginPass (
   ComponentInstance ci,
   ICMCompressionPassModeFlags passModeFlags,
   UInt32 flags,
   ICMMultiPassStorageRef multiPassStorage
);

Parameters
ci

A component instance that identifies a connection to an image codec component.

passModeFlags

Indicates how the compressor should operate in this pass. If the kICMCompressionPassMode_WriteToMultiPassStorage flag is set, the compressor may gather information of interest and store it in multiPassStorage. If the kICMCompressionPassMode_ReadFromMultiPassStorage flag is set, the compressor may retrieve information from multiPassStorage. If the kICMCompressionPassMode_OutputEncodedFrames flag is set, the compressor must encode or drop every frame by calling ICMCompressorSessionDropFrame or ICMCompressorSessionEmitEncodedFrame. If that flag is not set, the compressor should not call these routines.

flags

Reserved. Ignore this parameter.

multiPassStorage

The multipass storage object that the compressor should use to store and retrieve information between passes.

Return Value

An error code, or noErr if there is no error.

Availability
Declared In
ImageCodec.h

ImageCodecBusy

Lets your component report whether it is performing an asynchronous operation.

ComponentResult ImageCodecBusy (
   ComponentInstance ci,
   ImageSequence seq
);

Parameters
ci

An image decompressor component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

seq

The unique sequence identifier assigned by CompressSequenceBegin or DecompressSequenceBegin.

Return Value

Your component should return a result code value of 1 if an asynchronous operation is in progress; it should return a result code value of 0 if the component is not performing an asynchronous operation. You can indicate an error by returning a negative result code. See Error Codes.

Special Considerations

Both compressors and decompressors may receive this request.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecCancelTrigger

Cancels an image codec's ImageCodecTimeTriggerProc callback.

ComponentResult ImageCodecCancelTrigger (
   ComponentInstance ci
);

Parameters
ci

An image codec component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

Return Value

See Error Codes. Returns noErr if there is no error.

Version Notes

Introduced in QuickTime 4.

Availability
Declared In
ImageCodec.h

ImageCodecCompleteFrame

Directs the compressor to finish with a queued source frame, either emitting or dropping it.

ComponentResult ImageCodecCompleteFrame (
   ComponentInstance ci,
   ICMCompressorSourceFrameRef sourceFrame,
   UInt32 flags
);

Parameters
ci

A component instance that identifies a connection to an image codec component.

sourceFrame

The source frame that must be completed.

flags

Reserved; ignore.

Return Value

An error code, or noErr if there is no error.

Discussion

This frame does not necessarily need to be the first or only source frame emitted or dropped during this call, but the compressor must call either ICMCompressorSessionDropFrame or ICMCompressorSessionEmitEncodedFrame with this frame before returning. The ICM will call this function to force frames to be encoded for the following reasons: (a) the maximum frame delay count or maximum frame delay time in the compressionSessionOptions does not permit frames to be queued; (b) the client has called ICMCompressionSessionCompleteFrames.

Availability
Declared In
ImageCodec.h

ImageCodecCreateStandardParameterDialog

Creates a parameters dialog box for a specified effect.

ComponentResult ImageCodecCreateStandardParameterDialog (
   ComponentInstance ci,
   QTAtomContainer parameterDescription,
   QTAtomContainer parameters,
   QTParameterDialogOptions dialogOptions,
   DialogPtr existingDialog,
   short existingUserItem,
   QTParameterDialog *createdDialog
);

Parameters
ci

An effects component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent. The dialog box that is created will allow the user to specify the parameters of this effect.

parameterDescription

The parameter description atom container for this effect. You can obtain a valid parameter description by calling ImageCodecGetParameterList. A parameter is optionally tweenable if defined as kAtomInterpolateIsOptional in its parameter description atom.

parameters

The atom container that will receive the user's chosen parameter values once the dialog has been dismissed.

dialogOptions

Controls how parameters containing tween data are presented in the created dialog box. If dialogOptions contains 0, two values are collected for each parameter that can be tweened, and the usual tweening operation will be performed for the duration of the effect being controlled. For other values,. See these constants:

  • pdOptionsCollectOneValue

  • pdOptionsAllowOptionalInterpolations

existingDialog

An existing dialog box that will have the controls from the standard parameters dialog box added to it. Set this parameter to NIL if you want this function to create a stand-alone dialog box.

existingUserItem

The number of the user item in the existing dialog box that should be replaced with controls from the standard parameter dialog box. You should only pass a value to this parameter if the existingDialog parameter is not NIL.

createdDialog

On return, a reference to the dialog created and displayed by the function. This reference is required by several other low-level effects functions. It will contain a valid dialog identifier even if you requested that the controls from the standard parameter dialog box be incorporated into an existing dialog box.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This is a low-level function that can be used to create a standard parameter dialog box for a specified effect, allowing the user to set the parameter values for the effect. You can optionally request that the controls from the dialog box be included within a dialog box of the calling application. The following sample code shows how to create a standard parameter dialog box and add effects controls:

// ImageCodecCreateStandardParameterDialog coding example
// See "Discovering QuickTime," page 303
pMovableModalDialog =GetNewDialog(kExtraDialogID, NIL, (WindowRef)-1);
if (pMovableModalDialog !=NIL) {
    ImageCodecCreateStandardParameterDialog(
        compInstance,
        qtacParameterDescription,
        qtacEffectSample,
        pdOptionsModelDialogBox,
        pMovableModalDialog,
        kExtraUserItemID,
        &lCreatedDialogID);
    ShowWindow(pMovableModalDialog);
    SelectWindow(pMovableModalDialog);
    SetPort(pMovableModalDialog);
}
Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecDecodeBand

Returns an ImageSubCodecDecompressRecord structure for an image codec component.

ComponentResult ImageCodecDecodeBand (
   ComponentInstance ci,
   ImageSubCodecDecompressRecord *drp,
   unsigned long flags
);

Parameters
ci

A component instance that identifies a connection to an image codec component.

drp

A pointer to an ImageSubCodecDecompressRecord structure.

flags

Not used; set to 0.

Return Value

An error code, or noErr if there is no error.

Availability
Declared In
ImageCodec.h

ImageCodecDismissStandardParameterDialog

Retrieves values from a standard parameter dialog box created by the low-level ImageCodecCreateStandardParameterDialog function, then closes the dialog box.

ComponentResult ImageCodecDismissStandardParameterDialog (
   ComponentInstance ci,
   QTParameterDialog createdDialog
);

Parameters
ci

An effect component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent. This must be the instance passed to ImageCodecCreateStandardParameterDialog to create the dialog box.

createdDialog

A reference to the dialog box created by the call to ImageCodecCreateStandardParameterDialog.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

This function should be called after the ImageCodecIsStandardParameterDialogEvent function returns codecParameterDialogConfirm or userCanceledErr, which indicate that the user has dismissed the dialog box. The function dismisses the dialog box, deallocating any memory allocated during the call to ImageCodecCreateStandardParameterDialog.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecDisposeImageGWorld

Disposes of an image graphics world associated with an image codec.

ComponentResult ImageCodecDisposeImageGWorld (
   ComponentInstance ci,
   GWorldPtr theGW
);

Parameters
ci

An image codec component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

theGW

A pointer to a CGrafPort structure.

Return Value

See Error Codes. Returns noErr if there is no error.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecDisposeMemory

Disposes codec-allocated memory.

ComponentResult ImageCodecDisposeMemory (
   ComponentInstance ci,
   Ptr data
);

Parameters
ci

An image compressor component instance. Your software obtains this reference from OpenComponent or OpenDefaultComponent.

data

A pointer to the previously allocated memory block.

Return Value

See Error Codes. Returns noErr if there is no error.

Discussion

Your component receives the ImageCodecDisposeMemory request whenever an application calls CDSequenceDisposeMemory.

Special Considerations

When a codec instance is closed, it must ensure that all blocks allocated by that instance are disposed and call ICMMemoryDisposedProc.

Version Notes

Introduced in QuickTime 3 or earlier.

Availability
Declared In
ImageCodec.h

ImageCodecDITLEvent

Lets an image codec component receive and process dialog events.

ComponentResult ImageCodecDITLEvent (
   Compo