hyperzoanoid
2002.07.03, 06:40 PM
hi i have a simple question, (i think) on flattening NSMovies. heres the code
NSURL *whereat;
NSMovie *sound;
NSOpenPanel *panelz=[NSOpenPanel openPanel];
int answer=[panelz runModalForTypes:[NSArray arrayWithObject:@"mp3"]];
if(answer==NSOKButton){
whereat=[[NSURL alloc]initFileURLWithPath:[panelz filename]];
sound=[[NSMovie alloc]initWithURL:whereat byReference:NO];
[pack setObject:[[sound QTMovie]FlattenMovieData] forKey:@"sound"];}
first i get the movie, but i want to save the whole movie, so i use the QTMovie call to get it and then FlattenMovieData to return the data. After that NSArchiver archives 'pack' the dictionary to file. If the above seems ok, then could it be a problem with not including the framework? i copied the quicktime framework into my app, and use
#import <QuickTime/QuickTime.h>
to get all of it but project builder still says it cant find the FlattenMovieData method.
NSURL *whereat;
NSMovie *sound;
NSOpenPanel *panelz=[NSOpenPanel openPanel];
int answer=[panelz runModalForTypes:[NSArray arrayWithObject:@"mp3"]];
if(answer==NSOKButton){
whereat=[[NSURL alloc]initFileURLWithPath:[panelz filename]];
sound=[[NSMovie alloc]initWithURL:whereat byReference:NO];
[pack setObject:[[sound QTMovie]FlattenMovieData] forKey:@"sound"];}
first i get the movie, but i want to save the whole movie, so i use the QTMovie call to get it and then FlattenMovieData to return the data. After that NSArchiver archives 'pack' the dictionary to file. If the above seems ok, then could it be a problem with not including the framework? i copied the quicktime framework into my app, and use
#import <QuickTime/QuickTime.h>
to get all of it but project builder still says it cant find the FlattenMovieData method.