Batch Option Overlay Image Sequences

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

Batch Option Overlay Image Sequences

MSiebelt
Hi all,

as a complete idiot in writing macros, I am asking if anybody out there could help me with the following.

Using ImageJ, I am able to make an overlay of two different Image Sequences. Since I need to make a lot of these combined sequences, I was trying to automate this by creating a macro. Succesfully I've written something that speeded up my work, but I know for sure that it probably can be even better. This is what I got so far:

run("Image Sequence...");
run("Image Sequence...");
imageCalculator("Transparent-zero create stack", "Dataset 1","Dataset 2");
//run("Image Calculator...", "image1=Dataset 1 operation=Transparent-zero image2=Dataset 2 create stack");
run("Image Sequence... ", "format=BMP name=Combined start=0 digits=4 save=[..\\Combined\\Combined0000.bmp]");
close();
close();
close();

This macro opens both image sequences and creates an overlay dataset. But the problem lies in saving this dataset in a correct subfolder. For all my datasets I use a same folder tree, like the following:
          1\A                 (=> contains dataset 1.1)
          1\A\..\..\B         (=> contains dataset 1.2)

When ImageJ prompt me which datasets to load in this macro, these are the location were I select the images. But what command do I need to put at behind the save=, to store the combined dataset in folder ...A\C (<- this folder is already on the HD)?

And second (to make it a little more complicated): can you restart this macro so it runs on and on? As a result I would only have to select both dataset 1 and 2, and the combined images will be stored in the subfolder of dataset1.  
          1\A                 (=> contains dataset 1.1)
          1\A\..\..\B         (=> contains dataset 1.2)
          2\A                 (=> contains dataset 2.1)
          2\A\..\..\B         (=> contains dataset 2.2)
          3\A                 (=> contains dataset 3.1)
          3\A\..\..\B         (=> contains dataset 3.2)
And so on...

Hope somebody can help me with this!

Thanks in advance!

Michiel