QuickTime macro

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

QuickTime macro

arnim.jenett
I am trying to save a stack as a QuickTime movie using a macro.  THe corresponding line looks like this:

run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum frame=7 save=/Volumes/rubinlab/tests/rotation/"+'getTitle()'+".mov");

And the resulting error like this:
quicktime.std.StdQTException[QTJava:6.1.6g],-47=fBsyErr,QT.vers:7168000
        at quicktime.std.StdQTException.checkError(StdQTException.java:38)
        at quicktime.std.movies.Movie.createMovieFile(Movie.java:124)
        at QuickTime_Writer.writeMovie(QuickTime_Writer.java:109)
        at QuickTime_Writer.run(QuickTime_Writer.java:86)
        at ij.IJ.runUserPlugIn(IJ.java:266)
        at ij.IJ.runPlugIn(IJ.java:120)
        at ij.Executer.runCommand(Executer.java:95)
        at ij.Executer.run(Executer.java:46)
        at ij.IJ.run(IJ.java:331)
        at ij.macro.Functions.doRun(Functions.java:515)
        at ij.macro.Functions.doFunction(Functions.java:64)
        at ij.macro.Interpreter.doStatement(Interpreter.java:196)
        at ij.macro.Interpreter.doStatements(Interpreter.java:186)
        at ij.macro.Interpreter.run(Interpreter.java:91)
        at ij.macro.Interpreter.run(Interpreter.java:57)
        at ij.macro.MacroRunner.run(MacroRunner.java:65)
        at java.lang.Thread.run(Thread.java:613)

What am I doing wrong?
I really tried hard but I am completely stuck.
This was tried on a G5,Mac OS X 10.4.9
Reply | Threaded
Open this post in threaded view
|

Re: QuickTime macro

Wayne Rasband
QuickTime generates -47 (fBsyErr) errors if the file name is longer
than 32 characters. I may also not like parentheses in file names, for
example "getTitle().mov", which is the name generated by this macro. To
work as intended, the macro needs to be changed to

  run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum
frame=7 save=/Volumes/rubinlab/tests/rotation/"+getTitle()+".mov");

or to

  run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum
frame=7 save=[/Volumes/rubinlab/tests/rotation/"+getTitle()+".mov]");

to work with stacks that have spaces in the title.

-wayne



On May 16, 2007, at 12:15 PM, aRnim wrote:

> I am trying to save a stack as a QuickTime movie using a macro.  THe
> corresponding line looks like this:
>
> run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum
> frame=7
> save=/Volumes/rubinlab/tests/rotation/"+'getTitle()'+".mov");
>
> And the resulting error like this:
> quicktime.std.StdQTException[QTJava:6.1.6g],-47=fBsyErr,QT.vers:7168000
> at quicktime.std.StdQTException.checkError(StdQTException.java:38)
> at quicktime.std.movies.Movie.createMovieFile(Movie.java:124)
> at QuickTime_Writer.writeMovie(QuickTime_Writer.java:109)
> at QuickTime_Writer.run(QuickTime_Writer.java:86)
> at ij.IJ.runUserPlugIn(IJ.java:266)
> at ij.IJ.runPlugIn(IJ.java:120)
> at ij.Executer.runCommand(Executer.java:95)
> at ij.Executer.run(Executer.java:46)
> at ij.IJ.run(IJ.java:331)
> at ij.macro.Functions.doRun(Functions.java:515)
> at ij.macro.Functions.doFunction(Functions.java:64)
> at ij.macro.Interpreter.doStatement(Interpreter.java:196)
> at ij.macro.Interpreter.doStatements(Interpreter.java:186)
> at ij.macro.Interpreter.run(Interpreter.java:91)
> at ij.macro.Interpreter.run(Interpreter.java:57)
> at ij.macro.MacroRunner.run(MacroRunner.java:65)
> at java.lang.Thread.run(Thread.java:613)
>
> What am I doing wrong?
> I really tried hard but I am completely stuck.
> This was tried on a G5,Mac OS X 10.4.9
> --
> View this message in context:
> http://www.nabble.com/QuickTime-macro-tf3765455.html#a10644650
> Sent from the ImageJ mailing list archive at Nabble.com.
>
Reply | Threaded
Open this post in threaded view
|

