MR Curve Tool 4.1

Moho allows users to write new tools and plugins. Discuss scripting ideas and problems here.

Moderators: Víctor Paredes, Belgarath, slowtiger

User avatar
Lukas
Posts: 1308
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

Re: MR Curve Tool

Post by Lukas »

Nice! I really prefer Photoshop's pen tool to Moho's Add Point tool, it has a bit of a higher learning curve, but it's easier in the end to create vectors. Really curious about this script, looking forward to trying it out when I've got the time!
User avatar
Greenlaw
Posts: 9576
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: MR Curve Tool

Post by Greenlaw »

It takes a bit of practice. I sometimes unintentionally drag out bezier handles when I don't want them. I'm getting used to it though. :D
User avatar
KuzKuz
Posts: 523
Joined: Mon Aug 19, 2013 5:12 pm
Location: Ukraine

Re: MR Curve Tool

Post by KuzKuz »

Thanks for your feedback.
I can add an option to disable Bezier handles.
Also, I can add an option to change the distance the cursor needs to move from the point so that the Bezier handles are activated.
Please let me know if you need it.
User avatar
Greenlaw
Posts: 9576
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: MR Curve Tool

Post by Greenlaw »

KuzKuz wrote: Mon Feb 13, 2023 6:25 pm I can add an option to disable Bezier handles.
Also, I can add an option to change the distance the cursor needs to move from the point so that the Bezier handles are activated.
Please let me know if you need it.
Thank you Eugene!

I'm sure the first option will be very useful to me! When creating deforming artwork, I prefer to draw with only regular points, and keep Beizer off for Add Points until I really need it (usually for non-deforming art.) The second option sounds like it might help prevent creating unintended beziers points while drawing quickly with the tool.

No hurry for these options...your tool already works very well! :D
User avatar
KuzKuz
Posts: 523
Joined: Mon Aug 19, 2013 5:12 pm
Location: Ukraine

Re: MR Curve Tool

Post by KuzKuz »

Version 2.1 is released. The link in the first post is updated.
User avatar
JoelMayer
Posts: 300
Joined: Sun Apr 05, 2009 8:29 pm

Re: MR Curve Tool

Post by JoelMayer »

I'm getting some weirdness when trying to use the tool. Firstly it seems that it always adds the first point in the middle of the canvas and secondly, when creating beziers, there's mainly glitching happening:

Image

I'm on a M1 Pro Macbook with the latest macOS installed. I tried different viewport settings (GPU on/off, etc.) but all had the same effect.
User avatar
KuzKuz
Posts: 523
Joined: Mon Aug 19, 2013 5:12 pm
Location: Ukraine

Re: MR Curve Tool

Post by KuzKuz »

JoelMayer wrote: Tue Feb 14, 2023 8:36 am I'm getting some weirdness when trying to use the tool. Firstly it seems that it always adds the first point in the middle of the canvas and secondly, when creating beziers, there's mainly glitching happening:

Image

I'm on a M1 Pro Macbook with the latest macOS installed. I tried different viewport settings (GPU on/off, etc.) but all had the same effect.
Oh, I'm sorry. I don't have the opportunity to test on macOS.
Can you temporarily disable all other custom scripts except for this one to make sure that the problem is in this script?
Someone else faced this problem?
User avatar
davoodice2
Posts: 381
Joined: Tue Jun 15, 2021 1:14 pm

Re: MR Curve Tool

Post by davoodice2 »

Fantastic! I completely replaced it with default tool. Thank you.
خیام اگر ز باده مستی خوش باش
با ماهرخی اگر نشستی خوش باش
چون عاقبت کار جهان نیستی است
انگار که نیستی چو هستی خوش باش
User avatar
Greenlaw
Posts: 9576
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: MR Curve Tool

Post by Greenlaw »

Hi Eugene,

Thanks for updating the tool.

I played around with the latest version the other day and I'm not sure the Use Bezier Handles and Threshold options are working as intended...

- When I disable the Use Bezier Handles option, it immediately re-enables when I click in the workspace, even if I don't drag with the tool. I would have expected this to completely disable the ability to activate Bezier mode like

- When I increase the Threshold to a larger value, it seems to work for one click, and then it resets to 0.05.

Maybe I've misunderstood how these options are meant to be used?

