USD Variants - Split variant per file or I'm not getting it?

   834   2   1
User Avatar
Member
9 posts
Joined: April 2025
Offline
Good day everybody

Working on HDA for usd output automatization using wrap around stock Component Builder node.

So I do get where when variants are present upstream, we get "variants" folder.
But could please someone explain, why all variants do get written in ONE single geo.usd file and not into a respective subGeo per variant file?
Variant folder basically gets 1kb files while all the bulk is contained in one single geo.
From my understanding, at a given momemnt I'm loading Var1 out of , say, 6 present in the usd, it would be ligher on resources to load only Var1 from a separate file then to parse the main one and extract the needed variant.

Maybe I'm doing it wrong but I tried 3 different setups and I get this same behaviour - One huge usd.
In this particular case, incoming geo weights 500mbm where every variant goes around 80-100mb
Wouldn,t it be more effecient to have them split into different files?

Can someone shed some light this concept?

Thank you very much
User Avatar
Member
354 posts
Joined: Nov. 2013
Offline
Reading data from binary layers (.usd, .usdc etc, not .usda) is very efficient (lazy) and only extracts what's needed to compose the stage. Since unused variants are never composed their presence in the file won't incur much (if any) penalty. In fact it's likely to be the opposite, whereby when switching to a different variant it would be slower if finding/opening a completely new layer was needed, compared to reading additional data from an already open layer.

In general it can useful to think of binary layers as streamable content, kind of like a movie file.
Edited by antc - May 31, 2025 10:48:30
User Avatar
Member
9 posts
Joined: April 2025
Offline
Thank you
Very insightful answer

That clears up the question for me

Greetings
  • Quick Links