summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYunqing Wang <yunqingwang@google.com>2015-04-27 17:05:06 -0700
committerYunqing Wang <yunqingwang@google.com>2015-04-27 17:09:38 -0700
commit297b2b99dea954b4d88767e343e60eacc6843c06 (patch)
treeaacf3ff291d4182f586ca106f7c687f4d367f584
parent4feae6791c0da9535a1c4c347e473ebc996c9d39 (diff)
downloadlibvpx-297b2b99dea954b4d88767e343e60eacc6843c06.tar.gz
Fix debugmodes file to print modes and MVs correctly
This patch fixed the issues in debugmodes file because of the recent changes in MODE_INFO struct. Change-Id: I4df83379ecc887c1f009d4a8329c9809c5b299d6
-rw-r--r--vp9/common/vp9_debugmodes.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/vp9/common/vp9_debugmodes.c b/vp9/common/vp9_debugmodes.c
index 03fded01c..3d80103d2 100644
--- a/vp9/common/vp9_debugmodes.c
+++ b/vp9/common/vp9_debugmodes.c
@@ -25,7 +25,7 @@ static void log_frame_info(VP9_COMMON *cm, const char *str, FILE *f) {
static void print_mi_data(VP9_COMMON *cm, FILE *file, const char *descriptor,
size_t member_offset) {
int mi_row, mi_col;
- MODE_INFO *mi = cm->mi;
+ MODE_INFO **mi = cm->mi_grid_visible;
int rows = cm->mi_rows;
int cols = cm->mi_cols;
char prefix = descriptor[0];
@@ -35,7 +35,7 @@ static void print_mi_data(VP9_COMMON *cm, FILE *file, const char *descriptor,
fprintf(file, "%c ", prefix);
for (mi_col = 0; mi_col < cols; mi_col++) {
fprintf(file, "%2d ",
- *((int*) ((char *) (&mi->mbmi) +
+ *((int*) ((char *) (&mi[0]->mbmi) +
member_offset)));
mi++;
}
@@ -49,7 +49,7 @@ void vp9_print_modes_and_motion_vectors(VP9_COMMON *cm, const char *file) {
int mi_row;
int mi_col;
FILE *mvs = fopen(file, "a");
- MODE_INFO *mi = cm->mi;
+ MODE_INFO **mi = cm->mi_grid_visible;
int rows = cm->mi_rows;
int cols = cm->mi_cols;
@@ -64,7 +64,7 @@ void vp9_print_modes_and_motion_vectors(VP9_COMMON *cm, const char *file) {
for (mi_row = 0; mi_row < rows; mi_row++) {
fprintf(mvs, "S ");
for (mi_col = 0; mi_col < cols; mi_col++) {
- fprintf(mvs, "%2d ", mi->mbmi.skip);
+ fprintf(mvs, "%2d ", mi[0]->mbmi.skip);
mi++;
}
fprintf(mvs, "\n");
@@ -74,12 +74,12 @@ void vp9_print_modes_and_motion_vectors(VP9_COMMON *cm, const char *file) {
// output motion vectors.
log_frame_info(cm, "Vectors ", mvs);
- mi = cm->mi;
+ mi = cm->mi_grid_visible;
for (mi_row = 0; mi_row < rows; mi_row++) {
fprintf(mvs, "V ");
for (mi_col = 0; mi_col < cols; mi_col++) {
- fprintf(mvs, "%4d:%4d ", mi->mbmi.mv[0].as_mv.row,
- mi->mbmi.mv[0].as_mv.col);
+ fprintf(mvs, "%4d:%4d ", mi[0]->mbmi.mv[0].as_mv.row,
+ mi[0]->mbmi.mv[0].as_mv.col);
mi++;
}
fprintf(mvs, "\n");