Well, the art brush is working and I think it’s in a good state to release. There’s a good chance I’m going to do more work on it eventually but I think it’s to a point where people will be able to use it productively. As another example of what you can do with this tool, I present the following eye candy that I knocked together real quick-like:
This tool is a JSFL command that will take the currently selected symbol from your document’s library and map it onto the currently selected path on the stage. This means you can now create complex designs and apply them as brush strokes in your Flash files. There are a few considerations, though, when using this too. If you aren’t very keen on reading, skip ahead to the video, where I cover most of these things in glorious color:
- The symbol you use as a brush must contain only raw shape data. Anything other than raw shapes, or anything at all that appears in a frame other than the first one on the top layer, will be ignored when applying the brush stroke.
- At the moment there’s no way to control the direction in which the brush is applied. Flash is weird about how it orders its edges, so you may end up having to have two brushes for each type of stroke you want – one in one direction and a second in the other. This is pretty easy to do by just duplicating a symbol and rotating its contents 180 degrees. Just make sure when you do that that you deselect the symbol’s contents when you’re done. Another of Flash’s idiosyncrasies is that it doesn’t really finalize the new position of a shape after a rotation until you deselect it. So if you forget to deselect it the art brush tool won’t even realize that the rotation took place.
- In your brush symbol you can use any colors, transparencies, stroke styles, etc, but beware of using bitmap and gradient fills. The fill’s transform will be reset when applied as an art brush, so it may not end up looking like you had intended.
- When creating a new symbol to use as an art brush, remember that the brush will be applied as if the stroke is horizontal through the middle.
- The art brush command doesn’t create any new vertices. This means that some symbols with few vertices won’t work well when applied to complex paths. The easy fix for this is to use my other new tool, Add Vertices, to increase the vertex count in your brush symbol. This will make it follow the path more faithfully.
- If your brush symbol has a large height (that is, the width of the brush stroke) and you apply it to a tight curve, there’s a good chance that it’ll overlap itself, causing some negative space. There isn’t really anything I can reasonably do about it programmatically, so you’ll just have to be careful in how you apply your wide brushes.
- The art that’s applied when you run the Art Brush tool is created inside a group, making it easy to select with a single click, delete, move, etc. The path that you applied it to still exists, ungrouped, but the tool cranks its alpha down to zero, effectively making it invisible.
- Unfortunately the Art Brush tool only works in Flash CS4 or later.
And here’s a video explaining the tool and giving a few pointers on using it:
As a final bonus, I’m also releasing a tool that I made on the way to creating the art brush tool. It takes the currently selected symbol and places it periodically along the selected path. Something like this:
Without further ado, below are the tools for your downloading pleasure. If you download the Art Brush tool I’d strongly suggest you also get the Add Vertices tool to help whip uncooperative brush symbols into shape:
If you have any questions or comments I would love to hear them. If you have any trouble with the tools I would like to hear about that too. There may still be bugs remaining and I want to squash them as soon as I can.
Update April 7th 2010
I’ve modified the Art Brush tool so that you no longer need to worry about whether there are enough vertices in the brush symbol. Add Vertices is now no longer necessary (though I’m leaving it up, since people may find another use for it still).
Update October 2nd 2010
I’ve released yet another version of the art brush, New and Improved™. Check out my new post for more info on what’s changed: