summaryrefslogtreecommitdiffstats
path: root/video/out/vo_gpu_next.c
diff options
context:
space:
mode:
authorNiklas Haas <git@haasn.dev>2022-01-11 21:03:27 +0100
committerJan Ekström <jeebjp@gmail.com>2022-01-11 23:45:08 +0200
commit9e2c0b8baa3f9ccba997129a1c1023f61611e4dd (patch)
treefff3693f77deeef422f91fb817c028ef54f76e63 /video/out/vo_gpu_next.c
parent429402cb087f3a052cb9645af1e42156fd413c6c (diff)
downloadmpv-9e2c0b8baa3f9ccba997129a1c1023f61611e4dd.tar.bz2
mpv-9e2c0b8baa3f9ccba997129a1c1023f61611e4dd.tar.xz
sub: rename SUBBITMAP_RGBA to SUBBITMAP_BGRA
This was a misnomer, the actual channel order is IMGFMT_BGRA (as the comment explicitly point out). Rename the enum for consistency.
Diffstat (limited to 'video/out/vo_gpu_next.c')
-rw-r--r--video/out/vo_gpu_next.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/video/out/vo_gpu_next.c b/video/out/vo_gpu_next.c
index 98c673eb57..40b142bc50 100644
--- a/video/out/vo_gpu_next.c
+++ b/video/out/vo_gpu_next.c
@@ -215,7 +215,7 @@ static void write_overlays(struct vo *vo, struct mp_osd_res res, double pts,
struct priv *p = vo->priv;
static const bool subfmt_all[SUBBITMAP_COUNT] = {
[SUBBITMAP_LIBASS] = true,
- [SUBBITMAP_RGBA] = true,
+ [SUBBITMAP_BGRA] = true,
};
struct sub_bitmap_list *subs = osd_render(vo->osd, res, pts, flags, subfmt_all);
@@ -283,7 +283,7 @@ static void write_overlays(struct vo *vo, struct mp_osd_res res, double pts,
};
switch (item->format) {
- case SUBBITMAP_RGBA:
+ case SUBBITMAP_BGRA:
ol->mode = PL_OVERLAY_NORMAL;
ol->repr.alpha = PL_ALPHA_PREMULTIPLIED;
break;
@@ -1153,7 +1153,7 @@ static int preinit(struct vo *vo)
p->rr = pl_renderer_create(p->pllog, p->gpu);
p->queue = pl_queue_create(p->gpu);
p->osd_fmt[SUBBITMAP_LIBASS] = pl_find_named_fmt(p->gpu, "r8");
- p->osd_fmt[SUBBITMAP_RGBA] = pl_find_named_fmt(p->gpu, "rgba8");
+ p->osd_fmt[SUBBITMAP_BGRA] = pl_find_named_fmt(p->gpu, "rgba8");
char *cache_file = get_cache_file(p);
if (cache_file) {