diff options
author | Scott LaVarnway <slavarnway@google.com> | 2015-06-11 12:29:44 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2015-06-11 12:29:45 +0000 |
commit | a49c7015298911f903d740c09d34b609e2be1a9b (patch) | |
tree | 19d7943dc8c007c9ff1b621b6aa696fe8e3d6078 /vp9/common | |
parent | c7489f48151c482d10e9c880ddf1313f5a210be9 (diff) | |
parent | 42c0b1b1f11f8e5714dac98a1b48d30f32cc0268 (diff) | |
download | libvpx-a49c7015298911f903d740c09d34b609e2be1a9b.tar libvpx-a49c7015298911f903d740c09d34b609e2be1a9b.tar.gz libvpx-a49c7015298911f903d740c09d34b609e2be1a9b.tar.bz2 libvpx-a49c7015298911f903d740c09d34b609e2be1a9b.zip |
Merge "inline vp9_segfeature_active()"
Diffstat (limited to 'vp9/common')
-rw-r--r-- | vp9/common/vp9_loopfilter.c | 2 | ||||
-rw-r--r-- | vp9/common/vp9_quant_common.c | 2 | ||||
-rw-r--r-- | vp9/common/vp9_seg_common.c | 6 | ||||
-rw-r--r-- | vp9/common/vp9_seg_common.h | 9 |
4 files changed, 8 insertions, 11 deletions
diff --git a/vp9/common/vp9_loopfilter.c b/vp9/common/vp9_loopfilter.c index 484e457df..f95ff2146 100644 --- a/vp9/common/vp9_loopfilter.c +++ b/vp9/common/vp9_loopfilter.c @@ -267,7 +267,7 @@ void vp9_loop_filter_frame_init(VP9_COMMON *cm, int default_filt_lvl) { for (seg_id = 0; seg_id < MAX_SEGMENTS; seg_id++) { int lvl_seg = default_filt_lvl; - if (vp9_segfeature_active(seg, seg_id, SEG_LVL_ALT_LF)) { + if (segfeature_active(seg, seg_id, SEG_LVL_ALT_LF)) { const int data = vp9_get_segdata(seg, seg_id, SEG_LVL_ALT_LF); lvl_seg = clamp(seg->abs_delta == SEGMENT_ABSDATA ? data : default_filt_lvl + data, diff --git a/vp9/common/vp9_quant_common.c b/vp9/common/vp9_quant_common.c index 564a3eb0c..504288075 100644 --- a/vp9/common/vp9_quant_common.c +++ b/vp9/common/vp9_quant_common.c @@ -266,7 +266,7 @@ int16_t vp9_ac_quant(int qindex, int delta, vpx_bit_depth_t bit_depth) { int vp9_get_qindex(const struct segmentation *seg, int segment_id, int base_qindex) { - if (vp9_segfeature_active(seg, segment_id, SEG_LVL_ALT_Q)) { + if (segfeature_active(seg, segment_id, SEG_LVL_ALT_Q)) { const int data = vp9_get_segdata(seg, segment_id, SEG_LVL_ALT_Q); const int seg_qindex = seg->abs_delta == SEGMENT_ABSDATA ? data : base_qindex + data; diff --git a/vp9/common/vp9_seg_common.c b/vp9/common/vp9_seg_common.c index 910200ecc..78e842c05 100644 --- a/vp9/common/vp9_seg_common.c +++ b/vp9/common/vp9_seg_common.c @@ -25,12 +25,6 @@ static const int seg_feature_data_max[SEG_LVL_MAX] = { // the coding mechanism is still subject to change so these provide a // convenient single point of change. -int vp9_segfeature_active(const struct segmentation *seg, int segment_id, - SEG_LVL_FEATURES feature_id) { - return seg->enabled && - (seg->feature_mask[segment_id] & (1 << feature_id)); -} - void vp9_clearall_segfeatures(struct segmentation *seg) { vp9_zero(seg->feature_data); vp9_zero(seg->feature_mask); diff --git a/vp9/common/vp9_seg_common.h b/vp9/common/vp9_seg_common.h index ff2d66a36..679476388 100644 --- a/vp9/common/vp9_seg_common.h +++ b/vp9/common/vp9_seg_common.h @@ -49,9 +49,12 @@ struct segmentation { unsigned int feature_mask[MAX_SEGMENTS]; }; -int vp9_segfeature_active(const struct segmentation *seg, - int segment_id, - SEG_LVL_FEATURES feature_id); +static INLINE int segfeature_active(const struct segmentation *seg, + int segment_id, + SEG_LVL_FEATURES feature_id) { + return seg->enabled && + (seg->feature_mask[segment_id] & (1 << feature_id)); +} void vp9_clearall_segfeatures(struct segmentation *seg); |