decoder/ffmpeg: check for DSD codec
DSD uses a generic demuxer, therefore it does not appear in the demuxer list.
This commit is contained in:
parent
3c798b4907
commit
c53ee41855
|
@ -29,6 +29,7 @@
|
||||||
#include "util/IterableSplitString.hxx"
|
#include "util/IterableSplitString.hxx"
|
||||||
#include "util/ScopeExit.hxx"
|
#include "util/ScopeExit.hxx"
|
||||||
#include "util/StringAPI.hxx"
|
#include "util/StringAPI.hxx"
|
||||||
|
#include "util/StringCompare.hxx"
|
||||||
#include "Log.hxx"
|
#include "Log.hxx"
|
||||||
|
|
||||||
extern "C" {
|
extern "C" {
|
||||||
|
@ -705,6 +706,15 @@ ffmpeg_suffixes() noexcept
|
||||||
suffixes.emplace(input_format->name);
|
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;
|
return suffixes;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue