5

I'm trying to create a QTVR movie via QTKit, and I've got all the frames in the movie. However, setting the attributes necessary doesn't seem to be having any effect. For example:

NSNumber *val = [NSNumber numberWithBool:YES];
[fMovie setAttribute:val forKey:QTMovieIsInteractiveAttribute];

val = [NSNumber numberWithBool:NO];
[fMovie setAttribute:val forKey:QTMovieIsLinearAttribute];

If I then get the value of these attributes, they come up as NO and YES, respectively. The movie is editable, so I can't understand what I'm doing wrong here. How can I ensure that the attributes will actually change?

Josh Matthews
  • 12,816
  • 7
  • 36
  • 39

2 Answers2

1

What I do when I want to export a Quicktime movie is something like the following:

NSMutableDictionary *dictionary = [NSMutableDictionary dictionaryWithObjectsAndKeys:
    [NSNumber numberWithBool:YES], QTMovieExport,
    [exportSettings objectForKey: @"subtype"], QTMovieExportType,
    [exportSettings objectForKey: @"manufacturer"], QTMovieExportManufacturer,
    [exportSettings objectForKey: @"settings"], QTMovieExportSettings,                                      
  nil];

BOOL didSucceed = [movie writeToFile: tmpFileName withAttributes:dictionary error: &error];
Daniel
  • 4,847
  • 1
  • 23
  • 19
0

Those attributes are documented as things you can read but not write. However, you might be able to set them when you create the movie, with initWithAttributes:error:.

JWWalker
  • 22,385
  • 6
  • 55
  • 76