Technical: QuickTime
Advanced Search
Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

title


Previous Section Table of Contents Next Section


Components

Contents

The Component Manager

Component Types

References

A component can be thought of as a black box, a piece of code providing a specific set of services to a client. QuickTime is highly modular in that it is made up of over 200 different components, each performing a specific job and responding to a defined programming interface. This modularity not only make it simpler to program for QuickTime but allows QuickTime to be extended through the addition of new components providing new and or specific services. These components provide essential services to your application and to the managers that make up the QuickTime architecture.

The Component Manager

The Component Manager provides services that allow you to find, open, and access specific components.

Components of a particular type are found using three main criteria which are part of a ComponentDescription structure.

  • Type of component service - this is the componentType field within the component description and identifies the type of component. For example, graphics exporter components all have a component type 'grex' represented by the GraphicsExporterComponentType constant.
  • Specific service type - this is the componentSubType field within the component description and identifies the subtype of the component. Different subtypes of a component type may support additional features or provide interfaces that extend beyond the standard routines for a given component type. For example, the graphics exporter for PNG files has a component subtype of 'PNGf' represented by the kQTFileTypePNG constant.
  • Component manufacturer - this is the componentManufacturer field within the component description. This field allows for further differentiation between individual components.

Additionally, specific information about a particular component can be specified by using the componentFlags and componentFlagsMask fields of the component description record.

  • componentFlags - These flags can be used to indicate the presence of features or capabilities in a given component and can be used to further narrow the search criteria for a particular component. If you use the componentFlags field in a component search, use the componentFlagsMask field to indicate which flags are to be considered in the search.
  • componentFlagsMask - These flags indicates which flags in the componentFlags field are relevant to a particular component search operation. For each flag in the componentFlags field that is to be considered your application should set the corresponding bit in the componentFlagsMask field to 1. For example, to look for a component with a specific control flag that is set to 0, set the appropriate bit in the componentFlags field to 0 and the same bit in the componentFlagsMask field to 1. To look for a component with a specific control flag that is set to 1, set the bit in the componentFlags field to 1 and the same bit in the componentFlagsMask field to 1. To ignore a flag, set the bit in the componentFlagsMask field to 0.

There is an Ice Floe Engineering Technical Note which expands on the above discussion as it applies to Movie Export Components. IceFloe Dispatch 14 - Exporting Images

 

The FindNextComponent function returns the component identifier for the next registered component that meets the selection criteria specified by your application. You specify the selection criteria in a ComponentDescription structure.

You use the OpenComponent function to gain access to a specified component by using the previously obtained component identifier.

If you are interested only in using a component of a particular type-subtype and you do not need to specify any other characteristics of the component, use the OpenADefaultComponent or OpenDefaultComponent function and specify only the component type and subtype - the Component Manager then selects a component for you and opens a connection to that component.

When a component is opened through the component manager an instance of that component is created. This establishes a communications channel with the component and allocates memory for the tasks to be performed.

When you are done with a component instance that you opened, you should close it using CloseComponent. This will terminate the communication channel and release memory used by the component.

This diagram shows the relationship between an application, the Component Manager, and components.

Components Types

QuickTime components fall into several categories:

  • Movie Controllers - displays movies and provides playback controls.
  • Media Handlers - interpret and manipulate media sample data.
  • Video Digitizers/Sequence Grabbers - convert analog video data to digital form. Allows the ability to obtain digitized data from external sources.
  • Data Exchange - import and export data from non-movie sources and non-movie formats.
  • Compressors/Decompressors (Codecs) - provide compression and decompression services for media (such as sounds and image sequences).
  • Transcoders - translate data from one compressed format to another.
  • Video Output - send video to devices (such as DV Cameras) that are not recognized as displays by the computer.
  • Graphics Importers - display still images obtained from data in various file formats.
  • Graphics Exporters - store still images in the same format that graphics importers handle.
  • Preview - create and display previews.
  • Tween - perform interpolation between values of various data types.
  • Effects - provide real-time effects and transitions.
  • Text Channel - imports and exports text between movies and external text handling applications such as word processors.
  • Clock - generate timing information and schedule time-based callback events.
  • Real-time streaming - allow you to receive movies and live video in real time without downloading large files.

In some cases you may want to modify, extend or replace QuickTime's built-in components to accomplish a specific goal.

Media Presentation - You could write your own graphics importer, and sounds component or music synthesizer.

Media Capture - You may want to create a new Video Digitizer, image compressor or image compressor dialog component.

Media Handling - QuickTime provides extendable component frameworks that you can modify to provide custom handlers for video, sound, text, sprite, 3D, vector graphics and tween media. They include base components for media handling, effects, and transitions and musical instruments.

Utility Tasks - These include data exchange components, sequence grabber channel and panel components, video digitizers, video output components, image transcoders, data handlers, streaming components, clock components, music components and note allocators. These can be replaced if you want to alter specific areas of QuickTime's behavior.

References

Component Manager

 



Previous Section Table of Contents Next Section