USD-encoded MaterialX ? (updated for UE5.6)

UPDATE: MaterialX embedded into USD should work in UE5.6, but I am not able to get it working. See post below for details.

USD and MaterialX currently work in unreal with a .mtlx file referenced into a USD stage. For many other DCCs like Houdini and Maya it is preferable instead have USD-encoded MaterialX files (.usd rather than .usd + .mtlx).

To my knowledge that is not possible to read into Unreal currently. Please correct me if that is incorrect.

I’m also curious if there are development plans from Epic to support USD-encoded MaterialX in the future?

2 Likes

Hello @derekflood, this support should come with UE 5.6.

1 Like

I wanted to follow up with this now that UE5.6 is out. I have a USD stage loaded with USD-encoded MaterialX materials. This same USD file opens correctly in both Maya and Houdini, but not in Unreal. That is, it opens with all grey materials in UE.

I have the options purpose=render, and render context=mtlx. However, it looks like it is applying a USDPreviewSurfaceTwoSided. I have the plugins InterchangeOpenUSD, USDImporter, and USDcore loaded.

Any help in getting this to work would be greatly appreciated!

I get the same issue with Latest Unreal 5.6. It only works if Material is exported as an mtlx file and referenced in the USD stage.

2 Likes

I have the same issu usd encoded mtlx not working with ue 5.6

Apologies, USD newbie so not 100% sure this is correct location but my issue seems similar. A client has recently adopted Nvidia Omniverse and I’m now evaluating interoperability with Unreal. I have USDs on disk that I can open with Omniverse Kit (no access to Nexus servers yet, although I don’t think that’s required) and displays / renders correctly. In Unreal I’ve tried render context mdlx, universal and Unreal and none of these work, in the sense that the results are the same - a black product with no textures and I think incorrect materials. Looking at the stage, it appears as though everything is correct in terms of looks etc, although as I say I’m new to the format and may well be missing something (presumably I am!). The only errors I see appear to be for an externally referenced camera, which I don’t think is important. Any suggestions very much appreciated.

Hello all,
so importing USD with materialX embedded materials will work with USD interchange and not USD legacy nor loading in a USD stage actor.

  1. Make sure the plugin Interchange OpenUSD is activated. When importing the USD you can check it is interchange if you get the interchange dialog window (cf. 2.)
  2. Make sure the render context is “mtlx” in the Translator settings

If some of you still have issues, I might ask some sample to try to reproduce.

Thanks @UE_FlavienP, I’m still not seeing textures importing. I’ve tried this and a few variations now (universal etc). I have a stage file then folders containing subUSDs and within those texture folders, but whatever combination I try the textures will not load. This certainly could be user error though :frowning:

If you can share a model with us, do you mind contact me in direct message so we can look more details into it?

@UE_FlavienP I’m still not getting textures either. I am getting a materialX shader now, after going to the translator settings, but it is for Substrate. Does this only work with Substrate materials?

Many thanks for your help, zip file on its way.

Thank you both, I am letting the dev have a look.

@derekflood, it is a case of not supporting yet that way of describing the Material. The NodeGraph definition needs to be supported. We created a ticket for that

@201010, your file is not using MaterialX but MDL render context.
That is not supported with Interchange. Also, I get error and failed import when trying to import with USD Legacy.
Could you export your USD using another render context than MDL?

TBH I’m not seeing how to do that with Omniverse Kit (I no longer have launcher and USD Composer), and the files were sent to me from a client - all of which is my problem, and I’ll keep looking into it. I guess the process would involve either flattening or changing the materials entirely.

However, in more general terms (and again I have to flag up USD newbie status) is it fair to say the main issue is with MDL shaders not being supported except via a connector, and those connectors now being deprecated?

One potential issue is that the MDL files referenced in your USD files are not next to your USDs files, actually they are not in the archive you sent with me at all.
Example: uniform asset info:mdl:sourceAsset = @OmniSurface/OmniSurfaceBlendBase.mdl@ and uniform asset info:mdl:sourceAsset = @nvidia/core_definitions.mdl@.

So either you are missing files, or they are in a path that USD in UE does not manage to resolve and thus UE fails to find the files.

Hi

So I’m encounering similar issues described above - I’m exporting a usd file from Solaris with a mtlx standardSurface shader - When importing into Unreal via the Interchange Framework I have the Render Context in the Translator settings iset to “mtlx” but I can not get any textures imported at all.

If I enable Solaris to “Auto-generate Preview Surfaces” and I set the Render Context to “unreal” then I do some get textures coming in, but only Base Color and Roughness. For some reason it skips other bindings such as Metallic.

Anything we might be missing? As far as I know we’re following all the steps suggested.

Happy to share work files if it helps.

Thanks
Michael

@LastNightDundee My understanding is that the UE Interchange does not currently support node groups, which is how Houdini/Solaris makes a USD file using the Component Builder. The devs are working on supporting this in the future.

Node groups are supported on referenced .mtlx file, just on in one encoded into USD.

Thanks @derekflood for the clarification. I notice @toto12345 mentioned in an earlier message that it requires a mltx file to be referenced - missed that.

So that all works now for single textures. But our next hurdle is UDIM support - there appears to be an issue with the translator not liking it. I found this thread that suggested it wasn’t supported as of last March

@UE_FlavienP - I don’t suppose you have any update on when it might be supported or existing workarounds?

Thanks!

I see in the ticketing system the UDIM support was added a couple of weeks ago.
It will be in 5.7 release but should already be in Main if you build from source code from github.

That’s useful; I received the files in exactly the way I sent them to you , so you’re right of course, no mdl included. The first thing I’d done however was load them into omniverse kit, where they do in fact render correctly. I just checked, o-kit comes with a core set of shaders as part of the installation, there is an mdl folder included. And now I see in \mdl\core\ there is a Ue4 directory. Not quite sure what to do with this, but it feels like a step forward!

Thanks @UE_FlavienP for that update

I don’t suppose support for node groups and the component builder workflow from Solaris might also be finished and rolled into main?

These are exciting changes btw, will be a bit of a game changer for us once it’s available.

Thanks!