Preserve native broadcast video and add patient shared stream startup
This commit is contained in:
@@ -35,8 +35,9 @@ public static class ContinuityE2E
|
||||
try
|
||||
{
|
||||
var source = relay.Register($"http://127.0.0.1:{port}/fixture.ts");
|
||||
var pl = await streams.Open(source, "pl", CancellationToken.None);
|
||||
var en = await streams.Open(source, "en", CancellationToken.None);
|
||||
var tracks = LosslessSlateTests.Tracks(1280, 720, 25);
|
||||
var pl = await streams.Open(source, "pl", CancellationToken.None, tracks);
|
||||
var en = await streams.Open(source, "en", CancellationToken.None, tracks);
|
||||
Require(JsonSerializer.Serialize(streams.Status()).Contains("\"Sources\":1"), "two languages share one source worker");
|
||||
Require(!streams.Segment(pl.Id, 0).SequenceEqual(streams.Segment(en.Id, 0)), "same timeline uses different language slates");
|
||||
await File.WriteAllBytesAsync(Path.Combine(output, "pl-slate.ts"), streams.Segment(pl.Id, 0));
|
||||
@@ -81,7 +82,7 @@ public static class ContinuityE2E
|
||||
}
|
||||
var report = new { Passed = true, SyntheticOnly = true, ReceiverConnectionsOpened = 0, ViewerLanguages = new[] { "pl", "en" }, SourceConnections = connections, FailureSeconds = longTest ? 75 : 15,
|
||||
MaximumConcurrentSourceConnections = maximum, RemainingConnections = active, WaitingLossRecoverySamePlayer = true,
|
||||
StrictVideoAudioDecode = true, PreserveSourceResolution = preserveResolution, Width = preserveResolution ? 1280 : ContinuityStreams.Width, Height = preserveResolution ? 720 : ContinuityStreams.Height, FrameRate = ContinuityStreams.FrameRate,
|
||||
StrictVideoAudioDecode = true, PreserveSourceResolution = preserveResolution, Width = 1280, Height = 720, FrameRate = 25, OriginalAvCopied = true,
|
||||
PhysicalAndroidTvTested = false, ActualJellyfinPlayerTested = false };
|
||||
await File.WriteAllTextAsync(Path.Combine(output, "result.json"), JsonSerializer.Serialize(report, new JsonSerializerOptions { WriteIndented = true })); Console.WriteLine(JsonSerializer.Serialize(report));
|
||||
}
|
||||
@@ -105,7 +106,7 @@ public static class ContinuityE2E
|
||||
if (!enabled) { context.Response.StatusCode = 503; return; }
|
||||
var current = Interlocked.Increment(ref active); maximum = Math.Max(maximum, current);
|
||||
var info = new ProcessStartInfo(ffmpeg) { UseShellExecute = false, RedirectStandardOutput = true, RedirectStandardError = true };
|
||||
foreach (var arg in new[] { "-hide_banner", "-loglevel", "error", "-nostdin", "-threads", "1", "-filter_threads", "1", "-re", "-f", "lavfi", "-i", "testsrc2=size=1280x720:rate=25", "-f", "lavfi", "-i", "sine=frequency=440:sample_rate=48000", "-c:v", "libx264", "-threads", "1", "-preset", "ultrafast", "-g", "25", "-c:a", "aac", "-f", "mpegts", "pipe:1" }) info.ArgumentList.Add(arg);
|
||||
foreach (var arg in new[] { "-hide_banner", "-loglevel", "error", "-nostdin", "-threads", "1", "-filter_threads", "1", "-re", "-f", "lavfi", "-i", "testsrc2=size=1280x720:rate=25", "-f", "lavfi", "-i", "sine=frequency=440:sample_rate=48000", "-c:v", "libx264", "-threads", "1", "-preset", "ultrafast", "-g", "25", "-c:a", "aac", "-ac", "2", "-f", "mpegts", "pipe:1" }) info.ArgumentList.Add(arg);
|
||||
using var process = Process.Start(info); process.ErrorDataReceived += (_, _) => { }; process.BeginErrorReadLine(); context.Response.ContentType = "video/mp2t";
|
||||
try
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user