diff options
author | wm4 <wm4@nowhere> | 2016-06-30 21:38:50 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2016-06-30 21:38:50 +0200 |
commit | c57304a591d46df490e1584b1a3c9cda1ff91b44 (patch) | |
tree | d64734c8782bbd1b0a8be01b9c2b4a90df39899d /sub/osd_state.h | |
parent | 2d6da37b6b4acfd31487e59e788e2d7b13172314 (diff) | |
download | mpv-c57304a591d46df490e1584b1a3c9cda1ff91b44.tar.bz2 mpv-c57304a591d46df490e1584b1a3c9cda1ff91b44.tar.xz |
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.
Diffstat (limited to 'sub/osd_state.h')
-rw-r--r-- | sub/osd_state.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sub/osd_state.h b/sub/osd_state.h index 0fff668d2d..c2e7911d1b 100644 --- a/sub/osd_state.h +++ b/sub/osd_state.h @@ -57,8 +57,10 @@ struct osd_object { struct mp_osd_res vo_res; // Internally used by osd_libass.c - struct sub_bitmaps parts_cache; + bool changed; struct ass_state ass; + struct mp_ass_packer *ass_packer; + struct ass_image **ass_imgs; }; struct osd_external { |