diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2010-01-07 15:43:49 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2010-01-07 15:43:49 +0000 |
commit | 616251c924d9ea9bb0fcc4a5cf6ad241873500c6 (patch) | |
tree | 0a17249f260489b4a1c7bc917b1f0343606ba265 | |
parent | d6856c57084d7ae4f417072cc2b988269dcc8de7 (diff) | |
download | ffmpeg-616251c924d9ea9bb0fcc4a5cf6ad241873500c6.tar.gz |
Document decide_ac_pred() and restore_ac_coeffs().
Originally committed as revision 21063 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/h263.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libavcodec/h263.c b/libavcodec/h263.c index a3426ceb4d..198b34682e 100644 --- a/libavcodec/h263.c +++ b/libavcodec/h263.c @@ -368,6 +368,15 @@ static inline int get_block_rate(MpegEncContext * s, DCTELEM block[64], int bloc return rate; } + +/** + * Restores the ac coefficients in block that have been changed by decide_ac_pred(). + * This function also restores s->block_last_index. + * @param[in,out] block MB coefficients, these will be restored + * @param[in] dir ac prediction direction for each 8x8 block + * @param[out] st scantable for each 8x8 block + * @param[in] zigzag_last_index index refering to the last non zero coefficient in zigzag order + */ static inline void restore_ac_coeffs(MpegEncContext * s, DCTELEM block[6][64], int dir[6], uint8_t *st[6], int zigzag_last_index[6]) { int i, n; @@ -393,6 +402,11 @@ static inline void restore_ac_coeffs(MpegEncContext * s, DCTELEM block[6][64], i /** * Returns the optimal value (0 or 1) for the ac_pred element for the given MB in mpeg4. + * This function will also update s->block_last_index and s->ac_val. + * @param[in,out] block MB coefficients, these will be updated if 1 is returned + * @param[in] dir ac prediction direction for each 8x8 block + * @param[out] st scantable for each 8x8 block + * @param[out] zigzag_last_index index refering to the last non zero coefficient in zigzag order */ static inline int decide_ac_pred(MpegEncContext * s, DCTELEM block[6][64], int dir[6], uint8_t *st[6], int zigzag_last_index[6]) { |