static void mpeg4_encode_gop_header(MpegEncContext * s){

    int hours, minutes, seconds;

    int64_t time;



    put_bits(&s->pb, 16, 0);

    put_bits(&s->pb, 16, GOP_STARTCODE);



    time= s->current_picture_ptr->pts;

    if(s->reordered_input_picture[1])

        time= FFMIN(time, s->reordered_input_picture[1]->pts);

    time= time*s->avctx->time_base.num;



    seconds= time/s->avctx->time_base.den;

    minutes= seconds/60; seconds %= 60;

    hours= minutes/60; minutes %= 60;

    hours%=24;



    put_bits(&s->pb, 5, hours);

    put_bits(&s->pb, 6, minutes);

    put_bits(&s->pb, 1, 1);

    put_bits(&s->pb, 6, seconds);



    put_bits(&s->pb, 1, !!(s->flags&CODEC_FLAG_CLOSED_GOP));

    put_bits(&s->pb, 1, 0); //broken link == NO



    s->last_time_base= time / s->avctx->time_base.den;



    ff_mpeg4_stuffing(&s->pb);

}

static void mpeg4_encode_gop_header(MpegEncContext * s){

    int hours, minutes, seconds;

    int64_t time;



    put_bits(&s->pb, 16, 0);

    put_bits(&s->pb, 16, GOP_STARTCODE);



    time= s->current_picture_ptr->pts;

    if(s->reordered_input_picture[1])

        time= FFMIN(time, s->reordered_input_picture[1]->pts);

    time= time*s->avctx->time_base.num;



    seconds= time/s->avctx->time_base.den;

    minutes= seconds/60; seconds %= 60;

    hours= minutes/60; minutes %= 60;

    hours%=24;



    put_bits(&s->pb, 5, hours);

    put_bits(&s->pb, 6, minutes);

    put_bits(&s->pb, 1, 1);

    put_bits(&s->pb, 6, seconds);



    put_bits(&s->pb, 1, !!(s->flags&CODEC_FLAG_CLOSED_GOP));

    put_bits(&s->pb, 1, 0); 



    s->last_time_base= time / s->avctx->time_base.den;



    ff_mpeg4_stuffing(&s->pb);

}

static void FUNC_0(MpegEncContext * VAR_0){

    int VAR_1, VAR_2, VAR_3;

    int64_t time;



    put_bits(&VAR_0->pb, 16, 0);

    put_bits(&VAR_0->pb, 16, GOP_STARTCODE);



    time= VAR_0->current_picture_ptr->pts;

    if(VAR_0->reordered_input_picture[1])

        time= FFMIN(time, VAR_0->reordered_input_picture[1]->pts);

    time= time*VAR_0->avctx->time_base.num;



    VAR_3= time/VAR_0->avctx->time_base.den;

    VAR_2= VAR_3/60; VAR_3 %= 60;

    VAR_1= VAR_2/60; VAR_2 %= 60;

    VAR_1%=24;



    put_bits(&VAR_0->pb, 5, VAR_1);

    put_bits(&VAR_0->pb, 6, VAR_2);

    put_bits(&VAR_0->pb, 1, 1);

    put_bits(&VAR_0->pb, 6, VAR_3);



    put_bits(&VAR_0->pb, 1, !!(VAR_0->flags&CODEC_FLAG_CLOSED_GOP));

    put_bits(&VAR_0->pb, 1, 0); 



    VAR_0->last_time_base= time / VAR_0->avctx->time_base.den;



    ff_mpeg4_stuffing(&VAR_0->pb);

}

static void FUNC_0(MpegEncContext * VAR_0){ int VAR_1, VAR_2, VAR_3; int64_t time; put_bits(&VAR_0->pb, 16, 0); put_bits(&VAR_0->pb, 16, GOP_STARTCODE); time= VAR_0->current_picture_ptr->pts; if(VAR_0->reordered_input_picture[1])
time= FFMIN(time, VAR_0->reordered_input_picture[1]->pts); time= time*VAR_0->avctx->time_base.num; VAR_3= time/VAR_0->avctx->time_base.den; VAR_2= VAR_3/60; VAR_3 %= 60; VAR_1= VAR_2/60; VAR_2 %= 60; VAR_1%=24; put_bits(&VAR_0->pb, 5, VAR_1); put_bits(&VAR_0->pb, 6, VAR_2); put_bits(&VAR_0->pb, 1, 1); put_bits(&VAR_0->pb, 6, VAR_3); put_bits(&VAR_0->pb, 1, !!(VAR_0->flags&CODEC_FLAG_CLOSED_GOP)); put_bits(&VAR_0->pb, 1, 0); VAR_0->last_time_base= time / VAR_0->avctx->time_base.den; ff_mpeg4_stuffing(&VAR_0->pb); }