nkumarp Posted November 4, 2008 Share Posted November 4, 2008 Hi all, I am facing problem to create QTMovie object with class method -movieWithData:error:, if movie format other than mov. I wrote like this, NSData *data = [[NSData alloc] initWithContentsOfFile: path]; //path store the path of file. NSError *error; QTMovie *movie = [QTMovie movieWithData: data error:&error]; if(error != nil) NSLog("error %@", error); [movieView setMovie:movie]; if the file is other than mov, say mp3 , this code giving error message as NSError "the file is not a movie file" Domain=NSOSStatusErrorDomain Code=-2048 UserInfo={NSLocalizedDescription = "the file is not a movie file"; if i create qtmovie object with class method movieWithFile: i can create the object and play the file. but in app i want to initialize QTMovie object with NSData. Can anybody give solution for this or what is the mistake i have done here. with Thanks & regards, Nish. Link to comment Share on other sites More sharing options...
Recommended Posts