mirror of
https://github.com/mpv-player/mpv
synced 2024-11-07 01:47:00 +01:00
3365514951
Before this commit, the OSD was drawn using libass, but the resulting bitmaps were converted to the internal mplayer OSD format. We want to get rid of the old OSD format, because it's monochrome, and can't even be rendered directly using modern video output methods (like with OpenGL/Direct3D/VDPAU). Change it so that VOs can get the ASS images directly, without additional conversions. (This also has the consequence that the OSD can render colors now.) Currently, this is vo_gl3 only. The other VOs still use the old method. Also, the old OSD format is still used for all VOs with DVD subtitles (spudec). Rewrite sub.c. Remove all the awkward flags and bounding boxes and change detection things. It turns out that much of that isn't needed. Move code related to converting subtitle images to img_convert.c. (It has to be noted that all of these conversions were already done before in some places, and that the new code actually makes less use of them.)
26 lines
483 B
C
26 lines
483 B
C
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
|
|
#include "config.h"
|
|
#include "talloc.h"
|
|
#include "sub.h"
|
|
|
|
void osd_init_backend(struct osd_state *osd)
|
|
{
|
|
}
|
|
|
|
void osd_destroy_backend(struct osd_state *osd)
|
|
{
|
|
}
|
|
|
|
void osd_get_function_sym(char *buffer, size_t buffer_size, int osd_function)
|
|
{
|
|
}
|
|
|
|
void osd_object_get_bitmaps(struct osd_state *osd, struct osd_object *obj,
|
|
struct sub_bitmaps *out_imgs)
|
|
{
|
|
*out_imgs = (struct sub_bitmaps) {0};
|
|
}
|