Jump to content
awesomedata

Selecting edge corners

Recommended Posts

Posted (edited)

Is there a method that lets me select (and group) all (_only_) the particular corners of a rectangular shape, and then tag them as NW, NE, SW, SE?

For example, I want to select and group _this_ SW corner angle on _all_ rectangles in the geometry:

normal.thumb.png.948b4ef40eb5f20187878634cf57f87c.png

Edited by awesomedata

Share this post


Link to post
Share on other sites

Group SOP (type Edges)

- uncheck Base Group/Enable

- check Keep By Normals

- set Spread angle to something small, like 5

- set direction to:

NE: {-1, 0, 1}

NW: {1, 0, 1}

SE: {-1, 0, -1}

SW: {1, 0, -1}

considering based on your screenshot that Z is N and X is W

Share this post


Link to post
Share on other sites

Nice! -- Thanks! :D

To reward your awesome generosity -- I have two more questions:

  1. First, what does the 1/-1 mean in that context? -- I would assume it would be 45 or so (as in degrees), but this doesn't seem to matter.
  2. Second, what would I do if I wanted to get the center point of each edge segment in a group?

 

Seriously though -- I do appreciate your help, @anim.
I've been wracking my brain when working with edges for quite a while now. I guess I don't quite understand what's going on quite yet.

Share this post


Link to post
Share on other sites

1. it's a direction vector the normals are compared to

2. Detail Wrangle with your geo in the second input (assuming your edge group is called "edge_group")

int pts[] = expandedgegroup(1, "edge_group");

for (int i=0; i<len(pts); i+=2){
    vector P0 = point(1, "P", pts[i]);
    vector P1 = point(1, "P", pts[i+1]);
    vector P = avg(P0, P1);
    addpoint(0, P);
}

 

ts_point_per_edge_in_edge_group.hip

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×