|
Q: Did QuickTime 7.4 change the way Movie Import Components are called when importing from files?A: Yes, QuickTime 7.4 changed how the Movie Toolbox invokes Movie Import Components when specifically importing from files. With the release of QuickTime 7.4, the Movie Toolbox directly calls Component DevelopersThere are two APIs clients of Movie Import Components may call to invoke an import operation from a file; MovieImportFile
pascal ComponentResult MyComponent_MovieImportFile(My_Globals glob, const FSSpec *theFile, Movie theMovie, Track targetTrack, Track *usedTrack, TimeValue atTime, TimeValue *durationAdded, long inFlags, long *outFlags) Note: The MovieImportDataRef
pascal ComponentResult MyComponent_MovieImportDataRef(My_Globals glob, Handle dataRef, OSType dataRefType, Movie theMovie, Track targetTrack, Track *usedTrack, TimeValue atTime, TimeValue *durationAdded, long inFlags, long *outFlags) Developers writing Movie Import Components should implement both selectors to accommodate both older and newer behavior. Listing 1: Example MovieImportFile Component Implementation. pascal ComponentResult MyComponent_MovieImportFile(My_Globals glob, const FSSpec *theFile, Movie theMovie, Track targetTrack, Track *usedTrack, TimeValue atTime, TimeValue *durationAdded, long inFlags, long *outFlags) { ComponentResult err = noErr; AliasHandle alias = NULL; *outFlags = 0; err = NewAliasMinimal(theFile, &alias); if (err) return err; err = MovieImportDataRef(glob->self, (Handle)alias, rAliasType, theMovie, targetTrack, usedTrack, atTime, durationAdded, inFlags, outFlags); if (alias) DisposeHandle((Handle)alias); return err; } Application DevelopersApplication developers calling Movie Import Components directly to import from files should not call ReferencesDocument Revision History
Posted: 2008-03-11 |
|