diff options
author | Michael Niedermayer <[email protected]> | 2014-03-23 13:25:42 +0100 |
---|---|---|
committer | Michael Niedermayer <[email protected]> | 2014-03-23 20:31:05 +0100 |
commit | 9ff0467566e971a61dbc2cc7920034a1412df8ee (patch) | |
tree | f2375bb7a4dbd7bc06228bc79cccefcf73d05842 /libavcodec/utils.c | |
parent | 4407b38b28d1e64a75195851024c58b953dfb9b2 (diff) |
Move avpriv_find_pix_fmt() to utils.c
Fixes build with --disable-everything
Signed-off-by: Michael Niedermayer <[email protected]>
(cherry picked from commit 82a90e7764ad04afd3679e4e4e89d85c7e4d4b53)
Signed-off-by: Michael Niedermayer <[email protected]>
Diffstat (limited to 'libavcodec/utils.c')
-rw-r--r-- | libavcodec/utils.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/libavcodec/utils.c b/libavcodec/utils.c index 19df3cc748..7ffe6c6524 100644 --- a/libavcodec/utils.c +++ b/libavcodec/utils.c @@ -46,6 +46,7 @@ #include "thread.h" #include "frame_thread_encoder.h" #include "internal.h" +#include "raw.h" #include "bytestream.h" #include "version.h" #include <stdlib.h> @@ -1071,6 +1072,17 @@ int avcodec_default_execute2(AVCodecContext *c, int (*func)(AVCodecContext *c2, return 0; } +enum AVPixelFormat avpriv_find_pix_fmt(const PixelFormatTag *tags, + unsigned int fourcc) +{ + while (tags->pix_fmt >= 0) { + if (tags->fourcc == fourcc) + return tags->pix_fmt; + tags++; + } + return AV_PIX_FMT_NONE; +} + static int is_hwaccel_pix_fmt(enum AVPixelFormat pix_fmt) { const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt); |