Ornatrix to USD Format

 
 
 
Posted by:hitofffskiy
Data created:22 May

Hello!

I am currently trying to figure out the best way to integrate it into a strict USD pipeline:

 

1. If I use the standard USD export, the groom gets baked into static curves (which is expected, as standard USD doesn't know what an Ornatrix modifier is)

2. If I use the Save Groom button on the Ornatrix shelf, it perfectly saves the procedural stack, but outputs an .oxg.yaml file

Could you please help... Is there currently any way to save the editable Ornatrix procedural stack (Frizz, Clump, etc.) directly into a .usd file? 

* It is also possible to export animated hair into USD curves,

* What do you expect to do with an Ornatrix groom that is saved in a USD file? With which tool?

The point of saving the whole groom is to load it by Ornatrix on the various platforms where it runs. Other tools can't work with the groom, unless they decide to implement some kind of support for it. So far the only 3rd party tools that support Ornatrix hair are renderers, and these (usually) do not need the whole groom, they only need the final hair produced at the top of the stack, with its animation of course.

Ivan Kolev (Software Developer, EPHERE Inc.)

Discord: ikolev

Email: ivan.kolev at ephere com

Thanks for the detailed reply! I was initially looking for a way to keep everything inside a single USD container just for pipeline cleanliness... I used maya2024-2026, UE5 (with plugins Ornatrix)

Correct. As you noticed, USD doesn't know about Ornatrix and having the groom baked to plain curves is the only way to get it into your USD pipeline.
Ornatrix also supports alembic, but I believe USD will just see it as plain curves as well. 

Jeordanis Figuereo (Product Designer. EPHERE Inc.)


Thank you for this information. 

In houdini, it seems there is a way to keep the procedural groom inside the USD file... Mostly to be able to cache the groom guides and apply the animation on the full groom instead of caching the full groom sequence (too heavy).

It is not important to keep everything from the stack in Ornatrix, but if we can extract guide info + full groom assignment on which guide we could build a setup to add simulation on guide in the USD file and the full groom would deform accordingly (probably).

To build USD would need to extract:

-guides full (IDs) (+)

-groomfull (the same IDs, to match guides) (+)

-groom relation with guides (?)

-data density for viewport (?)

Do you think this could be done using Ornatrix?

Assuming that the Ornatrix groom gets somehow saved in the .usd file, what do you need to do with that file?

Render it?

Open it in another 3D app?

If it's about rendering, this can work only if a special plugin is developed for the renderer, that will recalculate the groom as part of the rendering process. We already do that for Arnold and V-Ray.

If it's about opening in another 3D app, it may be theoretically possible to achieve this by storing in the USD a reference to the .oxg.yaml groom file as an external asset. But that would require both the tool that exports the scene into USD and the tool that imports it from USD to know how to handle the groom.

Ivan Kolev (Software Developer, EPHERE Inc.)

Discord: ikolev

Email: ivan.kolev at ephere com

The main goal is to be able to package everything - the model geometry, lookdev, shading, and the groom - into a single assemblyMain USD asset file.

The idea is to load this master USD as a reference in the scene, and then simply attach cha_animation, simulation cache of the guides to it at the scene for the final render. (maya, vray, maybe EU5 too).  This would completely eliminate the massive file sizes and heavy disk read times associated with caching full groom caches.

Storing a reference to the oxg. yaml file inside the master USD (as you mentioned) sounds like a great way to handle the Ornatrix part of the asset. If the Ornatrix plugin in the target application (like UE5) could read that USD, fetch the . oxg. yaml parameters, and then deform/generate the full groom dynamically based on the external animated guides, it would be the perfect pipeline solution.

Is it currently possible to structure a master USD asset this way with Ornatrix, or would this require implementing new export/import features on your end?

Roman Adamanov

Grooming supervisor - AGORA.studio 

rAdamanov@agora.studio


Most likely this won't work out of the box, we'll have to implement new features.

We need a concrete small example, maybe a Maya scene with a basic furball, and detailed steps what is expected to happen with that scene - how should it be exported, what should the exported file(s) contain, and what tool should consume it, and how.


Here's an example how rendering Ornatrix with the Arnold procedural currently works, avoiding exporting the full animated hair curves to Arnold:

* In the HairShape attributes under Renderer Export / Arnold there is an option "Use Procedural". It must be enabled. Optionally a full path to the external .oxg.yaml file can be specified, otherwise a default file in TEMP is used

* Either render the scene with Arnold from within Maya, or export it to an .ASS file and render it with Arnold's command-line tool

Our procedural plugin gets loaded by Arnold and generates the hair from the groom file on the fly at each frame that is being rendered.


I suppose you need something similar, maybe for another renderer and another file format.

Actually, Arnold can also export the scene into .USD and render that, but we haven't tested if that will work with our procedural.


Ivan Kolev (Software Developer, EPHERE Inc.)

Discord: ikolev

Email: ivan.kolev at ephere com

Got it, I'll create a test scene and attach it to my next message. Thank you!

 Hello, the on-the-fly generation workflow you described for Arnold is exactly the core concept we are aiming for, but integrated within a USD asset structure. An important note about our pipeline: our primary render engine is V-Ray in Maya2024-2026

 I have prepared and attached a basic Maya test scene that replicates our standard studio groom setup.

Feature Coverage:

I have deliberately built this test scene to cover the maximum possible range of Ornatrix features to ensure the new workflow is robust. Inside the setup, I have used: A density map to control and mask hair growth in specific areas. Hair groom deformation driven by displacement map. The branchMode feature. A standard set of core modifiers (Frizz, Clump, Detail, Length, etc.)

Here is a detailed breakdown of our scene logic and how we envision the ideal workflow (the video is attached too)

1. We use the AdoptExternalGuides operator for connect simulation to the groomMain

The Outliner structure is as follows:

"groom_grp" - contains the full Ornatrix procedural groom, emitter_geo, AdoptExternalGuides sim setup, control curves

"geo_01_emitter" - the base geometry (scalp/body)

"geo_01_groom_driver_crv" - the driver curves used to guide the shape and dynamics/simulation of the groom

2. Our Current Publishing Pipeline:

Currently, this setup is published in our pipeline as a single master asset called "groomMain"

However, we separate the components so other departments can work with them in the modeling, shading, lookdev, lighting and animation stages:

The groomMain: we save/publish the entire "groom_grp" (with the full Ornatrix stack + emitter_geo + AdoptExternalGuides sim setup).

The Driver Curves (output_curves): Published separately so the CFX department can simulate/attach hair simulation caches to these specific curves directly in the render scene.

3. The Desired USD Workflow

We would love to translate this logic into a strict USD pipeline. Here is a step-by-step of how this should ideally work:

Step A: Export

We export the "groomMain" asset into a MasterCharacter USD file. Alongside it, the procedural groom stack is automatically saved as an external .oxg.yaml file.

Step B: Assembly (The Master USD) During the scene assembly stage (in Maya), we load this master USD. We then connect the character's body animation pointCache to geo_01_emitter and the CFX hair simulation cache to the geo_01_groom_driver_crv curves (via USD overrides/payloads).

Step C: On-the-fly Generation in V-Ray / Maya... This is where we need the new feature. When the assembled scene is opened/imported in Maya for the final render in V-Ray, the Ornatrix plugin should:

1 Read the metadata or a reference inside the USD pointing to the external .oxg.yaml file.

2 Reconstruct the procedural modifier stack.

3 Automatically pick up the incoming USD animation from the emitter (geo_01_emitter) and the simulation deformation from the curves (geo_01_groom_driver_crv), feeding this data into the AdoptExternalGuides node.

4 Dynamically generate the final, high-res animated hair on the fly during rendering with V-Ray.

Please let me know if this breakdown makes sense, or if I need to adjust the test scene in any way to make it easier for you to test.

Thank you again for your time and support!


Attached Files:

>groom_test.rar (27178438 bytes), >pipelineSetup_01.mp4 (29616064 bytes),

Thank you for the example scene.

We have a V-Ray plugin that evaluates .oxg files inside V-Ray but it expects a .vrscene exported from 3dsmax.
We will consider exporting to .vrscene and USD from Maya too.
I can't tell how long may that take though, maybe a couple of months.


Ivan Kolev (Software Developer, EPHERE Inc.)

Discord: ikolev

Email: ivan.kolev at ephere com

I just realized that you need more than just exporting to a VRay procedural, you need to save the scene into a USD file and load it back in Maya, preserving the hair stack. And in the video I see you're not using the built-in MayaUSD plugin but some other tool (probably called Agora).

We might be able to write an exporter plugin for MayaUSD that allows storing and restoring the hair stack in USD by referencing an external .oxg groom file, because MayaUSD supports exporter/importer plugins, though it won't be trivial. But we can't do it for all the USD tools out there.

Ivan Kolev (Software Developer, EPHERE Inc.)

Discord: ikolev

Email: ivan.kolev at ephere com

Hello, I think it should works on our side... Exporting our hair/groom result in a USD format that we can still drive with guides. (USD referencing to an external .oxg should be ok). I think we would be using native mayaUSD