-
Notifications
You must be signed in to change notification settings - Fork 93
/
destination_forwarding.usda
45 lines (36 loc) · 1.02 KB
/
destination_forwarding.usda
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#usda 1.0
(
"This example shows how to make a single relationship point to different targets after resolve-time, using VariantSets, without overriding its targets. The </Forwarder> is a class so that means it won't show up in regular traversals. But we can still change its variant sets programmatically (even if artists can't). To \"expose\" </Forwarder> to the user so they can change variants, just change `class` to `def`."
)
class "Forwarder" (
variants = {
string forwarding_variant_set = "selection_1"
}
prepend variantSets = "forwarding_variant_set"
)
{
variantSet "forwarding_variant_set" = {
"selection_1" {
rel something = </SomeLocation>
}
"selection_2" {
rel something = </AnotherLocation>
}
"selection_3" {
rel something = </ThirdLocation>
}
}
}
def Xform "SomePrim"
{
rel another = </Forwarder.something>
}
def Xform "SomeLocation"
{
}
def Xform "AnotherLocation"
{
}
def Xform "ThirdLocation"
{
}