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?
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.