Minor tweak to ASP6's freehand tool

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

Moderators: Víctor Paredes, Belgarath, slowtiger

User avatar
Blue
Posts: 157
Joined: Fri Jul 03, 2009 1:55 am
Location: Los Angeles
Contact:

Post by Blue »

Wow! The solid fill drawing works great Rudiger! Bravo!

Three features I'd love to see:

1. Ability to adjust the width. For instance, using my Wacom I could not get the line to go thick enough, so I had to go to the original drawing tool change the width to 8 (in the Style menu) then go back to your tool. The width in the Style menu is grayed out when using your drawing tool.

2. Ability to have overlapping shapes combine into one shape. This could be in the drawing tools menu or maybe as a separate tool.

3. Ability to erase by drawing over areas. Would be great if I could turn my Wacom pen around and naturally erase with that end (that might be asking too much).
joelstoryboards.com - (WinXP SP3, ASP 6.1)
Rudiger
Posts: 786
Joined: Sun Dec 18, 2005 2:25 am

Post by Rudiger »

Blue wrote:Wow! The solid fill drawing works great Rudiger! Bravo!

Three features I'd love to see:

1. Ability to adjust the width. For instance, using my Wacom I could not get the line to go thick enough, so I had to go to the original drawing tool change the width to 8 (in the Style menu) then go back to your tool. The width in the Style menu is grayed out when using your drawing tool.

2. Ability to have overlapping shapes combine into one shape. This could be in the drawing tools menu or maybe as a separate tool.

3. Ability to erase by drawing over areas. Would be great if I could turn my Wacom pen around and naturally erase with that end (that might be asking too much).
Hi Blue,

With regards to 1, there must be something else going on, as the width in the Style menu is not grayed out when I'm using my version of the freehand tool. Anyone else?

With regards to 2 and 3, that's the plan, but it'll probably take a long time as I only ended up getting 2 donations. The first thing I want to try is self-intersection. Imagine how cool it would be to be able to madly shade a region with the freehand tool and then get left with a single smooth outline shape of the whole region!
User avatar
Blue
Posts: 157
Joined: Fri Jul 03, 2009 1:55 am
Location: Los Angeles
Contact:

Post by Blue »

Post a Paypal Donate button on one of your web pages. I don't have a PayPal account, and do not want to create one, so can not email you money. Or look into Google Checkout.
joelstoryboards.com - (WinXP SP3, ASP 6.1)
User avatar
ulrik
Posts: 1087
Joined: Thu Aug 11, 2005 10:32 pm
Location: Stockholm Sweden
Contact:

Post by ulrik »

Rudiger wrote: With regards to 1, there must be something else going on, as the width in the Style menu is not grayed out when I'm using my version of the freehand tool. Anyone else?
No not here, the line width is adjustable, but I have other issues, this is happening when I have these buttons checked:

Auto-stroke - working fine, only a single stroke with working line width.
Auto-stroke + Stroke-fill - nothing works, no fill, no stroke, only paths (construction lines)
Stroke-fill - only paths
Auto-fill - works with either Auto-close or Auto-weld checked I can't get it to close without one of them checked.
Auto-fill + Auto stroke - works when one of the close or weld buttons are checked, makes a fill and outline, can't get it to close without them checked.
Stroke-fill alone - gets nothing, if I start a new document and make the first stroke with only "Stroke-fill" checked I get a Lua error saying: M_Mesh:Shape - out of range
Auto-stroke + Stroke-fill + Auto-fill - makes a stroke fill but no outline( only paths)

I'm using AS Pro 6.1 on a ppc mac running osx 10.5.8
Rudiger
Posts: 786
Joined: Sun Dec 18, 2005 2:25 am

Post by Rudiger »

ulrik wrote:
Rudiger wrote: With regards to 1, there must be something else going on, as the width in the Style menu is not grayed out when I'm using my version of the freehand tool. Anyone else?
No not here, the line width is adjustable, but I have other issues, this is happening when I have these buttons checked:

Auto-stroke - working fine, only a single stroke with working line width.
Auto-stroke + Stroke-fill - nothing works, no fill, no stroke, only paths (construction lines)
Stroke-fill - only paths
Auto-fill - works with either Auto-close or Auto-weld checked I can't get it to close without one of them checked.
Auto-fill + Auto stroke - works when one of the close or weld buttons are checked, makes a fill and outline, can't get it to close without them checked.
Stroke-fill alone - gets nothing, if I start a new document and make the first stroke with only "Stroke-fill" checked I get a Lua error saying: M_Mesh:Shape - out of range
Auto-stroke + Stroke-fill + Auto-fill - makes a stroke fill but no outline( only paths)

