THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 12/10/2010 at 16:21, xxxxxxxx wrote:
Cinema 4D Version: 12
Platform: Windows ;
Language(s) : C++ ;
I'm trying to create a tool that mimics the loop selection tool with some additions. I am able to get a loop selection by using the neighbor class and using GetNeighbor() I loop through the polys and get the neighbor of the selected poly and if the neighbor shares the .c and .d points with the previous poly it selects that poly. This allows for a simple loop selection. However, this idea doesn't always work because the polys are not always situated in such a way that the .c and .d points are the connected to make a loop.
I assume that the neighbor class is the way to go but does anyone know how the loop selection tool in C4D creates a loop selection? My neighbor class setup is not working quite right.
On 13/10/2010 at 03:18, xxxxxxxx wrote:
There is a reason other developers make commercial plugins out of good loop selection algorithms because it´s not a "do it xy way". You should think of a way yourself how to use the information you have to generate a sensible loop out of it. That´s what it´s all about.
On 13/10/2010 at 03:31, xxxxxxxx wrote:
Yeah I guess that first post was worded in a tell me how to do this sort of way. I think what I am looking for is, is there another class in the sdk somewhere that can get adjacent polys besides the neghbor class?
On 13/10/2010 at 03:44, xxxxxxxx wrote:
I might just have to do it with a little elbow grease and iterate through the polys and determine if the current poly shares particular points with the previous poly. But there will have to be more than that because of the overall topology of the object. I will keep chipping away at it.
On 13/10/2010 at 04:22, xxxxxxxx wrote:
You could use the neighbor class to obtain all possible directions you loop could go at a certain point. But as Katachi says, you need to design the specific behaviour yourself, as there is no well really defined way of doing this.