0

I need to be able to draw a thick patterend line between 2 points in AS3, I can't use the draw API because it doesn't all me to actually put detail (pattern etc) into the thickness of the line, I thought about perhaps using the line to create a bitmap version and then using that as a mask, but I remember many years ago seeing some examples that use a movieclip as a source for a line, but I can't find examples of that now at all, any ideas?

I've attached an example image of how I want the line to look.enter image description here

Phil
  • 2,995
  • 6
  • 40
  • 67

1 Answers1

3

I suspect Graphics.lineBitmapStyle() will do the trick. If you want to use a Sprite or MovieClip as the source, you'll have to draw() it to a BitmapData first. The example code on that later link should get you up and running with that.

grapefrukt
  • 27,016
  • 6
  • 49
  • 73
  • thanks, I got that working, but it gives a mask like effect, which after seeing it, is not what I want, I need it to look like I'm stretching out a line which has a pattern (movieclip) on it, not like I'm just moving a line-mask around over the top of a pattern, which is what lineBitmapStyle gives you. – Phil Apr 06 '12 at 13:16
  • 2
    If you expand your original question to cover how you want it to look it will be a lot easier to give pointers. – grapefrukt Apr 06 '12 at 13:18