Hi all,
As a very simple example, suppose I have 2 boxes aligned side by side (no gap between them) and merged with a merge sop, the resulting geometry will have 2 primitives overlapping each other.
How can I get rid of these overlapping primitives so that i have a hollow geometry? Basically what I want to do is to merge a few objects into one piece.
Wesley
How could I delete overlapping primitives?
14552 10 5- wes_sin
- Member
- 27 posts
- Joined: July 2005
- Offline
- elias336
- Member
- 7 posts
- Joined: Jan. 2007
- Offline
- wes_sin
- Member
- 27 posts
- Joined: July 2005
- Offline
- richardhale
- Member
- 1 posts
- Joined: Feb. 2019
- Offline
- Andr
- Member
- 900 posts
- Joined: Feb. 2016
- Offline
- jsmack
- Member
- 7659 posts
- Joined: Sept. 2011
- Offline
- Adriano
- Member
- 403 posts
- Joined: June 2015
- Offline
jsmack
A boolean is unnecessary for this type of operation. Assuming the points of the overlapping face are all in fuse distance, use a Clean SOP with "consolidate points" and "fix overlaps" enabled.
This does not work for me. I have several curves with overlapping edges, and i can't find a simple way to get rid of the overlapping bits in order to fuse the points together and keep a single curve. Any other approach that would be effective on curves please?
Cheers,
A.
- tamte
- Member
- 8449 posts
- Joined: July 2007
- Offline
AdrianoFuse + Convert Line + Poly Pathjsmack
A boolean is unnecessary for this type of operation. Assuming the points of the overlapping face are all in fuse distance, use a Clean SOP with "consolidate points" and "fix overlaps" enabled.
This does not work for me. I have several curves with overlapping edges, and i can't find a simple way to get rid of the overlapping bits in order to fuse the points together and keep a single curve. Any other approach that would be effective on curves please?
Cheers,
A.
even though Convert Line may not be necessary, try without
Edited by tamte - Oct. 10, 2022 19:12:39
Tomas Slancik
FX Supervisor
Method Studios, NY
FX Supervisor
Method Studios, NY
- animatrix_
- Member
- 4460 posts
- Joined: Feb. 2012
- Online
After fusing you can run 2 primitive wrangles like this:
Serialize point list:
Delete overlapping polygons:
If you want to keep the first overlapping polygon rather than deleting all, you can do this:
Serialize point list:
string serializePointIndices ( int primIndex ) { int indices [ ]; int count = primvertexcount ( geoself ( ), primIndex ); for ( int i = 0; i < count; ++i ) { int index = vertexpoint ( geoself ( ), vertexindex ( geoself ( ), primIndex, i ) ); push ( indices, index ); } indices = sort ( indices ); return sprintf ( "%s", indices ); } s@pointList = serializePointIndices ( @primnum );
Delete overlapping polygons:
string pointList = prim ( 1, "pointList", @primnum ); int count = findattribvalcount ( 1, "primitive", "pointList", pointList ); if ( count > 1 ) removeprim ( geoself ( ), @primnum, 1 );
If you want to keep the first overlapping polygon rather than deleting all, you can do this:
string pointList = prim ( 1, "pointList", @primnum ); int index = findattribval ( 1, "primitive", "pointList", pointList ); if ( @primnum != index ) removeprim ( geoself ( ), @primnum, 1 );
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]
youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]
youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
- Aizatulin
- Member
- 470 posts
- Joined: July 2005
- Offline
- LukeP
- Member
- 232 posts
- Joined: March 2009
- Offline
-
- Quick Links