diff --git a/libavcodec/rawdec.c b/libavcodec/rawdec.c
index f45ff4c..cbfb94e 100644
|
a
|
b
|
static av_cold int raw_init_decoder(AVCodecContext *avctx)
|
| 133 | 133 | memset(context->palette->data, 0, AVPALETTE_SIZE); |
| 134 | 134 | } |
| 135 | 135 | |
| 136 | | context->frame_size = avpicture_get_size(avctx->pix_fmt, avctx->width, |
| 137 | | avctx->height); |
| 138 | 136 | if ((avctx->bits_per_coded_sample == 4 || avctx->bits_per_coded_sample == 2) && |
| 139 | 137 | avctx->pix_fmt == AV_PIX_FMT_PAL8 && |
| 140 | 138 | (!avctx->codec_tag || avctx->codec_tag == MKTAG('r','a','w',' '))) |
| … |
… |
static int raw_decode(AVCodecContext *avctx, void *data, int *got_frame,
|
| 174 | 172 | AVFrame *frame = data; |
| 175 | 173 | AVPicture *picture = data; |
| 176 | 174 | |
| | 175 | context->frame_size = avpicture_get_size(avctx->pix_fmt, avctx->width, |
| | 176 | avctx->height); |
| 177 | 177 | frame->pict_type = AV_PICTURE_TYPE_I; |
| 178 | 178 | frame->key_frame = 1; |
| 179 | 179 | frame->reordered_opaque = avctx->reordered_opaque; |
diff --git a/libavformat/swfdec.c b/libavformat/swfdec.c
index 54e0f6d..bdc4305 100644
|
a
|
b
|
static int swf_read_packet(AVFormatContext *s, AVPacket *pkt)
|
| 332 | 332 | |
| 333 | 333 | for (i = 0; i < s->nb_streams; i++) { |
| 334 | 334 | st = s->streams[i]; |
| 335 | | if (st->codec->codec_id == AV_CODEC_ID_RAWVIDEO && st->id == -3) |
| | 335 | if (st->codec->codec_id == AV_CODEC_ID_RAWVIDEO && st->id == -3) { |
| | 336 | if (width != st->codec->width || height != st->codec->height) |
| | 337 | ff_add_param_change(pkt, 0, 0, 0, width, height); |
| 336 | 338 | break; |
| | 339 | } |
| 337 | 340 | } |
| 338 | 341 | if (i == s->nb_streams) { |
| 339 | 342 | vst = avformat_new_stream(s, NULL); |