Mercurial > libavcodec.hg
comparison ffv1.c @ 1360:047b1dff5976 libavcodec
simpler
author | michaelni |
---|---|
date | Sat, 12 Jul 2003 22:15:11 +0000 |
parents | daf951f32697 |
children | 8479b875a989 |
comparison
equal
deleted
inserted
replaced
1359:4c2febfefd78 | 1360:047b1dff5976 |
---|---|
183 | 183 |
184 static inline int predict(uint8_t *src, uint8_t *last){ | 184 static inline int predict(uint8_t *src, uint8_t *last){ |
185 const int LT= last[-1]; | 185 const int LT= last[-1]; |
186 const int T= last[ 0]; | 186 const int T= last[ 0]; |
187 const int L = src[-1]; | 187 const int L = src[-1]; |
188 uint8_t *cm = cropTbl + MAX_NEG_CROP; | 188 |
189 const int gradient= cm[L + T - LT]; | 189 return mid_pred(L, L + T - LT, T); |
190 | |
191 return mid_pred(L, gradient, T); | |
192 } | 190 } |
193 | 191 |
194 static inline int get_context(FFV1Context *f, uint8_t *src, uint8_t *last, uint8_t *last2){ | 192 static inline int get_context(FFV1Context *f, uint8_t *src, uint8_t *last, uint8_t *last2){ |
195 const int LT= last[-1]; | 193 const int LT= last[-1]; |
196 const int T= last[ 0]; | 194 const int T= last[ 0]; |