static void set_frame_distances(MpegEncContext * s){

    assert(s->current_picture_ptr->f.pts != AV_NOPTS_VALUE);

    s->time = s->current_picture_ptr->f.pts * s->avctx->time_base.num;



    if(s->pict_type==AV_PICTURE_TYPE_B){

        s->pb_time= s->pp_time - (s->last_non_b_time - s->time);

        assert(s->pb_time > 0 && s->pb_time < s->pp_time);

    }else{

        s->pp_time= s->time - s->last_non_b_time;

        s->last_non_b_time= s->time;

        assert(s->picture_number==0 || s->pp_time > 0);

    }

}

static void set_frame_distances(MpegEncContext * s){

    assert(s->current_picture_ptr->f.pts != AV_NOPTS_VALUE);

    s->time = s->current_picture_ptr->f.pts * s->avctx->time_base.num;



    if(s->pict_type==AV_PICTURE_TYPE_B){

        s->pb_time= s->pp_time - (s->last_non_b_time - s->time);

        assert(s->pb_time > 0 && s->pb_time < s->pp_time);

    }else{

        s->pp_time= s->time - s->last_non_b_time;

        s->last_non_b_time= s->time;

        assert(s->picture_number==0 || s->pp_time > 0);

    }

}

    assert(s->current_picture_ptr->f.pts != AV_NOPTS_VALUE);     s->time = s->current_picture_ptr->f.pts * s->avctx->time_base.num;
static void FUNC_0(MpegEncContext * VAR_0){

    assert(VAR_0->current_picture_ptr->f.pts != AV_NOPTS_VALUE);

    VAR_0->time = VAR_0->current_picture_ptr->f.pts * VAR_0->avctx->time_base.num;



    if(VAR_0->pict_type==AV_PICTURE_TYPE_B){

        VAR_0->pb_time= VAR_0->pp_time - (VAR_0->last_non_b_time - VAR_0->time);

        assert(VAR_0->pb_time > 0 && VAR_0->pb_time < VAR_0->pp_time);

    }else{

        VAR_0->pp_time= VAR_0->time - VAR_0->last_non_b_time;

        VAR_0->last_non_b_time= VAR_0->time;

        assert(VAR_0->picture_number==0 || VAR_0->pp_time > 0);

    }

}

static void FUNC_0(MpegEncContext * VAR_0){ assert(VAR_0->current_picture_ptr->f.pts != AV_NOPTS_VALUE); VAR_0->time = VAR_0->current_picture_ptr->f.pts * VAR_0->avctx->time_base.num; if(VAR_0->pict_type==AV_PICTURE_TYPE_B){ VAR_0->pb_time= VAR_0->pp_time - (VAR_0->last_non_b_time - VAR_0->time); assert(VAR_0->pb_time > 0 && VAR_0->pb_time < VAR_0->pp_time); }else{ VAR_0->pp_time= VAR_0->time - VAR_0->last_non_b_time; VAR_0->last_non_b_time= VAR_0->time; assert(VAR_0->picture_number==0 || VAR_0->pp_time > 0); } }