Fix build error: correct StreamingRequestDto cast
The previous commit referenced state.Request.SegmentContainer which doesn't exist. BaseEncodingJobOptions doesn't have a SegmentContainer property - only StreamingRequestDto does. Fixed by: - Cast BaseRequest to StreamingRequestDto before accessing SegmentContainer - Add using directive for MediaBrowser.Controller.Streaming namespace - Use null-conditional operator to safely check SegmentContainer
This commit is contained in:
@@ -20,6 +20,7 @@ using Jellyfin.Extensions;
|
||||
using MediaBrowser.Common.Configuration;
|
||||
using MediaBrowser.Controller.Extensions;
|
||||
using MediaBrowser.Controller.IO;
|
||||
using MediaBrowser.Controller.Streaming;
|
||||
using MediaBrowser.Model.Configuration;
|
||||
using MediaBrowser.Model.Dlna;
|
||||
using MediaBrowser.Model.Dto;
|
||||
@@ -7484,7 +7485,8 @@ namespace MediaBrowser.Controller.MediaEncoding
|
||||
{
|
||||
// Use fragmented MP4 for adaptive streaming (HLS/DASH with segments)
|
||||
// Use faststart for progressive downloads (better seeking and metadata)
|
||||
if (!string.IsNullOrEmpty(state.Request.SegmentContainer))
|
||||
var streamingRequest = state.BaseRequest as StreamingRequestDto;
|
||||
if (streamingRequest?.SegmentContainer is not null)
|
||||
{
|
||||
// Fragmented MP4 for HLS/DASH
|
||||
format = " -f mp4 -movflags frag_keyframe+empty_moov+delay_moov";
|
||||
|
||||
Reference in New Issue
Block a user