35 if (avctx->
width & 1) {
57 if (bytestream_get_le32(&buf) !=
MKTAG(
'F',
'R',
'W',
'1')) {
68 for (field = 0; field < 2; field++) {
70 int field_h = (avctx->
height + !field) >> 1;
71 int field_size, min_field_size = avctx->
width * 2 * field_h;
73 if (buf_end - buf < 8)
76 field_size = bytestream_get_le32(&buf);
77 if (field_size < min_field_size) {
78 av_log(avctx,
AV_LOG_ERROR,
"Field size %i is too small (required %i)\n", field_size, min_field_size);
81 if (buf_end - buf < field_size) {
82 av_log(avctx,
AV_LOG_ERROR,
"Packet is too small, need %i, have %i\n", field_size, (
int)(buf_end - buf));
90 for (i = 0; i < field_h; i++) {
93 memcpy(dst, buf, avctx->
width * 2);
94 buf += avctx->
width * 2;
97 buf += field_size - min_field_size;