comparison cook.c @ 4638:9f74306d4ac7 libavcodec

Don't output the first two frames, since they don't contain valid audio. This also eases comparison of decoded output with Real's binary decoder. Patch by Ian Braithwaite <ian at braithwaite dot dk>
author banan
date Thu, 08 Mar 2007 19:47:03 +0000
parents a96d905dcbaa
children 33fc84eae7c3
comparison
equal deleted inserted replaced
4637:fd9e324b3978 4638:9f74306d4ac7
1065 1065
1066 if (buf_size < avctx->block_align) 1066 if (buf_size < avctx->block_align)
1067 return buf_size; 1067 return buf_size;
1068 1068
1069 *data_size = decode_subpacket(q, buf, avctx->block_align, data); 1069 *data_size = decode_subpacket(q, buf, avctx->block_align, data);
1070
1071 /* Discard the first two frames: no valid audio. */
1072 if (avctx->frame_number < 2) *data_size = 0;
1070 1073
1071 return avctx->block_align; 1074 return avctx->block_align;
1072 } 1075 }
1073 1076
1074 #ifdef COOKDEBUG 1077 #ifdef COOKDEBUG