# * Add 2 second gap between clips # * # * Version: 1.0 # * Author: Harold Linke # * Date: October 6, 2018 # * Copyright: Harold Linke 2018 # * VEGASPython: https://www.hlinke.de/dokuwiki/doku.php?id=en:vegas_python # * VEGASPython on Github: https://github.com/haroldlinke/VEGASPython # * # * based on JScript script by: Edward Troxel # * www.jetdv.com/tts # * Modified: 05-29-2003 # * # * History of Change # * V1.00 06.10.2018 - Harold Linke - adaptation for VEGASPython # * # import clr clr.AddReference('ScriptPortal.Vegas') import ScriptPortal.Vegas from ScriptPortal.Vegas import * import sys def FromVegas(myVEGAS: Vegas): Gap = Timecode.FromString("00:00:02.00") #step through all selected video events for track in myVEGAS.Project.Tracks: tracktime = Gap for evnt in track.Events: evnt.AdjustStartLength(tracktime, evnt.Length, True) # workaround timecode + timecode is not possible tracktime = Timecode(tracktime.ToMilliseconds() + evnt.Length.ToMilliseconds() + Gap.ToMilliseconds()) if __name__ == "__main__": FromVegas(pyVEGAS)