def Shader "myMaterial" { uniform token info:implementationSource = "sourceAsset" uniform asset info:sourceAsset = @opdef:/LINK_TO_SOURCE_NODE?ARG_TO_OUTPUT_COMPILED_VEX@ } }
we have USD with materials coming from outside Houdini, all defined with
sourceAsset
as well. We can write nodes to generate houdini materials for them, and would like to intercept the read of whatever's inside sourceAsset = @THIS_REGION@
so we can feed a Hydra renderer with the code output from these nodes. What's more, we would like the sourceAsset
to remain unchanged when we re-export this USD.Is there a way to inject code in the
sourceAsset
reader that would customize the code being output to Hydra?Thanks!