On this page | |
Since | 18.0 |
Overview ¶
This node offsets and/or scales the timing of animation on certain instances. Since USD doesn’t allow destructive editing, it does this by creating new retimed references of the instances' prototypes, and overriding the instances to refer to the new prototypes.
This node allows you to specify per-instance time offsets and scales in a number of ways:
-
You can get per-instance offsets and/or scales from float/int primvars. Optionally you can specify an explicit frame the instance should be referring to.
-
You can set a fixed number of random time offsets and/or scales constrained within a specified min and max time offset and/or scale.
-
You can create a SOP network inside this node (or elsewhere in the Houdini node hierarchy) that generates a point cloud where each point corresponds to an instance and float SOP attributes on the points specify time offsets and scales. Optionally you can specify an explicit frame the instances should be referring to. See point cloud editing below.
Tip
You can offset/scale the animation on regular prims with the Time Shift LOP. If you use Time Shift on an instancer, it will affect all instances equally, whereas this node lets you retime instances individually.
Point cloud editing ¶
This node lets you build a SOP network to specify offsets and scales by processing points geometry that represents the instances.
-
If you choose “Internal SOP”, the node uses the nodes you build in the SOP subnet inside this node.
-
In this mode, the points are created for you and fed through the network (connect the output of
Sub-Network Input #1
to the first node in your processing network).
-
-
If you choose “External SOP”, you can specify a SOP network anywhere in the Houdini node hierarchy. However, the network must generate the points with the proper attributes somehow.
-
The points must have a
path
SOP attribute set to the scene graph path of the instancer. -
By default, the node will try to match points up with instances by matching point numbers to instance indices. This will probably only work if you are processing every instance in a single instancer. Otherwise, you should turn on Match by ID and set the
id
SOP attribute on each point to the index of the corresponding instance.
-
-
The points should have
frameoffset
and/ortimescale
float SOP attributes on the points to specify the offset and scale to apply to the corresponding instance, or aframe
float SOP attribute when using theExplicit Frame
option.
Tips and notes ¶
-
This node works best for offsetting/scaling the animation on large groups of instances, or all instances that share a certain prototype. Since each separate timing requires a separate prototype, if you try to give each instance a different offset/scale, you will essentially “de-instance” the point instances (by having the same number of instances and prototypes).
-
If you are retiming prototypes created dynamically on an in-memory layer, you need to have a Cache LOP upstream from this node, so all frames are cooked and available.
If the instances come from an external USD file, you don’t need a Cache, since the file should contain all the needed time samples.
-
By default, retiming prototypes will not affect the instance transforms or primvars (unless they are defined on the prototype prims themselves).
You can choose to retime transforms and primvars defined at the instance level with the Retime transforms and Retime primvars parameters.
-
This node is optimized to only create new retimed prototypes for each unique combination of frame offset and time scale. Frame offsets equal to zero with a time scale of 1 can be ignored. However, this node still usually has to do a lot of work, and can be slow.
Parameters ¶
Type
Whether you want to retime point instances, or instanceable primitives.
Instances
A space-separated list of instances, using /‹path›[‹instance_index›]
syntax (for example, /geometry/instancer[0] /geometry/instancer[1]
). To select all instances in an instancer, use /‹path›[*]
. To select a range, use /geometry/instancer[4-7]
(the range is inclusive). To select instances inside nested instancers, use multiple indexes, for example /geometry/instancer[2][7]
. VEXpressions can be used to specify instances, for example, /geometry/instancer[{@weights>0.5}]
.
Instances
When Type is “Native Instances”, a list of paths to instanceable prims.
Retime Using
How to compute the transform for each selected instance.
Internal SOP
Uses the SOP subnet inside this node to process points representing the instances.
External SOP
Uses an external SOP network that must generate points representing the instances from scratch. (See point cloud editing above.)
Primitive Properties
Gets the offset/scale primvars on the instancer/instance primitives themselves.
Random Values
Creates a set number of random offsets and scales distributed across instances.
Retime Method
When Retime Using is set to Internal SOP
, External SOP
or Primitive Properties
, you can specify the retiming method.
Frame Offset and Time Scale
Retime using a frame offset and a time scale. The referenced prototype/primvar/transform will be looked up using
($F + frame offset) / time scale
.
This is the preferred method as it can be expressed as a constant, non time-dependent, value which can improve performance when retiming prototypes.
Explicit Frame
Set the time offset by specifying the frame at which the retimed prototype/primvar/transform should be referenced.
Note
Since this will be a time dependent attribute or primvar in most cases, it will force the retimed prototype creation to be time dependent which will impact performance.
When retiming prototypes by a fixed frame offset, it is generally recommended to use the Frame Offset and Time Scale
retime method.
Match By ID
When Modify Using is “External SOP” and this is on, the node looks for id
SOP attributes on the generated points. The id
should be the index of the corresponding instance. (When this is off, the node matches point numbers to instance indices, which only works if you process every instance in a single instancer.)
SOP Path
When Modify Using is “External SOP”, the node path to the geometry node to cook to get the generated points. Each point in the output should correspond to one of the selected instances.
Group
When Modify Using is “External SOP”, if this is not blank, only consider points in this point group.
Retime Prototypes
Create retimed prototypes for the specified instances. When instance animation is driven by instance-level transforms, turning this off will greatly improve performance.
Retime Transforms
Even if instance transforms are animated, by default this node does not affect them. Turn this on to re-time transform animation as well.
Retime Primvars
Even if instance-level primvars are animated, by default this node does not affect them. Turn this on to re-time primvar animation as well.
Evaluation Frame
In order to improve performance and to guarantee a fixed number of retimed prototypes, select a frame where the instances are retimed by a unique amount. Creating the retimed prototypes is split into its own non time-dependent process where possible which can have a significant impact on playback performance.
Only Affect Retimed
When this options is enabled, retimed prototypes with frame offsets equal to zero and time scales equal to 1, or explicit frames equal to the current frame, will be ignored.
Use Frame Offset
Enable frame offsets to drive the instance retiming. This timeshifts the instance animation.
Use Time Scale
Enable time scales to drive the instance retiming. This slows down or speeds up the instance animation.
Attribute
When Retime Using is “Internal SOP” or “External SOP”, the name of the SOP point attribute that should specify the frame offset or time scale for each instance. When Use Explicit Frame is enabled, the name of the SOP point attribute that should specify the frame the retimed prototype should be using.
Primvar
When Retime Using is “Primitive properties”, the name of a primvar on the instancer that should specify the frame offset or time scale for each instance. When Use Explicit Frame is enabled, the name of the SOP point attribute that should specify the frame the retimed prototype should be using.
Variations
When Retime Using is “Random Values”, specify the total number of unique frame offset or time scale values.
Min/Max
When Retime Using is “Random Values”, specify the minimum and maximum values for the frame offset or time scales.
Seed
When Retime Using is “Random Values”, specify the seed to use when generating a random number for each instance.
Distribution
When Retime Using is “Random Values”, allows the user to control the distribution of the random values between the specified Min/Max.
Global Frame Offset
Apply this offset to all instances equally, in addition to any per-instance offsets.
Global Time Scale
Apply this time scaling factor to all instances equally, on top of any per-instance scales.
See also |