1
0
mirror of https://github.com/mpv-player/mpv synced 2025-03-11 08:37:59 +00:00

video: make IMGFMT_IS_HWACCEL() return 0 or 1

Sometimes helps avoiding usage mistakes.
This commit is contained in:
wm4 2018-01-16 11:38:16 +01:00 committed by Kevin Mitchell
parent 2115e2306e
commit 7533d3c3a8

View File

@ -231,7 +231,7 @@ static inline bool IMGFMT_IS_RGB(int fmt)
}
#define IMGFMT_RGB_DEPTH(fmt) (mp_imgfmt_get_desc(fmt).plane_bits)
#define IMGFMT_IS_HWACCEL(fmt) (mp_imgfmt_get_desc(fmt).flags & MP_IMGFLAG_HWACCEL)
#define IMGFMT_IS_HWACCEL(fmt) (!!(mp_imgfmt_get_desc(fmt).flags & MP_IMGFLAG_HWACCEL))
int mp_imgfmt_from_name(bstr name);
char *mp_imgfmt_to_name_buf(char *buf, size_t buf_size, int fmt);