1
0
mirror of https://github.com/mpv-player/mpv synced 2025-03-19 09:57:34 +00:00

vd_lavc: slightly better logging about why hwdec is not used

The old message was outdated and also not very precise. Make it all a
bit more elaborate.
This commit is contained in:
wm4 2018-03-07 22:39:51 +01:00 committed by Kevin Mitchell
parent 93fb79166b
commit 075aa21797

View File

@ -417,7 +417,12 @@ static void select_and_set_hwdec(struct mp_filter *vd)
bool hwdec_auto_copy = bstr_equals0(opt, "auto-copy");
bool hwdec_auto = hwdec_auto_all || hwdec_auto_copy;
if (hwdec_codec_allowed(vd, codec) && hwdec_requested) {
if (!hwdec_requested) {
MP_VERBOSE(vd, "No hardware decoding requested.\n");
} else if (!hwdec_codec_allowed(vd, codec)) {
MP_VERBOSE(vd, "Not trying to use hardware decoding: codec %s is not "
"on whitelist.\n", codec);
} else {
struct hwdec_info *hwdecs = NULL;
int num_hwdecs = 0;
add_all_hwdec_methods(&hwdecs, &num_hwdecs);
@ -472,10 +477,9 @@ static void select_and_set_hwdec(struct mp_filter *vd)
}
talloc_free(hwdecs);
} else {
MP_VERBOSE(vd, "Not trying to use hardware decoding: codec %s is not "
"on whitelist, or does not support hardware acceleration.\n",
codec);
if (!ctx->use_hwdec)
MP_VERBOSE(vd, "No hardware decoding available for this codec.\n");
}
if (ctx->use_hwdec) {