How do you make a line with round edges?

Wondering how to accomplish a certain animation task? Ask here.

Moderators: Víctor Paredes, Belgarath, slowtiger

Post Reply
User avatar
Nephilim
Posts: 100
Joined: Sun Mar 11, 2007 3:55 am
Location: USA

How do you make a line with round edges?

Post by Nephilim »

Is there any way to do this without making a filled shape? Like if I'm writing some words freehand. Is there an effect in which you can round the edges of the lines? Almost all other animation programs can do this and sometimes it would look better then always having a blunt edge on your lines.

Thanks.
~neph
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

Are you talking about rounded tips or ends?

To do that I use a brush for the stroke. A perfectly round circle PNG placed in the brushes folder of AS.

The trick is getting the round brush to be EXACTLY or just a tad smaller than the thickness of the line width.

This is necessary to avoid rough edges on the strokes because the spacing needs to be very low to keep the rounded tips on both ends of a stroke. Usually a brush on a stroke will only force the brush image on one end. The other end is determined by the length of the stroke. A trick I use is to create small separate shapes just on the ends of a long stroke with a low spacing value.

Here is a render to show the results:
Image

You can use this PNG image as a brush by placing it in your brushes folder:
Image

This is a more "complex" technique I came up with by joining two separate lines in a unique way so both ends AND "corners" always have a brush image. Basically two lines that are drawn in "opposite" directions are connected in the middle... sort of... so that each end is also the beginning. They meet in the center but maintain a smooth stroke. A Moho file is included in the zip.

http://www.lowrestv.com/moho_stuff/capped_ends.mov
http://www.lowrestv.com/moho_stuff/capped_ends.zip

-vern
human
Posts: 688
Joined: Tue Jan 02, 2007 7:53 pm

Post by human »

heyvern wrote:A Moho file is included in the zip.

http://www.lowrestv.com/moho_stuff/capped_ends.mov

-vern
Dang! It's a gol-durn Coral Snake! :lol:
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

human wrote:Dang! It's a gol-durn Coral Snake! :lol:
"There's a snake in my boots!"

There is a drawback to brush strokes like this. Due to how they are rendered by AS they can appear a bit... "jaggy" which is more noticeable at smaller sizes/stroke widths. I suppose you could render out at a larger resolution and size it down in post.

Making the brush image a larger size doesn't help and brush images aren't effected by the smooth images render option either.

Capped ends for strokes would be a nice feature in AS... and of course I forgot to put that one on my list. ;)

-vern
User avatar
Nephilim
Posts: 100
Joined: Sun Mar 11, 2007 3:55 am
Location: USA

Post by Nephilim »

For someone reason, when I use your circle image file as a brush it loses its anti aliasing. How did you get your first picture to be smooth? When I look at the image in the brush menu it is jagged but in the brush folder it is fine. What settings should I use for the brush? (Jitter angle, etc.)
~neph
User avatar
heyvern
Posts: 7035
Joined: Fri Sep 02, 2005 4:49 am

Post by heyvern »

I use two stroke shapes..

One for the "line" and one for the capped ends using the brush.

The brush image needs to be just a hair smaller so it is covered by the other stroke shape that is set to the same width and color. It could be that the image for the brush I posted isn't the correct version and I will check on this. I recall that this was trial and error in Photoshop and I had several versions.

There should be 0 jitter and a low number for the spacing (1-5). It is the spacing of the brush that causes the "aliasing" effect. Also as I mentioned in my previous post brush images used this way will have a jagged edge. It's a judgement call. It is a workaround for not having capped ends in AS... yet. Even with a 1 spacing there are gaps on the brush images. That is why a second stroke shape is needed to smooth that out.

In many cases I only add a small second shape on the ends. I create a sort of "doubled" tip that has two points close together and one is doubled back creating a single capped end brush image for the stroke tip.

-vern
Post Reply