Page 1 of 1

Set all layers to Hold|Ping-Pong|None|Repeat

Posted: 16 Sep 2022, 03:02
by cgmodeler
Just did this small script that sets all the layers for the current clip post behavior as none, repeat, ping-pong or hold

It has a little window to write the desired post behavior.

It will store it as a variable for the next session so you can run it quickly

Eg. If I want all layers on the current clipto be HOLD, I write "hold"
layers.jpg
layers.jpg (6.55 KiB) Viewed 5802 times
LayerPostBehavior.tvpx
(55 KiB) Downloaded 362 times

Code: Select all

Param None
tv_readUserString "postBehaviorVar" "postBehavior" Hold
parse result postBehavior
tv_reqstring "Input the mode for all layers none, repeat, ping-pong, hold |"postBehavior""
parse result postBehavior


IF (CMP("Cancel",postBehavior)!=1)
	tv_writeUserString "postBehaviorVar" "postBehavior" postBehavior
END

PARAM none
tv_readUserString "postBehaviorVar" "postBehavior" Hold
parse result postBehavior

layerCount = 0
loop2 = 1
WHILE loop2
tv_LayerGetID layerCount
currentLayerID = result
IF CMP(currentLayerID,"none") == 1
loop2 = 0
ELSE
tv_LayerSet currentLayerID
tv_layerpostbehavior 0 postBehavior
layerCount = LayerCount + 1
END
END

Re: Set all layers to Hold|Ping-Pong|None|Repeat

Posted: 16 Jan 2023, 13:14
by NathanOtano
Useful thanks! :)