]> git.sesse.net Git - ffmpeg/blobdiff - tests/checkasm/checkasm.c
Merge commit '85bfaa4949f4afcde19061def3e8a18988964858'
[ffmpeg] / tests / checkasm / checkasm.c
index 20ce56932fe5de4f5cde1ec3ddedf12497f837e6..9eec41e3c4f822aa964aca789641adf02ee3d324 100644 (file)
@@ -150,6 +150,9 @@ static const struct {
     #endif
 #endif
 #if CONFIG_AVFILTER
+    #if CONFIG_AFIR_FILTER
+        { "af_afir", checkasm_check_afir },
+    #endif
     #if CONFIG_BLEND_FILTER
         { "vf_blend", checkasm_check_blend },
     #endif
@@ -159,6 +162,9 @@ static const struct {
     #if CONFIG_HFLIP_FILTER
         { "vf_hflip", checkasm_check_vf_hflip },
     #endif
+    #if CONFIG_NLMEANS_FILTER
+        { "vf_nlmeans", checkasm_check_nlmeans },
+    #endif
     #if CONFIG_THRESHOLD_FILTER
         { "vf_threshold", checkasm_check_vf_threshold },
     #endif
@@ -294,8 +300,12 @@ int float_near_ulp_array(const float *a, const float *b, unsigned max_ulp,
 int float_near_abs_eps(float a, float b, float eps)
 {
     float abs_diff = fabsf(a - b);
+    if (abs_diff < eps)
+        return 1;
 
-    return abs_diff < eps;
+    fprintf(stderr, "test failed comparing %g with %g (abs diff=%g with EPS=%g)\n", a, b, abs_diff, eps);
+
+    return 0;
 }
 
 int float_near_abs_eps_array(const float *a, const float *b, float eps,
@@ -602,6 +612,7 @@ static int bench_init_linux(void)
 }
 #endif
 
+#if !CONFIG_LINUX_PERF
 static int bench_init_ffmpeg(void)
 {
 #ifdef AV_READ_TIME
@@ -612,6 +623,7 @@ static int bench_init_ffmpeg(void)
     return -1;
 #endif
 }
+#endif
 
 static int bench_init(void)
 {