mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-23 02:27:17 +00:00
Merge from master & fix conflict
This commit is contained in:
@@ -21,7 +21,7 @@ namespace MediaBrowser.MediaEncoding.Attachments
|
||||
{
|
||||
public class AttachmentExtractor : IAttachmentExtractor, IDisposable
|
||||
{
|
||||
private readonly ILogger _logger;
|
||||
private readonly ILogger<AttachmentExtractor> _logger;
|
||||
private readonly IApplicationPaths _appPaths;
|
||||
private readonly IFileSystem _fileSystem;
|
||||
private readonly IMediaEncoder _mediaEncoder;
|
||||
@@ -269,7 +269,6 @@ namespace MediaBrowser.MediaEncoding.Attachments
|
||||
|
||||
if (disposing)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
_disposed = true;
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||
/// </summary>
|
||||
internal const int DefaultImageExtractionTimeout = 5000;
|
||||
|
||||
private readonly ILogger _logger;
|
||||
private readonly ILogger<MediaEncoder> _logger;
|
||||
private readonly IServerConfigurationManager _configurationManager;
|
||||
private readonly IFileSystem _fileSystem;
|
||||
private readonly ILocalizationManager _localization;
|
||||
@@ -244,14 +244,14 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||
public void SetAvailableEncoders(IEnumerable<string> list)
|
||||
{
|
||||
_encoders = list.ToList();
|
||||
//_logger.Info("Supported encoders: {0}", string.Join(",", list.ToArray()));
|
||||
// _logger.Info("Supported encoders: {0}", string.Join(",", list.ToArray()));
|
||||
}
|
||||
|
||||
private List<string> _decoders = new List<string>();
|
||||
public void SetAvailableDecoders(IEnumerable<string> list)
|
||||
{
|
||||
_decoders = list.ToList();
|
||||
//_logger.Info("Supported decoders: {0}", string.Join(",", list.ToArray()));
|
||||
// _logger.Info("Supported decoders: {0}", string.Join(",", list.ToArray()));
|
||||
}
|
||||
|
||||
public bool SupportsEncoder(string encoder)
|
||||
@@ -497,11 +497,11 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||
break;
|
||||
case Video3DFormat.FullSideBySide:
|
||||
vf = "crop=iw/2:ih:0:0,setdar=dar=a,crop=min(iw\\,ih*dar):min(ih\\,iw/dar):(iw-min(iw\\,iw*sar))/2:(ih - min (ih\\,ih/sar))/2,setsar=sar=1,scale=600:trunc(600/dar/2)*2";
|
||||
//fsbs crop width in half,set the display aspect,crop out any black bars we may have made the scale width to 600.
|
||||
// fsbs crop width in half,set the display aspect,crop out any black bars we may have made the scale width to 600.
|
||||
break;
|
||||
case Video3DFormat.HalfTopAndBottom:
|
||||
vf = "crop=iw:ih/2:0:0,scale=(iw*2):ih),setdar=dar=a,crop=min(iw\\,ih*dar):min(ih\\,iw/dar):(iw-min(iw\\,iw*sar))/2:(ih - min (ih\\,ih/sar))/2,setsar=sar=1,scale=600:trunc(600/dar/2)*2";
|
||||
//htab crop heigh in half,scale to correct size, set the display aspect,crop out any black bars we may have made the scale width to 600
|
||||
// htab crop heigh in half,scale to correct size, set the display aspect,crop out any black bars we may have made the scale width to 600
|
||||
break;
|
||||
case Video3DFormat.FullTopAndBottom:
|
||||
vf = "crop=iw:ih/2:0:0,setdar=dar=a,crop=min(iw\\,ih*dar):min(ih\\,iw/dar):(iw-min(iw\\,iw*sar))/2:(ih - min (ih\\,ih/sar))/2,setsar=sar=1,scale=600:trunc(600/dar/2)*2";
|
||||
@@ -917,7 +917,6 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||
var fileParts = _fileSystem.GetFileNameWithoutExtension(f).Split('_');
|
||||
|
||||
return fileParts.Length == 3 && string.Equals(title, fileParts[1], StringComparison.OrdinalIgnoreCase);
|
||||
|
||||
}).ToList();
|
||||
|
||||
// If this resulted in not getting any vobs, just take them all
|
||||
|
||||
@@ -413,7 +413,6 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
.Where(i => !string.IsNullOrWhiteSpace(i))
|
||||
.Distinct(StringComparer.OrdinalIgnoreCase)
|
||||
.ToArray();
|
||||
|
||||
}
|
||||
else if (string.Equals(key, "screenwriters", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
@@ -425,7 +424,6 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
Type = PersonType.Writer
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
else if (string.Equals(key, "producers", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
@@ -562,7 +560,7 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
if (string.Equals(streamInfo.CodecName, "mov_text", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
// Edit: but these are also sometimes subtitles?
|
||||
//return null;
|
||||
// return null;
|
||||
}
|
||||
|
||||
var stream = new MediaStream
|
||||
@@ -684,7 +682,7 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
stream.BitDepth = streamInfo.BitsPerRawSample;
|
||||
}
|
||||
|
||||
//stream.IsAnamorphic = string.Equals(streamInfo.sample_aspect_ratio, "0:1", StringComparison.OrdinalIgnoreCase) ||
|
||||
// stream.IsAnamorphic = string.Equals(streamInfo.sample_aspect_ratio, "0:1", StringComparison.OrdinalIgnoreCase) ||
|
||||
// string.Equals(stream.AspectRatio, "2.35:1", StringComparison.OrdinalIgnoreCase) ||
|
||||
// string.Equals(stream.AspectRatio, "2.40:1", StringComparison.OrdinalIgnoreCase);
|
||||
|
||||
@@ -953,8 +951,8 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
audio.People = peoples.ToArray();
|
||||
}
|
||||
|
||||
//var conductor = FFProbeHelpers.GetDictionaryValue(tags, "conductor");
|
||||
//if (!string.IsNullOrWhiteSpace(conductor))
|
||||
// var conductor = FFProbeHelpers.GetDictionaryValue(tags, "conductor");
|
||||
// if (!string.IsNullOrWhiteSpace(conductor))
|
||||
//{
|
||||
// foreach (var person in Split(conductor, false))
|
||||
// {
|
||||
@@ -962,8 +960,8 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
// }
|
||||
//}
|
||||
|
||||
//var lyricist = FFProbeHelpers.GetDictionaryValue(tags, "lyricist");
|
||||
//if (!string.IsNullOrWhiteSpace(lyricist))
|
||||
// var lyricist = FFProbeHelpers.GetDictionaryValue(tags, "lyricist");
|
||||
// if (!string.IsNullOrWhiteSpace(lyricist))
|
||||
//{
|
||||
// foreach (var person in Split(lyricist, false))
|
||||
// {
|
||||
@@ -1028,7 +1026,6 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
audio.AlbumArtists = SplitArtists(albumArtist, _nameDelimiters, true)
|
||||
.DistinctNames()
|
||||
.ToArray();
|
||||
|
||||
}
|
||||
|
||||
if (audio.AlbumArtists.Length == 0)
|
||||
|
||||
@@ -130,10 +130,10 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
}
|
||||
}
|
||||
|
||||
//if (header.Length > 0)
|
||||
//subtitle.Header = header.ToString();
|
||||
// if (header.Length > 0)
|
||||
// subtitle.Header = header.ToString();
|
||||
|
||||
//subtitle.Renumber(1);
|
||||
// subtitle.Renumber(1);
|
||||
}
|
||||
trackInfo.TrackEvents = trackEvents.ToArray();
|
||||
return trackInfo;
|
||||
@@ -261,7 +261,6 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
text += "</font>";
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
text = text.Replace(@"{\i1}", "<i>");
|
||||
|
||||
@@ -25,7 +25,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
public class SubtitleEncoder : ISubtitleEncoder
|
||||
{
|
||||
private readonly ILibraryManager _libraryManager;
|
||||
private readonly ILogger _logger;
|
||||
private readonly ILogger<SubtitleEncoder> _logger;
|
||||
private readonly IApplicationPaths _appPaths;
|
||||
private readonly IFileSystem _fileSystem;
|
||||
private readonly IMediaEncoder _mediaEncoder;
|
||||
@@ -640,7 +640,6 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
}
|
||||
catch (FileNotFoundException)
|
||||
{
|
||||
|
||||
}
|
||||
catch (IOException ex)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user