I encountered issue described on github Missing refresh after changing NodeGraph attribute value · Issue #2128 · PixarAnimationStudios/OpenUSD · GitHub
where changing NodeGraph input inside Material is not triggering Hydra refresh.
Example Material with NodeGraph:
#usda 1.0
def Capsule "Capsule1" (
prepend apiSchemas = ["MaterialBindingAPI"]
)
{
rel material:binding = </mtl/UsdPreviewSurface1>
}
def Scope "mtl"
{
def Material "UsdPreviewSurface1"
{
token outputs:surface.connect = </mtl/UsdPreviewSurface1/NodeGraph1.outputs:surface>
def NodeGraph "NodeGraph1"
{
color3f inputs:diffuseColor = (0.872, 0.5327, 0)
token outputs:surface.connect = </mtl/UsdPreviewSurface1/NodeGraph1/UsdPreviewSurface1.outputs:surface>
def Shader "UsdPreviewSurface1"
{
uniform token info:id = "UsdPreviewSurface"
color3f inputs:diffuseColor.connect = </mtl/UsdPreviewSurface1/NodeGraph1.inputs:diffuseColor>
token outputs:surface
}
}
}
}
Without the fix from the github another way to make Material update is to connect NodeGraph inputs to Material inputs.
The question I have is whether other studios use nested NodeGraphs with inputs? If yes, it’s strange that this went unnoticed for long time. Is this USD structure looks sensible or another Material structures were designed to be used?
Thanks,
– ievgen