On this page | |
Since | 20.0 |
Overview ¶
In USD, a value clip is a way of storing data sets in separate files.
-
This allows you to split large data across multiple files. For example, simulations or other animated data where the size of each time sample is so large that authoring all time samples to a single file is unwieldy (such as in terms of required network bandwidth).
-
Value clips are also useful in situations where you may have a library of animation clips which need to be run in a sequence or a loop. Often different primitives can share animation clips, but assemble the clips in different ways to create the appearance of variation.
-
Value clips allow flexibility in composing layer overrides. USD value resolution stipulates that the first (strongest) layer that contains any
timeSample
for an attribute is the source of alltimeSamples
for the attribute. This is often fine, but for huge numbers of timeSamples you may need more flexibility.
You should read the USD documentation for value clips to understand how they work and how you can use them:
Note
This node provides a way of authoring a value clip in USD either from existing files on disk, or from data generated in LOPs fed into this node’s second input.
This node should supercede most use cases for either the Value Clip LOP or the USD Stitch Clips ROP, each of which have significant limitations. The Value Clip LOP will not author manifest or topology files (so they must already exist or USD will have to regenerate them every time the stage is loaded). The USD Stitch Clips ROP requires writing USD files to disk, running the ROP as a second step, and then referencing in the output of the ROP. And unlike either of these methods, this LOP has the ability to strip non-animated data from the clip files before they get written to disk (leaving non-animated data only in the topology file). This can result in huge disk space savings.
Note
A sequence of '.bgeo' or similar non-native USD files can be loaded directly as value clips, however you must ensure that each geometry file generate its USD attribute data with the correct time sample. This can be achieved by writing the time value into the geometry file as a detail attribute created by the USD Configure SOP. Or, the time value can be specified by appending arguments to the geometry file path with the suffix '/tmp/file.$F4.bgeo.sc:SDF_FORMAT_ARGS:sampleframe=$F'.
Parameters ¶
Sampling Behavior
Cooking this node can generate many USD time samples, rather than just a single time sample at the current time. This can be equivalent to having a Cache LOP following this node, but it will evaluate much faster, and does not cache data from any other nodes. This allows animated data to be authored to USD without introducing a node time dependency which would then cause all following nodes to also be time dependent. This can vastly improve playback performance of some LOP Networks.
In all sampling modes, if a parameter on this node does not vary with time, and does not rely on other time sampled data from the stage, only a single default value will be generated in USD for the corresponding attribute. USD time samples are only generated for parameters that may vary over time.
Sample Current Frame
A single time sample will be generated for the current time.
Sample Frame Range If Input Is Not Time Dependent
If the input to this node is time dependent, this node behaves as if it is in Sample current frame
mode. Otherwise it behaves as if it is in Sample frame range
mode.
Sample Frame Range
The Start/End/Inc parameter is used to generate multiple times at which this node’s parameters are evaluated, and a USD time sample is created for each attribute at each one of these times.
Start/End/Inc
When the Sampling behavior is Sample frame range
, this parameter controls the number and spacing of base time samples to be generated by this node. The default values of this parameter are @fstart
, @fend
, and @finc
. These values correspond to the start, end, and step size of the global Houdini animation settings when interacting with Houdini. When using a ROP node to generate a range of frames, these values correspond to the start, end, and increment values specified on the ROP node being executed. This default ensures that a USD file written to disk will contain time samples for exactly the frame range requested by the ROP (regardless of the Houdini animation settings).
Subframe Sampling
For each primary sample generated by this node, these parameters can cause additional samples to be generated around that primary sample time. This is most often used to ensure that accurate data exists at exactly the camera shutter open and close times, as well as at the primary sample time.
Shutter
Controls the method used to specify the shutter open and close times relative to the primary sample times.
Specify Manually
The Shutter Open/Close parameter values provide exact offset values relative to the primary sample time.
Use Camera Prim
The Camera Prim parameter provides the scene graph path of a camera primitive from which the shutter open and close times are extracted to provide the offset values relative to the primary time sample.
Shutter Open/Close
When Shutter is set to Specify Manually, these two offset values are added to the primary sample time to indicate the shutter open and close times. The open time should be less than or equal to zero, and the close time should be greater than or equal to zero.
Camera Prim
When Shutter is set to Use Camera Prim, this is the scene graph path of a camera prim on the input node’s stage. The shutter open and close attribute values are read from this primitive.
Samples
The number of subframe samples to create for each primary sample. These samples are evenly distributed between the shutter open and close times. Note that such an even distribution may or may not create a sample at exactly the primary sample time.
Always Include Frame Sample
When turned on, forces a sample to be created at exactly the primary sample time. If the Samples value, together with the shutter open and close times, already place a sample at the primary sample time, turning on this option has no effect. Otherwise, this option causes an addition sample to be added. This means that the actual number of samples per primary sample may in fact be one more than the number specified in the Samples parameter.
Value Clip Description ¶
Primitive Path
The scene graph path of the prim on which to author the value clip metadata. If the specified primitive does not exist, the node will create it with no primitive type (the primitive type will come from the clip files).
Primitive Kind
If the prim at Primitive path didn’t already exist so this node has to create it, the node sets this as the new prim’s kind.
Parent Primitive Type
If any parents of the path in Primitive path do not exist, this node will automatically create them. In this case, it will create parent nodes of this type.
Get Geometry From Second Input
Enable this option to generate clip files from the LOP node attached to this node’s second input. The save path of the incoming stage will not be used to control where the clip files will be saved. The Save clip file path parameter controls this.
Turn off this option to load clip files from disk, in which case the connection to the second input is ignored.
Load Clip File Path
When Get geometry from second input is off, this parameter specifies the path to existing clip files on disk.
All Clip Files Have Matching Scene Graph Structure
Turn on this option if all clip files are known to have the same scene graph hierarchy, and the same set of time sampled attributes on those primitives. This allows the node to optimize the generation of the manifest and topology files by only looking at a single clip file instead of processing all of them.
To profit from the new option, a couple of settings are mandatory
-
Turn off Get Geometry From Second Input.
-
Turn on All Clip Files Have Matching Scene Graph Structure.
-
In case you have an USD ROP, set Valid Frame Range to Render Current Frame.
Track Primitive Existence to Set Visibility
LOP networks may generate vastly different scene graphs from one frame to the next. When making a value clip from these scene graphs over a frame range, the set of primitives must be fixed, because primitives not in the topology file will not appear when they show up in a clip file. Enable this option to cause this node to track a list of all primitives at each frame, and automatically author animated visibility attributes for any primitives that are added to or removed from the scene graph over time. This gives the appearance of primitives being added and removed over time. These visibility opinions are added to the toplogy layer.
Only subclasses of UsdGeomImageable
primitives will be tracked this way, since these are the only USD primitive types which respect the visibility attribute.
If All Clip Files Have Matching Scene Graph Structure
is enabled, we know that no animated visibility opinions are required to handle changes in the scene graph structure, so this parameter is disabled.
Flatten Clip Files
Whether the clip files are from disk or from this node’s second input, it can be useful to flatten the layers of the incoming clip file. This is because clip files read in by a Value Clip in USD are not composed. Reference, sublayer, and payload arcs are not followed. Only the data stored directly in the clip file is read in by the value clip. If this option is enabled, whether the input is from the second input or files on disk, the flattened USD file will be written to disk using the path set in the Save clip file path parameter.
Remove Unused Data From Flattened Clip Files
If the clip files are being flattened by this node, turning on this option causes all non-animated data (which will be stored in the topology file) to be stripped out of the clip file before it is saved to disk. This is an automated process which can save considerable disk space.
Save Clip File Path
If the clip files are being written to disk by this LOP (either because the clip data is coming from the second input, or because the option to flatten the clip files is turned on), this parameter controls the path on disk where the clip files will be written. As with all USD data authored by LOPs, these cilp files will only be written to disk when the whole scene is saved out with a USD ROP or USD Render ROP.
This parameter can be time varying, in which case a separate clip file will be written for each frame, or it can be constant, in which case the data from all frames will be written to a single clip file. Either approach is valid depending on the size of your clip data.
Manifest File Save Path
The file path where the automatically generated manifest file will be saved. This file specifies exactly which primitives and values should be brought in from the value clip files. The contents of this file are generated automatically from the set of time sampled attributes ni the clip files.
Topology File Save Path
The file path where the automatically generated toplogy file will be saved. This file contains all the data from the clip files that is not animated. This topology file is referenced onto the primitive holding the clip metadata.
Clip Set
The name of the clip set the value clip belongs to. Multiple clip sets can exist on a single prim.
Clip Primitive Path
The path of a prim within the value clip file that should be mapped onto Primitive path when accessing values.
Start Frame
The first frame at which the value clip resolution should start. Prior to this frame no clip metadata is provided, which will cause USD to hold the values stored in the first clip file until the start frame is reached.
End Frame
The last frame at which the value resolution will occur. This parameter has no effect if it is not enabled, in which case clip metadata is generated for every frame for which this node is cooked. Otherwise the clip metadata will simply stop at the specified frame (and the values from the last clip file will hold forever), or the earlier clip files will be reused if Loop frames is enabled.
Loop Frames
To create a repeating loop of clips, set an End frame and enable this option. For frames after the end frame, the clip files will be reused to author the clip metadata, returning to the start frame each time the end frame is reached. Clip metadata will be authored at every frame on which this node is cooked.