Files
ersatztv/ErsatzTV.Core/Interfaces/Streaming/GraphicsEngineContext.cs
Jason Dove 5d081ceeff fix editorconfig and run code cleanup (#2324)
* fix formatting rules

* reformat ersatztv

* reformat ersatztv.application

* reformat ersatztv.core

* refactor ersatztv.core.tests

* reformat ersatztv.ffmpeg

* reformat ersatztv.ffmpeg.tests

* reformat ersatztv.infrastructure

* cleanup infra mysql

* cleanup infra sqlite

* cleanup infra tests

* cleanup ersatztv.scanner

* cleanup ersatztv.scanner.tests

* sln cleanup

* update dependencies
2025-08-16 14:44:48 +00:00

43 lines
1.2 KiB
C#

using ErsatzTV.Core.Domain;
using ErsatzTV.Core.FFmpeg;
using ErsatzTV.Core.Graphics;
namespace ErsatzTV.Core.Interfaces.Streaming;
public record GraphicsEngineContext(
string ChannelNumber,
MediaItem MediaItem,
List<GraphicsElementContext> Elements,
Resolution SquarePixelFrameSize,
Resolution FrameSize,
int FrameRate,
DateTimeOffset ChannelStartTime,
DateTimeOffset ContentStartTime,
TimeSpan Seek,
TimeSpan Duration);
public abstract record GraphicsElementContext;
public record WatermarkElementContext(WatermarkOptions Options) : GraphicsElementContext;
public record TextElementDataContext(TextGraphicsElement TextElement, Dictionary<string, string> Variables)
: GraphicsElementContext, ITemplateDataContext
{
public int EpgEntries => TextElement.EpgEntries;
}
public record ImageElementContext(ImageGraphicsElement ImageElement) : GraphicsElementContext;
public record SubtitleElementDataContext(
SubtitlesGraphicsElement SubtitlesElement,
Dictionary<string, string> Variables)
: GraphicsElementContext, ITemplateDataContext
{
public int EpgEntries => SubtitlesElement.EpgEntries;
}
public interface ITemplateDataContext
{
int EpgEntries { get; }
}