# HG changeset patch # User bcoudurier # Date 1235549290 0 # Node ID 3e1796a40c4df5b36e85bacd6cffe3dd04c2ec59 # Parent f3b6979fee40407c69e9c6ef443c82e4ef2d83af simplify, use codec->block_align diff -r f3b6979fee40 -r 3e1796a40c4d mxfenc.c --- a/mxfenc.c Wed Feb 25 08:06:15 2009 +0000 +++ b/mxfenc.c Wed Feb 25 08:08:10 2009 +0000 @@ -1592,8 +1592,7 @@ { MXFContext *mxf = s->priv_data; ByteIOContext *pb = s->pb; - int frame_size = (pkt->size<<3) / - (st->codec->channels*av_get_bits_per_sample(st->codec->codec_id)); + int frame_size = pkt->size / st->codec->block_align; uint8_t *samples = pkt->data; uint8_t *end = pkt->data + pkt->size; int i;