static int dxv_decompress_dxt1(AVCodecContext *avctx)

{

    DXVContext *ctx = avctx->priv_data;

    GetByteContext *gbc = &ctx->gbc;

    uint32_t value, prev, op;

    int idx = 0, state = 0;

    int pos = 2;



    /* Copy the first two elements */

    AV_WL32(ctx->tex_data, bytestream2_get_le32(gbc));

    AV_WL32(ctx->tex_data + 4, bytestream2_get_le32(gbc));



    /* Process input until the whole texture has been filled */

    while (pos < ctx->tex_size / 4) {

        CHECKPOINT(2);



        /* Copy two elements from a previous offset or from the input buffer */

        if (op) {

            prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;



            prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;

        } else {

            CHECKPOINT(2);



            if (op)

                prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            else

                prev = bytestream2_get_le32(gbc);

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;



            CHECKPOINT(2);



            if (op)

                prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            else

                prev = bytestream2_get_le32(gbc);

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;

        }

    }



    return 0;

}

static int dxv_decompress_dxt1(AVCodecContext *avctx)

{

    DXVContext *ctx = avctx->priv_data;

    GetByteContext *gbc = &ctx->gbc;

    uint32_t value, prev, op;

    int idx = 0, state = 0;

    int pos = 2;



    

    AV_WL32(ctx->tex_data, bytestream2_get_le32(gbc));

    AV_WL32(ctx->tex_data + 4, bytestream2_get_le32(gbc));



    

    while (pos < ctx->tex_size / 4) {

        CHECKPOINT(2);



        

        if (op) {

            prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;



            prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;

        } else {

            CHECKPOINT(2);



            if (op)

                prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            else

                prev = bytestream2_get_le32(gbc);

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;



            CHECKPOINT(2);



            if (op)

                prev = AV_RL32(ctx->tex_data + 4 * (pos - idx));

            else

                prev = bytestream2_get_le32(gbc);

            AV_WL32(ctx->tex_data + 4 * pos, prev);

            pos++;

        }

    }



    return 0;

}

    while (pos < ctx->tex_size / 4) {     while (pos < ctx->tex_size / 4) {
static int FUNC_0(AVCodecContext *VAR_0)

{

    DXVContext *ctx = VAR_0->priv_data;

    GetByteContext *gbc = &ctx->gbc;

    uint32_t value, prev, op;

    int VAR_1 = 0, VAR_2 = 0;

    int VAR_3 = 2;



    

    AV_WL32(ctx->tex_data, bytestream2_get_le32(gbc));

    AV_WL32(ctx->tex_data + 4, bytestream2_get_le32(gbc));



    

    while (VAR_3 < ctx->tex_size / 4) {

        CHECKPOINT(2);



        

        if (op) {

            prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1));

            AV_WL32(ctx->tex_data + 4 * VAR_3, prev);

            VAR_3++;



            prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1));

            AV_WL32(ctx->tex_data + 4 * VAR_3, prev);

            VAR_3++;

        } else {

            CHECKPOINT(2);



            if (op)

                prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1));

            else

                prev = bytestream2_get_le32(gbc);

            AV_WL32(ctx->tex_data + 4 * VAR_3, prev);

            VAR_3++;



            CHECKPOINT(2);



            if (op)

                prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1));

            else

                prev = bytestream2_get_le32(gbc);

            AV_WL32(ctx->tex_data + 4 * VAR_3, prev);

            VAR_3++;

        }

    }



    return 0;

}

static int FUNC_0(AVCodecContext *VAR_0)
{ DXVContext *ctx = VAR_0->priv_data; GetByteContext *gbc = &ctx->gbc; uint32_t value, prev, op; int VAR_1 = 0, VAR_2 = 0; int VAR_3 = 2; AV_WL32(ctx->tex_data, bytestream2_get_le32(gbc)); AV_WL32(ctx->tex_data + 4, bytestream2_get_le32(gbc)); while (VAR_3 < ctx->tex_size / 4) { CHECKPOINT(2); if (op) { prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1)); AV_WL32(ctx->tex_data + 4 * VAR_3, prev); VAR_3++; prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1)); AV_WL32(ctx->tex_data + 4 * VAR_3, prev); VAR_3++; } else { CHECKPOINT(2); if (op)
prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1)); else
prev = bytestream2_get_le32(gbc); AV_WL32(ctx->tex_data + 4 * VAR_3, prev); VAR_3++; CHECKPOINT(2); if (op)
prev = AV_RL32(ctx->tex_data + 4 * (VAR_3 - VAR_1)); else
prev = bytestream2_get_le32(gbc); AV_WL32(ctx->tex_data + 4 * VAR_3, prev); VAR_3++; } } return 0; }