mirror of https://github.com/ErsatzTV/ErsatzTV.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
741 B
27 lines
741 B
namespace ErsatzTV.FFmpeg.Decoder; |
|
|
|
public class DecoderAv1 : DecoderBase |
|
{ |
|
// ReSharper disable IdentifierTypo |
|
private const string Libdav1d = "libdav1d"; |
|
private const string Libaomav1 = "libaom-av1"; |
|
|
|
private readonly IReadOnlySet<string> _ffmpegDecoders; |
|
|
|
public DecoderAv1(IReadOnlySet<string> ffmpegDecoders) => _ffmpegDecoders = ffmpegDecoders; |
|
|
|
public override string Name |
|
{ |
|
get |
|
{ |
|
if (_ffmpegDecoders.Contains(Libdav1d)) |
|
{ |
|
return Libdav1d; |
|
} |
|
|
|
return _ffmpegDecoders.Contains(Libaomav1) ? Libaomav1 : "av1"; |
|
} |
|
} |
|
|
|
protected override FrameDataLocation OutputFrameDataLocation => FrameDataLocation.Software; |
|
}
|
|
|