Retired Document
Important: This document may not represent best practices for current development. Links to downloads and other resources may no longer be valid.
QuickTime Movies In Cocoa
Cocoa represents QuickTime movies as NSMovie objects. Any
QuickTime-readable movie can be loaded into an NSMovie object; the
movie data can be read from a pre-existing QuickTime movie pointer,
a URL, or a pasteboard. The NSMovie class does not define methods
for manipulating the movie data directly, but you can obtain a pointer
to the data (with the QTMovie
method) and
then use the extensive QuickTime APIs. Primarily, NSMovie is used
to display a movie inside an NSMovieView.
An NSMovieView displays an NSMovie object in a frame and provides methods for playing and editing the movie. With NSMovieView, you can control the sound volume, play speed, looping mode, and movie controller visibility. With the standard QuickTime movie controller visible, the user can play the movie, set the volume, reposition the play head, and make selections. (Note that the movie controller operates directly on the movie, bypassing the NSMovieView methods.) If the movie is editable, the user can also perform copy and paste operations on the movie. (See Archiving NSMovie Objects for details on saving a modified movie to a file.)
Copyright © 2002 Apple Computer, Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2002-11-12