Hey,
a simple question here: how can I move an object to the pivot or a pivot to the center of an object; or an object to the center of the world? Got a case where the ship as well as the pivot are off. I need them both at the same place on object level.
Move pivot to geo/geo to pivot or worl center
30328 12 2- Rosko Ron
- Member
- 184 posts
- Joined: 3月 2015
- Offline
- 8BitBeard
- Member
- 26 posts
- Joined: 6月 2016
- Offline
To reset the pivot to the center of the object:
Go inside the object (geo level) and put down a transform. On the transform properties, there is a 'Move Centroid to Origin“ Button.
To modify the pivot in general, when in object level press the ”Insert" Button on your keyboard. This will allow you to move the pivot. Can be combined with snap to point to move it to specific points on your object.
Go inside the object (geo level) and put down a transform. On the transform properties, there is a 'Move Centroid to Origin“ Button.
To modify the pivot in general, when in object level press the ”Insert" Button on your keyboard. This will allow you to move the pivot. Can be combined with snap to point to move it to specific points on your object.
- Rosko Ron
- Member
- 184 posts
- Joined: 3月 2015
- Offline
- Konstantin Magnus
- Member
- 671 posts
- Joined: 9月 2013
- Offline
-$CEX -$CEY -$CEZ
-$CEX -$YMIN -$CEZ
https://procegen.konstantinmagnus.de/ [procegen.konstantinmagnus.de]
- Rosko Ron
- Member
- 184 posts
- Joined: 3月 2015
- Offline
- Konstantin Magnus
- Member
- 671 posts
- Joined: 9月 2013
- Offline
Maybe I got you wrong, but in transform node it should be:
Pivot: $CEX $CEY $CEZ
Rosko RonTranslate: -$CEX -$CEY -$CEZ
how can I move an object to the pivot
Pivot: $CEX $CEY $CEZ
Rosko RonJust Pivot: $CEX $CEY $CEZ
or a pivot to the center of an object
https://procegen.konstantinmagnus.de/ [procegen.konstantinmagnus.de]
- anon_user_89151269
- Member
- 1755 posts
- Joined: 3月 2014
- Offline
A “normal” workflow - as in a few clicks and no expression shenanigans - would be to use a button “move centroid to COG (center of geometry)” and then use another feature which allows you to input a value a single time for all axis of a transformation - zero for translation at OBJ level in your case. I can do what you need here in three seconds flat in another program…
Both of these features (move centroid to COG, input once for all three axis) have been RFEed by yours truly as part of the “little things that would improve Houdini viewport interaction by a tenfold” campaign.
You might wanna start filing RFEs for these as well or they'll collect dust on a virtual shelf somewhere in SESI's virtual RFE basement.
Both of these features (move centroid to COG, input once for all three axis) have been RFEed by yours truly as part of the “little things that would improve Houdini viewport interaction by a tenfold” campaign.
You might wanna start filing RFEs for these as well or they'll collect dust on a virtual shelf somewhere in SESI's virtual RFE basement.
Edited by anon_user_89151269 - 2017年4月24日 10:15:31
- Olaf Finkbeiner
- Member
- 323 posts
- Joined: 1月 2015
- Offline
Hi McNistor,
normal as in not procedural? This is Houdini with full procedural shenanigans for even the smallest thing.
But i agree in so far as a few more ready made HDAs would be useful especially for people who dont like expression shenanigans.
And: you also have orbolt: https://orbolt.com/asset/animatrix::centroidalPoints::1.00 [orbolt.com]
I would love a node that put the pivot to the COG (center of gravity), center of bounding box i can wire up myself.
Center(Centroid) of geometry is not the same as center of bounding box.
Its actually not that trivial: http://wwwf.imperial.ac.uk/~rn/centroid.pdf [wwwf.imperial.ac.uk]
Maybe one of the math wizards here could do it… I cant even read it…
kind regards
Olaf
normal as in not procedural? This is Houdini with full procedural shenanigans for even the smallest thing.
But i agree in so far as a few more ready made HDAs would be useful especially for people who dont like expression shenanigans.
And: you also have orbolt: https://orbolt.com/asset/animatrix::centroidalPoints::1.00 [orbolt.com]
I would love a node that put the pivot to the COG (center of gravity), center of bounding box i can wire up myself.
Center(Centroid) of geometry is not the same as center of bounding box.
Its actually not that trivial: http://wwwf.imperial.ac.uk/~rn/centroid.pdf [wwwf.imperial.ac.uk]
Maybe one of the math wizards here could do it… I cant even read it…
kind regards
Olaf
- anon_user_89151269
- Member
- 1755 posts
- Joined: 3月 2014
- Offline
Hi Olaf,
No, “normal” as in a few clicks as I said earlier, # of clicks being inconsequential as far as proceduralism goes. I like expressions and the option to use them whenever it's necessary, but there are times, and I feel this is one of them, when I'd rather take a few secs hitting a button or two instead of much more for writing expressions for simple modeling tasks such as these.
Houdini's very generous regarding the first option but severely lacking in the latter.
Should one ever hope to see artists in the non-VFX modeling/concept art business using Houdini, one would do good to accept the need of such workflows in H.
p.s. THose summations seem rather simple. It would be more interesting to see how you end up with those. Hell, I'll look into it when I had enough Zbrush for a certain day.
No, “normal” as in a few clicks as I said earlier, # of clicks being inconsequential as far as proceduralism goes. I like expressions and the option to use them whenever it's necessary, but there are times, and I feel this is one of them, when I'd rather take a few secs hitting a button or two instead of much more for writing expressions for simple modeling tasks such as these.
Houdini's very generous regarding the first option but severely lacking in the latter.
Should one ever hope to see artists in the non-VFX modeling/concept art business using Houdini, one would do good to accept the need of such workflows in H.
p.s. THose summations seem rather simple. It would be more interesting to see how you end up with those. Hell, I'll look into it when I had enough Zbrush for a certain day.
Edited by anon_user_89151269 - 2017年4月24日 11:22:18
- anon_user_37409885
- Member
- 4189 posts
- Joined: 6月 2012
- Offline
- blackpixel
- Member
- 182 posts
- Joined: 4月 2009
- Offline
- blackpixel
- Member
- 182 posts
- Joined: 4月 2009
- Offline
To center it to world you simply need to transform along the reversed pivot location.
To make things easier you can reuse the Center Pivot shelf tool and add 2 lines to it.
Create a new shelf tool:
I only added this:
Now when you click the tool it centers the pivot like before, but when you CTRL click it it also moves the object to the center of the world.
To make things easier you can reuse the Center Pivot shelf tool and add 2 lines to it.
Create a new shelf tool:
import toolutils scene_viewer = None activepane = toolutils.activePane(kwargs) parent = activepane.pwd() if activepane.type() != hou.paneTabType.SceneViewer: # Use the last selected object if parent.childTypeCategory() != hou.objNodeTypeCategory(): raise hou.Error("This tool cannot be executed in this context") selected = [child for child in parent.children() if child.isSelected()] else: scene_viewer = toolutils.sceneViewer() selected = scene_viewer.selectObjects( prompt = toolutils.selectionPrompt(hou.objNodeTypeCategory()), allow_multisel = True, allowed_types = ("geo",)) if len(selected) == 0: raise hou.Error("Nothing was selected") for center_obj in selected: display = center_obj.displayNode() if display is None: pivot = hou.Vector3(0, 0, 0) # Use 0,0,0 by convention else: geo = display.geometry() pivot = geo.boundingBox().center() center_obj.parmTuple("p").set(pivot) if kwargs['ctrlclick']: center_obj.parmTuple("t").set(-pivot) if scene_viewer is not None: scene_viewer.setCurrentState("objxform")
I only added this:
if kwargs['ctrlclick']:
center_obj.parmTuple("t").set(-pivot)
Now when you click the tool it centers the pivot like before, but when you CTRL click it it also moves the object to the center of the world.
Edited by blackpixel - 2017年4月25日 04:20:43
- anon_user_89151269
- Member
- 1755 posts
- Joined: 3月 2014
- Offline
Thanks Mariusz.
I'm still debating in my mind while also trying to figure if there are any downsides regarding Houdini's way of dealing with these things - in this case using a “pivot value”. Transformations in Houdini are dealt a bit… different than I'm used to and in some cases worse, from a manipulation PoV.
I'm still debating in my mind while also trying to figure if there are any downsides regarding Houdini's way of dealing with these things - in this case using a “pivot value”. Transformations in Houdini are dealt a bit… different than I'm used to and in some cases worse, from a manipulation PoV.
-
- Quick Links