Hi,
Problem:
I use Assign Material to do what it is supposed to do, but if graph is time dependent, it does it on every frame. I want to assign them just once, because it can take quite some time on large scene during exporting USD file.
Attempted solution:
1. Layout my graph so that my non time dependent operations are first. But that is very restrictive and not intuitive.
2. Move Assign Material directly after Import SOP, but at that point materials do not exist in graph, so I get error. Is it possible to assign it ahead of material creation? Kinda a promise of where mat will be once graph is evaluated for rendering?
Is there a better way to force one time evaluation?
Thanks!
Assign materials ahead of importing them to stage
2116 6 2- tas3d
- Member
- 120 posts
- Joined: Jan. 2012
- Offline
- mtucker
- Staff
- 4438 posts
- Joined: July 2005
- Offline
I'd try feeding the time-dependent data into a timeshift LOP with the "Frame" set to 1. This eliminates the time dependency. You probably also want to turn off the "Evaluate Attributes at Specified Tim" toggle because that will just do some processing on the data which you don't care about. Then into a layer break, so that upstream data is not going to get baked in with your material assignments. Then the material assignment. Then bring this branch's data back into the main chain with a sublayer like you've done above. Because of the layer break, only the material assignments will be brought in as a sublayer. But the Material Assignment LOP will have access to the full stage in order to make its assignments (avoiding the errors from your image).
I hope that makes sense?
I hope that makes sense?
- tas3d
- Member
- 120 posts
- Joined: Jan. 2012
- Offline
Thanks for reply and suggestions.
Would you mind explaining it on the provided example hip? You talk about USD concepts that I am not familiar with.
Would you mind explaining it on the provided example hip? You talk about USD concepts that I am not familiar with.
Michal Tas Maciejewski @ www.vfxtricks.com
- tas3d
- Member
- 120 posts
- Joined: Jan. 2012
- Offline
Actually I gave it another try and it does make sense. Still need to double check it in production.
Take a look at screen, is this what you were talking about?
Take a look at screen, is this what you were talking about?
Michal Tas Maciejewski @ www.vfxtricks.com
- mtucker
- Staff
- 4438 posts
- Joined: July 2005
- Offline
- Tim Crowson
- Member
- 240 posts
- Joined: Oct. 2014
- Offline
- tas3d
- Member
- 120 posts
- Joined: Jan. 2012
- Offline
Hi Tim,
Once I turn off Eval Attrib at Spec Time, I don't need to target any primitives.
ConfigureLayer LOP is just setting save path, so SubLayer doesnt complain about save location.
Once I turn off Eval Attrib at Spec Time, I don't need to target any primitives.
ConfigureLayer LOP is just setting save path, so SubLayer doesnt complain about save location.
Michal Tas Maciejewski @ www.vfxtricks.com
-
- Quick Links