Originally committed as revision 7620 to svn://svn.ffmpeg.org/ffmpeg/trunk
Benjamin Larsson authored on 2007/01/22 06:24:05... | ... |
@@ -211,11 +211,12 @@ static int encode_bitstream(FlashSVContext *s, AVFrame *p, uint8_t *buf, int buf |
211 | 211 |
//av_log(avctx, AV_LOG_INFO, "compressed blocks: %d\n", size); |
212 | 212 |
*/ |
213 | 213 |
bytestream_put_be16(&ptr,(unsigned int)zsize); |
214 |
- buf_pos += zsize; |
|
214 |
+ buf_pos += zsize+2; |
|
215 | 215 |
//av_log(avctx, AV_LOG_ERROR, "buf_pos = %d\n", buf_pos); |
216 | 216 |
} else { |
217 | 217 |
pred_blocks++; |
218 | 218 |
bytestream_put_be16(&ptr,0); |
219 |
+ buf_pos += 2; |
|
219 | 220 |
} |
220 | 221 |
} |
221 | 222 |
} |
... | ... |
@@ -293,7 +294,7 @@ static int flashsv_encode_frame(AVCodecContext *avctx, uint8_t *buf, int buf_siz |
293 | 293 |
|
294 | 294 |
res = encode_bitstream(s, p, buf, buf_size, opt_w*16, opt_h*16, s->previous_frame, &I_frame); |
295 | 295 |
#endif |
296 |
- |
|
296 |
+ av_log(avctx, AV_LOG_ERROR, "res %d\n", res); |
|
297 | 297 |
//save the current frame |
298 | 298 |
memcpy(s->previous_frame, p->data[0], s->image_height*p->linesize[0]*3); |
299 | 299 |
|