Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

strange behaviour with my TransitionTrackBuilder mod



Really unusual scenario(bug??) I spent too much time narrowing down.  I was playing with the TransitionTrackBuilder from Chris' QTJ Notebook.  His code works fine of course.
 
Now, to save the finished movie, the code reads:

        OpenMovieFile omf = OpenMovieFile.asWrite(movFile);
        movie.addResource (omf,
                           StdQTConstants.movieInDataForkResID,
                           movFile.getName());
 
movFile was defined previously in creating the blank movie that all the tracks were added to:

QTFile movFile = new QTFile (new java.io.File("C:\\Tests\\translations\\transition.mov"));
        Movie movie =
           Movie.createMovieFile(movFile,
                                  StdQTConstants.kMoviePlayer,
                                  StdQTConstants.createMovieFileDeleteCurFile |
                                  StdQTConstants.createMovieFileDontCreateResFile);
 
Like I said, this all works fine. 
 
Now, if I make a small change and write the movie out this way instead:
 
QTFile qtf = new QTFile (new File("C:\Tests\transition.mov");
movie.flatten (0, // movieFlattenFlags
                             qtf, // fileOut
                             StdQTConstants.kMoviePlayer, // creator
                             IOConstants.smSystemScript, // scriptTag
                             StdQTConstants.createMovieFileDeleteCurFile, // createQTFileFlags
                             StdQTConstants.movieInDataForkResID, // resId
                             qtf.getName());
 
Not surprisingly, this works almost exactly like Chris' way.  The maddening difference is that there's a little 'tick' of white space introduced between the first clip and the beginning of the transition.  I've checked and double checked, and narrowed it down to the above difference.  Somehow, the track offset information seems to be getting slightly askew when flattening the movie as opposed to saving it back into the resource file.
 
What's going on?
 
The sample movie I'm working for both start and end movies can be found here:
http://java.sun.com/products/java-media/jmf/2.1.1/solutions/bluescreen2.mov
 
--Alex
 
 

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
QuickTime-java mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quicktime-java/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.