how many ways to make 2 object combine together without gap?
14363 12 2-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
Hi everyone , I have 2 model need to be combine together , well , actually is not only 2 , is plenty, so I cannot use “edit” or “transform” node to manual edit them 1 by 1.
I need some help , please kindly let me know as much tips as I can. (except with manual edit like “transform” or “edit” node , well , if there is expression can do the samething , please also tell me !!
Thanks please!!!
I need some help , please kindly let me know as much tips as I can. (except with manual edit like “transform” or “edit” node , well , if there is expression can do the samething , please also tell me !!
Thanks please!!!
-
- keyframe
- Member
- 1533 posts
- Joined: 7月 2005
- Offline
-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
-
- tamte
- Member
- 9111 posts
- Joined: 7月 2007
- Offline
assuming that they are both sops
connect both to Point SOP (each to one input)
now you can move the first one to touch the second in x axis by typing something like $TX + ($XMIN2-$XMAX) to the position x parameter of the point SOP
where $XMIN2 is the smalest x position of the geometry connected to second input and $XMAX is the largest x position of the geometry connected to the first input
at the end you need to use Merge SOP to merge Point SOP and the second geometry (which was used only as a template for the point sop so the output from the point sop is only translated 1st geo)
feel free to use $XMIN, $YMIN, $ZMIN, $XMAX … as well as $XMIN2, $YMIN2 … in your expressions to acheive desired effect
alse take a look at other useful variables like $BBX, $SIZEX, $CEX …
this will work for your example but it may be not usable for what you really want. Maybe if you can tell us what your real goal is (you mention more than 2 objects, maybe not in one axis?) then you can get more help from us
connect both to Point SOP (each to one input)
now you can move the first one to touch the second in x axis by typing something like $TX + ($XMIN2-$XMAX) to the position x parameter of the point SOP
where $XMIN2 is the smalest x position of the geometry connected to second input and $XMAX is the largest x position of the geometry connected to the first input
at the end you need to use Merge SOP to merge Point SOP and the second geometry (which was used only as a template for the point sop so the output from the point sop is only translated 1st geo)
feel free to use $XMIN, $YMIN, $ZMIN, $XMAX … as well as $XMIN2, $YMIN2 … in your expressions to acheive desired effect
alse take a look at other useful variables like $BBX, $SIZEX, $CEX …
this will work for your example but it may be not usable for what you really want. Maybe if you can tell us what your real goal is (you mention more than 2 objects, maybe not in one axis?) then you can get more help from us
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
-
- ragupasta
- Member
- 349 posts
- Joined: 8月 2006
- Offline
-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
-
- tamte
- Member
- 9111 posts
- Joined: 7月 2007
- Offline
I have made a little VOP SOP for you which will align first input geo to the second input geo by 2 primitives (one from each geo)
you just set two primitive numbers
and then you can correct the placement by angle parameter
it is very fast built, so it may be buggy
it will not work correctly if the two primitives you want to align have normals pointing in exactly the same direction(very small chance, but when you are testing it and place 2 exact spheres next to each other and try to align primitive 0 to primitive 0 it will happen)
It can be easily fixed by inserting the transform node before the first (or second) input and set the rotation to very small number just to introduce small difference in normals of the chosen primitives
you just set two primitive numbers
and then you can correct the placement by angle parameter
it is very fast built, so it may be buggy
it will not work correctly if the two primitives you want to align have normals pointing in exactly the same direction(very small chance, but when you are testing it and place 2 exact spheres next to each other and try to align primitive 0 to primitive 0 it will happen)
It can be easily fixed by inserting the transform node before the first (or second) input and set the rotation to very small number just to introduce small difference in normals of the chosen primitives
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- freesign
- Member
- 104 posts
- Joined: 3月 2008
- Offline
-
- tamte
- Member
- 9111 posts
- Joined: 7月 2007
- Offline
-
- jesta
- Member
- 311 posts
- Joined: 7月 2005
- Offline
-
- Quick Links