MoI discussion forum
MoI discussion forum

Full Version: Trim command behavior options

Show messages:  1-20  21-29

From: Rick
22 Jan 2023   [#1]
Anyone who frequently uses Make2D to generate linework will be familiar with the need to make lots of trims- sometimes hundreds on perspective views of threaded fasteners. A while back I was furiously trimming lines when I realized that MOI was working just the way I'd always wanted it to- when I selected a line on the side I wanted to keep and then selected the intersecting line the trim happened immediately, without the need to select the trimmed section. But, it didn't maintain that behavior, and I thought I must have been having a caffeine hallucination. Then it happened again this morning- I tried to find some option or checkbox that resulted in this action, but I couldn't, and in trying different options the behavior disappeared again. Is there an option to make this behavior stick? I know MOI is capable of working this way but can't reproduce it- if it's a bug I hope it can be written in.
From: Michael Gibson
22 Jan 2023   [#2] In reply to [#1]
Hi Rick, it kind of sounds like that may have been a bug.

Try this attached QuickTrim plugin instead (instructions for installing a plug-in here.), it will allow you to trim curves by swiping across the pieces you want to discard.

For this one you don't need to select anything, just swipe over them. But if you do have any selected it will only target those selected curves.

Works like this (here with repeat checkbox turned on):



- Michael

EDIT: Minor update, if using selected objects make result selected too.

EDIT: Jan 23 Another update, fix for swipe mistakenly targeting 3D curves in some cases and also not skipping hidden/locked curves. Also now only tries to intersect curves on the same plane as the swipe.

Attachments:
QuickTrim.zip


From: BurrMan
22 Jan 2023   [#3] In reply to [#2]
Whoa…..
From: Michael Gibson
22 Jan 2023   [#4] In reply to [#3]
Maybe right click on the Edit > Trim button would be a good place I could put this one in the regular build.

- Michael
From: BurrMan
22 Jan 2023   [#5] In reply to [#4]
I can dig it….
From: Frenchy Pilou (PILOU)
22 Jan 2023   [#6]
Christmas was one month ago! :)
And the cool thing is that works in 3D!!!

Maybe with unexpected result! :)
https://moiscript.weebly.com/uploads/3/9/3/8/3938813/gif_unexpectable.gif


From: Frenchy Pilou (PILOU)
22 Jan 2023   [#7]
French Version :)
https://moiscript.weebly.com/quicktrim.html



Curiously don't work for the 3 bottom external curves (video) ? (bug or don't work on yet trimed curves or...?)
From: Michael Gibson
23 Jan 2023   [#8] In reply to [#6]
Hi Pilou,

re:
> Maybe with unexpected result! :)

It's intended to be used on 2D curves. But can you please post the .3dm file for the model you show though, are you certain that the curves intersect each other?

But in general I would recommend using it on 2D curves and not on 3D curves.


> Curiously don't work for the 3 bottom external curves (video) ? (bug or don
> t work on yet trimed curves or...?)

It's because regular Edit > Trim is not focused on completely deleting entire curves, it's focused on deleting a portion of a curve. So with regular Trim if there is an intersection only at one end of the curve it won't be targeted. QuickTrim then inherits that same behavior from regular Trim.

Maybe I can get it set up so that QuickTrim will work for that case though.

- Michael
From: Frenchy Pilou (PILOU)
23 Jan 2023   [#9] In reply to [#8]
No problem i had saved it in case of! :)
https://moiscript.weebly.com/uploads/3/9/3/8/3938813/unexpectable_result.3dm
From: Rick
23 Jan 2023   [#10]
The concept and video are great, but, on my M1 Mac Studio it acts a little kooky. After swiping across the curve to trim away I get a 'beachball' for maybe 15 seconds and then every intersecting line on the entire model is 'broken' by inserting a point at the intersection- another 10 or 15 seconds and the section I wanted trimmed is gone. So, the curse of the Mac strikes again. I wish I could capture the model at the point where all of the intersecting lines are broken into separate segments and just run around the model deleting all of the segments I want to trim, but I can't do anything once the beachball and point insertion process starts.
It's so close to amazing- if I could forget about swiping and get MOI to temporarily insert a point that breaks every line at an intersection I could delete the offending line segments in no time.
Again, it's so close to being a technical illustrator's dream function. In case you don't have a silicon Mac I can make a screenshot of the intermediate step, where points are inserted at every intersection throughout the entire model.
Thanks for the effort,
Rick
From: Rick
23 Jan 2023   [#11]
This is what I see after swiping across 1 line segment- it does delete the segment. I would like to work on the drawing at this stage- it would be so easy to just move around deleting the bad segments.



Image Attachments:
Screen Shot 2023-01-23 at 6.44.37 AM.png 


From: pressure (PEER)
23 Jan 2023   [#12] In reply to [#11]
Hi Rick,

Have you tried out the Virtual Segment Delete tool in CorelDraw? https://www.youtube.com/watch?v=3nwKVFKy-4Q
From: pressure (PEER)
23 Jan 2023   [#13] In reply to [#11]
Also, I've had good luck with the Hatchet plugin for Illustrator when I need more control than virtual segment delete https://rj-graffix.com/product/cutting-tools-plugin/
From: Rick
23 Jan 2023   [#14]
Peer,
Thanks for the suggestions, I haven't used CorelDraw this century- didn't know it was still around, but that tool looks really useful. I've had mixed results with third party Illustrator plugins- not working over OS upgrades, Adobe updates, etc- I'm trying to like Affinity Designer, but it's not going well- just selecting a curve is too hard, and no LivePaint makes it too time consuming to use.
I really like 2D drawing and editing in MOI, so I export to illustration apps as a last resort. If/when MOI can make trimming faster I'd do 99% of a drawing in MOI.
Calling a Trim command and having it trim a selected line to intersections without clicking the cutting line and the segment to be deleted would be ideal, maybe with the option to delete or keep the new segment.
For me, bouncing back and forth between programs with all of the translations involved is slower than just struggling through- maybe Michael will come up with a solution.
Rick
From: BurrMan
23 Jan 2023   [#15] In reply to [#8]
“””””” So with regular Trim if there is an intersection only at one end of the curve it won't be targeted. QuickTrim then inherits that same behavior from regular Trim.

Maybe I can get it set up so that QuickTrim will work for that case though.””””””

That seems like the behavior i’d expect from your ”Eraser” tool once you get click and drag implemented.
From: Michael Gibson
23 Jan 2023   [#16] In reply to [#9]
Hi Pilou,

re:
> No problem i had saved it in case of! :)
> https://moiscript.weebly.com/uploads/3/9/3/8/3938813/unexpectable_result.3dm

Thanks, that was a bug where the "curve from 2 views" mechanism in the Intersect command was causing some 3D curves to be targeted by a swipe when they shouldn't be.

I've uploaded a fixed version, this one should now ignore this case instead of mistakenly targeting 3D curves.

Thanks, - Michael
From: Michael Gibson
23 Jan 2023   [#17] In reply to [#10]
Hi Rick,

re:
> After swiping across the curve to trim away I get a 'beachball' for maybe 15 seconds and then
> every intersecting line on the entire model is 'broken' by inserting a point at the intersection- another
> 10 or 15 seconds and the section I wanted trimmed is gone.

This likely has more to do with your particular model than being on Mac, can you please send the file to me at moi@moi3d.com so I can test with it?

One problem that I just fixed now is that it was trying to process hidden curves instead of skipping them.

Also I've updated it so that it only tries to intersect curves that are on the same plane as the swipe, that should help with performance.

Thanks, - Michael
From: Frenchy Pilou (PILOU)
23 Jan 2023   [#18] In reply to [#16]
Cool!
But seems this is not the same behaviour of the Trimer...
Now it is like a Polyline and not a curve!
Does this normal ?


From: Michael Gibson
23 Jan 2023   [#19] In reply to [#18]
Hi Pilou,

re:
> Now it is like a Polyline and not a curve!
> Does this normal ?

Turn off grid snap in the bottom toolbar.

- Michael
From: Michael Gibson
23 Jan 2023   [#20] In reply to [#14]
@Rick - thanks for sending the file through e-mail.

So just so others see this as well the slowdown issue is trying to use QuickTrim directly on your model with 3296 curves.

That will do the equivalent of using the regular Trim command and selecting all 3296 curves as both the objects to be cut and also as the cutting objects.

To solve this you'll need to narrow down the number of candidates that QuickTrim will be trying to process.

You can do that either by hiding curves outside of a current active working area of say a few hundred curves or by selecting curves in a particular area. If you have some selected curves the cutting up processing will only happen on that selection.

Maybe someday I can work on this to make a large several thousand candidate pool work better but that won't be anytime soon. To use it effectively you will need to narrow it down to something like 2 or 3 hundred curves or ideally even less rather than several thousand all being active on the same operation.

Thanks, - Michael

Show messages:  1-20  21-29