M. Scott Veach
unread,May 4, 2013, 6:28:09 PM5/4/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to pap...@googlegroups.com
Hi, I'm newish to JS and paper.js; so I apologize if I've missed something obvious.
1) Is there a way to easily give a path a strokeWidth that tapers or widens? I don't mean
does this in an animation but rather instead of a having a constant strokeWidth along the
length of the path, it starts out with one strokeWidth and then as move along the path it
either widens or tapers to a different strokeWidth?
Since, strokeWidth is a property of Path, I haven't found an easy to get this effect.
2) This is probably really basic, but consider the following two lines of code:
var anArrayOfSegments = aPath.segments();
aPath.remove();
in the above example, is anArrayOfSegments guaranteed to be defined? I'm using these lines
and it's working but it dawned on me that I might be getting lucky. Does that first line copy
the array of segments or just give anArrayOfSegments a reference to one? And if it's the latter,
does that mean once I've called aPath.remove() that memory is up-for-grabs?
Thanks for any information/help!
Scott.