if (keyframe) {
new_key_frame(s);
- p->pict_type = FF_I_TYPE;
+ p->pict_type = AV_PICTURE_TYPE_I;
p->key_frame = 1;
s->last_key_frame = avctx->frame_number;
av_log(avctx, AV_LOG_DEBUG, "Inserting key frame at frame %d\n", avctx->frame_number);
} else {
- p->pict_type = FF_P_TYPE;
+ p->pict_type = AV_PICTURE_TYPE_P;
p->key_frame = 0;
}
}
AVCodec ff_flashsv2_encoder = {
- "flashsv2",
- AVMEDIA_TYPE_VIDEO,
- CODEC_ID_FLASHSV2,
- sizeof(FlashSV2Context),
- flashsv2_encode_init,
- flashsv2_encode_frame,
- flashsv2_encode_end,
+ .name = "flashsv2",
+ .type = AVMEDIA_TYPE_VIDEO,
+ .id = CODEC_ID_FLASHSV2,
+ .priv_data_size = sizeof(FlashSV2Context),
+ .init = flashsv2_encode_init,
+ .encode = flashsv2_encode_frame,
+ .close = flashsv2_encode_end,
.pix_fmts = (enum PixelFormat[]) {PIX_FMT_BGR24, PIX_FMT_NONE},
.long_name = NULL_IF_CONFIG_SMALL("Flash Screen Video Version 2"),
.capabilities = CODEC_CAP_EXPERIMENTAL,