diff options
author | Stefan Gehrer <stefan.gehrer@gmx.de> | 2007-07-07 10:27:44 +0400 |
---|---|---|
committer | Stefan Gehrer <stefan.gehrer@gmx.de> | 2007-07-07 10:27:44 +0400 |
commit | 8a35c8e71aa285c9ad19837307e5f93c97306885 (patch) | |
tree | 0001ca127ed7df6527705a3b22b7cf9378c6deae /libavcodec | |
parent | 25c899471decb181b03eaf45ba4b4a1c634c4248 (diff) |
setting intra prediction modes to default values
in inter macroblocks is now in its own inline
function
Originally committed as revision 9515 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/cavs.c | 5 | ||||
-rw-r--r-- | libavcodec/cavs.h | 5 |
2 files changed, 7 insertions, 3 deletions
diff --git a/libavcodec/cavs.c b/libavcodec/cavs.c index e92e869367..4e4e5923c8 100644 --- a/libavcodec/cavs.c +++ b/libavcodec/cavs.c @@ -352,9 +352,6 @@ static void inter_pred(AVSContext *h, enum mb_t mb_type) { h->s.dsp.avg_cavs_qpel_pixels_tab[1], h->s.dsp.avg_h264_chroma_pixels_tab[1],&h->mv[MV_FWD_X3]); } - /* set intra prediction modes to default values */ - h->pred_mode_Y[3] = h->pred_mode_Y[6] = INTRA_L_LP; - h->top_pred_Y[h->mbx*2+0] = h->top_pred_Y[h->mbx*2+1] = INTRA_L_LP; } /***************************************************************************** @@ -696,6 +693,7 @@ static void decode_mb_p(AVSContext *h, enum mb_t mb_type) { mv_pred(h, MV_FWD_X3, MV_FWD_X0, MV_PRED_MEDIAN, BLK_8X8, ref[3]); } inter_pred(h, mb_type); + set_intra_mode_default(h); store_mvs(h); if(mb_type != P_SKIP) decode_residual_inter(h); @@ -805,6 +803,7 @@ static void decode_mb_b(AVSContext *h, enum mb_t mb_type) { } } inter_pred(h, mb_type); + set_intra_mode_default(h); if(mb_type != B_SKIP) decode_residual_inter(h); filter_mb(h,mb_type); diff --git a/libavcodec/cavs.h b/libavcodec/cavs.h index 2d56d4bb1a..b30f0aca61 100644 --- a/libavcodec/cavs.h +++ b/libavcodec/cavs.h @@ -325,6 +325,11 @@ static inline void modify_mb_i(AVSContext *h, int *pred_mode_uv) { } } +static inline void set_intra_mode_default(AVSContext *h) { + h->pred_mode_Y[3] = h->pred_mode_Y[6] = INTRA_L_LP; + h->top_pred_Y[h->mbx*2+0] = h->top_pred_Y[h->mbx*2+1] = INTRA_L_LP; +} + static inline void set_mvs(vector_t *mv, enum block_t size) { switch(size) { case BLK_16X16: |