Outputs a clip. Less to type.
Designed to be used with the good ol 'from vodesfunc import *' and the 'out' alias
Source code in vodesfunc/util.py
| def set_output(
clip: vs.VideoNode, name: str | None = None, frame_info: bool = False, allow_comp: bool = True, cache: bool | None = None, **kwargs: KwargsT
) -> vs.VideoNode:
"""
Outputs a clip. Less to type.
Designed to be used with the good ol 'from vodesfunc import *' and the 'out' alias
"""
if frame_info and name:
clip = _print_frameinfo(clip, name)
try:
args = KwargsT(name=name, cache=cache, disable_comp=not allow_comp)
if kwargs:
args.update(**kwargs)
from vspreview import is_preview, set_output as setsu_sucks
if cache is None:
cache = is_preview()
setsu_sucks(clip, **args)
except:
if name is not None:
clip = clip.std.SetFrameProp("Name", data=name)
clip.set_output(len(vs.get_outputs()))
return clip
|