namespace AmiReel.Models; public enum EncoderMode { Auto, NvidiaNvenc, CpuX264 } /// /// One render job's parameters. Uses named init properties rather than a positional /// constructor: TrimStart/FadeSeconds/EndCardHoldSeconds are three consecutive /// members (and Width/Height/FramesPerSecond/ThumbnailWidth/ /// ThumbnailHeight five consecutive members), so a positional /// record would let arguments be silently transposed at a call site without the /// compiler catching it. /// public sealed record RenderSettings { public required IReadOnlyList InputFiles { get; init; } public required string EndCardPath { get; init; } public required string OutputDirectory { get; init; } public required string OutputName { get; init; } public required string FfmpegPath { get; init; } public required string FfprobePath { get; init; } public required EncoderMode Encoder { get; init; } public required double TrimStart { get; init; } public required double FadeSeconds { get; init; } public required double EndCardHoldSeconds { get; init; } public required int ThumbnailInterval { get; init; } public bool MoveSourcesToOriginals { get; init; } = true; public ShortSourceCropMode SourceCropMode { get; init; } = ShortSourceCropMode.Auto; public int CropLeft { get; init; } public int CropRight { get; init; } public int CropTop { get; init; } public int CropBottom { get; init; } public int Width { get; init; } = 3840; public int Height { get; init; } = 2160; public int FramesPerSecond { get; init; } = 50; public int ThumbnailWidth { get; init; } = 1280; public int ThumbnailHeight { get; init; } = 720; } public sealed record RenderProgress(double Percent, string Stage, string Message); /// Which moment of a long-form video a preview still represents. public enum VideoPreviewShot { Opening, Closing, } /// PNG stills of the cropped 4K source look and the end card. public sealed record VideoPreviewFrames(string OpeningPath, string ClosingPath);