Workflow issue

   2395   7   0
User Avatar
Member
1755 posts
Joined: March 2014
Offline
Heya,

Say you have a poly-mesh object from which you want to create another object based on a selection of faces (primitives).
In XSI I simply select the faces and execute “extract and keep/delete (from current object) polys” which will give me another poly mesh object made out of those selected faces.

Is there a command like this in Houdini? I didn't find one and this operation is one I use a lot so that would be another wrench thrown in the “adopt the Houdini modeling” thing for me.

The way I worked around this was to create a group from those faces and “import” them into another empty geo node via an object_merge node. All good except I've stumbled a huge problem (for which I hope there's a solution): when I went back to the object from which I've “extracted” the faces used for creating the new object and edited it, the elements' indexes have changed and now the group based on which I've created and edited the new object is invalid. I don't remember exactly what I've changed to the original (not sure if it even helped) and now about one hour of work is almost lost.

What we need (if there isn't already) is a high level node/shelf command that does this more easily with the option of having the “extracted” faces cutoff (as in baked/no longer having a relationship) from their “parent” object or to keep them still pointing to their “”parent.
User Avatar
Member
2537 posts
Joined: June 2008
Offline
The problem was that you edited the object before the group was created. If you apply your edits after the Group node, your secondary reference to the original geometry would still be valid. Try to make your Group selection early on in the chain. Often what is seen in Houdini networks is a NULL is dropped down to indicate a marker where certain geometry can be safely fetched. Then your Object Merge can fetch from that node.

Also to emulate your suggested style you can drop down a Delete node and supply the Group name from your selection. Then you have the option of deleting the selection or the inverse of the selection. This is an easy way to split a single object into two network streams for further processing.
Using Houdini Indie 20.0
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
User Avatar
Member
1755 posts
Joined: March 2014
Offline
Enivob
The problem was that you edited the object before the group was created. If you apply your edits after the Group node, your secondary reference to the original geometry would still be valid.

Ah, I get it. It was about a few unfused points on a retopo node so I went and dealt with that. If it wasn't that, the edit would've happened after the group creation most likely.

Enivob
Try to make your Group selection early on in the chain. Often what is seen in Houdini networks is a NULL is dropped down to indicate a marker where certain geometry can be safely fetched. Then your Object Merge can fetch from that node.

Yeah, I think you're talking about “procedural modeling” here
“Trad modeling” doesn't work like that, you extract the geometry when you need it and you know you need it only when you get there.

Enivob
Also to emulate your suggested style you can drop down a Delete node and supply the Group name from your selection. Then you have the option of deleting the selection or the inverse of the selection. This is an easy way to split a single object into two network streams for further processing.

Thanks. But doesn't that mean that any editing before the delete will have an effect on the group contents? “My solution” is about totally (as in destructively - something most Houdini veterans probably frown upon) cutting the relation between the new geo and the old one. I guess I'll scratch my left ear with my right toe for the time being. I hope SESI will implement an easier solution (about two clicks like in XSI) in the future. I'll surely submit a RFE as well.

As I've said a thousands times before, box modeling isn't just about having a good bevel, but about some esoteric workflows other 3d branches specialists don't usually consider.
The current workflow in Houdini is not having trad modelers in mind. At all. I'm tempted to start a rant about the new Polysplit and why it was rushed (hopefully it's WIP, not classified as final), but I'll refrain…
Edited by anon_user_89151269 - Oct. 28, 2016 10:14:11
User Avatar
Staff
3455 posts
Joined: July 2005
Offline
you could branch and lock then object merge (the geometry would get stored in your hip file so…)
or object merge and lock (geo still stored in the hip but far less that in the first case)


this way if you did make changes upstream you'll be able to unlock and get the new geo - often this will work very nicely
Michael Goldfarb | www.odforce.net
Training Lead
SideFX
www.sidefx.com
User Avatar
Member
1755 posts
Joined: March 2014
Offline
Thank you arctor, will definitely try it this way next time I'll need it.

IMO what people, that is purebred H users and especially devs, should take home from this is that right now Houdini won't allow for an “uninterrupted” - don't deal with nodes - box modeling. When I model in XSI (this applies to other apps as well) I never go into the stack to fiddle with it. Granted, even if I were, no app would allow me to stick my nose so deep into the history as Houdini does, which is a great thing when you want/need it, but this doesn't mean that just because I can I should do something.

