diff --git a/src/decoder/plugins/FfmpegDecoderPlugin.cxx b/src/decoder/plugins/FfmpegDecoderPlugin.cxx index a11729777..a24594a98 100644 --- a/src/decoder/plugins/FfmpegDecoderPlugin.cxx +++ b/src/decoder/plugins/FfmpegDecoderPlugin.cxx @@ -29,6 +29,7 @@ #include "util/IterableSplitString.hxx" #include "util/ScopeExit.hxx" #include "util/StringAPI.hxx" +#include "util/StringCompare.hxx" #include "Log.hxx" extern "C" { @@ -705,6 +706,15 @@ ffmpeg_suffixes() noexcept suffixes.emplace(input_format->name); } + void *codec_opaque = nullptr; + while (const auto codec = av_codec_iterate(&codec_opaque)) { + if (StringStartsWith(codec->name, "dsd_")) { + /* FFmpeg was compiled with DSD support */ + suffixes.emplace("dff"); + suffixes.emplace("dsf"); + } + } + return suffixes; }