How to use ReplaceEdge to "untrim"?

I have a surface that’s trimmed too much in one area.

What’s the fastest workflow to move the trim edge?

Things I’ve tried and failed so far:

  • I can’t draw a curve on surface on a part that’s trimmed away.
  • I can’t project a curve to a surface on a part that’s trimmed away.

Anyone has any other ideas?

Copying the surface and doing UntrimAll isn’t a good workaround because it’s not fast.

EDIT: Also, the fact that I must join curves before ReplaceEdge works also slows me down…

I do not see a good way I’m afraid. Thinking…

@eobet - it is kinda hokey but maybe a start - (721 Bytes)

To use the Python script use RunPythonScript, or a macro:

_-RunPythonScript "Full path to py file inside double-quotes"



Do you have a sample image of that particular surface?

Interesting! I see what you’re doing, but I don’t think I’d want to “do it live” with drawing the new edge inside the command, so to speak. :slight_smile:

Edit: Before here was a suggestion of a workflow, but it was based on some sort of bug I bumped into when I created this thread, so I’ve removed it for now. If the above script could be extended with the user being able to draw an arbitrary amount of curves on the surface, I think it would work well!

Yeah, I’m going to have to keep an eye out for examples because turns out, I was bumping up to some sort of an edge case when I created this thread…

Why not use a blend curve: Rhino 7 and Replace Edge = so much fun!!! - YouTube
I watched that on @Rhino_Bulgaria YT channel and I liked that method so much that I`ve recorded my own movie about that.

1 Like

“Replace edge” with the “Select curve” is the way to go. It does its job 95% of the time. On rare occasions Rhino may refuse to execute the command properly due to the target curve being build slightly away from the surface in the normal direction.

1 Like

Ok, your video made me go and try some things, and turns out, I made this thread from some sort of “bug”.

However, I guess I also had some trouble with “drawing curves in the air”… there’s a view based drag mode that I often use, but I can’t seem to enable it during line creation… that would help quite some ways with the issue @Pascal was trying to solve for me as well!

1 Like

Ok, so I think I found another example for the same reason why I made this thread… it’s not as easy to use ReplaceEdge to do a local untrim in practise as in theory:

I ensured that the curve starts and ends at the point where I split the trim edge I want replaced and I joined them as well. But is it that the pulled curve can’t go outside the control points this far, or why does the command fail here without even a message as to why?

replaceedge2.3dm (198.8 KB)

(I had to shrink the trimmed surface here because it’s a live project, but the non-result is the same.)

what result would you expect in this case? If I untrim that surface and look at the trim curve you want to keep, it doesn’t follow the isocurves, so if Rhino would manage to untrim it, you will be left with something like this:

Here’s what I expected, and what I manually had to construct now using DupEdge, UntrimAll, Pull, Trim (such tedious time waste and the pull, which ReplaceEdge seems to do internally looked fine but it resulted in two curves, which I guess is why it failed since there apparently is no logic to internally connect the ends):

(Again, it’s the non-shrunk live project part since it’s slightly more obvious there.)

okay, so the lower line is a new trim curve right (the one closest to your shortest straight line in your file)? Does it follow the isocurve? Without the surface itself it’s hard to see. Basically what we need is untrim being able to untrim only selected edges. This is not so much a replace edge problem I think. Then if you untrim a edge that is part of a split, like in this example, it should extend it according the isocurve direction. That would certainly be handy and time saving.

In fact one of the most underrated and overlooked rhino commands.

1 Like