static void video_image_display(VideoState *is)

{

    Frame *vp;

    Frame *sp;

    AVPicture pict;

    SDL_Rect rect;

    int i;



    vp = frame_queue_peek(&is->pictq);

    if (vp->bmp) {

        if (is->subtitle_st) {

            if (frame_queue_nb_remaining(&is->subpq) > 0) {

                sp = frame_queue_peek(&is->subpq);



                if (vp->pts >= sp->pts + ((float) sp->sub.start_display_time / 1000)) {

                    SDL_LockYUVOverlay (vp->bmp);



                    pict.data[0] = vp->bmp->pixels[0];

                    pict.data[1] = vp->bmp->pixels[2];

                    pict.data[2] = vp->bmp->pixels[1];



                    pict.linesize[0] = vp->bmp->pitches[0];

                    pict.linesize[1] = vp->bmp->pitches[2];

                    pict.linesize[2] = vp->bmp->pitches[1];



                    for (i = 0; i < sp->sub.num_rects; i++)

                        blend_subrect(&pict, sp->sub.rects[i],

                                      vp->bmp->w, vp->bmp->h);



                    SDL_UnlockYUVOverlay (vp->bmp);

                }

            }

        }



        calculate_display_rect(&rect, is->xleft, is->ytop, is->width, is->height, vp->width, vp->height, vp->sar);



        SDL_DisplayYUVOverlay(vp->bmp, &rect);



        if (rect.x != is->last_display_rect.x || rect.y != is->last_display_rect.y || rect.w != is->last_display_rect.w || rect.h != is->last_display_rect.h || is->force_refresh) {

            int bgcolor = SDL_MapRGB(screen->format, 0x00, 0x00, 0x00);

            fill_border(is->xleft, is->ytop, is->width, is->height, rect.x, rect.y, rect.w, rect.h, bgcolor, 1);

            is->last_display_rect = rect;

        }

    }

}

static void video_image_display(VideoState *is)

{

    Frame *vp;

    Frame *sp;

    AVPicture pict;

    SDL_Rect rect;

    int i;



    vp = frame_queue_peek(&is->pictq);

    if (vp->bmp) {

        if (is->subtitle_st) {

            if (frame_queue_nb_remaining(&is->subpq) > 0) {

                sp = frame_queue_peek(&is->subpq);



                if (vp->pts >= sp->pts + ((float) sp->sub.start_display_time / 1000)) {

                    SDL_LockYUVOverlay (vp->bmp);



                    pict.data[0] = vp->bmp->pixels[0];

                    pict.data[1] = vp->bmp->pixels[2];

                    pict.data[2] = vp->bmp->pixels[1];



                    pict.linesize[0] = vp->bmp->pitches[0];

                    pict.linesize[1] = vp->bmp->pitches[2];

                    pict.linesize[2] = vp->bmp->pitches[1];



                    for (i = 0; i < sp->sub.num_rects; i++)

                        blend_subrect(&pict, sp->sub.rects[i],

                                      vp->bmp->w, vp->bmp->h);



                    SDL_UnlockYUVOverlay (vp->bmp);

                }

            }

        }



        calculate_display_rect(&rect, is->xleft, is->ytop, is->width, is->height, vp->width, vp->height, vp->sar);



        SDL_DisplayYUVOverlay(vp->bmp, &rect);



        if (rect.x != is->last_display_rect.x || rect.y != is->last_display_rect.y || rect.w != is->last_display_rect.w || rect.h != is->last_display_rect.h || is->force_refresh) {

            int bgcolor = SDL_MapRGB(screen->format, 0x00, 0x00, 0x00);

            fill_border(is->xleft, is->ytop, is->width, is->height, rect.x, rect.y, rect.w, rect.h, bgcolor, 1);

            is->last_display_rect = rect;

        }

    }

}

static void FUNC_0(VideoState *VAR_0)

