Grasshopper

algorithmic modeling for Rhino

Does somebody have a good idea how I can identify those edges of a brep where there is no "kink" in the brep, i.e. edges where the brep is at least G1 continuous?

The background is: I would likle to write a meshing component, and the mesh vertices close to the edges should snap to the edges. With the exception of edges where the brep is G1 continuous. In these cases it would look strange to have a "seam" in the mesh.

In the case of a truncated cone, the "verticalish" edge would be such a case:

Views: 871

Replies to This Discussion

This doesn't use continuity, but you could use the IsSmoothManifoldEdge on the BrepEdge object?

  private void RunScript(Brep x, ref object Smooth, ref object NotSmooth)
  {
    List<Curve> output = new List<Curve>();
    List<Curve> output2 = new List<Curve>();
    foreach (BrepEdge be in x.Edges)
    {
      if (be.IsSmoothManifoldEdge(RhinoDocument.ModelAngleToleranceRadians))
      {
        output.Add(be.DuplicateCurve());
      } else {
        output2.Add(be.DuplicateCurve());
      }
    }
    Smooth = output;
    NotSmooth = output2;

  }

Thanks! That sounds good.

I'll try it.

The continuity of two adjacent faces on opposite sides of an edge may differ from place to place, so do you want to only find edges that are entirely continuous or do you want to find -for every edge- the domains over which the adjacent faces are continuous?

I suspected that :)

It would be best to have the domains of edges where the faces are continuous.

Or, more to the point: what I am actually interested in are those edges (or parts of them) where the faces are non-continous. I just asked the question the other way round, because that seemed more intuitive - for some reason.

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service