I'm using AS Pro 6.1 on a ppc mac running osx 10.5.8
At the moment, you need to have either Auto-Fill or Auto-Close checked for the Stroke-Fill option to work, and it doesn't make a lot of sense to use it without Auto-Fill selected. I'll probably get around to fixing the "shape - out of range" error in the next release, but it's fairly low priority.
User avatar
ulrik
Posts: 1087
Joined: Thu Aug 11, 2005 10:32 pm
Location: Stockholm Sweden
Contact:

Post by ulrik »

Rudiger wrote:
ulrik wrote:
Rudiger wrote: With regards to 1, there must be something else going on, as the width in the Style menu is not grayed out when I'm using my version of the freehand tool. Anyone else?
No not here, the line width is adjustable, but I have other issues, this is happening when I have these buttons checked:

Auto-stroke - working fine, only a single stroke with working line width.
Auto-stroke + Stroke-fill - nothing works, no fill, no stroke, only paths (construction lines)
Stroke-fill - only paths
Auto-fill - works with either Auto-close or Auto-weld checked I can't get it to close without one of them checked.
Auto-fill + Auto stroke - works when one of the close or weld buttons are checked, makes a fill and outline, can't get it to close without them checked.
Stroke-fill alone - gets nothing, if I start a new document and make the first stroke with only "Stroke-fill" checked I get a Lua error saying: M_Mesh:Shape - out of range
Auto-stroke + Stroke-fill + Auto-fill - makes a stroke fill but no outline( only paths)

I'm using AS Pro 6.1 on a ppc mac running osx 10.5.8
At the moment, you need to have either Auto-Fill or Auto-Close checked for the Stroke-Fill option to work, and it doesn't make a lot of sense to use it without Auto-Fill selected. I'll probably get around to fixing the "shape - out of range" error in the next release, but it's fairly low priority.
I see, yes you're right about the stroke fill.
A short question, are you planning to make the auto close and auto weld work together with stroke fill? I can see some nice things to do with that option, a fill with an auto filled outline.

btw, I forgot to say thank you for the great tool!! :D
Rudiger
Posts: 786
Joined: Sun Dec 18, 2005 2:25 am

Post by Rudiger »

Blue wrote:Post a Paypal Donate button on one of your web pages. I don't have a PayPal account, and do not want to create one, so can not email you money. Or look into Google Checkout.
Google Checkout is a no go, at least at the moment, as you have to be in the US or the UK to register as a merchant. I like the idea of creating a website featuring a PayPal Donate button though. It's high time I collected all my scripts together in a central place anyway! The only thing is, it'll eat into my script writing time, as I've had no real experience with website development.
chucky
Posts: 4650
Joined: Sun Jan 28, 2007 4:24 am

Post by chucky »

Nice tool Rudiger,
thanks. :D
User avatar
jahnocli
Posts: 3471
Joined: Fri Oct 29, 2004 2:13 pm
Location: UK

Post by jahnocli »

Rudiger wrote:It's high time I collected all my scripts together in a central place anyway! The only thing is, it'll eat into my script writing time, as I've had no real experience with website development.
Buy a template. Most of them are dead easy to work with, and there is no shortage of sites out there selling them fairly cheaply. Same with hosting. If you get into difficulties, post in here -- someone witll help you out...!
You can't have everything. Where would you put it?
User avatar
BA
Posts: 196
Joined: Tue Mar 08, 2005 7:28 pm
Location: Griddleville
Contact:

Post by BA »

I just upgraded to ASpro 7.1 (from 7) and suddenly the very cool fill-stroke option in your tool is no longer available. It worked perfectly in version 7. What's up with that???
User avatar
BA
Posts: 196
Joined: Tue Mar 08, 2005 7:28 pm
Location: Griddleville
Contact:

Post by BA »

Uhh... well, I just replaced your 'originalwidth' freehand tool with the latest one, and now stroke-fill seems to work again in 7.1 (might useful feature by the way, thanks!)

so... disregard previous message.

please continue awesome scripting work (haven't been on the forum for a while, so I'm playing catch-up)
Create cartoon characters and comics in minutes: www.bitstrips.com
Rudiger
Posts: 786
Joined: Sun Dec 18, 2005 2:25 am

Post by Rudiger »

I have added a link to the latest version of my modified freehand tool to the original post of this thread.

Here are some of the new features:

If you hold down the <Ctrl> key you can click out a polygon. To terminate the polygon just release the <Ctrl> key before the last click. If you want to terminate without adding another point, press <Ctrl>-c. If you want the polygon to have sharp corners, make sure the Sharp Corners checkbox is checked. This also turns on the sharp corners feature for freehand drawing that was introduced in AS 7.

Also, the width of the filled stroke is now controlled by a separate parameter instead of the style settings. This means you can draw filled strokes with an outline, which is kind of cool.

I'm still working on the feature to add and subtract strokes from previous shapes. The basic concept is there, but there's a bit of a bug infestation going on the moment :).
Post Reply