1

Sorry if this is a very easy question but:

I'm trying to create a reference movie of a Quicktime movie . I am cutting parts of the movie out then I want to save the file as a reference not a self contained movie. I know how to do the cutting and how to save a self contained file but I don't know how to make a reference file.

Thanks for the help.

1 Answers1

0

-[QTMovie writeToFile:withAttributes:] with nil as attribute-dictionary should work.

If — for whatever reason — it doesn't work directly with your edited movie, the simplest way I can think of is:

// assuming "sourceMovie" is your edited QTMovie:
NSError *error;
QTMovie *destinationMovie = [QTMovie movieWithData:[sourceMovie movieFormatRepresentation] error:&error];
if ( !destinationMovie )
//  bail!
if ( ![destinationMovie writeToFile:newFilename withAttributes:nil error:&error] ) 
//  respond to not being able to write...
danyowdee
  • 4,658
  • 2
  • 20
  • 35