mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-27 12:31:57 +00:00
add more codecs to direct play profiles
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace MediaBrowser.Controller.Dlna
|
||||
{
|
||||
@@ -6,12 +7,16 @@ namespace MediaBrowser.Controller.Dlna
|
||||
{
|
||||
public CodecType Type { get; set; }
|
||||
public List<ProfileCondition> Conditions { get; set; }
|
||||
public string[] Codecs { get; set; }
|
||||
public string Codec { get; set; }
|
||||
|
||||
public CodecProfile()
|
||||
{
|
||||
Conditions = new List<ProfileCondition>();
|
||||
Codecs = new string[] { };
|
||||
}
|
||||
|
||||
public List<string> GetCodecs()
|
||||
{
|
||||
return (Codec ?? string.Empty).Split(',').Where(i => !string.IsNullOrWhiteSpace(i)).ToList();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -58,6 +58,8 @@ namespace MediaBrowser.Controller.Dlna
|
||||
public MediaProfile[] MediaProfiles { get; set; }
|
||||
public CodecProfile[] CodecProfiles { get; set; }
|
||||
|
||||
public int TimelineOffsetSeconds { get; set; }
|
||||
|
||||
public DeviceProfile()
|
||||
{
|
||||
DirectPlayProfiles = new DirectPlayProfile[] { };
|
||||
|
||||
@@ -1,12 +1,13 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace MediaBrowser.Controller.Dlna
|
||||
{
|
||||
public class DirectPlayProfile
|
||||
{
|
||||
public string[] Containers { get; set; }
|
||||
public string[] AudioCodecs { get; set; }
|
||||
public string[] VideoCodecs { get; set; }
|
||||
public string AudioCodec { get; set; }
|
||||
public string VideoCodec { get; set; }
|
||||
|
||||
public DlnaProfileType Type { get; set; }
|
||||
|
||||
@@ -16,10 +17,18 @@ namespace MediaBrowser.Controller.Dlna
|
||||
{
|
||||
Conditions = new List<ProfileCondition>();
|
||||
|
||||
AudioCodecs = new string[] { };
|
||||
VideoCodecs = new string[] { };
|
||||
Containers = new string[] { };
|
||||
}
|
||||
|
||||
public List<string> GetAudioCodecs()
|
||||
{
|
||||
return (AudioCodec ?? string.Empty).Split(',').Where(i => !string.IsNullOrWhiteSpace(i)).ToList();
|
||||
}
|
||||
|
||||
public List<string> GetVideoCodecs()
|
||||
{
|
||||
return (VideoCodec ?? string.Empty).Split(',').Where(i => !string.IsNullOrWhiteSpace(i)).ToList();
|
||||
}
|
||||
}
|
||||
|
||||
public enum DlnaProfileType
|
||||
|
||||
@@ -1,20 +1,26 @@
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace MediaBrowser.Controller.Dlna
|
||||
{
|
||||
public class MediaProfile
|
||||
{
|
||||
public string Container { get; set; }
|
||||
public string[] AudioCodecs { get; set; }
|
||||
public string[] VideoCodecs { get; set; }
|
||||
|
||||
public string AudioCodec { get; set; }
|
||||
public string VideoCodec { get; set; }
|
||||
|
||||
public DlnaProfileType Type { get; set; }
|
||||
public string OrgPn { get; set; }
|
||||
public string MimeType { get; set; }
|
||||
|
||||
public MediaProfile()
|
||||
public List<string> GetAudioCodecs()
|
||||
{
|
||||
AudioCodecs = new string[] { };
|
||||
VideoCodecs = new string[] { };
|
||||
return (AudioCodec ?? string.Empty).Split(',').Where(i => !string.IsNullOrWhiteSpace(i)).ToList();
|
||||
}
|
||||
|
||||
public List<string> GetVideoCodecs()
|
||||
{
|
||||
return (VideoCodec ?? string.Empty).Split(',').Where(i => !string.IsNullOrWhiteSpace(i)).ToList();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user