Skip to content

Commit

Permalink
video: silence warnings for missing libavutils pixel formats
Browse files Browse the repository at this point in the history
Using vf_screenshot on Libav printed useless/misleading error messages
when playing 10 bit h264 with a VO that supports 8 bit yuv420p only:

    Unsupported format 444p14le
    Unsupported format 444p14be
    ...

The cause of this is that vf_scale is inserted to handle the format
conversion, and tries to find a pixel format with best quality. This
includes the 14 bit and 12 bit formats, which don't exist on Libav.
vf_screenshot tries to query whether Libav's libswscale supports it,
resulting in these error messages. (In theory, vf_scale is missing this
check, but it doesn't matter in practice.)

Since this warning is rather useless anyway, because all input video
comes from libavcodec, and only the conversion into the other could
possibly fail. Silence the warning by raising it to verbose message
level.

Closes #7.
  • Loading branch information
wm4 committed Dec 14, 2012
1 parent e288af5 commit 5f999d9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion video/fmt-conversion.c
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ enum PixelFormat imgfmt2pixfmt(int fmt)
break;
pix_fmt = conversion_map[i].pix_fmt;
if (pix_fmt == PIX_FMT_NONE)
mp_msg(MSGT_GLOBAL, MSGL_ERR, "Unsupported format %s\n", vo_format_name(fmt));
mp_msg(MSGT_GLOBAL, MSGL_V, "Unsupported format %s\n", vo_format_name(fmt));
return pix_fmt;
}

Expand Down

0 comments on commit 5f999d9

Please sign in to comment.