Commit b066bb43 authored by Ronald S. Bultje's avatar Ronald S. Bultje
Browse files

seg_common: give all exported symbols a vp9_ prefix.

Change-Id: Ie8ba934a757acec1c80ac37ab9307c9a2783254e
parent d36cc98e
...@@ -122,12 +122,12 @@ void vp8_loop_filter_frame_init(VP8_COMMON *cm, ...@@ -122,12 +122,12 @@ void vp8_loop_filter_frame_init(VP8_COMMON *cm,
// Set the baseline filter values for each segment // Set the baseline filter values for each segment
if (segfeature_active(xd, seg, SEG_LVL_ALT_LF)) { if (vp9_segfeature_active(xd, seg, SEG_LVL_ALT_LF)) {
/* Abs value */ /* Abs value */
if (xd->mb_segment_abs_delta == SEGMENT_ABSDATA) { if (xd->mb_segment_abs_delta == SEGMENT_ABSDATA) {
lvl_seg = get_segdata(xd, seg, SEG_LVL_ALT_LF); lvl_seg = vp9_get_segdata(xd, seg, SEG_LVL_ALT_LF);
} else { /* Delta Value */ } else { /* Delta Value */
lvl_seg += get_segdata(xd, seg, SEG_LVL_ALT_LF);; lvl_seg += vp9_get_segdata(xd, seg, SEG_LVL_ALT_LF);
lvl_seg = (lvl_seg > 0) ? ((lvl_seg > 63) ? 63 : lvl_seg) : 0; lvl_seg = (lvl_seg > 0) ? ((lvl_seg > 63) ? 63 : lvl_seg) : 0;
} }
} }
...@@ -476,7 +476,7 @@ void vp8_loop_filter_frame_segment(VP8_COMMON *cm, MACROBLOCKD *xd, ...@@ -476,7 +476,7 @@ void vp8_loop_filter_frame_segment(VP8_COMMON *cm, MACROBLOCKD *xd,
// TODO: Make this work for when segment 0 has the alt lv enabled // TODO: Make this work for when segment 0 has the alt lv enabled
if (filter_level if (filter_level
&& (seg == segment && (seg == segment
|| (!segfeature_active(xd, seg, SEG_LVL_ALT_LF) || (!vp9_segfeature_active(xd, seg, SEG_LVL_ALT_LF)
&& segment == 0))) { && segment == 0))) {
if (cm->filter_type == NORMAL_LOOPFILTER) { if (cm->filter_type == NORMAL_LOOPFILTER) {
const int hev_index = const int hev_index =
...@@ -576,12 +576,12 @@ void vp8_loop_filter_partial_frame ...@@ -576,12 +576,12 @@ void vp8_loop_filter_partial_frame
for (i = 0; i < MAX_MB_SEGMENTS; i++) { for (i = 0; i < MAX_MB_SEGMENTS; i++) {
/* Abs value */ /* Abs value */
if (xd->mb_segment_abs_delta == SEGMENT_ABSDATA) { if (xd->mb_segment_abs_delta == SEGMENT_ABSDATA) {
lvl_seg[i] = get_segdata(xd, i, SEG_LVL_ALT_LF); lvl_seg[i] = vp9_get_segdata(xd, i, SEG_LVL_ALT_LF);
} }
/* Delta Value */ /* Delta Value */
else { else {
lvl_seg[i] = default_filt_lvl + lvl_seg[i] = default_filt_lvl +
get_segdata(xd, i, SEG_LVL_ALT_LF); vp9_get_segdata(xd, i, SEG_LVL_ALT_LF);
lvl_seg[i] = (lvl_seg[i] > 0) ? lvl_seg[i] = (lvl_seg[i] > 0) ?
((lvl_seg[i] > 63) ? 63 : lvl_seg[i]) : 0; ((lvl_seg[i] > 63) ? 63 : lvl_seg[i]) : 0;
} }
......
...@@ -326,7 +326,7 @@ MV_REFERENCE_FRAME vp9_get_pred_ref(const VP8_COMMON *const cm, ...@@ -326,7 +326,7 @@ MV_REFERENCE_FRAME vp9_get_pred_ref(const VP8_COMMON *const cm,
unsigned char above_left_in_image; unsigned char above_left_in_image;
// Is segment coding ennabled // Is segment coding ennabled
seg_ref_active = segfeature_active(xd, segment_id, SEG_LVL_REF_FRAME); seg_ref_active = vp9_segfeature_active(xd, segment_id, SEG_LVL_REF_FRAME);
// Special case treatment if segment coding is enabled. // Special case treatment if segment coding is enabled.
// Dont allow prediction of a reference frame that the segment // Dont allow prediction of a reference frame that the segment
...@@ -334,7 +334,7 @@ MV_REFERENCE_FRAME vp9_get_pred_ref(const VP8_COMMON *const cm, ...@@ -334,7 +334,7 @@ MV_REFERENCE_FRAME vp9_get_pred_ref(const VP8_COMMON *const cm,
if (seg_ref_active) { if (seg_ref_active) {
for (i = 0; i < MAX_REF_FRAMES; i++) { for (i = 0; i < MAX_REF_FRAMES; i++) {
frame_allowed[i] = frame_allowed[i] =
check_segref(xd, segment_id, i); vp9_check_segref(xd, segment_id, i);
// Score set to 0 if ref frame not allowed // Score set to 0 if ref frame not allowed
ref_score[i] = cm->ref_scores[i] * frame_allowed[i]; ref_score[i] = cm->ref_scores[i] * frame_allowed[i];
......
...@@ -19,77 +19,78 @@ const int vp8_seg_feature_data_bits[SEG_LVL_MAX] = ...@@ -19,77 +19,78 @@ const int vp8_seg_feature_data_bits[SEG_LVL_MAX] =
// the coding mechanism is still subject to change so these provide a // the coding mechanism is still subject to change so these provide a
// convenient single point of change. // convenient single point of change.
int segfeature_active(const MACROBLOCKD *xd, int vp9_segfeature_active(const MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
// Return true if mask bit set and segmentation enabled. // Return true if mask bit set and segmentation enabled.
return (xd->segmentation_enabled && return (xd->segmentation_enabled &&
(xd->segment_feature_mask[segment_id] & (xd->segment_feature_mask[segment_id] &
(0x01 << feature_id))); (0x01 << feature_id)));
} }
void clearall_segfeatures(MACROBLOCKD *xd) { void vp9_clearall_segfeatures(MACROBLOCKD *xd) {
vpx_memset(xd->segment_feature_data, 0, sizeof(xd->segment_feature_data)); vpx_memset(xd->segment_feature_data, 0, sizeof(xd->segment_feature_data));
vpx_memset(xd->segment_feature_mask, 0, sizeof(xd->segment_feature_mask)); vpx_memset(xd->segment_feature_mask, 0, sizeof(xd->segment_feature_mask));
} }
void enable_segfeature(MACROBLOCKD *xd, void vp9_enable_segfeature(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
xd->segment_feature_mask[segment_id] |= (0x01 << feature_id); xd->segment_feature_mask[segment_id] |= (0x01 << feature_id);
} }
void disable_segfeature(MACROBLOCKD *xd, void vp9_disable_segfeature(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
xd->segment_feature_mask[segment_id] &= ~(1 << feature_id); xd->segment_feature_mask[segment_id] &= ~(1 << feature_id);
} }
int seg_feature_data_bits(SEG_LVL_FEATURES feature_id) { int vp9_seg_feature_data_bits(SEG_LVL_FEATURES feature_id) {
return vp8_seg_feature_data_bits[feature_id]; return vp8_seg_feature_data_bits[feature_id];
} }
int is_segfeature_signed(SEG_LVL_FEATURES feature_id) { int vp9_is_segfeature_signed(SEG_LVL_FEATURES feature_id) {
return (segfeaturedata_signed[feature_id]); return (segfeaturedata_signed[feature_id]);
} }
void clear_segdata(MACROBLOCKD *xd, void vp9_clear_segdata(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
xd->segment_feature_data[segment_id][feature_id] = 0; xd->segment_feature_data[segment_id][feature_id] = 0;
} }
void set_segdata(MACROBLOCKD *xd, void vp9_set_segdata(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id, SEG_LVL_FEATURES feature_id,
int seg_data) { int seg_data) {
xd->segment_feature_data[segment_id][feature_id] = seg_data; xd->segment_feature_data[segment_id][feature_id] = seg_data;
} }
int get_segdata(const MACROBLOCKD *xd, int vp9_get_segdata(const MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
return xd->segment_feature_data[segment_id][feature_id]; return xd->segment_feature_data[segment_id][feature_id];
} }
#if CONFIG_FEATUREUPDATES #if CONFIG_FEATUREUPDATES
int old_segfeature_active(MACROBLOCKD *xd, int vp9_old_segfeature_active(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
// Return true if mask bit set and segmentation enabled. // Return true if mask bit set and segmentation enabled.
return (xd->segmentation_enabled && return (xd->segmentation_enabled &&
(xd->old_segment_feature_mask[segment_id] & (xd->old_segment_feature_mask[segment_id] &
(0x01 << feature_id))); (0x01 << feature_id)));
} }
int get_old_segdata(MACROBLOCKD *xd, int vp9_get_old_segdata(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
return xd->old_segment_feature_data[segment_id][feature_id]; return xd->old_segment_feature_data[segment_id][feature_id];
} }
int segfeature_changed(MACROBLOCKD *xd, int vp9_segfeature_changed(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id) { SEG_LVL_FEATURES feature_id) {
// Return true if mask bit or data is different from last time // Return true if mask bit or data is different from last time
return return
(xd->segmentation_enabled && (xd->segmentation_enabled &&
...@@ -102,7 +103,7 @@ int segfeature_changed(MACROBLOCKD *xd, ...@@ -102,7 +103,7 @@ int segfeature_changed(MACROBLOCKD *xd,
); );
} }
void save_segment_info(MACROBLOCKD *xd) { void vp9_save_segment_info(MACROBLOCKD *xd) {
int i, j; int i, j;
for (i = 0; i < MAX_MB_SEGMENTS; i++) { for (i = 0; i < MAX_MB_SEGMENTS; i++) {
xd->old_segment_feature_mask[i] = xd->segment_feature_mask[i]; xd->old_segment_feature_mask[i] = xd->segment_feature_mask[i];
...@@ -115,32 +116,32 @@ void save_segment_info(MACROBLOCKD *xd) { ...@@ -115,32 +116,32 @@ void save_segment_info(MACROBLOCKD *xd) {
} }
} }
#endif #endif
void clear_segref(MACROBLOCKD *xd, int segment_id) { void vp9_clear_segref(MACROBLOCKD *xd, int segment_id) {
xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] = 0; xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] = 0;
} }
void set_segref(MACROBLOCKD *xd, void vp9_set_segref(MACROBLOCKD *xd,
int segment_id, int segment_id,
MV_REFERENCE_FRAME ref_frame) { MV_REFERENCE_FRAME ref_frame) {
xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] |= xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] |=
(1 << ref_frame); (1 << ref_frame);
} }
int check_segref(const MACROBLOCKD *xd, int vp9_check_segref(const MACROBLOCKD *xd,
int segment_id, int segment_id,
MV_REFERENCE_FRAME ref_frame) { MV_REFERENCE_FRAME ref_frame) {
return (xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] & return (xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] &
(1 << ref_frame)) ? 1 : 0; (1 << ref_frame)) ? 1 : 0;
} }
int check_segref_inter(MACROBLOCKD *xd, int segment_id) { int vp9_check_segref_inter(MACROBLOCKD *xd, int segment_id) {
return (xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] & return (xd->segment_feature_data[segment_id][SEG_LVL_REF_FRAME] &
~(1 << INTRA_FRAME)) ? 1 : 0; ~(1 << INTRA_FRAME)) ? 1 : 0;
} }
int get_seg_tx_type(MACROBLOCKD *xd, int segment_id) { int vp9_get_seg_tx_type(MACROBLOCKD *xd, int segment_id) {
if (segfeature_active(xd, segment_id, SEG_LVL_TRANSFORM)) if (vp9_segfeature_active(xd, segment_id, SEG_LVL_TRANSFORM))
return get_segdata(xd, segment_id, SEG_LVL_TRANSFORM); return vp9_get_segdata(xd, segment_id, SEG_LVL_TRANSFORM);
else else
return TX_4X4; return TX_4X4;
} }
......
...@@ -15,71 +15,71 @@ ...@@ -15,71 +15,71 @@
#ifndef __INC_SEG_COMMON_H__ #ifndef __INC_SEG_COMMON_H__
#define __INC_SEG_COMMON_H__ 1 #define __INC_SEG_COMMON_H__ 1
int segfeature_active(const MACROBLOCKD *xd, int vp9_segfeature_active(const MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
void clearall_segfeatures(MACROBLOCKD *xd); void vp9_clearall_segfeatures(MACROBLOCKD *xd);
void enable_segfeature(MACROBLOCKD *xd, void vp9_enable_segfeature(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
void disable_segfeature(MACROBLOCKD *xd, void vp9_disable_segfeature(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
int seg_feature_data_bits(SEG_LVL_FEATURES feature_id); int vp9_seg_feature_data_bits(SEG_LVL_FEATURES feature_id);
int is_segfeature_signed(SEG_LVL_FEATURES feature_id); int vp9_is_segfeature_signed(SEG_LVL_FEATURES feature_id);
void clear_segdata(MACROBLOCKD *xd, void vp9_clear_segdata(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
void set_segdata(MACROBLOCKD *xd, void vp9_set_segdata(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id, SEG_LVL_FEATURES feature_id,
int seg_data); int seg_data);
int get_segdata(const MACROBLOCKD *xd, int vp9_get_segdata(const MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
#if CONFIG_FEATUREUPDATES #if CONFIG_FEATUREUPDATES
int old_segfeature_active(MACROBLOCKD *xd, int vp9_old_segfeature_active(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
int get_old_segdata(MACROBLOCKD *xd, int vp9_get_old_segdata(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
void save_segment_info(MACROBLOCKD *xd); void vp9_save_segment_info(MACROBLOCKD *xd);
int segfeature_changed(MACROBLOCKD *xd, int vp9_segfeature_changed(MACROBLOCKD *xd,
int segment_id, int segment_id,
SEG_LVL_FEATURES feature_id); SEG_LVL_FEATURES feature_id);
#endif #endif
void clear_segref(MACROBLOCKD *xd, int segment_id); void vp9_clear_segref(MACROBLOCKD *xd, int segment_id);
void set_segref(MACROBLOCKD *xd, void vp9_set_segref(MACROBLOCKD *xd,
int segment_id, int segment_id,
MV_REFERENCE_FRAME ref_frame); MV_REFERENCE_FRAME ref_frame);
int check_segref(const MACROBLOCKD *xd, int vp9_check_segref(const MACROBLOCKD *xd,
int segment_id, int segment_id,
MV_REFERENCE_FRAME ref_frame); MV_REFERENCE_FRAME ref_frame);
int check_segref_inter(MACROBLOCKD *xd, int segment_id); int vp9_check_segref_inter(MACROBLOCKD *xd, int segment_id);
int get_seg_tx_type(MACROBLOCKD *xd, int segment_id); int vp9_get_seg_tx_type(MACROBLOCKD *xd, int segment_id);
#endif /* __INC_SEG_COMMON_H__ */ #endif /* __INC_SEG_COMMON_H__ */
...@@ -110,18 +110,18 @@ static void kfread_modes(VP8D_COMP *pbi, ...@@ -110,18 +110,18 @@ static void kfread_modes(VP8D_COMP *pbi,
m->mbmi.mb_skip_coeff = 0; m->mbmi.mb_skip_coeff = 0;
if (pbi->common.mb_no_coeff_skip && if (pbi->common.mb_no_coeff_skip &&
(!segfeature_active(&pbi->mb, (!vp9_segfeature_active(&pbi->mb,
m->mbmi.segment_id, SEG_LVL_EOB) || m->mbmi.segment_id, SEG_LVL_EOB) ||
(get_segdata(&pbi->mb, (vp9_get_segdata(&pbi->mb,
m->mbmi.segment_id, SEG_LVL_EOB) != 0))) { m->mbmi.segment_id, SEG_LVL_EOB) != 0))) {
MACROBLOCKD *const xd = &pbi->mb; MACROBLOCKD *const xd = &pbi->mb;
m->mbmi.mb_skip_coeff = m->mbmi.mb_skip_coeff =
vp8_read(bc, vp9_get_pred_prob(cm, xd, PRED_MBSKIP)); vp8_read(bc, vp9_get_pred_prob(cm, xd, PRED_MBSKIP));
} else { } else {
if (segfeature_active(&pbi->mb, if (vp9_segfeature_active(&pbi->mb,
m->mbmi.segment_id, SEG_LVL_EOB) && m->mbmi.segment_id, SEG_LVL_EOB) &&
(get_segdata(&pbi->mb, (vp9_get_segdata(&pbi->mb,
m->mbmi.segment_id, SEG_LVL_EOB) == 0)) { m->mbmi.segment_id, SEG_LVL_EOB) == 0)) {
m->mbmi.mb_skip_coeff = 1; m->mbmi.mb_skip_coeff = 1;
} else } else
m->mbmi.mb_skip_coeff = 0; m->mbmi.mb_skip_coeff = 0;
...@@ -363,17 +363,17 @@ static MV_REFERENCE_FRAME read_ref_frame(VP8D_COMP *pbi, ...@@ -363,17 +363,17 @@ static MV_REFERENCE_FRAME read_ref_frame(VP8D_COMP *pbi,
VP8_COMMON *const cm = &pbi->common; VP8_COMMON *const cm = &pbi->common;
MACROBLOCKD *const xd = &pbi->mb; MACROBLOCKD *const xd = &pbi->mb;
seg_ref_active = segfeature_active(xd, seg_ref_active = vp9_segfeature_active(xd,
segment_id, segment_id,
SEG_LVL_REF_FRAME); SEG_LVL_REF_FRAME);
// If segment coding enabled does the segment allow for more than one // If segment coding enabled does the segment allow for more than one
// possible reference frame // possible reference frame
if (seg_ref_active) { if (seg_ref_active) {
seg_ref_count = check_segref(xd, segment_id, INTRA_FRAME) + seg_ref_count = vp9_check_segref(xd, segment_id, INTRA_FRAME) +
check_segref(xd, segment_id, LAST_FRAME) + vp9_check_segref(xd, segment_id, LAST_FRAME) +
check_segref(xd, segment_id, GOLDEN_FRAME) + vp9_check_segref(xd, segment_id, GOLDEN_FRAME) +
check_segref(xd, segment_id, ALTREF_FRAME); vp9_check_segref(xd, segment_id, ALTREF_FRAME);
} }
// Segment reference frame features not available or allows for // Segment reference frame features not available or allows for
...@@ -410,12 +410,12 @@ static MV_REFERENCE_FRAME read_ref_frame(VP8D_COMP *pbi, ...@@ -410,12 +410,12 @@ static MV_REFERENCE_FRAME read_ref_frame(VP8D_COMP *pbi,
// setting the branch probability to 0. // setting the branch probability to 0.
if (seg_ref_active) { if (seg_ref_active) {
mod_refprobs[INTRA_FRAME] *= mod_refprobs[INTRA_FRAME] *=
check_segref(xd, segment_id, INTRA_FRAME); vp9_check_segref(xd, segment_id, INTRA_FRAME);
mod_refprobs[LAST_FRAME] *= mod_refprobs[LAST_FRAME] *=
check_segref(xd, segment_id, LAST_FRAME); vp9_check_segref(xd, segment_id, LAST_FRAME);
mod_refprobs[GOLDEN_FRAME] *= mod_refprobs[GOLDEN_FRAME] *=
(check_segref(xd, segment_id, GOLDEN_FRAME) * (vp9_check_segref(xd, segment_id, GOLDEN_FRAME) *
check_segref(xd, segment_id, ALTREF_FRAME)); vp9_check_segref(xd, segment_id, ALTREF_FRAME));
} }
// Default to INTRA_FRAME (value 0) // Default to INTRA_FRAME (value 0)
...@@ -441,7 +441,7 @@ static MV_REFERENCE_FRAME read_ref_frame(VP8D_COMP *pbi, ...@@ -441,7 +441,7 @@ static MV_REFERENCE_FRAME read_ref_frame(VP8D_COMP *pbi,
else { else {
if (seg_ref_active) { if (seg_ref_active) {
if ((pred_ref == GOLDEN_FRAME) || if ((pred_ref == GOLDEN_FRAME) ||
!check_segref(xd, segment_id, GOLDEN_FRAME)) { !vp9_check_segref(xd, segment_id, GOLDEN_FRAME)) {
ref_frame = ALTREF_FRAME; ref_frame = ALTREF_FRAME;
} else } else
ref_frame = GOLDEN_FRAME; ref_frame = GOLDEN_FRAME;
...@@ -689,16 +689,16 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi, ...@@ -689,16 +689,16 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi,
read_mb_segment_id(pbi, mb_row, mb_col, bc); read_mb_segment_id(pbi, mb_row, mb_col, bc);
if (pbi->common.mb_no_coeff_skip && if (pbi->common.mb_no_coeff_skip &&
(!segfeature_active(xd, (!vp9_segfeature_active(xd,
mbmi->segment_id, SEG_LVL_EOB) || mbmi->segment_id, SEG_LVL_EOB) ||
(get_segdata(xd, mbmi->segment_id, SEG_LVL_EOB) != 0))) { (vp9_get_segdata(xd, mbmi->segment_id, SEG_LVL_EOB) != 0))) {
// Read the macroblock coeff skip flag if this feature is in use, // Read the macroblock coeff skip flag if this feature is in use,
// else default to 0 // else default to 0
mbmi->mb_skip_coeff = vp8_read(bc, vp9_get_pred_prob(cm, xd, PRED_MBSKIP)); mbmi->mb_skip_coeff = vp8_read(bc, vp9_get_pred_prob(cm, xd, PRED_MBSKIP));
} else { } else {
if (segfeature_active(xd, if (vp9_segfeature_active(xd,
mbmi->segment_id, SEG_LVL_EOB) && mbmi->segment_id, SEG_LVL_EOB) &&
(get_segdata(xd, mbmi->segment_id, SEG_LVL_EOB) == 0)) { (vp9_get_segdata(xd, mbmi->segment_id, SEG_LVL_EOB) == 0)) {
mbmi->mb_skip_coeff = 1; mbmi->mb_skip_coeff = 1;
} else } else
mbmi->mb_skip_coeff = 0; mbmi->mb_skip_coeff = 0;
...@@ -762,9 +762,9 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi, ...@@ -762,9 +762,9 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi,
vp8_mv_ref_probs(&pbi->common, mv_ref_p, rct); vp8_mv_ref_probs(&pbi->common, mv_ref_p, rct);
// Is the segment level mode feature enabled for this segment // Is the segment level mode feature enabled for this segment
if (segfeature_active(xd, mbmi->segment_id, SEG_LVL_MODE)) { if (vp9_segfeature_active(xd, mbmi->segment_id, SEG_LVL_MODE)) {
mbmi->mode = mbmi->mode =
get_segdata(xd, mbmi->segment_id, SEG_LVL_MODE); vp9_get_segdata(xd, mbmi->segment_id, SEG_LVL_MODE);
} else { } else {
#if CONFIG_SUPERBLOCKS #if CONFIG_SUPERBLOCKS
if (mbmi->encoded_as_sb) { if (mbmi->encoded_as_sb) {
...@@ -1077,9 +1077,9 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi, ...@@ -1077,9 +1077,9 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi,
/* required for left and above block mv */ /* required for left and above block mv */
mbmi->mv[0].as_int = 0; mbmi->mv[0].as_int = 0;
if (segfeature_active(xd, mbmi->segment_id, SEG_LVL_MODE)) if (vp9_segfeature_active(xd, mbmi->segment_id, SEG_LVL_MODE))
mbmi->mode = (MB_PREDICTION_MODE) mbmi->mode = (MB_PREDICTION_MODE)
get_segdata(xd, mbmi->segment_id, SEG_LVL_MODE); vp9_get_segdata(xd, mbmi->segment_id, SEG_LVL_MODE);
else { else {
// FIXME write using SB mode tree // FIXME write using SB mode tree
mbmi->mode = (MB_PREDICTION_MODE) mbmi->mode = (MB_PREDICTION_MODE)
......
...@@ -102,15 +102,15 @@ static void mb_init_dequantizer(VP8D_COMP *pbi, MACROBLOCKD *xd) { ...@@ -102,15 +102,15 @@ static void mb_init_dequantizer(VP8D_COMP *pbi, MACROBLOCKD *xd) {
int segment_id = xd->mode_info_context->mbmi.segment_id; int segment_id = xd->mode_info_context->mbmi.segment_id;
// Set the Q baseline allowing for any segment level adjustment // Set the Q baseline allowing for any segment level adjustment
if (segfeature_active(xd, segment_id, SEG_LVL_ALT_Q)) { if (vp9_segfeature_active(xd, segment_id, SEG_LVL_ALT_Q)) {
/* Abs Value */