diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2009-01-03 17:54:48 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2009-01-03 17:54:48 +0000 |
commit | db4fac64db305e14f04d87f639b3fc851266b38c (patch) | |
tree | 942e9a98911e53b3d33ea9024e201438fef5556c /ffplay.c | |
parent | 7cf9c6ae40181f2d769ce73bf141c445f036f30c (diff) | |
download | ffmpeg-db4fac64db305e14f04d87f639b3fc851266b38c.tar.gz |
Change AVSubtitle.rects to an array of pointers so ABI does not break
when the size of AVSubtitleRect changes.
Originally committed as revision 16412 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'ffplay.c')
-rw-r--r-- | ffplay.c | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -636,8 +636,9 @@ static void free_subpicture(SubPicture *sp) for (i = 0; i < sp->sub.num_rects; i++) { - av_free(sp->sub.rects[i].bitmap); - av_free(sp->sub.rects[i].rgba_palette); + av_freep(&sp->sub.rects[i]->bitmap); + av_freep(&sp->sub.rects[i]->rgba_palette); + av_freep(&sp->sub.rects[i]); } av_free(sp->sub.rects); @@ -721,7 +722,7 @@ static void video_image_display(VideoState *is) pict.linesize[2] = vp->bmp->pitches[1]; for (i = 0; i < sp->sub.num_rects; i++) - blend_subrect(&pict, &sp->sub.rects[i], + blend_subrect(&pict, sp->sub.rects[i], vp->bmp->w, vp->bmp->h); SDL_UnlockYUVOverlay (vp->bmp); @@ -1435,13 +1436,13 @@ static int subtitle_thread(void *arg) for (i = 0; i < sp->sub.num_rects; i++) { - for (j = 0; j < sp->sub.rects[i].nb_colors; j++) + for (j = 0; j < sp->sub.rects[i]->nb_colors; j++) { - RGBA_IN(r, g, b, a, sp->sub.rects[i].rgba_palette + j); + RGBA_IN(r, g, b, a, sp->sub.rects[i]->rgba_palette + j); y = RGB_TO_Y_CCIR(r, g, b); u = RGB_TO_U_CCIR(r, g, b, 0); v = RGB_TO_V_CCIR(r, g, b, 0); - YUVA_OUT(sp->sub.rects[i].rgba_palette + j, y, u, v, a); + YUVA_OUT(sp->sub.rects[i]->rgba_palette + j, y, u, v, a); } } |