The Time Loop layer can be used to repeat an animation over and over. It loops a section of the layers below and within the same canvas over and over.

+

The {{literal|Time Loop layer}} is used to repeat an animation over and over. It loops a section of the layers below and within the same canvas over and over.

See also the {{l|Convert#Time_Loop|Time Loop ValueNode}} conversion, which can be used to loop the value of a single parameter, rather than an entire layer or group of layers.

See also the {{l|Convert#Time_Loop|Time Loop ValueNode}} conversion, which can be used to loop the value of a single parameter, rather than an entire layer or group of layers.

Line 14:

Line 14:

==Parameters of Time Loop Layers==

==Parameters of Time Loop Layers==

−

These parameters, to prevent undesired modification, by default are {{l|Static_Parameters|statics}}.

+

These parameters, to '''prevent undesired modification''', by default are {{l|Static_Parameters|statics}}.

−

+

−

To animate the parameters of the Time Loop Layer right-click on the 'green guy'-icon of the parameter you want to animate in the Parameters Panel of the Time Loop layer and set {{literal|Allow animation}} and switch to {{L|Animate_Editing_Mode|Animate Edit Mode}}.

+

−

+

−

Once they are no more {{l|Static_Parameters|statics}}, like any other parameters in Synfig they can be animated, so that they change over time. This can be confusing, so make sure you aren't in {{L|Animate_Editing_Mode|Animate Edit Mode}} when working with the Time Loop layer, unless you know what you're doing!

+

The parameters of the time loop layers are:

The parameters of the time loop layers are:

Line 78:

Line 74:

If not checked, and the current time is less than {{Literal|Local Time}}, then {{Literal|Duration}} is taken off the resulting time. This is to provide compatibility with {{l|Time Loop Layer (v0.1)|version 0.1}} of the time loop layer.

If not checked, and the current time is less than {{Literal|Local Time}}, then {{Literal|Duration}} is taken off the resulting time. This is to provide compatibility with {{l|Time Loop Layer (v0.1)|version 0.1}} of the time loop layer.

−

== How to loop ==

+

== How to use the Time Loop Layer ? ==

+

+

The {{literal|Time Loop layer}} repeatedly loops through the {{Literal|Duration}} seconds of its child layers, from {{Literal|Link Time}} to {{Literal|Link Time}} + {{Literal|Duration}}.

+

+

{{Literal|Local Time}} is used to line up the offset of the time looping.

−

The Time Loop layer repeatedly loops through the {{Literal|Duration}} seconds of its child layers, from {{Literal|Link Time}} to {{Literal|Link Time}} + {{Literal|Duration}}. {{Literal|Local Time}} is used to line up the offset of the time looping. When the Time Loop layer is asked to set its time to {{Literal|Local Time}}, it sets the time in its child layers to be {{Literal|Link Time}}, ie. the start of the loop.

+

When the Time Loop layer is asked to set its time to {{Literal|Local Time}}, it sets the time in its child layers to be {{Literal|Link Time}}, ie. the start of the loop.

=== Breaking loop ===

=== Breaking loop ===

# Be Sure you are not in {{l|Animate Editing Mode|Animation Mode}}

# Be Sure you are not in {{l|Animate Editing Mode|Animation Mode}}

−

# In the layer's parameters of the time loop, you need to remove the 'green guy' from {{l|Time_Loop_Layer#Duration_.28time.29|Duration Parameter}}. Just right-click on him and set {{literal|Allow animation}}.

+

# In the layer's parameters of the time loop, you need to remove the 'green guy' ({{l|Image:Animate mode off icon.png|16px}}), indicating that the parameter is {{literal|Static}}, from {{l|Time_Loop_Layer#Duration_.28time.29|Duration Parameter}}. Just right-click on him and set {{literal|Allow animation}}. See {{l|Static Parameters}} for more informations.

# On the {{L|Timebar|timeline}} navigate to a place where you want to break the animation. And now enter the {{l|Animate Editing Mode|Animation Mode}}.

# On the {{L|Timebar|timeline}} navigate to a place where you want to break the animation. And now enter the {{l|Animate Editing Mode|Animation Mode}}.

# In the time loop parameters, set 'Duration' to {{literal|EOT}} (End-of-Time).

# In the time loop parameters, set 'Duration' to {{literal|EOT}} (End-of-Time).

Line 91:

Line 91:

# Now test it. Pay attention, that loop will always break at the very first frame of you animation, so you need to break it in the right place.

# Now test it. Pay attention, that loop will always break at the very first frame of you animation, so you need to break it in the right place.

−

====Detailed explanation====

+

===Detailed explanation===

−

'Green guy' is a guard that says "You shall not pass!" to the animation. So when you attempt to change such parameter in animation mode it just changes the usual way. It's done to prevent unnecessary parameters to be animated, e.g. 'Blend method'.

+

'Green guy' ({{l|Image:Animate mode off icon.png|16px}}) - {{l|Static Parameters}} - is a guard that says "You shall not pass!" to the animation. So when you attempt to change such parameter in animation mode it just changes the usual way. It's done to prevent unnecessary parameters to be animated, e.g. {{l|Blend Method Parameter|Blend Method}}.

−

Setting 'Duration' to EOT. If you set it to 0f, then the whole animation will stop, because you try to play it from 0f (local time) to 0f (duration). And EOT means it'll continue to play your animation to the end of the time...

+

Setting {{Literal|Duration}} to {{literal|EOT}}. If you set it to 0f, then the whole animation will stop, because you try to play it from 0f ({{Literal|local time}}) to 0f ({{Literal|Duration}}). And EOT means it'll continue to play your animation to the end of the time...

−

Removing waypoint after current one. If you skip this step, then at the next waypoint 'Duration' parameter will be restored to the value before current waypoint. It's a standard Synfig's behavior, but there's a magical button somewhere that can change it.

+

Removing {{l|Waypoint|waypoint}} after current one. If you skip this step, then at the next waypoint {{Literal|Duration}} parameter will be restored to the value before current waypoint. It's a standard Synfig's behavior, but there's a magical button somewhere that can change it.

−

Converting current waypoint to the constant. Without it, 'Duration' will be smoothly interpolated from value you set to the EOT and the constant type will just set immediately at the waypoint. Interpolation can be a bit confusing sometimes, so you better read this: http://wiki.synfig.org/Waypoint

+

Converting current waypoint to the constant. Without it, {{Literal|Duration}} will be smoothly interpolated from value you set to the EOT and the constant type will just set immediately at the waypoint. Interpolation can be a bit confusing sometimes, so you better read this about {{l|Waypoint|waypoints}}.

Breaking loop

In the layer's parameters of the time loop, you need to remove the 'green guy' (), indicating that the parameter is "Static", from Duration Parameter. Just right-click on him and set "Allow animation". See Static Parameters for more informations.

Now you have three waypoints. One before the current, we left it as it is. One is current, we convert it to the "constant" (right-click on it -> Both -> Constant). And one after current, this one have to be removed (right-click on it -> Remove).

Now test it. Pay attention, that loop will always break at the very first frame of you animation, so you need to break it in the right place.

Detailed explanation

'Green guy' () - Static Parameters - is a guard that says "You shall not pass!" to the animation. So when you attempt to change such parameter in animation mode it just changes the usual way. It's done to prevent unnecessary parameters to be animated, e.g. Blend Method.

Setting "Duration" to "EOT". If you set it to 0f, then the whole animation will stop, because you try to play it from 0f ("local time") to 0f ("Duration"). And EOT means it'll continue to play your animation to the end of the time...

Removing waypoint after current one. If you skip this step, then at the next waypoint "Duration" parameter will be restored to the value before current waypoint. It's a standard Synfig's behavior, but there's a magical button somewhere that can change it.

Converting current waypoint to the constant. Without it, "Duration" will be smoothly interpolated from value you set to the EOT and the constant type will just set immediately at the waypoint. Interpolation can be a bit confusing sometimes, so you better read this about waypoints.

Visualized Example

For example, suppose:

Link Time is 5s

Duration is 3s

Local Time' is 4s

And suppose that the Time Loop layer is applied over an existing animation. The "Link Time" and "Duration" specify that the section from 5s to 8s in the children layers will be looped. The "Local Time" specifies that this loop will be at the beginning at 4s. (And so also therefore at 1s, 7s, 10s, etc).

This is how the mapping actually works:

real time

child time(symmetrical = true)

child time(symmetrical = false)

0

7

4

1

5

2

2

6

3

3

7

4

4

5

5 (local time = 4; link time = 5)

5

6

6

6

7

7

7

5

5 (duration = 3, so loop repeats after 3 seconds)

8

6

6

9

7

7

10

5

5

Specifying a huge number for the Duration parameter effectively turns the Time Loop layer into a Time Shift layer. The Link Time and Local Time parameters controls which time in the children lines up with which time in the Time Loop layer, giving the amount of the timeshift, with both positive and negative differences working as expected.

Contrived Example

It's a 10 second animation, and shows 2 circles. The top one moves linearly from the left to the right. Its position is marked by static text digits 0 through 10.

The other circle is an identical copy of the first one, with the same waypoints, but it's inside an Group layer. The parameters are:

Link Time: 5s

Duration: 1.5s

Local Time: 2s

Symmetrical: true

So as time=2s, the top circle is at position 2 (local time) and the bottom circle is at position 5 (link time):

The loop is 1.5s long, so the bottom circle is also at position 5 every 1.5 seconds before and after this point in time, for example at t=3.5s and at t=8s:

The following two images show the positions at t=0s and t=3s. The loop starts at t=2s, so it's also at the start at t=0.5s. So at t=0s it's half a second before finishing the previous loop. And at t=3s the same is true, but 2 loops later on:

Documentation

Wiki

Search

Tools

Content of this Synfig Studio Documentation Wiki is available under the terms of Creative Commons Attribution-Share Alike 3.0 license.
By contributing here you agree that the same license will be applied to your writing. If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it to this wiki. You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!