mirror of
https://github.com/Sonarr/Sonarr.git
synced 2025-04-24 06:17:08 -04:00
New: Add HDR Type to XBMC metadata video stream details
(cherry picked from commit a7dbdadd2146b60efa7ebe8e2b65d32bc075232c) Co-Authored-By: Bogdan <mynameisbogdan@users.noreply.github.com>
This commit is contained in:
parent
b598795262
commit
64956d7be7
1 changed files with 17 additions and 0 deletions
|
@ -353,6 +353,23 @@ namespace NzbDrone.Core.Extras.Metadata.Consumers.Xbmc
|
|||
video.Add(new XElement("duration", episodeFile.MediaInfo.RunTime.TotalMinutes));
|
||||
video.Add(new XElement("durationinseconds", Math.Round(episodeFile.MediaInfo.RunTime.TotalSeconds)));
|
||||
|
||||
if (episodeFile.MediaInfo.VideoHdrFormat is HdrFormat.DolbyVision or HdrFormat.DolbyVisionHdr10 or HdrFormat.DolbyVisionHdr10Plus or HdrFormat.DolbyVisionHlg or HdrFormat.DolbyVisionSdr)
|
||||
{
|
||||
video.Add(new XElement("hdrtype", "dolbyvision"));
|
||||
}
|
||||
else if (episodeFile.MediaInfo.VideoHdrFormat is HdrFormat.Hdr10 or HdrFormat.Hdr10Plus or HdrFormat.Pq10)
|
||||
{
|
||||
video.Add(new XElement("hdrtype", "hdr10"));
|
||||
}
|
||||
else if (episodeFile.MediaInfo.VideoHdrFormat == HdrFormat.Hlg10)
|
||||
{
|
||||
video.Add(new XElement("hdrtype", "hlg"));
|
||||
}
|
||||
else if (episodeFile.MediaInfo.VideoHdrFormat == HdrFormat.None)
|
||||
{
|
||||
video.Add(new XElement("hdrtype", ""));
|
||||
}
|
||||
|
||||
streamDetails.Add(video);
|
||||
|
||||
var audio = new XElement("audio");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue