s->mpeg_f_code[1][0] = f_code;
s->mpeg_f_code[1][1] = f_code;
}
- s->current_picture.f.pict_type = s->pict_type;
- s->current_picture.f.key_frame = s->pict_type == AV_PICTURE_TYPE_I;
+ s->current_picture.f->pict_type = s->pict_type;
+ s->current_picture.f->key_frame = s->pict_type == AV_PICTURE_TYPE_I;
if (avctx->debug & FF_DEBUG_PICT_INFO)
av_log(avctx, AV_LOG_DEBUG,
s->pict_type = AV_PICTURE_TYPE_P;
} else
s->pict_type = AV_PICTURE_TYPE_B;
- s->current_picture.f.pict_type = s->pict_type;
- s->current_picture.f.key_frame = s->pict_type == AV_PICTURE_TYPE_I;
+ s->current_picture.f->pict_type = s->pict_type;
+ s->current_picture.f->key_frame = s->pict_type == AV_PICTURE_TYPE_I;
}
s->mpeg_f_code[0][0] += !s->mpeg_f_code[0][0];
s->mpeg_f_code[0][1] += !s->mpeg_f_code[0][1];
ff_mpeg_er_frame_start(s);
/* first check if we must repeat the frame */
- s->current_picture_ptr->f.repeat_pict = 0;
+ s->current_picture_ptr->f->repeat_pict = 0;
if (s->repeat_first_field) {
if (s->progressive_sequence) {
if (s->top_field_first)
- s->current_picture_ptr->f.repeat_pict = 4;
+ s->current_picture_ptr->f->repeat_pict = 4;
else
- s->current_picture_ptr->f.repeat_pict = 2;
+ s->current_picture_ptr->f->repeat_pict = 2;
} else if (s->progressive_frame) {
- s->current_picture_ptr->f.repeat_pict = 1;
+ s->current_picture_ptr->f->repeat_pict = 1;
}
}
- pan_scan = av_frame_new_side_data(&s->current_picture_ptr->f,
+ pan_scan = av_frame_new_side_data(s->current_picture_ptr->f,
AV_FRAME_DATA_PANSCAN,
sizeof(s1->pan_scan));
if (!pan_scan)
if (s1->a53_caption) {
AVFrameSideData *sd = av_frame_new_side_data(
- &s->current_picture_ptr->f, AV_FRAME_DATA_A53_CC,
+ s->current_picture_ptr->f, AV_FRAME_DATA_A53_CC,
s1->a53_caption_size);
if (sd)
memcpy(sd->data, s1->a53_caption, s1->a53_caption_size);
}
if (s1->has_stereo3d) {
- AVStereo3D *stereo = av_stereo3d_create_side_data(&s->current_picture_ptr->f);
+ AVStereo3D *stereo = av_stereo3d_create_side_data(s->current_picture_ptr->f);
if (!stereo)
return AVERROR(ENOMEM);
}
for (i = 0; i < 4; i++) {
- s->current_picture.f.data[i] = s->current_picture_ptr->f.data[i];
+ s->current_picture.f->data[i] = s->current_picture_ptr->f->data[i];
if (s->picture_structure == PICT_BOTTOM_FIELD)
- s->current_picture.f.data[i] +=
- s->current_picture_ptr->f.linesize[i];
+ s->current_picture.f->data[i] +=
+ s->current_picture_ptr->f->linesize[i];
}
}
ff_MPV_frame_end(s);
if (s->pict_type == AV_PICTURE_TYPE_B || s->low_delay) {
- int ret = av_frame_ref(pict, &s->current_picture_ptr->f);
+ int ret = av_frame_ref(pict, s->current_picture_ptr->f);
if (ret < 0)
return ret;
ff_print_debug_info(s, s->current_picture_ptr, pict);
/* latency of 1 frame for I- and P-frames */
/* XXX: use another variable than picture_number */
if (s->last_picture_ptr != NULL) {
- int ret = av_frame_ref(pict, &s->last_picture_ptr->f);
+ int ret = av_frame_ref(pict, s->last_picture_ptr->f);
if (ret < 0)
return ret;
ff_print_debug_info(s, s->last_picture_ptr, pict);
input_size = buf_end - buf_ptr;
if (avctx->debug & FF_DEBUG_STARTCODE)
- av_log(avctx, AV_LOG_DEBUG, "%3"PRIX32" at %td left %d\n",
+ av_log(avctx, AV_LOG_DEBUG, "%3"PRIX32" at %"PTRDIFF_SPECIFIER" left %d\n",
start_code, buf_ptr - buf, input_size);
/* prepare data for next start code */
Mpeg1Context *s = avctx->priv_data;
AVFrame *picture = data;
MpegEncContext *s2 = &s->mpeg_enc_ctx;
- av_dlog(avctx, "fill_buffer\n");
if (buf_size == 0 || (buf_size == 4 && AV_RB32(buf) == SEQ_END_CODE)) {
/* special case for last picture */
if (s2->low_delay == 0 && s2->next_picture_ptr) {
- int ret = av_frame_ref(picture, &s2->next_picture_ptr->f);
+ int ret = av_frame_ref(picture, s2->next_picture_ptr->f);
if (ret < 0)
return ret;