summaryrefslogtreecommitdiff
path: root/vp8
diff options
context:
space:
mode:
authorJames Zern <jzern@google.com>2016-09-07 16:17:50 -0700
committerJames Zern <jzern@google.com>2016-09-20 20:19:36 -0700
commit3f72509587d4865e9e7c9a52fec65d9221e9a8bf (patch)
treebe86a2d874657419d1e542ac09fc303ea5620bce /vp8
parentb6e686b1ea0cb5d609de85836b829557660e7d55 (diff)
downloadlibvpx-3f72509587d4865e9e7c9a52fec65d9221e9a8bf.tar
libvpx-3f72509587d4865e9e7c9a52fec65d9221e9a8bf.tar.gz
libvpx-3f72509587d4865e9e7c9a52fec65d9221e9a8bf.tar.bz2
libvpx-3f72509587d4865e9e7c9a52fec65d9221e9a8bf.zip
vp8: remove VP8_SET_DBG* control support
the --enable-postproc-visualizer configure option remains as a no-op as do the control names and values for compatibility + remove the corresponding debug flags from vpxdec: --pp-* Change-Id: I4a001cd9962b59560d7d6bda6272d4ff32b8d37c
Diffstat (limited to 'vp8')
-rw-r--r--vp8/common/onyxc_int.h4
-rw-r--r--vp8/common/postproc.c402
-rw-r--r--vp8/common/textblit.c118
-rw-r--r--vp8/vp8_common.mk1
-rw-r--r--vp8/vp8_dx_iface.c73
5 files changed, 0 insertions, 598 deletions
diff --git a/vp8/common/onyxc_int.h b/vp8/common/onyxc_int.h
index 732656f2f..9a12c7fb6 100644
--- a/vp8/common/onyxc_int.h
+++ b/vp8/common/onyxc_int.h
@@ -160,10 +160,6 @@ typedef struct VP8Common {
#ifdef PACKET_TESTING
VP8_HEADER oh;
#endif
-#if CONFIG_POSTPROC_VISUALIZER
- double bitrate;
- double framerate;
-#endif
#if CONFIG_MULTITHREAD
int processor_core_count;
diff --git a/vp8/common/postproc.c b/vp8/common/postproc.c
index 1c4e042c8..8b8c1701a 100644
--- a/vp8/common/postproc.c
+++ b/vp8/common/postproc.c
@@ -37,46 +37,6 @@
(0.071 * (float)(t & 0xff)) + 128)
/* clang-format on */
-/* global constants */
-#if CONFIG_POSTPROC_VISUALIZER
-static const unsigned char MB_PREDICTION_MODE_colors[MB_MODE_COUNT][3] = {
- { RGB_TO_YUV(0x98FB98) }, /* PaleGreen */
- { RGB_TO_YUV(0x00FF00) }, /* Green */
- { RGB_TO_YUV(0xADFF2F) }, /* GreenYellow */
- { RGB_TO_YUV(0x228B22) }, /* ForestGreen */
- { RGB_TO_YUV(0x006400) }, /* DarkGreen */
- { RGB_TO_YUV(0x98F5FF) }, /* Cadet Blue */
- { RGB_TO_YUV(0x6CA6CD) }, /* Sky Blue */
- { RGB_TO_YUV(0x00008B) }, /* Dark blue */
- { RGB_TO_YUV(0x551A8B) }, /* Purple */
- { RGB_TO_YUV(0xFF0000) } /* Red */
-};
-
-static const unsigned char B_PREDICTION_MODE_colors[B_MODE_COUNT][3] = {
- { RGB_TO_YUV(0x6633ff) }, /* Purple */
- { RGB_TO_YUV(0xcc33ff) }, /* Magenta */
- { RGB_TO_YUV(0xff33cc) }, /* Pink */
- { RGB_TO_YUV(0xff3366) }, /* Coral */
- { RGB_TO_YUV(0x3366ff) }, /* Blue */
- { RGB_TO_YUV(0xed00f5) }, /* Dark Blue */
- { RGB_TO_YUV(0x2e00b8) }, /* Dark Purple */
- { RGB_TO_YUV(0xff6633) }, /* Orange */
- { RGB_TO_YUV(0x33ccff) }, /* Light Blue */
- { RGB_TO_YUV(0x8ab800) }, /* Green */
- { RGB_TO_YUV(0xffcc33) }, /* Light Orange */
- { RGB_TO_YUV(0x33ffcc) }, /* Aqua */
- { RGB_TO_YUV(0x66ff33) }, /* Light Green */
- { RGB_TO_YUV(0xccff33) }, /* Yellow */
-};
-
-static const unsigned char MV_REFERENCE_FRAME_colors[MAX_REF_FRAMES][3] = {
- { RGB_TO_YUV(0x00ff00) }, /* Blue */
- { RGB_TO_YUV(0x0000ff) }, /* Green */
- { RGB_TO_YUV(0xffff00) }, /* Yellow */
- { RGB_TO_YUV(0xff0000) }, /* Red */
-};
-#endif
-
extern void vp8_blit_text(const char *msg, unsigned char *address,
const int pitch);
extern void vp8_blit_line(int x0, int x1, int y0, int y1, unsigned char *image,
@@ -308,43 +268,6 @@ void vp8_blend_b_c(unsigned char *y, unsigned char *u, unsigned char *v,
}
}
-#if CONFIG_POSTPROC_VISUALIZER
-static void constrain_line(int x_0, int *x_1, int y_0, int *y_1, int width,
- int height) {
- int dx;
- int dy;
-
- if (*x_1 > width) {
- dx = *x_1 - x_0;
- dy = *y_1 - y_0;
-
- *x_1 = width;
- if (dx) *y_1 = ((width - x_0) * dy) / dx + y_0;
- }
- if (*x_1 < 0) {
- dx = *x_1 - x_0;
- dy = *y_1 - y_0;
-
- *x_1 = 0;
- if (dx) *y_1 = ((0 - x_0) * dy) / dx + y_0;
- }
- if (*y_1 > height) {
- dx = *x_1 - x_0;
- dy = *y_1 - y_0;
-
- *y_1 = height;
- if (dy) *x_1 = ((height - y_0) * dx) / dy + x_0;
- }
- if (*y_1 < 0) {
- dx = *x_1 - x_0;
- dy = *y_1 - y_0;
-
- *y_1 = 0;
- if (dy) *x_1 = ((0 - y_0) * dx) / dy + x_0;
- }
-}
-#endif // CONFIG_POSTPROC_VISUALIZER
-
#if CONFIG_POSTPROC
int vp8_post_proc_frame(VP8_COMMON *oci, YV12_BUFFER_CONFIG *dest,
vp8_ppflags_t *ppflags) {
@@ -455,331 +378,6 @@ int vp8_post_proc_frame(VP8_COMMON *oci, YV12_BUFFER_CONFIG *dest,
oci->post_proc_buffer.y_stride);
}
-#if CONFIG_POSTPROC_VISUALIZER
- if (flags & VP8D_DEBUG_TXT_FRAME_INFO) {
- char message[512];
- sprintf(message, "F%1dG%1dQ%3dF%3dP%d_s%dx%d",
- (oci->frame_type == KEY_FRAME), oci->refresh_golden_frame,
- oci->base_qindex, oci->filter_level, flags, oci->mb_cols,
- oci->mb_rows);
- vp8_blit_text(message, oci->post_proc_buffer.y_buffer,
- oci->post_proc_buffer.y_stride);
- }
-
- if (flags & VP8D_DEBUG_TXT_MBLK_MODES) {
- int i, j;
- unsigned char *y_ptr;
- YV12_BUFFER_CONFIG *post = &oci->post_proc_buffer;
- int mb_rows = post->y_height >> 4;
- int mb_cols = post->y_width >> 4;
- int mb_index = 0;
- MODE_INFO *mi = oci->mi;
-
- y_ptr = post->y_buffer + 4 * post->y_stride + 4;
-
- /* vp8_filter each macro block */
- for (i = 0; i < mb_rows; ++i) {
- for (j = 0; j < mb_cols; ++j) {
- char zz[4];
-
- sprintf(zz, "%c", mi[mb_index].mbmi.mode + 'a');
-
- vp8_blit_text(zz, y_ptr, post->y_stride);
- mb_index++;
- y_ptr += 16;
- }
-
- mb_index++; /* border */
- y_ptr += post->y_stride * 16 - post->y_width;
- }
- }
-
- if (flags & VP8D_DEBUG_TXT_DC_DIFF) {
- int i, j;
- unsigned char *y_ptr;
- YV12_BUFFER_CONFIG *post = &oci->post_proc_buffer;
- int mb_rows = post->y_height >> 4;
- int mb_cols = post->y_width >> 4;
- int mb_index = 0;
- MODE_INFO *mi = oci->mi;
-
- y_ptr = post->y_buffer + 4 * post->y_stride + 4;
-
- /* vp8_filter each macro block */
- for (i = 0; i < mb_rows; ++i) {
- for (j = 0; j < mb_cols; ++j) {
- char zz[4];
- int dc_diff = !(mi[mb_index].mbmi.mode != B_PRED &&
- mi[mb_index].mbmi.mode != SPLITMV &&
- mi[mb_index].mbmi.mb_skip_coeff);
-
- if (oci->frame_type == KEY_FRAME)
- sprintf(zz, "a");
- else
- sprintf(zz, "%c", dc_diff + '0');
-
- vp8_blit_text(zz, y_ptr, post->y_stride);
- mb_index++;
- y_ptr += 16;
- }
-
- mb_index++; /* border */
- y_ptr += post->y_stride * 16 - post->y_width;
- }
- }
-
- if (flags & VP8D_DEBUG_TXT_RATE_INFO) {
- char message[512];
- sprintf(message, "Bitrate: %10.2f framerate: %10.2f ", oci->bitrate,
- oci->framerate);
- vp8_blit_text(message, oci->post_proc_buffer.y_buffer,
- oci->post_proc_buffer.y_stride);
- }
-
- /* Draw motion vectors */
- if ((flags & VP8D_DEBUG_DRAW_MV) && ppflags->display_mv_flag) {
- YV12_BUFFER_CONFIG *post = &oci->post_proc_buffer;
- int width = post->y_width;
- int height = post->y_height;
- unsigned char *y_buffer = oci->post_proc_buffer.y_buffer;
- int y_stride = oci->post_proc_buffer.y_stride;
- MODE_INFO *mi = oci->mi;
- int x0, y0;
-
- for (y0 = 0; y0 < height; y0 += 16) {
- for (x0 = 0; x0 < width; x0 += 16) {
- int x1, y1;
-
- if (!(ppflags->display_mv_flag & (1 << mi->mbmi.mode))) {
- mi++;
- continue;
- }
-
- if (mi->mbmi.mode == SPLITMV) {
- switch (mi->mbmi.partitioning) {
- case 0: /* mv_top_bottom */
- {
- union b_mode_info *bmi = &mi->bmi[0];
- MV *mv = &bmi->mv.as_mv;
-
- x1 = x0 + 8 + (mv->col >> 3);
- y1 = y0 + 4 + (mv->row >> 3);
-
- constrain_line(x0 + 8, &x1, y0 + 4, &y1, width, height);
- vp8_blit_line(x0 + 8, x1, y0 + 4, y1, y_buffer, y_stride);
-
- bmi = &mi->bmi[8];
-
- x1 = x0 + 8 + (mv->col >> 3);
- y1 = y0 + 12 + (mv->row >> 3);
-
- constrain_line(x0 + 8, &x1, y0 + 12, &y1, width, height);
- vp8_blit_line(x0 + 8, x1, y0 + 12, y1, y_buffer, y_stride);
-
- break;
- }
- case 1: /* mv_left_right */
- {
- union b_mode_info *bmi = &mi->bmi[0];
- MV *mv = &bmi->mv.as_mv;
-
- x1 = x0 + 4 + (mv->col >> 3);
- y1 = y0 + 8 + (mv->row >> 3);
-
- constrain_line(x0 + 4, &x1, y0 + 8, &y1, width, height);
- vp8_blit_line(x0 + 4, x1, y0 + 8, y1, y_buffer, y_stride);
-
- bmi = &mi->bmi[2];
-
- x1 = x0 + 12 + (mv->col >> 3);
- y1 = y0 + 8 + (mv->row >> 3);
-
- constrain_line(x0 + 12, &x1, y0 + 8, &y1, width, height);
- vp8_blit_line(x0 + 12, x1, y0 + 8, y1, y_buffer, y_stride);
-
- break;
- }
- case 2: /* mv_quarters */
- {
- union b_mode_info *bmi = &mi->bmi[0];
- MV *mv = &bmi->mv.as_mv;
-
- x1 = x0 + 4 + (mv->col >> 3);
- y1 = y0 + 4 + (mv->row >> 3);
-
- constrain_line(x0 + 4, &x1, y0 + 4, &y1, width, height);
- vp8_blit_line(x0 + 4, x1, y0 + 4, y1, y_buffer, y_stride);
-
- bmi = &mi->bmi[2];
-
- x1 = x0 + 12 + (mv->col >> 3);
- y1 = y0 + 4 + (mv->row >> 3);
-
- constrain_line(x0 + 12, &x1, y0 + 4, &y1, width, height);
- vp8_blit_line(x0 + 12, x1, y0 + 4, y1, y_buffer, y_stride);
-
- bmi = &mi->bmi[8];
-
- x1 = x0 + 4 + (mv->col >> 3);
- y1 = y0 + 12 + (mv->row >> 3);
-
- constrain_line(x0 + 4, &x1, y0 + 12, &y1, width, height);
- vp8_blit_line(x0 + 4, x1, y0 + 12, y1, y_buffer, y_stride);
-
- bmi = &mi->bmi[10];
-
- x1 = x0 + 12 + (mv->col >> 3);
- y1 = y0 + 12 + (mv->row >> 3);
-
- constrain_line(x0 + 12, &x1, y0 + 12, &y1, width, height);
- vp8_blit_line(x0 + 12, x1, y0 + 12, y1, y_buffer, y_stride);
- break;
- }
- default: {
- union b_mode_info *bmi = mi->bmi;
- int bx0, by0;
-
- for (by0 = y0; by0 < (y0 + 16); by0 += 4) {
- for (bx0 = x0; bx0 < (x0 + 16); bx0 += 4) {
- MV *mv = &bmi->mv.as_mv;
-
- x1 = bx0 + 2 + (mv->col >> 3);
- y1 = by0 + 2 + (mv->row >> 3);
-
- constrain_line(bx0 + 2, &x1, by0 + 2, &y1, width, height);
- vp8_blit_line(bx0 + 2, x1, by0 + 2, y1, y_buffer, y_stride);
-
- bmi++;
- }
- }
- }
- }
- } else if (mi->mbmi.mode >= NEARESTMV) {
- MV *mv = &mi->mbmi.mv.as_mv;
- const int lx0 = x0 + 8;
- const int ly0 = y0 + 8;
-
- x1 = lx0 + (mv->col >> 3);
- y1 = ly0 + (mv->row >> 3);
-
- if (x1 != lx0 && y1 != ly0) {
- constrain_line(lx0, &x1, ly0 - 1, &y1, width, height);
- vp8_blit_line(lx0, x1, ly0 - 1, y1, y_buffer, y_stride);
-
- constrain_line(lx0, &x1, ly0 + 1, &y1, width, height);
- vp8_blit_line(lx0, x1, ly0 + 1, y1, y_buffer, y_stride);
- } else
- vp8_blit_line(lx0, x1, ly0, y1, y_buffer, y_stride);
- }
-
- mi++;
- }
- mi++;
- }
- }
-
- /* Color in block modes */
- if ((flags & VP8D_DEBUG_CLR_BLK_MODES) &&
- (ppflags->display_mb_modes_flag || ppflags->display_b_modes_flag)) {
- int y, x;
- YV12_BUFFER_CONFIG *post = &oci->post_proc_buffer;
- int width = post->y_width;
- int height = post->y_height;
- unsigned char *y_ptr = oci->post_proc_buffer.y_buffer;
- unsigned char *u_ptr = oci->post_proc_buffer.u_buffer;
- unsigned char *v_ptr = oci->post_proc_buffer.v_buffer;
- int y_stride = oci->post_proc_buffer.y_stride;
- MODE_INFO *mi = oci->mi;
-
- for (y = 0; y < height; y += 16) {
- for (x = 0; x < width; x += 16) {
- int Y = 0, U = 0, V = 0;
-
- if (mi->mbmi.mode == B_PRED &&
- ((ppflags->display_mb_modes_flag & B_PRED) ||
- ppflags->display_b_modes_flag)) {
- int by, bx;
- unsigned char *yl, *ul, *vl;
- union b_mode_info *bmi = mi->bmi;
-
- yl = y_ptr + x;
- ul = u_ptr + (x >> 1);
- vl = v_ptr + (x >> 1);
-
- for (by = 0; by < 16; by += 4) {
- for (bx = 0; bx < 16; bx += 4) {
- if ((ppflags->display_b_modes_flag & (1 << mi->mbmi.mode)) ||
- (ppflags->display_mb_modes_flag & B_PRED)) {
- Y = B_PREDICTION_MODE_colors[bmi->as_mode][0];
- U = B_PREDICTION_MODE_colors[bmi->as_mode][1];
- V = B_PREDICTION_MODE_colors[bmi->as_mode][2];
-
- vp8_blend_b(yl + bx, ul + (bx >> 1), vl + (bx >> 1), Y, U, V,
- 0xc000, y_stride);
- }
- bmi++;
- }
-
- yl += y_stride * 4;
- ul += y_stride * 1;
- vl += y_stride * 1;
- }
- } else if (ppflags->display_mb_modes_flag & (1 << mi->mbmi.mode)) {
- Y = MB_PREDICTION_MODE_colors[mi->mbmi.mode][0];
- U = MB_PREDICTION_MODE_colors[mi->mbmi.mode][1];
- V = MB_PREDICTION_MODE_colors[mi->mbmi.mode][2];
-
- vp8_blend_mb_inner(y_ptr + x, u_ptr + (x >> 1), v_ptr + (x >> 1), Y,
- U, V, 0xc000, y_stride);
- }
-
- mi++;
- }
- y_ptr += y_stride * 16;
- u_ptr += y_stride * 4;
- v_ptr += y_stride * 4;
-
- mi++;
- }
- }
-
- /* Color in frame reference blocks */
- if ((flags & VP8D_DEBUG_CLR_FRM_REF_BLKS) &&
- ppflags->display_ref_frame_flag) {
- int y, x;
- YV12_BUFFER_CONFIG *post = &oci->post_proc_buffer;
- int width = post->y_width;
- int height = post->y_height;
- unsigned char *y_ptr = oci->post_proc_buffer.y_buffer;
- unsigned char *u_ptr = oci->post_proc_buffer.u_buffer;
- unsigned char *v_ptr = oci->post_proc_buffer.v_buffer;
- int y_stride = oci->post_proc_buffer.y_stride;
- MODE_INFO *mi = oci->mi;
-
- for (y = 0; y < height; y += 16) {
- for (x = 0; x < width; x += 16) {
- int Y = 0, U = 0, V = 0;
-
- if (ppflags->display_ref_frame_flag & (1 << mi->mbmi.ref_frame)) {
- Y = MV_REFERENCE_FRAME_colors[mi->mbmi.ref_frame][0];
- U = MV_REFERENCE_FRAME_colors[mi->mbmi.ref_frame][1];
- V = MV_REFERENCE_FRAME_colors[mi->mbmi.ref_frame][2];
-
- vp8_blend_mb_outer(y_ptr + x, u_ptr + (x >> 1), v_ptr + (x >> 1), Y,
- U, V, 0xc000, y_stride);
- }
-
- mi++;
- }
- y_ptr += y_stride * 16;
- u_ptr += y_stride * 4;
- v_ptr += y_stride * 4;
-
- mi++;
- }
- }
-#endif
-
*dest = oci->post_proc_buffer;
/* handle problem with extending borders */
diff --git a/vp8/common/textblit.c b/vp8/common/textblit.c
deleted file mode 100644
index e7c15c4e4..000000000
--- a/vp8/common/textblit.c
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * Copyright (c) 2010 The WebM project authors. All Rights Reserved.
- *
- * Use of this source code is governed by a BSD-style license
- * that can be found in the LICENSE file in the root of the source
- * tree. An additional intellectual property rights grant can be found
- * in the file PATENTS. All contributing project authors may
- * be found in the AUTHORS file in the root of the source tree.
- */
-
-#include <stdlib.h>
-
-void vp8_blit_text(const char *msg, unsigned char *address, const int pitch) {
- int letter_bitmap;
- unsigned char *output_pos = address;
- int colpos;
- const int font[] = {
- 0x0, 0x5C00, 0x8020, 0xAFABEA, 0xD7EC0, 0x1111111, 0x1855740,
- 0x18000, 0x45C0, 0x74400, 0x51140, 0x23880, 0xC4000, 0x21080,
- 0x80000, 0x111110, 0xE9D72E, 0x87E40, 0x12AD732, 0xAAD62A, 0x4F94C4,
- 0x4D6B7, 0x456AA, 0x3E8423, 0xAAD6AA, 0xAAD6A2, 0x2800, 0x2A00,
- 0x8A880, 0x52940, 0x22A20, 0x15422, 0x6AD62E, 0x1E4A53E, 0xAAD6BF,
- 0x8C62E, 0xE8C63F, 0x118D6BF, 0x1094BF, 0xCAC62E, 0x1F2109F, 0x118FE31,
- 0xF8C628, 0x8A89F, 0x108421F, 0x1F1105F, 0x1F4105F, 0xE8C62E, 0x2294BF,
- 0x164C62E, 0x12694BF, 0x8AD6A2, 0x10FC21, 0x1F8421F, 0x744107, 0xF8220F,
- 0x1151151, 0x117041, 0x119D731, 0x47E0, 0x1041041, 0xFC400, 0x10440,
- 0x1084210, 0x820
- };
- colpos = 0;
-
- while (msg[colpos] != 0) {
- char letter = msg[colpos];
- int fontcol, fontrow;
-
- if (letter <= 'Z' && letter >= ' ')
- letter_bitmap = font[letter - ' '];
- else if (letter <= 'z' && letter >= 'a')
- letter_bitmap = font[letter - 'a' + 'A' - ' '];
- else
- letter_bitmap = font[0];
-
- for (fontcol = 6; fontcol >= 0; fontcol--)
- for (fontrow = 0; fontrow < 5; ++fontrow)
- output_pos[fontrow * pitch + fontcol] =
- ((letter_bitmap >> (fontcol * 5)) & (1 << fontrow) ? 255 : 0);
-
- output_pos += 7;
- colpos++;
- }
-}
-
-static void plot(const int x, const int y, unsigned char *image,
- const int pitch) {
- image[x + y * pitch] ^= 255;
-}
-
-/* Bresenham line algorithm */
-void vp8_blit_line(int x0, int x1, int y0, int y1, unsigned char *image,
- const int pitch) {
- int steep = abs(y1 - y0) > abs(x1 - x0);
- int deltax, deltay;
- int error, ystep, y, x;
-
- if (steep) {
- int t;
- t = x0;
- x0 = y0;
- y0 = t;
-
- t = x1;
- x1 = y1;
- y1 = t;
- }
-
- if (x0 > x1) {
- int t;
- t = x0;
- x0 = x1;
- x1 = t;
-
- t = y0;
- y0 = y1;
- y1 = t;
- }
-
- deltax = x1 - x0;
- deltay = abs(y1 - y0);
- error = deltax / 2;
-
- y = y0;
-
- if (y0 < y1)
- ystep = 1;
- else
- ystep = -1;
-
- if (steep) {
- for (x = x0; x <= x1; ++x) {
- plot(y, x, image, pitch);
-
- error = error - deltay;
- if (error < 0) {
- y = y + ystep;
- error = error + deltax;
- }
- }
- } else {
- for (x = x0; x <= x1; ++x) {
- plot(x, y, image, pitch);
-
- error = error - deltay;
- if (error < 0) {
- y = y + ystep;
- error = error + deltax;
- }
- }
- }
-}
diff --git a/vp8/vp8_common.mk b/vp8/vp8_common.mk
index d863a0a26..886b127d6 100644
--- a/vp8/vp8_common.mk
+++ b/vp8/vp8_common.mk
@@ -68,7 +68,6 @@ VP8_COMMON_SRCS-yes += common/vp8_entropymodedata.h
-VP8_COMMON_SRCS-$(CONFIG_POSTPROC_VISUALIZER) += common/textblit.c
VP8_COMMON_SRCS-yes += common/treecoder.c
VP8_COMMON_SRCS-$(ARCH_X86)$(ARCH_X86_64) += common/x86/filter_x86.c
diff --git a/vp8/vp8_dx_iface.c b/vp8/vp8_dx_iface.c
index cab0a9997..b1f8340d6 100644
--- a/vp8/vp8_dx_iface.c
+++ b/vp8/vp8_dx_iface.c
@@ -46,13 +46,6 @@ struct vpx_codec_alg_priv {
int decoder_init;
int postproc_cfg_set;
vp8_postproc_cfg_t postproc_cfg;
-#if CONFIG_POSTPROC_VISUALIZER
- unsigned int dbg_postproc_flag;
- int dbg_color_ref_frame_flag;
- int dbg_color_mb_modes_flag;
- int dbg_color_b_modes_flag;
- int dbg_display_mv_flag;
-#endif
vpx_decrypt_cb decrypt_cb;
void *decrypt_state;
vpx_image_t img;
@@ -478,22 +471,8 @@ static vpx_image_t *vp8_get_frame(vpx_codec_alg_priv_t *ctx,
if (ctx->base.init_flags & VPX_CODEC_USE_POSTPROC) {
flags.post_proc_flag = ctx->postproc_cfg.post_proc_flag;
-#if CONFIG_POSTPROC_VISUALIZER
- flags.post_proc_flag |=
- ((ctx->dbg_color_ref_frame_flag != 0) ? VP8D_DEBUG_CLR_FRM_REF_BLKS
- : 0) |
- ((ctx->dbg_color_mb_modes_flag != 0) ? VP8D_DEBUG_CLR_BLK_MODES : 0) |
- ((ctx->dbg_color_b_modes_flag != 0) ? VP8D_DEBUG_CLR_BLK_MODES : 0) |
- ((ctx->dbg_display_mv_flag != 0) ? VP8D_DEBUG_DRAW_MV : 0);
-#endif
flags.deblocking_level = ctx->postproc_cfg.deblocking_level;
flags.noise_level = ctx->postproc_cfg.noise_level;
-#if CONFIG_POSTPROC_VISUALIZER
- flags.display_ref_frame_flag = ctx->dbg_color_ref_frame_flag;
- flags.display_mb_modes_flag = ctx->dbg_color_mb_modes_flag;
- flags.display_b_modes_flag = ctx->dbg_color_b_modes_flag;
- flags.display_mv_flag = ctx->dbg_display_mv_flag;
-#endif
}
if (0 == vp8dx_get_raw_frame(ctx->yv12_frame_buffers.pbi[0], &sd,
@@ -589,54 +568,6 @@ static vpx_codec_err_t vp8_set_postproc(vpx_codec_alg_priv_t *ctx,
#endif
}
-static vpx_codec_err_t vp8_set_dbg_color_ref_frame(vpx_codec_alg_priv_t *ctx,
- va_list args) {
-#if CONFIG_POSTPROC_VISUALIZER && CONFIG_POSTPROC
- ctx->dbg_color_ref_frame_flag = va_arg(args, int);
- return VPX_CODEC_OK;
-#else
- (void)ctx;
- (void)args;
- return VPX_CODEC_INCAPABLE;
-#endif
-}
-
-static vpx_codec_err_t vp8_set_dbg_color_mb_modes(vpx_codec_alg_priv_t *ctx,
- va_list args) {
-#if CONFIG_POSTPROC_VISUALIZER && CONFIG_POSTPROC
- ctx->dbg_color_mb_modes_flag = va_arg(args, int);
- return VPX_CODEC_OK;
-#else
- (void)ctx;
- (void)args;
- return VPX_CODEC_INCAPABLE;
-#endif
-}
-
-static vpx_codec_err_t vp8_set_dbg_color_b_modes(vpx_codec_alg_priv_t *ctx,
- va_list args) {
-#if CONFIG_POSTPROC_VISUALIZER && CONFIG_POSTPROC
- ctx->dbg_color_b_modes_flag = va_arg(args, int);
- return VPX_CODEC_OK;
-#else
- (void)ctx;
- (void)args;
- return VPX_CODEC_INCAPABLE;
-#endif
-}
-
-static vpx_codec_err_t vp8_set_dbg_display_mv(vpx_codec_alg_priv_t *ctx,
- va_list args) {
-#if CONFIG_POSTPROC_VISUALIZER && CONFIG_POSTPROC
- ctx->dbg_display_mv_flag = va_arg(args, int);
- return VPX_CODEC_OK;
-#else
- (void)ctx;
- (void)args;
- return VPX_CODEC_INCAPABLE;
-#endif
-}
-
static vpx_codec_err_t vp8_get_last_ref_updates(vpx_codec_alg_priv_t *ctx,
va_list args) {
int *update_info = va_arg(args, int *);
@@ -706,10 +637,6 @@ vpx_codec_ctrl_fn_map_t vp8_ctf_maps[] = {
{ VP8_SET_REFERENCE, vp8_set_reference },
{ VP8_COPY_REFERENCE, vp8_get_reference },
{ VP8_SET_POSTPROC, vp8_set_postproc },
- { VP8_SET_DBG_COLOR_REF_FRAME, vp8_set_dbg_color_ref_frame },
- { VP8_SET_DBG_COLOR_MB_MODES, vp8_set_dbg_color_mb_modes },
- { VP8_SET_DBG_COLOR_B_MODES, vp8_set_dbg_color_b_modes },
- { VP8_SET_DBG_DISPLAY_MV, vp8_set_dbg_display_mv },
{ VP8D_GET_LAST_REF_UPDATES, vp8_get_last_ref_updates },
{ VP8D_GET_FRAME_CORRUPTED, vp8_get_frame_corrupted },
{ VP8D_GET_LAST_REF_USED, vp8_get_last_ref_frame },