static int v210_read_packet(AVFormatContext *s, AVPacket *pkt)

{

    int packet_size, ret, width, height;

    AVStream *st = s->streams[0];



    width = st->codec->width;

    height = st->codec->height;



    packet_size = GET_PACKET_SIZE(width, height);

    if (packet_size < 0)

        return -1;



    ret = av_get_packet(s->pb, pkt, packet_size);

    pkt->pts = pkt->dts = pkt->pos / packet_size;



    pkt->stream_index = 0;

    if (ret < 0)

        return ret;

    return 0;

}

static int v210_read_packet(AVFormatContext *s, AVPacket *pkt)

{

    int packet_size, ret, width, height;

    AVStream *st = s->streams[0];



    width = st->codec->width;

    height = st->codec->height;



    packet_size = GET_PACKET_SIZE(width, height);

    if (packet_size < 0)

        return -1;



    ret = av_get_packet(s->pb, pkt, packet_size);

    pkt->pts = pkt->dts = pkt->pos / packet_size;



    pkt->stream_index = 0;

    if (ret < 0)

        return ret;

    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)

{

    int VAR_2, VAR_3, VAR_4, VAR_5;

    AVStream *st = VAR_0->streams[0];



    VAR_4 = st->codec->VAR_4;

    VAR_5 = st->codec->VAR_5;



    VAR_2 = GET_PACKET_SIZE(VAR_4, VAR_5);

    if (VAR_2 < 0)

        return -1;



    VAR_3 = av_get_packet(VAR_0->pb, VAR_1, VAR_2);

    VAR_1->pts = VAR_1->dts = VAR_1->pos / VAR_2;



    VAR_1->stream_index = 0;

    if (VAR_3 < 0)

        return VAR_3;

    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0, AVPacket *VAR_1)
{ int VAR_2, VAR_3, VAR_4, VAR_5; AVStream *st = VAR_0->streams[0]; VAR_4 = st->codec->VAR_4; VAR_5 = st->codec->VAR_5; VAR_2 = GET_PACKET_SIZE(VAR_4, VAR_5); if (VAR_2 < 0)
return -1; VAR_3 = av_get_packet(VAR_0->pb, VAR_1, VAR_2); VAR_1->pts = VAR_1->dts = VAR_1->pos / VAR_2; VAR_1->stream_index = 0; if (VAR_3 < 0)
return VAR_3; return 0; }