Regardless, this is still a wonderful tool...my wrist and finger thanks you very much for it!
User avatar
KuzKuz
Posts: 523
Joined: Mon Aug 19, 2013 5:12 pm
Location: Ukraine

Re: MR Curve Tool

Post by KuzKuz »

Greenlaw wrote: Sun Feb 19, 2023 3:20 am Hi Eugene,

Thanks for updating the tool.

I played around with the latest version the other day and I'm not sure the Use Bezier Handles and Threshold options are working as intended...

- When I disable the Use Bezier Handles option, it immediately re-enables when I click in the workspace, even if I don't drag with the tool. I would have expected this to completely disable the ability to activate Bezier mode like

- When I increase the Threshold to a larger value, it seems to work for one click, and then it resets to 0.05.

Maybe I've misunderstood how these options are meant to be used?

Regardless, this is still a wonderful tool...my wrist and finger thanks you very much for it!
Hello, the script should work like the example below.

There is nothing in the code that would reset the value of threshold to 0.5 except for the default reset tool function.
Could you record a video of how the script works for you?
The only thing that comes to my mind is that the problem with it is conflicts with other scripts.
To check this, you need to temporarily disable all custom scripts and start Moho only with this one.
If the problem disappears, you can try to find which script affects this one.
User avatar
EricTheFish
Posts: 89
Joined: Thu Jun 15, 2017 4:37 pm
Location: Lymm, UK

Re: MR Curve Tool

Post by EricTheFish »

@KuzKuz, I've just been experimenting with the V2 update for bezier and threshold options.
Everything works OK as expected here, I haven't experienced any weirdness. I'm on Win10 and have a bunch of third party scripts installed.
Hope this helps.
EricTheFish
Artist, musician, animator, coder and dabbler in stuff
www.tech-nique.co.uk
User avatar
KuzKuz
Posts: 523
Joined: Mon Aug 19, 2013 5:12 pm
Location: Ukraine

Re: MR Curve Tool

Post by KuzKuz »

EricTheFish wrote: Sun Feb 19, 2023 1:46 pm @KuzKuz, I've just been experimenting with the V2 update for bezier and threshold options.
Everything works OK as expected here, I haven't experienced any weirdness. I'm on Win10 and have a bunch of third party scripts installed.
Hope this helps.
Thank you very much for testing.
User avatar
Greenlaw
Posts: 9576
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: MR Curve Tool

Post by Greenlaw »

Thanks for replying so quickly Eugene! Yes, it's behaving differently here from what I see in your video. The behavior in your video is what I expected.
KuzKuz wrote: Sun Feb 19, 2023 12:31 pm The only thing that comes to my mind is that the problem with it is conflicts with other scripts.
I was thinking that too, but I wanted to make sure I was using your tool as intended first. I'll test it with other scripts disabled and get back to you when I have more information.
User avatar
Greenlaw
Posts: 9576
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: MR Curve Tool

Post by Greenlaw »

Hi Eugene,

I renamed my content folder which forced Moho to create a clean content folder, and then I installed MR Curve Tool to the new content folder. Here's what I'm seeing here.

1. After I disable Use Bezier Handles option, the option re-enables as soon as I click in the workspace, even when I don't drag the mouse.

Image

2. After I increase the default value for Threshold, it resets to 0.05 when I click in the workspace. When I enter the value directly and press enter, it resets to 0.05.

Image

That's pretty weird isn't it?

The download I installed is the Download For Install Script Command version. It's possible I goofed up this install because I've been trying to sync my content folders between multiple computers.

I'm going to try the Download As Simple Zip version next and see if it behaves properly. Will let you know how that goes.

Update: No, the files are identical, so that's not it.
User avatar
Greenlaw
Posts: 9576
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: MR Curve Tool

Post by Greenlaw »

I wondered if it was my computer, which is a desktop running Windows 11, so I tried again on my laptop running Windows 11 and I see the same problems there.

I also found another problem: The styles settings aren't working. If I change the tool's default white fill color to a different color, and change the stroke color from black to another color and increase the default stroke width of 1 to say 10, the tool ignores my settings always draw a white shape with black stroke width of 1. I've been mainly using the tool to create empty curves so I hadn't noticed this till now.

I'm not sure what can make this is behave differently from how it works on your computer. I will let you know if I find anything unusual about Moho on these two computers.
Post Reply