Re: QuickTime macro

arnim.jenett
The file nane in the test case was generated by RGBMerge: RGB.
No spaces, less than 32 characters.
suggestion #1 was the initial trial. doesn't work.
suggestion #2 does not work either. As expected, because there are no spaces in the file name.

Actually the error even appears if I replace the getTitle() with a static value like
run("QuickTime Movie..., compression=[Sorenson 3] quality=Maximum frame=7 save=/Volumes/rubinlab/tests/rotation/foobar.mov");

Recording the call of the macro with the macro recorder gives me:
run("Run...", "run=/Volumes/rubinlab/aRnim/ImageJ/macros/2tests.txt compression=[Sorenson 3] quality=Maximum frame=7 save=/Volumes/rubinlab/tests/rotation/foobar.mov");

Running the macro with the getTitle()
run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum frame=7 save=[/Volumes/rubinlab/tests/rotation/"+getTitle()+".mov]");

records like this:
run("Run...", "run=/Volumes/rubinlab/aRnim/ImageJ/macros/2tests.txt compression=[Sorenson 3] quality=Maximum frame=7 save=/Volumes/rubinlab/tests/rotation/RGB.mov");

Therefore the I think the parameters are right but applied to tha macro instead of the QuickTime writer.
How can I cope with that?



Wayne Rasband wrote
QuickTime generates -47 (fBsyErr) errors if the file name is longer
than 32 characters. I may also not like parentheses in file names, for
example "getTitle().mov", which is the name generated by this macro. To
work as intended, the macro needs to be changed to

  run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum
frame=7 save=/Volumes/rubinlab/tests/rotation/"+getTitle()+".mov");

or to

  run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum
frame=7 save=[/Volumes/rubinlab/tests/rotation/"+getTitle()+".mov]");

to work with stacks that have spaces in the title.

-wayne



On May 16, 2007, at 12:15 PM, aRnim wrote:

> I am trying to save a stack as a QuickTime movie using a macro.  THe
> corresponding line looks like this:
>
> run("QuickTime Movie...", "compression=[Sorenson 3] quality=Maximum
> frame=7
> save=/Volumes/rubinlab/tests/rotation/"+'getTitle()'+".mov");
>
> And the resulting error like this:
> quicktime.std.StdQTException[QTJava:6.1.6g],-47=fBsyErr,QT.vers:7168000
> at quicktime.std.StdQTException.checkError(StdQTException.java:38)
> at quicktime.std.movies.Movie.createMovieFile(Movie.java:124)
> at QuickTime_Writer.writeMovie(QuickTime_Writer.java:109)
> at QuickTime_Writer.run(QuickTime_Writer.java:86)
> at ij.IJ.runUserPlugIn(IJ.java:266)
> at ij.IJ.runPlugIn(IJ.java:120)
> at ij.Executer.runCommand(Executer.java:95)
> at ij.Executer.run(Executer.java:46)
> at ij.IJ.run(IJ.java:331)
> at ij.macro.Functions.doRun(Functions.java:515)
> at ij.macro.Functions.doFunction(Functions.java:64)
> at ij.macro.Interpreter.doStatement(Interpreter.java:196)
> at ij.macro.Interpreter.doStatements(Interpreter.java:186)
> at ij.macro.Interpreter.run(Interpreter.java:91)
> at ij.macro.Interpreter.run(Interpreter.java:57)
> at ij.macro.MacroRunner.run(MacroRunner.java:65)
> at java.lang.Thread.run(Thread.java:613)
>
> What am I doing wrong?
> I really tried hard but I am completely stuck.
> This was tried on a G5,Mac OS X 10.4.9
> --
> View this message in context:
> http://www.nabble.com/QuickTime-macro-tf3765455.html#a10644650
> Sent from the ImageJ mailing list archive at Nabble.com.
>