mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-19 14:10:14 -05:00
Add support for Curve objects in smooth() ranges.
This commit is contained in:
parent
5f11345fc9
commit
7ad6dc2d5f
1 changed files with 2 additions and 0 deletions
|
@ -2073,8 +2073,10 @@ var Path = PathItem.extend(/** @lends Path# */{
|
|||
? _default
|
||||
: typeof value === 'number'
|
||||
? value
|
||||
// Support both Segment and Curve through getIndex()
|
||||
: value.getIndex
|
||||
? value.getIndex()
|
||||
+ (_default && value instanceof Curve ? 1 : 0)
|
||||
: _default;
|
||||
// Handle negative values based on whether a path is open or not:
|
||||
// Closed paths are wrapped around the end (allowing values to be
|
||||
|
|
Loading…
Reference in a new issue