Just to be clear - I'm not preaching destructive workflows here. When I got into XSI one thing, among many others, that I appreciated was its non-linear (that's how it was marketed) workflow, which is another way to say it's non-destructive, at least compared to others most popular at that time. Houdini wins hands down at this but fails to deliver on the high-level tools domain, which is most likely why most technical artists love it while the ones oriented towards “painting” less so.

Any Maya, 3dsMax, Modo, Lightwave and probably others coming here reading about the solution to this workflow problem I'm sure many will use in their chosen apps will think this is nuts. This doesn't have to require an orange belt in Houdini node-fu, it's just a damn modeling operation. Less willing/inclined for technical stuff people shouldn't be punished, just those more technically able be rewarded, the latter already happening.

Fill those tool bars with tool icons or Houdini will never appeal to traditional artists.
I hate drama, but I feel this has to go down from time to time, for if not anything else, I think it's true.
Edited by anon_user_89151269 - Oct. 28, 2016 11:34:38
User Avatar
Member
182 posts
Joined: April 2009
Offline
There is a shelf tool, which does what you want with one click -> It's called “Extract” in the Modify tab on the left. It creates a new Obj node with an object merge sop inside using the selection from the viewport.

Now you can copy the python code from that tool to create your own and extend it. If you add this code below, then you automatically lock the object merge after it is created if the ctrl key was pressed:
if kwargs['ctrlclick']:
merge_sop.setHardLocked(1)

Here's the whole code:
import toolutils
import soptoolutils

activepane = toolutils.activePane(kwargs)
if activepane.type() != hou.paneTabType.SceneViewer:
raise hou.Error("This tool cannot run in the current pane")

scene_viewer = toolutils.sceneViewer()
nodetypename = "delete"

# Obtain a geometry selection
geo_types = (hou.geometryType.Primitives, )
selection = scene_viewer.selectGeometry(
"Select the primitives to extract and press Enter to complete",
geometry_types = geo_types,
allow_obj_sel = True)
# The following will raise an exception if nothing was selected.
if len(selection.nodes()) == 0:
raise hou.Error("Nothing was selected.")

# Create a new SOP container with the merged geometry
container = soptoolutils.createSopNodeContainer(scene_viewer, "extract_object1")
merge_sop = selection.mergedNode(container, nodetypename, True, True)
# Turn back on the display flag for merged nodes
for sop in selection.nodes():
sop.parent().setDisplayFlag(True)

# Change our viewer to the new object
scene_viewer.setPwd(merge_sop.parent())
merge_sop.setDisplayFlag(True)
merge_sop.setRenderFlag(True)
merge_sop.setHighlightFlag(True)
merge_sop.setCurrent(True, True)
merge_sop.moveToGoodPosition()
toolutils.homeToSelectionNetworkEditorsFor(merge_sop)
scene_viewer.enterCurrentNodeState()

# Set lock flag if ctrl key was used
if kwargs['ctrlclick']:
merge_sop.setHardLocked(1)
Edited by blackpixel - Nov. 11, 2016 22:51:00
User Avatar
Member
182 posts
Joined: April 2009
Offline
I totally get what you are saying. Sometimes you just want to do stuff without having to think about the technical side. One of the best examples would be ZBrush or 3dCoat. You don't care about topology. You just sculpt and deal with it later with remeshing and retopo.
You can get quite far with custom tools and scripts to streamline your workflow, but you'll never be truly destructive / dirty. I also rarely see people hard lock geometry into the scene, unless it's for portability or debugging. It bloats your scene file and makes it difficult to work with. What Houdini excels at though is building systems: (input) > {do something} > (output). In a pipeline you often have versioned file cache nodes, that break long tool chains into smaller pieces, but then again it's not feasible for pure modeling.
But I think it's slowly getting there. Each version has become more and more user friendly with better modeling tools.
Edited by blackpixel - Nov. 11, 2016 23:55:36
User Avatar
Member
1755 posts
Joined: March 2014
Offline
Hey man, I just saw your posts. Thanks a bunch for these tips!
  • Quick Links