|
|
|
@ -1,5 +1,6 @@ |
|
|
|
using System.Buffers; |
|
|
|
using System.Buffers; |
|
|
|
using System.IO.Pipelines; |
|
|
|
using System.IO.Pipelines; |
|
|
|
|
|
|
|
using System.Text.Json; |
|
|
|
using CliWrap; |
|
|
|
using CliWrap; |
|
|
|
using ErsatzTV.Core; |
|
|
|
using ErsatzTV.Core; |
|
|
|
using ErsatzTV.Core.Graphics; |
|
|
|
using ErsatzTV.Core.Graphics; |
|
|
|
@ -80,9 +81,12 @@ public class ScriptElement(ScriptGraphicsElement scriptElement, ILogger logger) |
|
|
|
pixelFormat, |
|
|
|
pixelFormat, |
|
|
|
SKAlphaType.Unpremul); |
|
|
|
SKAlphaType.Unpremul); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
string json = JsonSerializer.Serialize(context.TemplateVariables); |
|
|
|
|
|
|
|
|
|
|
|
Command command = Cli.Wrap(scriptElement.Command) |
|
|
|
Command command = Cli.Wrap(scriptElement.Command) |
|
|
|
.WithArguments(scriptElement.Arguments) |
|
|
|
.WithArguments(scriptElement.Arguments) |
|
|
|
.WithWorkingDirectory(FileSystemLayout.TempFilePoolFolder) |
|
|
|
.WithWorkingDirectory(FileSystemLayout.TempFilePoolFolder) |
|
|
|
|
|
|
|
.WithStandardInputPipe(PipeSource.FromString(json)) |
|
|
|
.WithStandardOutputPipe(PipeTarget.ToStream(pipe.Writer.AsStream())); |
|
|
|
.WithStandardOutputPipe(PipeTarget.ToStream(pipe.Writer.AsStream())); |
|
|
|
|
|
|
|
|
|
|
|
logger.LogDebug( |
|
|
|
logger.LogDebug( |
|
|
|
|