jwoelper Posted March 23, 2010 Share Posted March 23, 2010 Hi everyone, just came across a problem where I wanted to fuse points between two or more groups. Suppose I have groups A and B. I do not want points from group A to fuse with other points within group A, just with ones in group B. That way points in A should only fuse to ones in group B and vice versa. Is that possible? I tried to work around that by creating volumes from the geometry and intersecting them, but that method is not precise and cpu-intensive... Any help is greatly appreciated! Johann Quote Link to comment Share on other sites More sharing options...
dbukovec Posted March 23, 2010 Share Posted March 23, 2010 hi! take a look a t the file, basically i created a new group based on other two, nothing magical fuseGroups.hip Quote Link to comment Share on other sites More sharing options...
jwoelper Posted March 23, 2010 Author Share Posted March 23, 2010 Hi! Thank you very much for the help! Unfortunately, this method does not work for me... my grouped points are closer together than their targets, so I'd strictly need a member of A snap to a member of B only. I have included my problem next to your example in the file - sorry if I did not explain it properly. fuseGroups.hipnc hi! take a look a t the file, basically i created a new group based on other two, nothing magical Quote Link to comment Share on other sites More sharing options...
Mario Marengo Posted March 23, 2010 Share Posted March 23, 2010 Sounds like a perfect job for point clouds. When I get a chance I'll sketch an example, but in the meantime: for each point 'i' in A open B as a pointcloud with query_pos=A[i] and radius=snap_threshold if point 'j' found, move A[i] to B[j] close pcloud end foreach Quote Link to comment Share on other sites More sharing options...
Mario Marengo Posted March 27, 2010 Share Posted March 27, 2010 Here's a quick sketch using point clouds. I couldn't open your file Johann, so I modified Daniel's. Just hit play to see it in action. As an aside, while doing this I noticed that using pcfilter() (or using pcfarthest() as a determinant for whether a point was found, one or the other) failed in some cases (and shouldn't). No time to check right now, but it *may* be a bug. Anyway, you'll see that (much shorter/cleaner) approach commented out, and a hand-rolled pcfilter() used instead -- but still pretty straight forward. fuseGroups_pcmethod.hip HTH, Cheers. Quote Link to comment Share on other sites More sharing options...
mightcouldb1 Posted March 27, 2010 Share Posted March 27, 2010 Thanks for taking the time to post this Mario. Super helpful as I am learning VEX. Quote Link to comment Share on other sites More sharing options...
jwoelper Posted March 29, 2010 Author Share Posted March 29, 2010 Thanks a million for taking the time to assemble this example! This was very very helpful! Thanks again Johann Here's a quick sketch using point clouds. I couldn't open your file Johann, so I modified Daniel's. Just hit play to see it in action. As an aside, while doing this I noticed that using pcfilter() (or using pcfarthest() as a determinant for whether a point was found, one or the other) failed in some cases (and shouldn't). No time to check right now, but it *may* be a bug. Anyway, you'll see that (much shorter/cleaner) approach commented out, and a hand-rolled pcfilter() used instead -- but still pretty straight forward. fuseGroups_pcmethod.hip HTH, Cheers. Quote Link to comment Share on other sites More sharing options...
XAavBp Posted April 6, 2016 Share Posted April 6, 2016 Hi, I have pretty much the same problem as you but i'm using a sweep to instance multiple objects along a curve, I've grouped all the points in the positive and negative Z space separate group but I can't figure how to implement them with your point cloud.Could someone give me a hint as to how to implement your solution in my context. Thanks ! test.hipnc Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.