How can Omniverse USD Composer read custom attributes on a model?

I created a mask on my model in Houdini, and when I export it to Omniverse in USD format, the texture shows incorrectly. It turns out that my mask doesn’t work.


I used this mask to apply different textures, and when I check in Omniverse, I found that the mask was also exported to the USD file.
image
However, my material in Omniverse can’t read this mask, so the texture doesn’t change.

Can you help me solve this issue? Thank you very much. T.T

You exported this to usd using our USD Exporter or Houdini’s ? Which ever way around, try the other one to compare.

Thanks for your reply.
I tried both, and they had the same result.


When I checked this problem, I found something that might help. I used the [mtlxgeompropvalue] node to read ‘mask’, but it failed. However, when I removed this node and just used [mtlxmix] to control the two textures directly, it worked.
To make it easier to observe, I first created two shaders: one red and the other blue. I set the mix parameter to 0.5, and the model turned purple. When exported to Omniverse, the result was correct. You can even find and adjust the mix parameter in the material’s property panel.



However, when I returned to the file that uses the [mtlxgeompropvalue] node, I found that the mix parameter had disappeared.


What’s strange is that the mix node can be found in the material graph, but it doesn’t work.

Is it possible that Omniverse doesn’t support adjusting nodes like [mtlxgeompropvalue] or [mtlxgeomcolor] in Houdini yet?

Sure, that is very possible. Please do not assume that just because you have a material node in Houdini, it is automatically in Omniverse. But I am glad you have found a solution.

Actually, I still haven’t been able to solve this. I don’t know how to make my ‘mask’ work. @.@

Have you tried this? The “Blend” node? You can just add your base material, and then your mask

Hi @zuobbhaha
You did not specify in your original post what Kit and Graph Extension you’re using, but MaterialX authoring is not publicly supported yet in Omniverse. Is the graph that you show https://global.discourse-cdn.com/nvidia/original/4X/9/5/3/9532fdb42ad8734e4c4620e89c9f4aac5f9c36b5.jpeg, just what’s imported from Houdini? We have complete authoring available internally and it will be available to the public sometime early this year.

If you can, it would be helpful to attach a zip with your USD and any associated texture data for us to inspect what’s going on. However I can say we do support ND_geomprop_<*type> lookups. I’m not sure how ND_geomcolor_color3 works with your indexing without looking at your scene data.

@Richard3D MaterialX and MDL nodes are not compatible with each other. The new editor will isolate authoring and viewing so that graphs cannot be intermixed.

Regards
Frankie

Another thing the team pointed out is that the mtlmix node you have looks like it’s for mixing floats. Not surface shaders. There’s a different ND_mix_surfaceshader node for that.

Thank you for your reply.
I didn’t use any Kit. I’m just using USD Composer, and the Graph Extension I’m working with is the MDL Material Graph in Composer.
$HIP/tex/gun2/Metallic..png
$HIP/tex/gun2/Metallic..png
This graph displays the same nodes as those in Houdini’s Material Library.
$HIP/tex/gun2/Metallic..png
I’m uploading my USD and tex data here, I made them three bucause the size is over 100MB.
geo.zip (52.3 MB)
gun2.zip (74.8 MB)
rusted_gun.zip (37.2 MB)
In ‘just_mix’, I didn’t use geomvalue and the mix can be adjusted in property panel, however the other one can’t.
Thank you very much.

I think what we were asking it what version of USD Composer. Maybe you are using an old version. Are you using 2023.2.5 from the Launcher? If so that would be old. The new version is 106.5 from our GitHub Page. GitHub - NVIDIA-Omniverse/kit-app-template: Omniverse Kit App Template

Hello,

I created a quick demo file that shows the use of the geomprop node to look up a float value called “mask”
Im including the hip file the the usd file.

mtlx_mix_example.zip (99.8 KB)

Thank you very much. I’m using 2023.2.5 version of USD Composer.0.0

Thank you very much.
I will check on this shortly.

Right… so that is really old now. Please update.

  1. Download “git” from Git - Downloads
  2. Download "git Large File Storage from https://git-lfs.com/
  3. Start a windows command console by using running cmd from the Windows Start menu
  4. run cd\
  5. run git clone https://github.com/NVIDIA-Omniverse/kit-app-template.git
  6. run cd kit-app-template
  7. run repo template new
  8. run repo build
  9. run repo launch -d

I’m sorry when I run “cd kit-app-template” it says the system can’t find specified path.
I downloaded kit-app-template-main.zip and unziped it. I keep these two both in my C drive download folder.

Maybe it’s really a problem with my Composer version. I can’t see the mask here.

Ok you downloaded it from GitHub, which is “ok”. But better still, forget the download and on number 3) go to the windows command CMD and type in git clone https://github.com/NVIDIA-Omniverse/kit-app-template.git

See above, I have clarified the instructions.


Thank you for your guidance. Does it mean I have installed it successfully? I still have Composer 2023.2.5 in my Omniverse Launcher.

Ok you have missed a step. Slow down :-) You have made a new template, but not BUILD IT. Step 2 here.

  1. run repo template new
    2. run repo build
  2. run repo launch -d