The Transform menu contains nodes used for spatial transformations such as cropping, scaling, and rotating: Crop, Flip Flop, Resize, Skew, and Transform. The Transform node is the most versatile--it translates, rotates, and scales.
The Morph node can be used to distort or morph images, and the Track node tracks movement through time. Tracking data can be used throughout RAYZ to control the animation of various operations across a range of frames. The Match Move and Stabilize nodes require tracking data to control their operations.
The Resize, Transform, Match Move, and Stabilize nodes all include a Filtering parameter group to specify the type of filtering to apply to scaling and other transformations to remove aliasing, ringing, and similar artifacts that may be introduced.
The Filtering menu provides the following options:
Select the option that fits your imagery. For the best looking result, choose the natural scene option for film footage or the CG scene option for computer generated images, as from a 3D program. RAYZ assumes that CG imagery is likely to have harder edges than filmed imagery and will dynamically choose the best filter for the type of transformation operation specified.
Bilinear interpolation is fast and often produces an adequate result. The fastest option is no filtering at all, which may be adequate when image quality is not a top concern, as when reviewing your initial settings.
If you want to specify individual filtering parameters yourself, select the Advanced option, which activates the parameters within the Filtering group.
Expand the Filtering group to access the Advanced parameters, which become active whenever "Advanced - User Set" is selecting in the Filtering menu. Use the Advanced parameters to select a specific type of image filter and then set any other filter-specific parameters that are activated by your selection.
The Filter Type menu includes Box, Triangle, Quadratic, Cubic, and Gaussian; as well as Catmull-Rom/Overhauser Spline, Mitchell, Sinc (Windowed), Bessel (Windowed), Lanczos 2-lobe Sinc, and Lanczos 3-lobe Sinc.
Box, Triangle, Quadratic, Cubic and Gaussian refer to the shape of the distribution function that defines the filter. Box equals constant, triangle is linear; and so on in increasing precision and processing time.
The other filter options are named for the individuals who developed them, and the best choice will depend on the individual characteristics of the image as well as on the type of operations the node is performing. For example, since scaling an image down can introduce high frequency artifacts, a low-pass filter would be a good choice.
The Mitchell and Lanczos filters are among the most popular filter options. Mitchell filtering is often preferred for images with a lot of fine lines (and for JPEGs). Lanczos filtering generally provides a good compromise between sharpness, ringing and aliasing reduction, especially for images without a lot of hard edges. It is best used on images which will be scaled down.
To experiment with different filter options when working with large images, use ROI to confine processing to a smaller area. For more information about using ROI, see Defining a Region of Interest in chapter 6. |
This parameter can be used with any filter option when heavy blurring is needed. The minimum value of 1, which is the default, adds no blurring to the image; values greater than 1 represent increased blurring, up to the maximum of 4.
The Mitchell B and C parameters are activated when Mitchell filtering is selected in the Filter Type menu to enable you to make adjustments to the Mitchell filtering process.
The default values, 0.333 for both parameters, fall within a recommended range of roughly 0.25 to 0.5. Since the quality of the result must be judged based on your imagery and intentions, the best course may be to experiment with these settings.
As a guideline, note that values above 0.5 for the Mitchell B parameter may produce unnecessary blurring. Values above 0.5 for the Mitchell C parameter may result in excessive ringing (rippling patterns). When both parameters are set at values above 0.6 or below 0.2, anisotropic artifacts may appear.
The Window Type parameter is activated only when the Sinc or Bessel filter type is selected from the Filter Type menu. Choose Hann, Hamming, Blackman, or Kaiser.
When Kaiser is chosen in the Window Type parameter, this additional control parameter is activated, which modifies the level of filtering.
The Transform, Match Move and Stabilize nodes all include a Motion Blur parameter group, which is used to add motion blur to the movement generated by the node. The RAYZ motion blur algorithm works by sampling and accumulating, just as film or any other light-gathering source would.
Check the Motion Blur box to turn on motion blur for the node. You can expand the Motion Blur group to access the Shutter Phase and Shutter Speed parameters:
The Shutter Phase parameter enables you to specify where in a frame to "open the shutter," in a range of -1 to 1. The default is 0, which represents the beginning of the frame.
The Shutter Speed parameter enables you to specify the duration of the effect for each frame in a range of 0 to 2, where 2 represents the duration of one complete frame, or 360 degrees rotation of the iris (so that a Shutter Speed value of 1 represents 180 degrees, or a half-frame duration).
Fig. 17.1 This diagram illustrates the effect of the Shutter Phase and Shutter Speed settings. Frame 2 of the output sequence is currently being processed.
Contents | Top of Page | Index
The Corner Pin node is used to animate the distortion of an image by controlling the position of the image corners through a series of frames. It can be used to stretch or twist an image, especially to simulate perspective.
The Corner Pin node is most often used to match the changing perspective of a moving element in a background image. For example, Corner Pin could be used to add a sign to the side of a truck driving along a winding road.
The Corner Pin node accepts one or two inputs: the image to be pinned and an optional reference image input. The reference image establishes the frame size of the output image. In addition, the primary input can be viewed in a temporary composite over the reference input by selecting Temporary Pre-Comp from the Source menu. (In fact, this view is selected by default when you connect a reference image.) However, the Corner Pin node only outputs the modified primary input (the pinned image), which can then be composited in an appropriate composite node.
The corner positions can be adjusted interactively using an overlay widget, similar to a cropping box, in the Image Viewer. The numerical values representing the x,y coordinates for each corner can be viewed and further adjusted in the Node Panel.
If you connect the background image to the reference input of Corner Pin, you will have the option of setting the corner positions while viewing the foreground, the reference image, or a temporary composite of the two.
All four corners can be animated, and the Corner Pin node often uses position data from a Track node to control the corner values.
To use data generated in a Track node to control the position of each corner, follow these steps:
/track1:points.point_name.position.x
(for the
x
curve)
/track1:points.point_name.position.y
(for the
y
curve)
As an alternative to typing an expression into the Keypoint Editor as described in steps 7 and 8 above, you can right-hold on a curve in the graph and select Edit Expression.
In the Expression Editor, select Node Parameters and a list of all nodes in the Worksheet will be displayed. Select the Track node from this list to display all of the Track node's parameters in another list.
Then you can double-click the x or y position parameter for the appropriate track point and it will be entered in the expression field. This way you do not need to remember the proper syntax to use.
You can repeat the process with each curve, or you can then open the Keypoint Editor to access all of the expression fields in one list. You can copy and paste the first track point expression into the other fields, modifying only the point name and coordinate designation.
To view the results, select Temporary Pre-Comp in the Viewer's Source menu and use the flipbook controls to play the sequence in a temporary composite of the pinned foreground image over the background.
Once you have set up a Corner Pin to use Track node data, you can save the nodes to the Custom menu to use as a template for future operations. (See also Adding Nodes to the Custom Menu in chapter 5.) In this way, any time you need to do a corner pin based on track data, select the custom nodes to add them to the worksheet and connect them to the specific images to be tracked and pinned. Reposition the four track points to the new image features and retrack. Be sure to match the track point name ("top_left," e.g.) to the appropriate track feature. |
The Corner Pin Node Panel includes parameters that specify the position of the four corners as well as a Filtering menu.
Each of the four corner position parameters provides a pair of data entry fields representing the x,y coordinate values for that corner. By default the parameter values create a four-corner pin area the size of the input image--the Bottom Left parameter value is 0, 0 and the Top Right parameter value is the maximum for the image. The corner parameters are listed in clockwise order starting at the bottom left corner:
The values in the fields update automatically when the Corner Pin widget in the Viewer is adjusted, and vice versa.
Use this menu to specify whether to use a bilinear interpolation filter to reduce aliasing and other image artifacts that may be introduced by the Corner Pin operation. Bilinear Interpolation is selected by default, as it is fairly fast and efficient, however, you can select No Filtering for the fastest processing.
Contents | Top of Page | Index
The Crop node enables you to crop, or trim, an image to a specified area. You can choose to output only the cropped area, that is, to change the size of the output frame; or you can output the same size frame as the input image, with the pixels outside the crop area set to the backing color specified for the source image.
The crop area can be defined interactively or numerically. When the Crop node is displayed in a Viewer and Input Image is selected in the Source menu, a crop box appears as an overlay on the image. You can drag the crop box in the image to interactively define the crop area, or you can adjust the parameter values in the Crop Node Panel--when one is changed, the other updates automatically to reflect the changes.
By default, the input image is displayed in the Viewer to enable you crop to the desired area interactively. To view the cropped output image, switch the Source menu in the Viewer from Input Image to Output Image.
Fig. 17.2 View the Input Image (left) to define crop area and switch the view to Output Image (right) to see the result.
Use the s hotkey (with the cursor over the Image Viewer) to toggle back and forth between the input and output image views. |
Both the Corner and Size parameters display their values in pixel units by default. To view parameter values in floating point units, check the Float Display box in the Parameter menu (located on the right side of the parameter's slider control).
Use this parameter to position the cropping box over the input image by specifying the x,y coordinates of the bottom left corner of the box.
Unlike the Size parameter fields, the Corner fields accept negative values so that you can position the corner outside the bottom or right border of the image (the spatial coordinates of the bottom left corner of the input frame are 0,0).
Use this parameter to specify the dimensions of the crop area. You can type positive pixel values into the Width and Height fields or use the Size menu to select a preset size from a list of film and video resolutions.
By default, the node resizes the output frame to the crop area. However, you can uncheck the Change Output Size box if you want the output frame to be the same size as the input, with the pixels outside of the crop area set to the Backing Color value of the source image (which is black, or 0, by default). Refer to the section on the Backing Color Parameters in chapter 14 if you need more information.
Fig. 17.3 The frame boundaries are outlined in white in these examples. At left, output size changes to match the crop area; at right, output size matches input, with pixels outside crop area set to black (0).
Contents | Top of Page | Index
The Flip Flop node enables you to flip an image horizontally and/or vertically as well as to rotate it in 90-degree increments.
For finer control of rotation, or to animate rotation values across time, use the Rotate parameter in the Transform node instead. |
The Flip Flop node provides three checkbox parameters, which can be used singly or in combination. When the associated box is checked,
The Flip Flop parameters can be used in the following combinations to rotate the input image:
Contents | Top of Page | Index
The Match Move node is used to animate a foreground element to match the movement in a background scene.
Match Move accepts one or two inputs, with the second optional input being used for a reference image that establishes the frame size of the output. This means that the reference image must be connected to Match Move whenever it differs in size from the primary input image, because the track point values are scaled in relation to the output size.
Another reason to use a reference input is that the primary input can be viewed in a temporary composite over the reference image by selecting Temporary Pre-Comp from the Source menu. (In fact, Temporary Pre-Comp is selected by default when you connect a reference image.)
Match Move uses tracking data to control the translation, rotation, and scaling of the foreground over time. The Match Move node does not create tracking data. Refer to the description of the Track Node later in this chapter for instructions on generating track data. |
A match move is performed to position a foreground element at each frame to match the movement of an object in a background image. The Match Move node uses data previously created in a Track node by tracking an appropriate area of the background.
For match moves, follow these steps:
The Translation menu enables you to choose Match Move (the default) or No Translation. (The No Translation option is provided for matching scaling or rotation only.)
The Translate Point menu automatically lists all the track points in every existing Track node in the file.
Optionally, you can create an Offset for the position data by dragging the Offset overlay in the image viewer to the desired location, or by entering x,y coordinate values into the Offset parameter fields.
Fig. 17.4 The Offset overlay is a simple crosshairs device located by default at the 0,0 coordinates of the image; that is, the lower left corner.
You can also match scaling and rotation, as explained below.
You can match scaling and rotation in conjunction with the match move. Additionally, you can use the "No Translation" option when you want to use tracking data to match scaling and rotation alone.
Refer to the Rotation and Scale Parameters description for more detailed information about these parameters.
The Translation menu can be used to change the default selection from Match Move to "No Translation." This option should be selected only if you are using the node strictly to match rotation or scaling, without any other translation.
Expand the Translation parameter to access the Translate Point and Offset parameters:
This parameter enables you to specify which track point to reference for the Match Move operation. The Translate Point menu will automatically list all track points in all existing Track nodes.
The Offset parameter enables you to offset the position data by keying specific x,y values into the fields. The Offset parameter is tied to the corresponding overlay in the Image Viewer, which can also be used to specify the Offset value by dragging the crosshairs device over the desired location in the image.
The Rotation and Scale parameters enable you to match rotation and scaling. Unlike the Translation operation, the Scale and Rotation operations each require two sets of track data, as the changes in length or position of the vector between two track points are used to calculate the values.
The Rotation menu enables you to select No Rotation (the default) or Match Rotation.
The associated Pivot and Reference menus become active whenever Match Rotation is selected (expand the Rotation parameter to access). Use the menus to select the track point data to use for each parameter.
For the Pivot, use the track point that represents the pivot of the rotation.
For the Reference, use the point that represents the position of the moving end of the rotation vector.
The Scale menu enables you to select No Scale (the default), Match Size Scale, or Match Distance Scale:
The associated Reference parameters become active whenever a match option is selected (expand the Scale parameter to access). Use the Reference A and Reference B menus to select the track point to use to represent each end of the vector defining the scale value.
Use this menu to select the filtering option to use to reduce aliasing and other artifacts that may be introduced by the node operations. The "Best for natural scenes" and "Best for CG scenes" options are recommended choices; however, you can have complete control over the options by selecting "Advanced - User Set" from the menu. This is explained in detail in Filtering Transformations.
Check this box to add motion blur. You can expand the Motion Blur group to access parameters that control the phase and duration of the effect, as explained in Adding Motion Blur to Transformations.
Contents | Top of Page | Index
The Morph node is used to distort or warp an image, or to morph one image into another. It can be used to correct a mismatch in size and shape between two image elements, as when an actor's face is to be composited over the face of a stunt double, where the final effect should be invisible to the audience. It can also be used for flashy effects such as morphing an actor into a monster.
The Morph node is spline-based; that is, you draw splines in the Image Viewer to designate the image areas to be distorted. You can draw open-ended splines or closed shapes.
The Morph node accepts one or two inputs. The second input is used when morphing between two separate image sequences. The top input is for the source image and the bottom is for the target image, which means that the node will morph from the source image to the target input.
The output will be the same number of channels as the source input unless you elect to output a shape matte with an RGB source image, as explained in the Alpha menu description in Morph Parameters.
The basic steps to create a warp effect in an image are as follows:
When warping a single input, the source and target splines represent areas in the same image. When morphing between two image inputs, however, the source spline represents an area in the source image and the target spline, an area in the target image.
You can draw as many pairs of splines as necessary, as described in See Creating Splines below. For example, you might draw source shapes outlining the eyes and mouth of a head, and then draw exaggerated versions of them to use as the targets. Different distortion and dissolve values can be set for each connected pair.
You can also protect an area from being distorted, as described in Boundary Shapes: Preventing Pixels from Distorting.
Typically, you would start by drawing a spline around an image feature that you want to distort, animating the spline, if necessary, to follow the feature throughout the sequence. Then you would draw another spline that represents the distortion, also animating it if necessary. (See also Animating the Effect.)
You can create as many splines as you need, in any order, and any spline can become a source or target spline. It is the order in which two splines are connected that defines them as source and target: the source spline is selected first, as described in Making and Adjusting Connections.
Splines are drawn over the image, using the Morph node controls in the Image Viewer to select drawing, editing, and connection modes. The image to view while drawing a spline is selected in the Viewer's Source menu, as described in Selecting a View.
In general, you draw and edit a spline in the Morph node in the same way, using the same drawing tools, as in the Roto node. The difference is that the Morph node enables you to draw open-ended splines or closed shapes (in Roto you have to close a shape), and that additional tools for connecting splines are included in the Morph control strip. For more information about drawing and editing splines, see also Using the Roto Node in chapter 15. |
Fig. 17.5 Draw mode buttons in the node control strip are, from left to right, Freehand, Ellipse, and Rectangle.
Select a drawing mode from the node control strip. The Ellipse and Rectangle draw modes are used to draw a prescribed shape in one dragging motion. Freehand mode is used to draw an open spline or a closed shape of any configuration.
The node controls should be displayed in the Viewer; if not, right-hold anywhere in the image to access the Viewer Actions menu and select the Node Controls item.
Click in the image to create the starting point, move the cursor to a new location, and click again. A line will be drawn between the two points. You can continue to move and click, creating as many spline segments as you need:
Fig. 17.6 Examples of open and closed splines. An open spline has been drawn across the top of the mouth, and a pair of closed spline shapes have been drawn around the eyes.
You can create linear (straight) or curved spline segments. A curved segment is controlled by a point with handles you can use to adjust the slope and acceleration of the curve.
The click-and-move-and-click method creates linear segments; to create a curved segment as you draw, click and drag briefly before releasing the mouse button and moving to a new click-spot. (This process is more complicated to describe than to perform.) In addition, you can always change the state of any existing point after the spline is drawn: Ctrl-click a linear point to convert it to a curve and vice versa.
For each spline you draw, an entry is created in the Splines list in the Node Panel. You can use this entry to give the spline a distinctive name, which is especially helpful when working with many splines in a complex morph. See also Splines List.
To edit a spline, click an Edit or Transform mode button.
Fig. 17.7 The Edit and Transform mode buttons.
The Edit buttons are used to edit points in existing splines. In both editing modes, any spline point can be selected and manipulated. The choice of mode is only relevant when manipulating points with handles (points that control curved segments).
Selecting the Edit button on the left ensures that both ends of a point handle move when you drag one end. The other Edit mode enables you to adjust each end of a handle separately.
In Rotate or Scale mode, dragging selected points or shapes will rotate them or scale them, based on the mode selected.
Spline manipulation is covered in more detail in the Roto node description. Refer to the sections on Editing a Shape in chapter 15 and Transform Modes in chapter 15.
To duplicate a spline, copy and paste the corresponding entry in the Node Panel. See Copying, Pasting, and Deleting Layers in chapter 7 if you need instructions. |
To make and edit connections, press the appropriate Connect mode button in the Morph node controls in the Viewer.
Fig. 17.8 Connect Mode buttons in the node control strip: Make Connection mode (left) and Edit Connection mode (right).
To create a connection between two splines, press the Make Connection mode button and select the splines:
When two splines are connected, their overlays are color coded by the node: red represents the source and blue, the target. Several yellow connection lines representing correspondence points will link specific locations on the source spline to corresponding locations on the target.
Fig. 17.9 The example on the left shows two unconnected splines; the one on the right shows the same splines connected to each other. The inner spline (red) is the source and the outer spline (blue) is the target.
Fig. 17.10 In Edit Connection mode you can manipulate the connection lines, as illustrated here.
You can adjust the default connections made by the node if necessary. Press the Connect button on the right to enter Edit Connection mode and then drag the connection point at either end of a yellow line.
Say, for example, that you are morphing from an eye in one image to an eye in the other image. You might want to reposition the end-points of a connection line so that the spline point over the inner corner of the source eye is connected to the spline point over the inner corner of the target eye.
You can also delete a connection line by selecting one of its points and pressing the Delete key. Be careful not to select the connection line itself as this may select all connection lines. If you do delete all of them, you will disconnect the two splines altogether and the corresponding connection entry in the Node Panel will be deleted too. The Undo command is Ctrl-z.
A new entry will appear in the Node Panel Connections group to represent each connected pair of splines. The connection entry name automatically includes the names of both of the splines, to helps distinguish among multiple connections.
Fig. 17.11 The connection entry in the Morph Node Panel is where you access the Distortion and Dissolve parameters for the spline-pair.
It also includes the parameters used to control the distortion and dissolve levels, as described in Animating the Effect. When working with multiple pairs of splines, you may want to use the Dissolve parameters for each connected pair in conjunction with the Overall Dissolve parameter (located at the top of the Node Panel), as described in Morph Parameters.
You can delete a connection by deleting the entry. Click once on the entry label to select it and then right-hold on the entry and select Delete from the actions menu. This does not delete the shapes, but they are no longer defined as source or target until you reconnect them (to each other or to different shapes).
Fig. 17.12 The order in which two splines are connected affects the outcome, as these examples illustrate: The smaller shape has been designated as the source in the middle image, and as the target in the image on the right.
Typically you will be distorting a sequence rather than a single frame, and you can animate the splines as well as the distortion and dissolve levels. In fact, the distortion and dissolve levels are animated by default.
Always start by navigating to the first frame, or whichever frame the animation will start on, and turning on Autokey mode (press the Autokey button in the Viewer or the Node Panel). If you need more information, refer to Using Autokey Mode in chapter 7.
You animate a Morph spline exactly the way you animate a spline shape in the Roto node: in Autokey mode, draw the spline at the first frame and then modify its shape and position at key frames. The node will interpolate the in-between frames.
The distortion level for each connected pair of shapes is controlled by the Distortion parameter, which is located in the corresponding connection entry in the Node Panel (see Fig. ).
Distortion is animated by default, using linear interpolation from 0 (no effect) at the first frame to 1 (maximum distortion) at the last frame, in the global range defined for the project.
Fig. 17.13 First, middle, and last frames of a morph sequence from programmer to foo dog.
To use the same value for every frame, select "Delete All Keys" or "Change Interpolation > To Constant" from the parameter Animation menu. For general information about animating node parameters, refer to Animating Parameter Values in chapter 7.
The Dissolve parameter becomes active when morphing between two image inputs to control the level of dissolve from the source input to the target input.
Dissolve is animated by default in the same way as Distortion, using linear interpolation from 0 to 1, where a value of 0 returns only the source input and a value of 1, only the target input.
To use the target input only as a reference to draw the target spline, change the Dissolve interpolation to Constant (so that the value will not change across the frame range) and set the Dissolve value to 0.
Fig. 17.14 The target input was used as a reference to draw the target spline (middle), and the Dissolve value was set to 0 to warp the source image (left) to fit the target shape. The result is shown at right.
Depending on the number of inputs, there may be up to six different views available in the Image Viewer when displaying a Morph node. The available views are always listed in the Viewer's Source menu. You can cycle through all the available views by repeatedly pressing the Source menu hotkey (s) .
At minimum, you can choose between viewing the Source Image and the Output Image. When a target input is connected, you can also view the Target Image.
When morphing between two inputs you can also view the warped source or target image in isolation by selecting Source Warped or Target Warped. You can even view the dissolve matte used by the node to blend the warped source and target images by selecting Dissolve Image.
Fig. 17.15 Source menu views available when morphing between two inputs.
View the Source or Target Image when you want to draw splines that define features in one of these images.
Then switch to Output Image to see the image that will be output from the node at the current frame. Always double-check that the Source menu is set to Output Image before running a flipbook of the morphed sequence.
The Morph node controls in the Image Viewer include a group of View buttons used to control the display of spline overlays.
Fig. 17.16 View buttons in the node control strip.
Unlike the overlay display buttons associated with each spline entry in the Node Panel, which affect only one spline, each View button toggles the display of all overlays of a specific type on or off in the Image Viewer:
During the morph operation, when the pixels defined by the splines are warped, the surrounding pixels will also be distorted according to how they are "pushed and pulled" by the modification of the warped pixels.
Fig. 17.17 Boundary shape drawn to prevent pixels inside the boundary from being distorted by the node operation.
To protect an image area from change, draw a boundary around the area and then connect the shape to itself by clicking the same shape twice while in Make Connection mode.
Whenever you connect a shape to itself, it becomes a boundary shape, which is color-coded in green. A corresponding entry is created in the Connections list in the Node Panel for each boundary shape. When morphing between two images, a boundary shape protects the pixels it bounds in both the source and the target images.
Fig. 17.18 A pair of open splines are used to warp the mouth, with a boundary shape used to protect one eye from modification (left). The result (right) is a lopsided roar.
The Overall Dissolve parameter can be used as a master dissolve level control for all of the spline-pairs by referencing Overall Dissolve in the individual Dissolve parameters for each connection entry. Unless you specifically reference the Overall Dissolve parameter, however, it has no effect on the image.
To reference the Overall Dissolve value, use the Animation menu of the individual Dissolve parameters to change the interpolation type to Expression and then select Edit Expression from the same menu.
In the Expression Editor, enter the same expression in all of the Dissolve parameters: /morph1:dissolve (replacing "morph1" with the actual name of the Morph node). Then when you adjust the Overall Dissolve parameter, the individual dissolve parameter values are reset.
If you forget the syntax, just use the Expression Browser at the bottom of the editor panel to select the Morph node. All of its parameters, including the Overall Dissolve, will be listed in the pane on the right. Double-click on the Overall Dissolve entry and the correct expression will be entered in the field automatically. See also Appendix C: Using Expressions in RAYZ.
By default, the Morph node does not affect the input alpha channel, if any, as reflected in the default Alpha menu setting: No Changes.
However, if you select the other Alpha menu option, Closed Shape Matte, the node will generate an alpha channel for output with opacity values based on the closed spline shapes you have drawn and animated according to the distortion level settings.
An entry is created in the Splines list for each spline you draw in the image. The procedure for drawing splines was described above in Creating Splines.
You can give each spline a unique name; in fact, this is recommended when working with numerous splines to help identify them easily. You can disable a spline temporarily, turn off the display of its overlay, or lock it to keep from modifying it accidentally.
You can also duplicate a spline (by copying and pasting its entry in the Node Panel) or delete it altogether if you wish. All of these actions are described in the section on Dynamic Parameter Groups in chapter 7.
An entry is created in the Connections list for each connected pair of splines. The procedure for connecting two splines was described previously in Making and Adjusting Connections. The connection entry name automatically includes the names of both of the splines, to help distinguish among multiple connections when you have drawn many splines.
The connection entries have the same controls as the spline entries, which means that you can delete a connection. This does not delete the splines, but they are no longer defined as source or target until you reconnect them (to each other or to different splines).
Each connection entry can be expanded to access Distortion, Dissolve, and Samples parameters, which are specific to the spline-pair.
This parameter controls the amount and rate of distortion from the source spline to the target spline. By default the Distortion value is animated linearly from 0 (no distortion) to 1 (maximum distortion) using the global range specified in the Time Scooter when the connection was created. See also Animating Distortion Levels.
This parameter controls the amount and rate of the dissolve from the source image to the target image. By default the Dissolve value is animated linearly from 0 (all source image) to 1 (all target image) using the global range specified in the Time Scooter when the connection was created. See also Animating Dissolve Levels and Overall Dissolve.
This parameter specifies the number of point samples to use. If you think of a spline as a string of pearls, the Samples value represents how many pearls are in the string. In most cases the default value of 50 will be satisfactory, however, you may want to increase it for especially long spline segments if the distortion effect doesn't seem smooth enough in those areas.
Contents | Top of Page | Index
The Resize node changes the spatial resolution of an image by scaling it up or down to fit the dimensions you specify.
The Resize node accepts one or two inputs. The top input is the image to be resized, and the optional bottom input is used as a reference for the resizing operation.
Use the Size parameter to specify the size to which the input image should be scaled. You can enter specific pixel dimensions by typing a positive integer into each field, or you can use the Size menu to select a size from a list of common film and video resolutions.
If you would prefer to work in scale factors (fractional units) rather than pixels, check Float Display in the Animation menu, which is located on the right side of the Size parameter slider. Then, for example, to scale the image by half, you would enter 0.5 in each field.
No matter which display units you use, RAYZ actually stores the Size value as floating point data rather than specific pixel values to accommodate the use of proxies and clones. |
The Size parameter is deactivated when a reference input is used to resize the image.
Check the Fit box to preserve the aspect ratio of the input image when resizing.
Fig. 17.19 Example of how the Fit setting affects the output of the Resize node: when checked (at right), this parameter constrains the proportions of the output to match the aspect ratio of the input.
Use this menu to select the filtering option to use to reduce aliasing and other artifacts that may be introduced by scaling. The "Best for natural scenes" and "Best for CG scenes" options are recommended choices; however, you can have complete control over the options by selecting "Advanced - User Set" from the menu. This is explained in detail in Filtering Transformations.
Contents | Top of Page | Index
The Skew node slants the input image in the direction you specify. One edge is effectively translated relative to its parallel edge, with the intervening pixels on the axis lined up along the diagonal created by the skew.
Use the Direction menu to select the orientation of the slant:
Use this parameter to specify how much to skew in the selected direction. The range is -1 to 1, with the default value of 0 representing no change:
Fig. 17.20 Examples of Skew settings, clockwise from upper left: horizontal, -1; horizontal,1; vertical, -1; vertical,1.
Contents | Top of Page | Index
The Stabilize node is used eliminate the appearance of overall motion, as when the input sequence suffers from camera jitter.
Stabilize accepts one or two inputs, with the second optional input being used for a reference image that establishes the frame size of the output. This means that the reference image must be connected to Stabilize whenever it differs in size from the primary input image, because the track point values are scaled in relation to the output size.
Another reason to use a reference input is that the primary input can be viewed in a temporary composite over the reference image by selecting Temporary Pre-Comp from the Source menu. (In fact, Temporary Pre-Comp is selected by default when you connect a reference image.)
Stabilize uses tracking data to control the stabilization operations. The Stabilize node does not create tracking data. Refer to the description of the Track Node later in this chapter for instructions on generating track data. |
To stabilize imagery, the Track node that is accessed must contain a track point that was placed to follow a background element that is meant to remain stationary throughout the scene.
For image stabilization, follow these steps:
The Translation menu enables you to choose Stabilize (the default) or No Translation. (The No Translation option is provided for undoing scaling or rotation without translating.)
The Translate Point menu automatically lists all the track points in every existing Track node in the file.
Optionally, you can create an Offset for the position data by dragging the Offset overlay in the image viewer to the desired location, or by entering x,y coordinate values into the Offset parameter fields. The Offset overlay is illustrated in Fig. 17.4 of the Match Move node description.
You can also undo scaling and rotation, as explained below.
You can undo scaling and rotation in conjunction with the stabilization operation. Additionally, you can use the "No Translation" option to use tracking data to undo scaling and rotation alone.
Refer to the Rotation and Scale Parameters description for more detailed information about using these parameters.
The Translation menu can be used to change the default selection from Stabilize to "No Translation." This option should be used only if you are using the node strictly to undo rotation or scaling, without any other translation.
Expand the Translation parameter to access the Translate Point and Offset parameters:
This parameter enables you to specify which track point to reference for the Stabilize operation. The Translate Point menu will automatically list all track points in all existing Track nodes.
The Offset parameter enables you to offset the position data by typing specific x,y values into the fields. The Offset parameter is tied to the corresponding overlay in the Image Viewer, which can also be used to specify the Offset value by dragging the crosshairs device over the desired location in the image.
The Rotation and Scale parameters enable you to undo rotation and scaling. Unlike the Translation operation, the Scale and Rotation operations each require two sets of track data, as the changes in length or position of the vector between two track points are used to calculate the values.
The Rotation menu enables you to select No Rotation (the default) or Undo Rotation.
The associated Pivot and Reference menus become active whenever Undo Rotation is selected (expand the Rotation parameter to access). Use the menus to select the track point data to use for each parameter.
For the Pivot, use the track point that represents the pivot of the rotation.
For the Reference, use the point that represents the position of the moving end of the rotation vector.
The Scale menu enables you to select No Scale (the default), Undo Size Scale, or Undo Distance Scale:
The associated Reference parameters become active whenever an undo option is selected (expand the Scale parameter to access). Use the Reference A and Reference B menus to select the track point to use to represent each end of the vector defining the scale value.
Use this menu to select the filtering option to use to reduce aliasing and other artifacts that may be introduced by the node operations. The "Best for natural scenes" and "Best for CG scenes" options are recommended choices; however, you can have complete control over the options by selecting "Advanced - User Set" from the menu. This is explained in detail in Filtering Transformations.
Check this box to add motion blur. You can expand the Motion Blur group to access parameters that control the phase and duration of the effect, as explained in Adding Motion Blur to Transformations.
Contents | Top of Page | Index
The Track node enables you to identify one or more features in an image, which the Track node then follows throughout the sequence, creating
x,y
coordinate values representing its position at every frame. The position data created by the Track node can be accessed from other nodes to perform various operations.
There is almost no limit to what you can do with this tracking data. Two common applications are to stabilize an image and to match the motion of a foreground element to an object in the background plate (i.e., match move). See also the descriptions of the Match Move Node and the Stabilize Node. The Corner Pin Node can access tracking data to control the position of each corner, and complex animation effects can be created by using tracking data in conjunction with the Transform Node.
The Track node accepts one input. The image data output from the Track node is the same as the input, and it is not necessary to connect the output of Track to another node to use the tracking data generated by the node.
Any node parameter that can use expressions can reference tracking data, and some nodes that rely on tracking data (Match Move, for example) provide convenient menus for selecting which Track point values to use.
Start by connecting the image sequence to be tracked to the input of a Track node. Make sure that
You can track a sequence that contains gaps, however the Track node will stop processing when it reaches a non-existent frame.
If there are gaps in the sequence to be tracked, or you need to perform other re-sequencing tasks before tracking, you can insert a Sequence Node in chapter 21 between the input node and the Track node. You can use the Sequence node to close gaps, track on twos, and so forth. |
Follow steps A through D below for each image area you need to track. Then continue on to steps E and F. If applicable, see also Tracking Features That Leave Frame.
Fig. 17.21 Each time you press the Add Point button, a new track point is created.
A track point entry will be created in the Points list of the Node Panel, and a corresponding overlay for the track point will appear in the Image Viewer. By default, the track point is positioned in the center of the image.
In the Viewer, position the point over the image feature to be tracked by dragging the crosshairs in the center of the point overlay. The x,y values of the Position parameter in the Node Panel will update accordingly. (For detailed descriptions of the individual Viewer tools, refer to Track Tools in the Image Viewer).
The more detail present in the area you select, and the more distinct the differences in contrast or color, the better RAYZ will be able to track the feature.
The track point overlay includes boxes that define the image feature to be tracked (Feature Area) and the surrounding area to search (Search Area):
Fig. 17.22 Track Point: Drag crosshairs (red) in center of point to reposition it; drag Feature Area box (green) to resize it; drag Search Area box (blue) to resize it.
The search area must be large enough to cover the distance that the tracked feature will travel from one frame to the next. The larger the search area, on the other hand, the longer the track will take to process.
Review subsequent frames to evaluate the extent of movement from frame to frame and set the Search area to accommodate it. |
Each track point entry in the Node Panel provides numerous parameters for adjusting how RAYZ performs the tracking function. In most cases you can use the default settings, adjusting them only if you encounter a problem with the initial track. (For detailed descriptions of the individual Node Panel parameters, refer to Track Parameters.)
By default, RAYZ will track every frame in the sequence (assuming you start tracking on the first frame). Press the Fit button in the Image Viewer's Flipbook controls to set the range to match the sequence. To track a subset of the total range, use the Range fields in the Image Viewer's Flipbook controls to specify the range of frames to track.
You can change the default settings of the parameters in the first track point you create and then copy and paste that point to create other track points with the same settings. (See Copying, Pasting, and Deleting Layers in chapter 7 if you need more information.) |
Actuate the track function by clicking the "play" button in the Tracking Controls in the Image Viewer. The Track buttons enable you to track forward or backward. To stop tracking, press the Stop button. For more information, see Track Tools in the Image Viewer.
When the node has finished tracking, you can review the track path in the Image Viewer and make any necessary adjustments. Use the Flipbook controls to play the tracked sequence and watch the track point overlays change position from frame to frame.
Track points can be repositioned manually at any frame, and you can re-track if necessary. The tracker will use the keyframes you set to guide it when tracking if User Keyframed is selected in the Prediction menu (as it is by default).
You may want to change the default settings in the Node Panel for the Method, Channel, or Prediction parameters. The descriptions in the Track Parameters section explain which settings are best for track features that change shape significantly, move smoothly or jerkily, and so on.
Any track point can be disabled or locked before re-tracking, so that other points can be re-tracked without affecting accurate track data. See also Locked Point Overlays.
In some cases no single feature can be tracked for the entire length of the sequence. If so, you can track a feature until it moves out of frame (or cannot be distinguished for some other reason) and switch the focus of the track point to a different object, using an offset value to compensate for the change. That way you can still generate a single set of track data for the entire sequence.
The Image Viewer for the Track node provides a tool strip, along with an overlay for each track point in the image. (The Node Controls item must be checked in the Viewer Actions menu to use these Track node tools.)
Fig. 17.23 When displaying a Track node image, the Image Viewer provides tracking controls and overlays.
Each time you create a new point (using the Points button in the Track Node Panel), a corresponding overlay is added to the Image Viewer. The overlay shows the current settings for the track point parameters that control the size and position of the feature area and the search area.
You can manipulate the overlays directly in the Viewer or use the corresponding parameters for the point in the Node Panel:
You can also create offsets using the track point overlays:
Once a feature has been tracked, the overlay can also display the tracking path for the point and the location of the point at each frame.
Whenever you reposition a track point manually, the point indicator in the center of the overlay changes to a larger dot at that frame.
This indicates that the point is a reference point at that frame, which is relevant whenever "User Reference Points" is selected in the Reference menu of the point entry in the Node Panel (this option is selected by default). The description of the Reference menu explains the significance of reference points.
To change a reference point to a "regular" point, Ctrl-click on the point marker in the center of the point overlay. Ctrl-clicking a regular point, on the other hand, turns it into a reference point.
Fig. 17.24 The overlay for a locked point is drawn in the Image Viewer using a dotted lines.
You can lock any point using the Lock button (padlock icon) in the track point entry in the Node Panel. While a point is locked, it cannot be modified, which means that you won't accidentally drag an accurately tracked point out of position in the Viewer.
When you Ctrl-drag a point by its Feature box to create an offset (or change the default value in the Offset parameter for the point), a dotted indicator line is drawn from the original position to the offset position.
The tracking controls in the Viewer tool strip include a group of buttons that control the display of individual elements in the track point overlays.
Fig. 17.25 Overlay Display Toggles: These buttons control the display of individual components of the track point overlays.
Display of the Feature boundary box, the Search Area boundary box, the Track Path, and the Frame Markers can be turned on and off individually. The same is true for display of the track point Name and the Position data for the current frame.
The tool strip also provides the tracking controls, which are used to start and stop the RAYZ tracking function.
Fig. 17.26 Tracking Controls in Play Forward Mode.
You can track forward or backward from the current frame to the end (or to the start, if tracking backward), or you can track one frame forward or back at a time. Press the Stop button (red) to stop tracking.
RAYZ will track forward from the current frame to the last frame specified in the Flipbook Range fields. When tracking backward, RAYZ tracks from the current frame back to the first frame specified in the Flipbook Range fields.
If most of the frames in a sequence tracked well, but you need to re-track a subset of frames, use the Range fields in the Flipbook to specify the new frame range to track.
To avoid re-tracking points that do not need revision--especially if you have tweaked any of the frame positions by hand--lock those points before re-tracking other points. |
The Track Node Panel generates a new track point entry each time you click the Add Point button.
Fig. 17.27 Track point entries in the Points list of the Node Panel.
Each track point entry can be temporarily disabled or permanently deleted. You can rename and lock a track point and control whether the overlay for a track point is displayed in the Image Viewer, as illustrated below in Fig. 17.28.
Fig. 17.28 Top-level track point entry controls. (The dark shading of the entry label indicates that it is selected.)
The Method menu is used to select the tracking method RAYZ will use: Correlation or Centroid. The default method, Correlation, is appropriate for most situations. It examines the difference between two frames to find the best correlation with the feature being tracked.
The Centroid method, on the other hand, is useful for tracking a simple shape on a plain, contrasting background such as a track ball that was placed on a bluescreen backing for the express purpose of tracking it in post-production.
The Method parameter can be expanded to access additional controls for tracking.
Fig. 17.29 Expand the Method group to access parameters that modify the selected tracking method.
The Reference menu tells the tracker where (from which frame) to get the track feature to use as the reference when searching other frames for a match. The best choice depends on how much the feature being tracked changes across the frame range.
The default selection, User Reference Points , searches each frame for a match with the track area in the previous reference frame. (User reference points are created at any frame in which you manually adjust the track point position. For more information about how to designate a reference point, or remove this designation, see Reference Points.) This works well if the feature being tracked doesn't change shape significantly over time, just its location in the frame.
If the feature being tracked is rotating or zooming, or otherwise changing size and shape, however, Previous Frame is a better option. Instead of searching each frame for a match with a reference frame, Previous Frame searches each frame for a match with the previous frame. Although this makes it easier to track an object that changes shape, it may also introduce a little drift.
The other Reference menu options, Match Above/Below Threshold , can be a good compromise between User Reference Points and Previous Frame. Threshold matching uses the user reference frame as the reference, until it reaches a frame for which the error value goes above or below a specified amount, or threshold. Then the previous frame is used as the new reference frame until the error value again exceeds the threshold, and so on.
The Threshold parameter becomes relevant when a Match Threshold option is selected from the Reference menu. The tracker automatically calculates the amount of error in the correlation between the track feature in the reference frame and the current frame being tracked, and the Threshold parameter specifies a threshold level for this error value. The default Threshold level is 0.1, in a range of 0-1.
The Precision menu is used to specify the level of precision RAYZ should use to calculate the correlation during tracking, expressed in terms of subpixel accuracy, from 1 pixel (the lowest level of precision) to 1/64 pixel (the highest).
Higher precision levels track more accurately, and lower levels track more quickly. The default Precision level, 1/8 pixel, is a good compromise.
The Channel menu is used to specify which channel of the input image should be used in the track operation. The default is Luminance, however you can select any image channel that will provide the most detail and contrast in the image feature you are tracking:
The Prediction menu specifies the method the tracker should use to search each frame; that is, where in the frame it should start looking. The best method to use depends on the type of motion in the sequence.
For naturally moving objects in a filmed scene, Velocity or Acceleration are probably the best options. For jerky motion, such as that caused by camera shake or certain kinds of computer animation, Last Position or User Keyframed should work better.
The default prediction method, User Keyframed , means that the tracker will start looking in a frame at the interpolated position of the point, based on any existing keyframes you have set (by positioning a point manually). If no user keyframes are detected, the tracker uses the Last Position method. The Last Position method means that the tracker will start looking at the track position of the previous frame.
Velocity prediction uses the speed at which the point was moving in the previous frame to extrapolate its position in the current frame and start searching there. Acceleration uses both the velocity and the acceleration rate to predict where the point should be in the current frame.
This menu is used to specify the color of the track point (and track path, once the point has been tracked) that is displayed in the Image Viewer. This enables you to specify different colors for different track points if necessary to help distinguish them from one another, or simply to pick a color that shows up better against the image being tracked.
The Position parameter specifies the x,y coordinate location of the track point at each frame. This data is generated automatically when the point is tracked, however, you can also type values into the fields. (RAYZ will update the position of the track point overlay in the Image Viewer accordingly.)
The Offset parameter enables you to specify an offset to the Position parameter values by typing x,y coordinates into the fields.
You can also create an offset in the Image Viewer by Ctrl-dragging a point by the Feature box (the green box in the point overlay), and the Offset parameter values will change accordingly.
The Error parameter value displays the correlation error of the point at the current frame. It indicates the extent to which the pixel area determined in the Size parameter correlates with the pixel area in the previous frame. The greater the error value, the less accurate the match.
The Size parameter specifies the size of the track area, in pixels. The Size rectangle (the middle rectangle of the track point) should fit as closely as possible the feature to be tracked. The default size is 16 x 16 pixels.
This parameter enables you to offset the position of the search area, as defined in the Search Size parameter.
The Search Size parameter specifies the size of the surrounding area to search, in pixels. The search size is represented by the outermost rectangle of the track point. The default size is 48 x 48 pixels. The search area needs to be large enough to get a good correlation from frame to frame; however, the larger the search area the longer the track will take to process.
Contents | Top of Page | Index
The Transform node enables you to rotate, translate, or scale an image within the frame area. You can use Transform to animate the motion of one image relative to another or to simulate camera moves such as pans or zooms or complex shots that integrate pans, zooms, translations, and rotations.
The Transform node accepts one or two inputs: the foreground image and an optional reference image input.
The reference image establishes the frame size of the output image and acts as a visual reference for the transform operation when Temp Pre-Comp view is selected from the Source menu. This view shows the primary input in a temporary composite over the reference input.
Fig. 17.30 Temp Pre-Comp is selected by default in the Image Viewer's Source menu when an image is connected to the reference input of the Transform node.
Use the Source menu to view the output image or the temporary pre-comp (or use the Source menu hotkey, which is S, to cycle through all available views).
It is important to note that Transform is different from other nodes that offer interactive overlays in the Image Viewer. In other nodes, the overlay in the Image Viewer and the corresponding parameters in the Node Panel are completely interdependent, in that any change in one is reflected exactly in the other.
In Transform, however, the overlay behavior is optimized for performing transforms interactively, where each change updates the image in order, while the Node Panel parameters are optimized for complex animations of the rotation and scale parameters over time.
For example, the Pivot parameter in the Transform Node Panel applies to both Scaling and Rotation. This enables the pivot value to use track point data and rotate and scale around the same position, producing the desired result in almost all cases.
When manipulating the pivot interactively in the overlay, however, this would often result in unexpected behavior--the entire image would move when the scale was recalculated to account for the pivot value change. RAYZ prevents this by actually offsetting the current translation value (this is evident in the Translate parameter in the Node Panel), with the result that the image doesn't "jump" in the Viewer.
The bottom line is this: RAYZ assumes that you don't want the pivot value to control the scale operation when using the interactive tools and it manipulates the actual Node Panel parameters accordingly to produce the equivalent result. And if, on the other hand, you use the Transform node to animate a complex acrobatic maneuver using tracking data or expressions, it will be much easier to use the Node Panel parameters to do so.
When the Transform node is displayed in a Viewer, a transform tool appears as an overlay on the image. You can use the mouse to manipulate the transform overlay in the image.
Fig. 17.31 Transform Overlay: an interactive overlay in the Image Viewer that is manipulated by dragging.
To translate the image, drag the center of the transform tool to a new position.
Drag inward to scale down; outward to scale up. To scale the image
To rotate the image, drag the circle in the transform tool clockwise or counterclockwise. The rotation circle will animate to show you the degree of rotation.
Fig. 17.32 Ctrl-drag circle to move pivot point.
By default, the pivot point for the rotation is in the center of the image. To change the pivot, hold down the Control key and drag the rotation circle to a new position. The "x" in the center of the rotation circle marks the new pivot point.
The numerical parameters in the Transform Node Panel are Rotate, Scale, Translate, and Pivot.
Fig. 17.33 Transform parameters in the Node Panel.
The Rotate parameter value is expressed in degrees and the others are expressed, by default, in pixel units.
If you prefer, you can change the display units for a parameter from pixels to fractional units by checking the Float Display item in the Parameter menu (located at the right end of the parameter). For example, you might prefer to use pixel values for the Translate parameter to move the image 10 pixels horizontally, and float display for the Scale parameter to scale the image down to 80 percent (0.8) of full size.
However the parameter values are displayed, RAYZ always stores them at floating point precision to accommodate the use of proxies and clones.
This menu enables you to specify the order in which the transformation operations will be computed. The default order--scale first, then rotate, then translate--is likely to be the best choice in the majority of cases, where the pivot point will be at the center of the image being transformed.
For transformations where the pivot will be located at a corner (such as a swinging arm motion), try using the "Translate, Rotate, Scale" order. |
The Rotate parameter enables you to rotate the image by specifying a value which is expressed in degrees, with the default value of 0 representing no rotation. A positive value rotates the image in a counterclockwise direction; a negative value rotates the image in a clockwise direction. The rotation is centered around a pivot point that you specify by using the Pivot parameter.
The Rotate parameter range is unconstrained to accommodate animation of the rotation over time, as to create a spinning or spiraling effect. |
The Scale parameter enables you to scale the input image up or down by keying appropriate values into the Width and Height fields. By default these fields are set such that no change occurs to the input image.
The Width and Height values can be displayed as scale factors (using the Float Display option in the Animation menu) or as pixel values. Float display is the easiest way to scale proportionally, as you can enter the same value in both fields. For example, full size (no change to the input) is expressed by a float value of 1.0 in each field, so entering 0.5 in each field will result in an image that is half as high and half as wide as the input.
The Scale parameter also includes a Size menu, which you can use to select specific dimensions from a list of common film and video resolutions.
The Translate parameter is used to translate the image--to move it along the X and Y axes. By default the X and Y parameter values are set at 0, which represents no change to the input image.
A nonzero value in the first field shifts the image along the X axis (horizontally), and the second field shifts the image along the Y axis (vertically). Positive values shift the image to the right and upward; negative values shift the image to the left and downward. The values may be displayed in floating point (as a percentage of the total image width and height) or in pixels, and the parameter range is unconstrained.
For example (using float), values of 0.5 and 0 will shift the image to the right a distance equal to one-half the width of the image. To shift the image to the left by an equal amount, use values of -0.5 and 0.