]> granicus.if.org Git - libvpx/commitdiff
Change to call vp9_post_proc_frame()
authorYaowu Xu <yaowu@google.com>
Wed, 20 Jul 2016 16:25:14 +0000 (09:25 -0700)
committerYaowu Xu <yaowu@google.com>
Wed, 20 Jul 2016 18:01:49 +0000 (11:01 -0700)
This commit changes the call in vp9 encoder from vp9_deblock() to
vp9_post_proc_frame() to ensure the data structures used in the call
are properly allocated. This fixes an encoder crash when configured
with --enable-internal-stats.

Change-Id: I2393b336c0f566665336df4f1ba91c405eb56764

vp9/encoder/vp9_encoder.c

index 0d78874b7bf8794e13f8de8cf7fee03ca50c1e27..ec696a7f348d8d5a890b6f89122593b558885963 100644 (file)
@@ -4944,9 +4944,13 @@ int vp9_get_compressed_data(VP9_COMP *cpi, unsigned int *frame_flags,
             vpx_internal_error(&cm->error, VPX_CODEC_MEM_ERROR,
                                "Failed to allocate post processing buffer");
           }
-
-          vp9_deblock(cm->frame_to_show, pp,
-                      cm->lf.filter_level * 10 / 6, cm->postproc_state.limits);
+          {
+            vp9_ppflags_t ppflags;
+            ppflags.post_proc_flag = VP9D_DEBLOCK;
+            ppflags.deblocking_level = 0;  // not used in vp9_post_proc_frame()
+            ppflags.noise_level = 0;       // not used in vp9_post_proc_frame()
+            vp9_post_proc_frame(cm, pp, &ppflags);
+          }
 #endif
           vpx_clear_system_state();