Hi
I have a really simple scene,
i try to render with Karma, but the Karma viewport is not showing the geometry
and the render is empty.
i am new on render with Houdini , maybe a forgot something
Thank for your help
Best regards
Daniel
KarmaRender Viewport is empty
3098 5 2- dpotuznik
- Member
- 11 posts
- Joined: April 2019
- Offline
- mtucker
- Staff
- 4419 posts
- Joined: July 2005
- Offline
- dpotuznik
- Member
- 11 posts
- Joined: April 2019
- Offline
- robp_sidefx
- Staff
- 446 posts
- Joined: June 2020
- Offline
Thanks for this example Daniel!
I'll give the quick-fix first, and the explanation below.
Somewhere in
The Karma ROP uses a Scene Import LOP internally, which is responsible for translating Houdini geometry to USD. It uses Python plugins to handle the translation of custom node types, and ignores node types that don't have associated translators. This is what you've run into, though the warning is a bit hidden (if you dive into the Karma ROP and then the lopnet, you'll see it).
There's more information about writing translators here: https://www.sidefx.com/docs/houdini/hom/sceneimport_object_translator.html [www.sidefx.com]
Note that the Python code above is extremely minimal. If you want to support the display flag, for example, the translator's logic will need to be extended. The best place to look for an example is the
I hope this helps!
- Rob
I'll give the quick-fix first, and the explanation below.
Somewhere in
$HOUDINI_PATH
(e.g., $HOME/houdini19.0
), create husdplugins/objtranslators/rendernft.py
with the following contents:import husd class RenderNFTTranslator(husd.objtranslator.Translator): def shouldTranslateNode(self): return True def primType(self): return 'Xform' def registerTranslators(manager): manager.registerTranslator('feeble::dev::RenderNFT::1.0', RenderNFTTranslator)
The Karma ROP uses a Scene Import LOP internally, which is responsible for translating Houdini geometry to USD. It uses Python plugins to handle the translation of custom node types, and ignores node types that don't have associated translators. This is what you've run into, though the warning is a bit hidden (if you dive into the Karma ROP and then the lopnet, you'll see it).
There's more information about writing translators here: https://www.sidefx.com/docs/houdini/hom/sceneimport_object_translator.html [www.sidefx.com]
Note that the Python code above is extremely minimal. If you want to support the display flag, for example, the translator's logic will need to be extended. The best place to look for an example is the
GeometryTranslator
in $HH/husdplugins/objtranslators/base.py
, which you should be able to use as-is.I hope this helps!
- Rob
Edited by robp_sidefx - Jan. 14, 2022 05:07:20
- jsmack
- Member
- 7658 posts
- Joined: Sept. 2011
- Online
robp_sidefx
Thanks for this example Daniel!
I'll give the quick-fix first, and the explanation below.
Somewhere in$HOUDINI_PATH
(e.g.,$HOME/houdini19.0
), createhusdplugins/objtranslators/rendernft.py
with the following contents:import husd class RenderNFTTranslator(husd.objtranslator.Translator): def shouldTranslateNode(self): return True def primType(self): return 'Xform' def registerTranslators(manager): manager.registerTranslator('feeble::dev::RenderNFT::1.0', RenderNFTTranslator)
The Karma ROP uses a Scene Import LOP internally, which is responsible for translating Houdini geometry to USD. It uses Python plugins to handle the translation of custom node types, and ignores node types that don't have associated translators. This is what you've run into, though the warning is a bit hidden (if you dive into the Karma ROP and then the lopnet, you'll see it).
There's more information about writing translators here: https://www.sidefx.com/docs/houdini/hom/sceneimport_object_translator.html [www.sidefx.com]
Note that the Python code above is extremely minimal. If you want to support the display flag, for example, the translator's logic will need to be extended. The best place to look for an example is theGeometryTranslator
in$HH/husdplugins/objtranslators/base.py
, which you should be able to use as-is.
I hope this helps!
- Rob
Would it be possible for husdtranslators to use the translator associated with the base class of a node type if no translator exists explicitly for the node type? For example use 'base' for node types that subclass geo nodes, and 'hlight' for nodes that subclass the light, etc.
- robp_sidefx
- Staff
- 446 posts
- Joined: June 2020
- Offline
jsmack
Would it be possible for husdtranslators to use the translator associated with the base class of a node type if no translator exists explicitly for the node type? For example use 'base' for node types that subclass geo nodes, and 'hlight' for nodes that subclass the light, etc.
That sounds like a good idea. RFE created to investigate further!
-
- Quick Links