{

    Frame *vp;

    Frame *sp;

    AVPicture pict;

    SDL_Rect rect;

    int VAR_1;



    vp = frame_queue_peek(&VAR_0->pictq);

    if (vp->bmp) {

        if (VAR_0->subtitle_st) {

            if (frame_queue_nb_remaining(&VAR_0->subpq) > 0) {

                sp = frame_queue_peek(&VAR_0->subpq);



                if (vp->pts >= sp->pts + ((float) sp->sub.start_display_time / 1000)) {

                    SDL_LockYUVOverlay (vp->bmp);



                    pict.data[0] = vp->bmp->pixels[0];

                    pict.data[1] = vp->bmp->pixels[2];

                    pict.data[2] = vp->bmp->pixels[1];



                    pict.linesize[0] = vp->bmp->pitches[0];

                    pict.linesize[1] = vp->bmp->pitches[2];

                    pict.linesize[2] = vp->bmp->pitches[1];



                    for (VAR_1 = 0; VAR_1 < sp->sub.num_rects; VAR_1++)

                        blend_subrect(&pict, sp->sub.rects[VAR_1],

                                      vp->bmp->w, vp->bmp->h);



                    SDL_UnlockYUVOverlay (vp->bmp);

                }

            }

        }



        calculate_display_rect(&rect, VAR_0->xleft, VAR_0->ytop, VAR_0->width, VAR_0->height, vp->width, vp->height, vp->sar);



        SDL_DisplayYUVOverlay(vp->bmp, &rect);



        if (rect.x != VAR_0->last_display_rect.x || rect.y != VAR_0->last_display_rect.y || rect.w != VAR_0->last_display_rect.w || rect.h != VAR_0->last_display_rect.h || VAR_0->force_refresh) {

            int VAR_2 = SDL_MapRGB(screen->format, 0x00, 0x00, 0x00);

            fill_border(VAR_0->xleft, VAR_0->ytop, VAR_0->width, VAR_0->height, rect.x, rect.y, rect.w, rect.h, VAR_2, 1);

            VAR_0->last_display_rect = rect;

        }

    }

}

static void FUNC_0(VideoState *VAR_0)
{ Frame *vp; Frame *sp; AVPicture pict; SDL_Rect rect; int VAR_1; vp = frame_queue_peek(&VAR_0->pictq); if (vp->bmp) { if (VAR_0->subtitle_st) { if (frame_queue_nb_remaining(&VAR_0->subpq) > 0) { sp = frame_queue_peek(&VAR_0->subpq); if (vp->pts >= sp->pts + ((float) sp->sub.start_display_time / 1000)) { SDL_LockYUVOverlay (vp->bmp); pict.data[0] = vp->bmp->pixels[0]; pict.data[1] = vp->bmp->pixels[2]; pict.data[2] = vp->bmp->pixels[1]; pict.linesize[0] = vp->bmp->pitches[0]; pict.linesize[1] = vp->bmp->pitches[2]; pict.linesize[2] = vp->bmp->pitches[1]; for (VAR_1 = 0; VAR_1 < sp->sub.num_rects; VAR_1++) blend_subrect(&pict, sp->sub.rects[VAR_1],
vp->bmp->w, vp->bmp->h); SDL_UnlockYUVOverlay (vp->bmp); } } } calculate_display_rect(&rect, VAR_0->xleft, VAR_0->ytop, VAR_0->width, VAR_0->height, vp->width, vp->height, vp->sar); SDL_DisplayYUVOverlay(vp->bmp, &rect); if (rect.x != VAR_0->last_display_rect.x || rect.y != VAR_0->last_display_rect.y || rect.w != VAR_0->last_display_rect.w || rect.h != VAR_0->last_display_rect.h || VAR_0->force_refresh) { int VAR_2 = SDL_MapRGB(screen->format, 0x00, 0x00, 0x00); fill_border(VAR_0->xleft, VAR_0->ytop, VAR_0->width, VAR_0->height, rect.x, rect.y, rect.w, rect.h, VAR_2, 1); VAR_0->last_display_rect = rect; } } }