add scripted control instructions (#2341)
* add start_epg_group, stop_epg_group * fix imports * add graphics_on, graphics_off * add skip_items * add skip_to_item * add watermark_on, watermark_off
This commit is contained in:
@@ -50,6 +50,14 @@ public class ScriptedPlayoutBuilder(
|
||||
var engine = Python.CreateEngine();
|
||||
var scope = engine.CreateScope();
|
||||
|
||||
string scriptPath = Path.GetDirectoryName(playout.ScheduleFile);
|
||||
if (!string.IsNullOrWhiteSpace(scriptPath) && localFileSystem.FolderExists(scriptPath))
|
||||
{
|
||||
ICollection<string> paths = engine.GetSearchPaths();
|
||||
paths.Add(scriptPath);
|
||||
engine.SetSearchPaths(paths);
|
||||
}
|
||||
|
||||
var sys = engine.GetSysModule();
|
||||
var modules = (PythonDictionary)sys.GetVariable("modules");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user