shithub: libvpx

Download patch

ref: 4f9d852759ceca15c16f9ffed96c08d4b427f40b
parent: 98666368ee7f01a3344c1065abd8700b4002e275
author: James Zern <[email protected]>
date: Mon Jun 12 14:08:20 EDT 2017

vp8_skin_detection: add 'vp8_' prefix to public fns

BUG=webm:1438

Change-Id: I5feb31c254d02e116e624cfe702e73ba5a1f7aca

--- a/vp8/common/vp8_skin_detection.c
+++ b/vp8/common/vp8_skin_detection.c
@@ -14,9 +14,9 @@
 #include "vpx_mem/vpx_mem.h"
 #include "vpx_util/vpx_write_yuv_frame.h"
 
-int compute_skin_block(const uint8_t *y, const uint8_t *u, const uint8_t *v,
-                       int stride, int strideuv, int consec_zeromv,
-                       int curr_motion_magn) {
+int vp8_compute_skin_block(const uint8_t *y, const uint8_t *u, const uint8_t *v,
+                           int stride, int strideuv, int consec_zeromv,
+                           int curr_motion_magn) {
   // No skin if block has been zero/small motion for long consecutive time.
   if (consec_zeromv > 60 && curr_motion_magn == 0) {
     return 0;
@@ -39,7 +39,7 @@
 
 #ifdef OUTPUT_YUV_SKINMAP
 // For viewing skin map on input source.
-void compute_skin_map(VP8_COMP *const cpi, FILE *yuv_skinmap_file) {
+void vp8_compute_skin_map(VP8_COMP *const cpi, FILE *yuv_skinmap_file) {
   int i, j, mb_row, mb_col, num_bl;
   VP8_COMMON *const cm = &cpi->common;
   uint8_t *y;
@@ -74,8 +74,8 @@
                              VPXMIN(cpi->consec_zero_last[bl_index1],
                                     VPXMIN(cpi->consec_zero_last[bl_index2],
                                            cpi->consec_zero_last[bl_index3])));
-      is_skin = compute_skin_block(src_y, src_u, src_v, src_ystride,
-                                   src_uvstride, consec_zeromv, 0);
+      is_skin = vp8_compute_skin_block(src_y, src_u, src_v, src_ystride,
+                                       src_uvstride, consec_zeromv, 0);
       for (i = 0; i < 16; i++) {
         for (j = 0; j < 16; j++) {
           if (is_skin)
--- a/vp8/common/vp8_skin_detection.h
+++ b/vp8/common/vp8_skin_detection.h
@@ -22,13 +22,13 @@
 
 struct VP8_COMP;
 
-int compute_skin_block(const uint8_t *y, const uint8_t *u, const uint8_t *v,
-                       int stride, int strideuv, int consec_zeromv,
-                       int curr_motion_magn);
+int vp8_compute_skin_block(const uint8_t *y, const uint8_t *u, const uint8_t *v,
+                           int stride, int strideuv, int consec_zeromv,
+                           int curr_motion_magn);
 
 #ifdef OUTPUT_YUV_SKINMAP
 // For viewing skin map on input source.
-void compute_skin_map(struct VP8_COMP *const cpi, FILE *yuv_skinmap_file);
+void vp8_compute_skin_map(struct VP8_COMP *const cpi, FILE *yuv_skinmap_file);
 #endif
 
 #ifdef __cplusplus
--- a/vp8/encoder/onyx_if.c
+++ b/vp8/encoder/onyx_if.c
@@ -4405,7 +4405,7 @@
 
 #ifdef OUTPUT_YUV_SKINMAP
   if (cpi->common.current_video_frame > 1) {
-    compute_skin_map(cpi, yuv_skinmap_file);
+    vp8_compute_skin_map(cpi, yuv_skinmap_file);
   }
 #endif
 
--- a/vp8/encoder/pickinter.c
+++ b/vp8/encoder/pickinter.c
@@ -691,7 +691,7 @@
   x->is_skin = 0;
   if (!cpi->oxcf.screen_content_mode) {
     int block_index = mb_row * cpi->common.mb_cols + mb_col;
-    x->is_skin = compute_skin_block(
+    x->is_skin = vp8_compute_skin_block(
         x->src.y_buffer, x->src.u_buffer, x->src.v_buffer, x->src.y_stride,
         x->src.uv_stride, cpi->consec_zero_last[block_index], 0);
   }