STAGE: SOP Import

   3824   8   4
User Avatar
Member
51 posts
Joined: Oct. 2019
Offline
I'm having a bit of problems with Alembic and the path attribute. I have an alembic that I've exported out which has a complete hierarchy. But when I try and import it into LOPS to export out as USD I don't get the full hierarchy but a flat hierarchy (image below)


If I then convert the alembic via
usdcat teapot.usd --out teapot.usd

I get the correct hierarchy (image below)



I've also tested turning the Primitive Definition - Path Attributes on, and that didn't do anything.

Any takers?

best regards
stefan
Edited by StefanA - Dec. 17, 2019 10:00:36

Attachments:
flat.jpg (57.2 KB)
usdcat.jpg (55.3 KB)

CG Supervisor - Important Looking Pirates
http://www.ilpvfx.com/ [www.ilpvfx.com]
User Avatar
Staff
4435 posts
Joined: July 2005
Offline
This has come up before, and the short answer is: don't import Alembic into LOPs via SOPs.
Just load the Alembic directly into LOPs (with a Sublayer or Reference LOP).

By going through SOPs you are (as you've seen) throwing away a lot of information. You might be able to preserve more of the information by unpacking the alembic in SOPs, but why? Loading the Alembic directly into LOPs is always going to be the fastest and most accurate translation of Alembic to USD.
User Avatar
Member
8525 posts
Joined: July 2007
Online
it's great to know that Sublayer LOP supports .abc and that this is the preferred way of importing it

I think the source of confusion is partially due to lack of information about what filetypes Sublayer LOP supports
most of accessible doccummentation deals with .usd file types and in LOP help tutorials you import .obj files through SOPs even though Sublayer SOP supports .obj too

so maybe more training material dealing directly with Sublayer LOP for importing various filetypes would be helpful
or at least the File Browser in Sublayer and Reference LOPs can have supported file type filters instead of just * (even though not sure if this is possible to be dynamic based on which file format plugins are currently installed)
Edited by tamte - Dec. 17, 2019 12:15:50
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
51 posts
Joined: Oct. 2019
Offline
Thanks for the answer! To be honest, I never tried to import alembic directly into the reference node. I just assumed that I should do a SOP import

best regards
stefan
CG Supervisor - Important Looking Pirates
http://www.ilpvfx.com/ [www.ilpvfx.com]
User Avatar
Member
31 posts
Joined: Feb. 2014
Offline
On this topic, is there a good way to prefix the import path when loading an alembic directly with the Sublayer LOP?
Say I have a flat alembic with no hierarchy (just pieces of geometry in worldspace), I'd like to parent the imported prims under an assembly or group prim in order to organise the scene graph.
I'm able to achieve this end result with a graft node, but it feels like this is a bad idea. Houdini chugs a bit applying this operation and when I export the newly arranged scene to usd the geometry from the alembic is completely rewritten to large usd files rather than retaining the direct reference to the alembic file.

I've attached a demo scene that hopefully clarifies what we're looking to do.




cheers
Ben
Edited by ben toogood - Dec. 20, 2019 07:46:30

Attachments:
Annotation 2019-12-20 124148.png (382.1 KB)
abc_lops_prefix.zip (11.2 MB)

User Avatar
Member
7737 posts
Joined: Sept. 2011
Online
That's what the reference is for. If you graft a layer it has to be flattened.
User Avatar
Staff
4159 posts
Joined: Sept. 2007
Online
tamte
it's great to know that Sublayer LOP supports .abc and that this is the preferred way of importing it

I think the source of confusion is partially due to lack of information about what filetypes Sublayer LOP supports
most of accessible doccummentation deals with .usd file types and in LOP help tutorials you import .obj files through SOPs even though Sublayer SOP supports .obj too

so maybe more training material dealing directly with Sublayer LOP for importing various filetypes would be helpful
or at least the File Browser in Sublayer and Reference LOPs can have supported file type filters instead of just * (even though not sure if this is possible to be dynamic based on which file format plugins are currently installed)

WRT to Sublayer supporting a format, it actually supports any format USD is aware of. In Houdini any geometry format supported by Houdini can be referenced/sublayered into LOPs; SideFX has USD format plugins for all their geometry, which is super cool (you can sublayer an obj file directly, see screenshot), though you don't have a lot of control as most of these formats import into USD suboptimally (Alembic, and probably bgeos+packed prims, being an exception).

I try too look at this support as temporary convenience for converting data into USD for 2 big reasons:

  1. Only a USD library that has SideFX's plugins will be able to read those non-USD layers
  2. Even with a file format plugin, non-USD formats will not perform as well as USD

Alembic files are a bit of an exception to #1, since that plugin ships with USD and convert pretty well to USD. However, it still has the performance hit in #2. For more info, see https://graphics.pixar.com/usd/docs/Alembic-USD-Plugin.html#AlembicUSDPlugin-KnownLimitations [graphics.pixar.com]

Hope that helps!

Attachments:
screenshot-area-2019-12-20-095827.png (249.5 KB)

I'm o.d.d.
User Avatar
Member
31 posts
Joined: Feb. 2014
Offline
jsmack
That's what the reference is for. If you graft a layer it has to be flattened.

Thanks - I have looked at using the Reference LOP, but have only been able to import one prim at a time from within the alembic. Unless I'm missing something it looks like I would need a root prim in my alembic to specify for the reference. Is that right?



Any suggestions on how to get that to work?

cheers
Edited by ben toogood - Dec. 20, 2019 11:39:45

Attachments:
Annotation 2019-12-20 163604.png (259.1 KB)

User Avatar
Member
7737 posts
Joined: Sept. 2011
Online
Correct, the hierarchy needs to be rooted under one prim in the alembic to load an entire alembic with one reference. Or to put another way, a reference is needed for each root prim.
  • Quick Links