Say I have some footage that is 30 frames long, and I want to to apply a mask to it via mix nodes that is 3 frames long. I need it to loop 10 times to cover all my frames. How do I do this in the compositor? If it's not possible in the compositor, can it be done in the sequence editor?
-
$\begingroup$ What is your exact intention of using a mask? A mask of 3 frames repeated 10 times doesn't make much sense to me... Or are this just example lengthes? $\endgroup$– SamothCommented Nov 23, 2015 at 10:16
-
$\begingroup$ Maybe this helps? youtube.com/… $\endgroup$– SamothCommented Nov 23, 2015 at 10:22
-
$\begingroup$ It's just example lengths. $\endgroup$– AscalonCommented Nov 23, 2015 at 21:52
-
3$\begingroup$ Export your mask as a black and white image sequence. Re-import it as as an image sequence in the compositor and enable the Cyclic option. $\endgroup$– user1853Commented Nov 26, 2015 at 4:00
-
$\begingroup$ Yo Cegaton, you should put that answer into an answer. $\endgroup$– Spencer BrownCommented Nov 26, 2015 at 4:13
2 Answers
Let's say your setup on the compositor is like this:
Unplug the input from the mix node and make the colors black and white and render the mask as an image sequence.
And import them as an image sequence node:
And use the sequence instead of the mask node.
Make sure the cyclic and auto refresh options are enabled.
The mask will be used in an endless cycle:
The main disadvantage of this solution is that if you need to make changes on the mask's shape you have to re-export/re-load the images.
A labor intensive solution would be to copy the keyframes for the mask.
Go to the Dope Sheet window and enable Mask Mode.
Then select the keyframes for the mask (press A to select all), duplicate them (ShiftD) and move them over on the time line (press G to move), duplicate again as needed to get as many iterations of the mask you need.
Even tough this solution seems a bit more tedious, editing and re-shaping the masks is quite easy. Also if you need to change the order in which the mask changes shape you just need to re-order the key frames.