void ff_framequeue_skip_samples(FFFrameQueue *fq, size_t samples, AVRational time_base)

{

    FFFrameBucket *b;

    size_t bytes;

    int planar, planes, i;



    check_consistency(fq);

    av_assert1(fq->queued);

    b = bucket(fq, 0);

    av_assert1(samples < b->frame->nb_samples);

    planar = av_sample_fmt_is_planar(b->frame->format);

    planes = planar ? b->frame->channels : 1;

    bytes = samples * av_get_bytes_per_sample(b->frame->format);

    if (!planar)

        bytes *= b->frame->channels;

    if (b->frame->pts != AV_NOPTS_VALUE)

        b->frame->pts += av_rescale_q(samples, av_make_q(1, b->frame->sample_rate), time_base);

    b->frame->nb_samples -= samples;

    b->frame->linesize[0] -= bytes;

    for (i = 0; i < planes; i++)

        b->frame->extended_data[i] += bytes;

    for (i = 0; i < planes && i < AV_NUM_DATA_POINTERS; i++)

        b->frame->data[i] = b->frame->extended_data[i];

    fq->total_samples_tail += samples;


    ff_framequeue_update_peeked(fq, 0);

}
void ff_framequeue_skip_samples(FFFrameQueue *fq, size_t samples, AVRational time_base)

{

    FFFrameBucket *b;

    size_t bytes;

    int planar, planes, i;



    check_consistency(fq);

    av_assert1(fq->queued);

    b = bucket(fq, 0);

    av_assert1(samples < b->frame->nb_samples);

    planar = av_sample_fmt_is_planar(b->frame->format);

    planes = planar ? b->frame->channels : 1;

    bytes = samples * av_get_bytes_per_sample(b->frame->format);

    if (!planar)

        bytes *= b->frame->channels;

    if (b->frame->pts != AV_NOPTS_VALUE)

        b->frame->pts += av_rescale_q(samples, av_make_q(1, b->frame->sample_rate), time_base);

    b->frame->nb_samples -= samples;

    b->frame->linesize[0] -= bytes;

    for (i = 0; i < planes; i++)

        b->frame->extended_data[i] += bytes;

    for (i = 0; i < planes && i < AV_NUM_DATA_POINTERS; i++)

        b->frame->data[i] = b->frame->extended_data[i];

    fq->total_samples_tail += samples;


    ff_framequeue_update_peeked(fq, 0);

}
void FUNC_0(FFFrameQueue *VAR_0, size_t VAR_1, AVRational VAR_2)

{

    FFFrameBucket *b;

    size_t bytes;

    int VAR_3, VAR_4, VAR_5;



    check_consistency(VAR_0);

    av_assert1(VAR_0->queued);

    b = bucket(VAR_0, 0);

    av_assert1(VAR_1 < b->frame->nb_samples);

    VAR_3 = av_sample_fmt_is_planar(b->frame->format);

    VAR_4 = VAR_3 ? b->frame->channels : 1;

    bytes = VAR_1 * av_get_bytes_per_sample(b->frame->format);

    if (!VAR_3)

        bytes *= b->frame->channels;

    if (b->frame->pts != AV_NOPTS_VALUE)

        b->frame->pts += av_rescale_q(VAR_1, av_make_q(1, b->frame->sample_rate), VAR_2);

    b->frame->nb_samples -= VAR_1;

    b->frame->linesize[0] -= bytes;

    for (VAR_5 = 0; VAR_5 < VAR_4; VAR_5++)

        b->frame->extended_data[VAR_5] += bytes;

    for (VAR_5 = 0; VAR_5 < VAR_4 && VAR_5 < AV_NUM_DATA_POINTERS; VAR_5++)

        b->frame->data[VAR_5] = b->frame->extended_data[VAR_5];

    VAR_0->total_samples_tail += VAR_1;


    ff_framequeue_update_peeked(VAR_0, 0);

}
void FUNC_0(FFFrameQueue *VAR_0, size_t VAR_1, AVRational VAR_2)
{ FFFrameBucket *b; size_t bytes; int VAR_3, VAR_4, VAR_5; check_consistency(VAR_0); av_assert1(VAR_0->queued); b = bucket(VAR_0, 0); av_assert1(VAR_1 < b->frame->nb_samples); VAR_3 = av_sample_fmt_is_planar(b->frame->format); VAR_4 = VAR_3 ? b->frame->channels : 1; bytes = VAR_1 * av_get_bytes_per_sample(b->frame->format); if (!VAR_3)
bytes *= b->frame->channels; if (b->frame->pts != AV_NOPTS_VALUE)
b->frame->pts += av_rescale_q(VAR_1, av_make_q(1, b->frame->sample_rate), VAR_2); b->frame->nb_samples -= VAR_1; b->frame->linesize[0] -= bytes; for (VAR_5 = 0; VAR_5 < VAR_4; VAR_5++) b->frame->extended_data[VAR_5] += bytes; for (VAR_5 = 0; VAR_5 < VAR_4 && VAR_5 < AV_NUM_DATA_POINTERS; VAR_5++) b->frame->data[VAR_5] = b->frame->extended_data[VAR_5]; VAR_0->total_samples_tail += VAR_1; ff_framequeue_update_peeked(VAR_0, 0); }