control Houdini from Maya with RPC

   4283   4   0
User Avatar
Member
538 posts
Joined: 12月 2006
Offline
Hi all.
I try to script houdini behaviour with python in Maya. I use houxmlrpc.
So all works from maya like in houdini python, but…
This code work in houdini python shell:
hObj = hou.node('/obj').createNode('geo', ‘mayaGeometry’)
hObj.moveToGoodPosition()
hObj.node('file1').destroy()
hImportFromMaya = hObj.createNode('file','importFromMaya')
hExportToMaya= hObj.createNode('file','exportToMaya')
hExportToMaya.setFirstInput(hImportFromMaya)
But it does not work in Maya. On last line
hExportToMaya.setFirstInput(hImportFromMaya)
I get the error:
# Error: TypeError: cannot marshal recursive dictionaries #

I want to understand why so…
https://gumroad.com/alexeyvanzhula [gumroad.com]
User Avatar
Member
538 posts
Joined: 12月 2006
Offline
And also I want to understand why, from maya?
print hou

# Error: Fault: #
https://gumroad.com/alexeyvanzhula [gumroad.com]
User Avatar
Member
538 posts
Joined: 12月 2006
Offline
Now I see that this error also returned with my system python, not only in maya.
https://gumroad.com/alexeyvanzhula [gumroad.com]
User Avatar
Member
538 posts
Joined: 12月 2006
Offline
So, I read that houxmlrpc has many errors an in v11 need to use hrpyc.
And its works well
Solved.
https://gumroad.com/alexeyvanzhula [gumroad.com]
User Avatar
Member
1 posts
Joined: 1月 2012
Offline
This is a great post and i really like it, i really appreciate it for sharing this post.
roofing contractor nj [localroofingexpert.com]
  • Quick Links