I am trying to create a single node with a custom viewer state that adds geometry when clicking, similar to Houdini's native curve editor.
Using the following code sample, I am able to click in the scene and append points to a multi-parameter:
https://www.sidefx.com/docs/houdini/hom/state_node.html [www.sidefx.com]
Image Not Found
However, as soon as I attempt to modify geometry on the node (rather than just changing parameters), I get the following error:
GeometryPermissionError: Geometry is read-only.
Here is the code I added to the viewer state's onMouseEvent:
node = self._node = kwargs["node"] geo = node.geometry() geo.createPoint()
How can I get the node's modifiable geometry inside of the viewer state?
Thank you