summaryrefslogtreecommitdiffstats
path: root/libswscale/tests
diff options
context:
space:
mode:
authorClément Bœsch <u@pkh.me>2017-03-23 22:46:28 +0100
committerClément Bœsch <u@pkh.me>2017-03-24 00:06:35 +0100
commit99dd6fe62cb43ae26c854f61c58b8b6fc4f236e3 (patch)
tree66cf4a458d8920e1ac91b6f3314151e2a1f6d8c5 /libswscale/tests
parentbc7308aae82053ad371bed1e1dd3298f0c07ec35 (diff)
downloadffmpeg-streaming-99dd6fe62cb43ae26c854f61c58b8b6fc4f236e3.zip
ffmpeg-streaming-99dd6fe62cb43ae26c854f61c58b8b6fc4f236e3.tar.gz
sws/tests/pixdesc_query: remove func wrappers
Diffstat (limited to 'libswscale/tests')
-rw-r--r--libswscale/tests/pixdesc_query.c59
1 files changed, 17 insertions, 42 deletions
diff --git a/libswscale/tests/pixdesc_query.c b/libswscale/tests/pixdesc_query.c
index 9591b04..a4aa8ac 100644
--- a/libswscale/tests/pixdesc_query.c
+++ b/libswscale/tests/pixdesc_query.c
@@ -20,52 +20,27 @@
#include "libswscale/swscale_internal.h"
-/* TODO: drop this wrapper when all the is*() becomes functions */
-#define DECLARE_WRAPPER(macro) \
-static int macro##_func(enum AVPixelFormat pix_fmt) \
-{ \
- return macro(pix_fmt); \
-}
-
-DECLARE_WRAPPER(is16BPS)
-DECLARE_WRAPPER(isNBPS)
-DECLARE_WRAPPER(isBE)
-DECLARE_WRAPPER(isYUV)
-DECLARE_WRAPPER(isPlanarYUV)
-DECLARE_WRAPPER(isRGB)
-DECLARE_WRAPPER(isGray)
-DECLARE_WRAPPER(isRGBinInt)
-DECLARE_WRAPPER(isBGRinInt)
-DECLARE_WRAPPER(isBayer)
-DECLARE_WRAPPER(isAnyRGB)
-DECLARE_WRAPPER(isALPHA)
-DECLARE_WRAPPER(isPacked)
-DECLARE_WRAPPER(isPlanar)
-DECLARE_WRAPPER(isPackedRGB)
-DECLARE_WRAPPER(isPlanarRGB)
-DECLARE_WRAPPER(usePal)
-
static const struct {
const char *class;
int (*cond)(enum AVPixelFormat pix_fmt);
} query_tab[] = {
- {"is16BPS", is16BPS_func},
- {"isNBPS", isNBPS_func},
- {"isBE", isBE_func},
- {"isYUV", isYUV_func},
- {"isPlanarYUV", isPlanarYUV_func},
- {"isRGB", isRGB_func},
- {"Gray", isGray_func},
- {"RGBinInt", isRGBinInt_func},
- {"BGRinInt", isBGRinInt_func},
- {"Bayer", isBayer_func},
- {"AnyRGB", isAnyRGB_func},
- {"ALPHA", isALPHA_func},
- {"Packed", isPacked_func},
- {"Planar", isPlanar_func},
- {"PackedRGB", isPackedRGB_func},
- {"PlanarRGB", isPlanarRGB_func},
- {"usePal", usePal_func},
+ {"is16BPS", is16BPS},
+ {"isNBPS", isNBPS},
+ {"isBE", isBE},
+ {"isYUV", isYUV},
+ {"isPlanarYUV", isPlanarYUV},
+ {"isRGB", isRGB},
+ {"Gray", isGray},
+ {"RGBinInt", isRGBinInt},
+ {"BGRinInt", isBGRinInt},
+ {"Bayer", isBayer},
+ {"AnyRGB", isAnyRGB},
+ {"ALPHA", isALPHA},
+ {"Packed", isPacked},
+ {"Planar", isPlanar},
+ {"PackedRGB", isPackedRGB},
+ {"PlanarRGB", isPlanarRGB},
+ {"usePal", usePal},
};
int main(void)
OpenPOWER on IntegriCloud