5.4 Stereo pairs batch processing mode
Batch processing allows to generate GIF or images+depth maps (2D+Z) animation from the several stereo pairs. To launch batch processing go to Project >> Batch processing (Ctrl+B) (Fig. 5.17).
Figure 5.17. Menu – Project – Batch processing
And Select conversion type (Fig. 5.18).
Figure 5.18. Select conversion type dialog, 2D+Z > GIF tab
In batch generation, the following types are available:
1) Generating GIF-animation from a 2D image and depth map - 2D+Z > GIF tab:
Type of input files:
- Image and depth map are in different files;
- The image and the depth map are in one file (side-by-side);
Output file type:
Images will be recorded in one file with animated viewing;
2) Generating a stereopair from a 2D image and a depth map - 2D+Z > stereo pair tab:
Type of input files:
- Image and depth map are in different files;
- The image and the depth map are in one file (side-by-side);
Output file type:
- The left and right images will be recorded in separate files;
- The left and right images will be recorded in one file (side-by-side);
3) Generate a 2D image and a depth map from a stereo pair - Stereo pair> 2D+Z tab:
Type of input files:
- The left and right images are in different files;
- The left and right images are in one file (side-by-side);
Output file type:
- The image and depth map will be recorded in separate files;
- The image and depth map will be recorded in one file (side-by-side).
- Generating a depth map from a 2D image – 2D tab > 2D+Z:
Output file type:
- The image and depth map will be written to separate files;
- The image and depth map will be written to one file (side-by-side).
Generating GIF animation from a 2D image and depth map
When generating a GIF animation or a stereopair from a 2D image and a depth map, two options for specifying input files are possible: images are taken from two separate files or from one file.
Also at the stage of selecting the type of generation, the type of output files is indicated: one file or two files with placement of two images side-by-side.
Another selection parameter for output files is the file format on disk. Standard formats are available: JPEG, PNG, TIFF, BMP. The default fromat is JPEG. Only in the case of GIF-animation generation is the only GIF file format available.
When you select the first option (Image and depth map are in different files) and press Next the Select images dialog appears Select images (Fig. 5.19).
Figure 5.19. Select images dialog for batch processing
Select source images and depth maps by pressing Add… (Fig. 5.20).
Figure 5.20. Open images dialog
Selected images are numbered automatically (Fig. 5.21). This order will be used to couple the source image and its depth map (e.g. the first image is used in combination with the first depth map). Check the ordering and update with “up” and “down” arrows in case it’s wrong. You can delete files that were added occasionally. Delete
Figure 5.21. Sorting images and depth
Press OK when finished, Batch animation properties dialog appears (Fig. 5.22).
Figure 5.22. Batch animation properties dialog
Here you can control the following settings:
- Number of frames animation consists of;
- Parallax - first and the last frames difference (shift between them);
- Plain of zero parallax - the object with zero parallax is an object “in focus”, i.e. perceived by both eyes equally, without displacement (have no parallax);
- Frames per second – animation speed;
- Loop – GIF-animation repeat mode;
- Resize image – change the source image size (pixels);
- Keep aspect ratio - to keep the source image proportions when edit Width or Height parameter;
Press ОК to continue. Browse for folder dialog appears (Fig. 5.23). Select the path to save your GIF-animation result.
Figure 5.23. Browse For Folder dialog
Press OK to launch the generation process.
If the image and depth map are located in the one file, clicking the Next >> button will show another dialog image selecting dialog (Figure 5.24).
Figure 5.24. Select 2d plus depth (side by side) dialog
Generating a stereopair from a 2D image and depth map
A stereopair from a 2D image and a depth map generation process is similar. Conversion type selection tab on dialog shown on fig. 5.25.
Figure 5.25. Select conversion type dialog, 2D+Z > stereo pair tab
Batch properties dialog differs from that shown in Fig. 5.22, and is called the Batch stereo pair properties (see Figure 5.26).
Fig. 5.26. Stereo pair properties dialog
The output file with the addition to the original name "_stereo" or the "Left" and "Right" directories will be created in the location of the source images, in which the corresponding output files will be placed. The file extension will match the selected format.
Generating a depth map and 2d image from stereo pair
When you select stereo pair to 2D+Z conversion type (Fig. 5.27) you go the same way follow the same steps as when processing as GIF-animation processing except Batch (animation or stereo pair) properties step (Fig. 5.22 and fig. 5.26). The left image serves as a source image, the right image is used instead of the depth map.
Figure 5.27. Select conversion type dialog
In case you select 2D+Z animation out of a stereo pair side-by-side specify the source stereo pair in Select stereo pairs dialog (Fig. 5.28) and press Next >>.
Figure 5.28. Select stereo pairs dialog for batch processing
Note: A stereo pair should be in side-by-side format (left and right frames aligned). In case the source stereo pair has the backwards order, mark cross eyed check box. Side-by-side source image sample is shown on the image below (Fig. 5.29).
Figure 5.29. Side-by-side source stereopair
Press Open to continue. Browse for folder dialog appears (Fig. 5.30). Specify the path to save your result. The output depth maps format will have the same format as the source images.
Figure 5.30. Browse For Folder dialog
Press OK to launch the generation process. The output file with the addition to the original name "_2DZ" or the "2D" and "Depth" directories will be created in the location of the source images, in which the corresponding output files will be placed. The file extension will match the selected format.
Generating a depth map from a 2D image
When generating a pair from a 2D image and a depth map from of original 2D image, one option is possible when the images are taken from the same file. The type of output files can be selected from two options: the original 2D image and the generated depth map can be saved to separate files, or into one file (side-by-side).
The output file format selection is also available (Fig. 5.31).
Rice. 5.31. Batch processing type selection dialog, 2D tab > 2D+Z
By clicking the Next >> button, a dialog will open with a choice of source 2D images (Fig. 5.32).
Rice. 5.32. 2D images selection dialog
Then after clicking the Open button, the Browse Folder dialog will be displayed (Fig. 5.23 and 5.30). The generation results will be saved to the selected location. After the generation and export process is completed, a dialog will appear with a message asking you to go to the saving destination (Fig. 5.33).
Rice. 5.33. Message dialog to complete the process and go to the export location