About the Domain of Definition (DOD) |
The Domain of Definition (DOD) is a rectangular zone that Shake uses to bind the significant pixels in an image in order to optimize rendering speed. Everything outside of the DOD is considered as background (black by default), and is therefore ignored in most computations. Proper handling of the DOD is an extremely powerful way to speed up your render times.
To demonstrate the DOD node's efficiency, do the following:
To test this:
Attach a Filter - RBlur to the Text node, and set the oRadius to 360.
Create an Image - Rand, to create an entire frame of pixels.
Attach a Color - Monochrome to the Rand to turn it into a two channel image (The Text node creates a Black&White + Alpha image by default, so you must match the channels to compare rendering speeds.
Copy RBlur1 and attach the copied node to Monochrome1. There
is a significant difference in rendering speed, even though both images
are the same resolution.
All images from disk are automatically assigned a DOD that is equal to the resolution of the image. There are five ways to alter the DOD:
An image from disk is transformed or filtered. For example, this image is read in and scaled down and/or rotated with a Move2D. The DOD is automatically recalculated. Also, if an image is blured, the DOD expands accordingly.
A rendered .iff from Shake is embedded with a DOD. When Shake writes an .iff file, it automatically saves the DOD information. Only the .iff format embeds the DOD. In this example, the image that was written out in the previous example is read back into Shake:
The SetDOD node. This node, under the Transform tab, allows you to manually assign a DOD box to an image. Here, to limit the effects to the tower, attach a SetDOD node to it. This node is the Bee's Knees. Use it.
Note: When using onscreen controls to edit a shape (for example, a Rotoshape or QuickPaint object) that has control points within the boundaries of the DOD, move the cursor over the shape inside of the DOD, and then drag-select the points.
Combining images with a DOD is an excellent way to optimize green/bluescreen images that need garbage mattes, because it simultaneously removes the garbage areas and assigns an efficient DOD to the image. Here is an example tree:
building
(OK, it's a girl, deal with it)
|
QuickShape1 |
![]() |
![]() |
Primatte1
|
Inside1 |
![]() |
![]() |
With a good understanding of the role of the DOD, you can optimize the tree before and after the node in question. The above example not only optimizes any nodes you attach to Inside1, but executes the Primatte and reads in the part of the image that is inside of the DOD, reducing processing and IO activity.
This section discusses the area outside of the DOD, which is called the Background Color, (BGColor) for short.
The two main keyers in Shake, Keylight and Primatte, recognize the background color, and have a toggle to either key it in or out. By default, the background area is left black in the Alpha by the keyer. However, by toggling BGColor on, it turns the background completely white.
When color correcting the BGColor, Shake processes it very quickly,
as it recognizes there is a pure correction applied to previously black pixels.
If the color correction doesn't change black, like Gamma or Mult,
it is ignored. If it does affect the black areas, like Add or Compress,
it processes these areas, but understands that they are still the result of
a lookup process. Therefore, the DOD does not get reasserted to the resolution
frame. This is the same process that is used when the Infinite Workspace kicks
in. So even though the pixels outside of the DOD are not visibly different from
the pixels inside, the DOD remains in place.
There may be cases, however, where you want to take advantage
of the DOD for masking purposes. In this tree, an image is scaled down, and
the the brightness raised up with an Add node. This, however, turns the
area outside of the image a medium grey. Since this area is recognized to be
outside of the DOD, it can be returned to black with the Color - SetBGColor
node, which sets the color for the area outside of the DOD.
The Layer - Constraint node.also limits a process. The Constraint
node mixes two images according to a combination of modes. The modes are Area
of Interest (AOI), tolerance, channel, or field. For
this discussion, AOI applies. Toggle it on, and then set the area box.
Only the area inside of the box of the second image is calculated.