HOM save geometry

   5168   2   2
User Avatar
Member
11 posts
Joined: Oct. 2007
Offline
Anyone happen to know if you can save the geometry a SOP is generating to file via HOM (same as RMB->'Save Geometry')? I am not finding anything in the docs…
User Avatar
Member
1390 posts
Joined: July 2005
Offline
There is a command:
hou.Geometry.saveToFile()
but it's still not documented yet, not even sure if it works…

You can always use old hscript command: opsave. It saves appropriate data format for a specified operator, so simple:
hou.hscript('opsave /obj/geo1/null1')
should work.

hope this help,
sy.
User Avatar
Staff
270 posts
Joined: July 2005
Offline
To do it from Python, you would write:
hou.node('/obj/geo1/null1').geometry().saveToFile(“file.bgeo”)
  • Quick Links