< Previous | Contents | Next >
Where to Calculate Disparity and Optical Flow?
Where you choose to generate optical flow or disparity in your composition can drastically affect the results.
For example, if you have composited a lens flare in, it is better to compute OpticalFlow/Disparity before that, since the semi-transparent lens flare will confuse the tracking algorithms.
If you are color correcting the left/right eyes to match or for deflickering, it is better to apply the OpticalFlow/Disparity afterward, since it will be easier for the tracking algorithm to find matches if the color matches between frames.
If you are removing lens distortion, think carefully about whether you want to do it before or after Disparity computation. If you do it after, your Disparity map will also act as a lens distortion map, combining the two effects as one.
As a general rule of thumb, it is best to use OpticalFlow/Disparity before any compositing operations except an initial color matching correction and a lens distortion removal.
Cropping the Source
As a general tip, if you are cropping down your input images for any reason, it is probably better to compute the optical flow or disparity before the crop and then afterward crop the flow/disparity along with the color.
The reason is that flow/disparity matching works well when there is common pixel data to match in both frames, but when there are pixels that show up in just one frame (or one eye), then the Disparity/ OpticalFlow nodes must make a guess and fill in the data. The biggest occlusions going from L <–> R are usually pixels along the L/R edges of the images that get moved outside. This is similar for optical flow when you have a moving camera.
Another thing to be aware of are black borders around the edges of your frames, which you should crop away.
Nodes with Multiple Outputs
Many of the stereo nodes in the Fusion toolset have multiple outputs. This can cause some confusion to new users. One particularly confusing thing is that when you drag a Stereo node to the view, it will always display the left output. There is no way to view the right output without connecting another node like BC (BrightnessContrast) to the right output and viewing that.
Picking from Aux Channels
Some nodes, like StereoAlign, allow one to drag pick from the Z or Disparity auxiliary channels. You must pick from a node upstream of the StereoAlign, not from the output of the StereoAlign. If you try to pick a disparity from the output of a StereoAlign node, you will get nothing because StereoAlign consumes/destroys the Disparity aux channel (and even if it did not destroy the Disparity channel, you would still be picking the wrong value since you would be picking from the aligned result).