From c57304a591d46df490e1584b1a3c9cda1ff91b44 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 30 Jun 2016 21:38:50 +0200 Subject: sub: pack libass bitmaps directly in sd_ass.c and osd_libass.c Change all producer of libass images to packing the bitmaps into a single larger bitmap directly when they're output. This is supposed to help working towards refcounted sub bitmaps. This will reduce performance for VOs like vo_xv, but not for vo_opengl. vo_opengl simply will pick up the pre-packed sub bitmaps, and skip packing them again. vo_xv will copy and pack the sub bitmaps unnecessarily - but if we want sub bitmap refcounting, they'd have to be copied anyway. The packing code cannot be removed yet from vo_opengl, because there are certain corner cases that still produce unpackad other sub bitmaps. Actual refcounting will also require more work. --- sub/osd.h | 1 + 1 file changed, 1 insertion(+) (limited to 'sub/osd.h') diff --git a/sub/osd.h b/sub/osd.h index 7cfc695873..ade546f4f4 100644 --- a/sub/osd.h +++ b/sub/osd.h @@ -69,6 +69,7 @@ struct sub_bitmaps { // parts[].bitmap pointer points into the image data here (and stride will // correspond to packed->stride[0]). // SUBBITMAP_RGBA: IMGFMT_BGRA (exact match) + // SUBBITMAP_LIBASS: IMGFMT_Y8 (not the same, but compatible layout) // Other formats have this set to NULL. struct mp_image *packed; -- cgit v1.2.3