|
Hi!,
I think that it is more simple than you can think. Continuing with the flower example:
Online Canvas
-Duplicate layer (amount =5)
-Online Canvas (x=indexA *2, y=0)
--Duplicate layer (amount=8 )
--Petal (canvas)
---Rotate (angle=45*indexB) (0,45, 90, 135, 180, 125, 270, 315)
---Petal
The first duplicate would duplicate also the indexB, so we finally we would have following petals duplications:
indexA=0 (indexB=0,1,2,3,4,5,6,7)
indexA=1 (indexB=0,1,2,3,4,5,6,7)
indexA=2 (indexB=0,1,2,3,4,5,6,7)
indexA=3 (indexB=0,1,2,3,4,5,6,7)
indexA=4 (indexB=0,1,2,3,4,5,6,7)
Total 40 petals.
Regarding to Yoyobuae comments I think that it is better to have a convert type that can be used by the Duplicate layer as the index. For example:
Convert type: Index
Sub-params:
<param> link
<param> Increment
Link can be Real, Integer, Angle, Time, (anything more?) and can be an animated value.
Increment is a value of the same type than link that can also be animated. It represents how much should you add to Link for each new duplicated layer
When Duplicate layer find that parameter then it would return this:
Link + index*Increment
where index is 0 for the original layer, 1 for the next, 2 for the next, and so on.
Until it reaches the Amount-1 value of the Duplicate Layer
What we can do is that nested convert types means to use a higher parent index.
For example:
Positionx (Index)
Link (index)
- Link = 0.0 (Real)
- Increment = 1.0 (Real)
Increment =1.0 (Real)
Positiony (Index)
Link =0.0 (Real)
Increment =1.0 (Real)
Then if those parameters are over two Duplicate Layers then it would produce:
x=0.0 y=0.0; x=1.0 y=0.0; x=2.0 y=0.0....
x=0.0 y=1.0; x=1.0 y=1.0; x=2.0 y=1.0....
x=0.0 y=2.0; x=1.0 y=2.0; x=2.0 y=2.0....
...
-G
_________________ Synfig needs your help! Developers, packagers, bug testers, translators, artists, web developers, wiki writers... you can contribute!
|