SPLIT ROTOPAINT NODE

This script takes a RotoPaint node and separates it in several nodes, this can help when you have too many shapes in the same node, so it kind of helps to optimize your script. This works with most of the RotoPaint shapes (clones, beziers, splines, blur, sharpen, smear, dodge, burn) It doesn't work with Eraser and Reveal (as these options depend on the content in the RotoPaint, behind the Eraser, or require the BG connected to reveal, so these are not going to work with the script.) Another consideration is that all the shapes must be in the root layer. As a recommendation I suggest to copy the node you want to split to a new file, run the script there and then bring back the nodes to your work area, this because it takes time to process the script.

SplitRotoWork.jpg