summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNiklas Haas <git@haasn.dev>2021-11-10 10:38:58 +0100
committerNiklas Haas <git@haasn.dev>2021-11-10 10:38:58 +0100
commitc413720801bbcda94cccac65a2baf2ce4d59a721 (patch)
treec3a3f7024456795a5193449435ad568df8762432
parent69527077c1a8be7b6c8cb2f7fc31b690e7722bab (diff)
downloadmpv-c413720801bbcda94cccac65a2baf2ce4d59a721.tar.bz2
mpv-c413720801bbcda94cccac65a2baf2ce4d59a721.tar.xz
vo_gpu_next: fix slight performance regression
This logic, which was working around a libplacebo bug, ended up always alpha blending - even for sources without an alpha channel. This caused a minor slowdown to be constantly enabled. Due to the recent bump to libplacebo v170, this is no longer needed.
-rw-r--r--video/out/placebo/utils.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/video/out/placebo/utils.c b/video/out/placebo/utils.c
index f677c20335..da16b65745 100644
--- a/video/out/placebo/utils.c
+++ b/video/out/placebo/utils.c
@@ -154,9 +154,7 @@ enum pl_color_levels mp_levels_to_pl(enum mp_csp_levels levels)
enum pl_alpha_mode mp_alpha_to_pl(enum mp_alpha_type alpha)
{
switch (alpha) {
- // Note: Older versions of libplacebo incorreclty handled PL_ALPHA_UNKNOWN
- // as premultiplied, so explicitly default this to independent instead.
- case MP_ALPHA_AUTO: return PL_ALPHA_INDEPENDENT;
+ case MP_ALPHA_AUTO: return PL_ALPHA_UNKNOWN;
case MP_ALPHA_STRAIGHT: return PL_ALPHA_INDEPENDENT;
case MP_ALPHA_PREMUL: return PL_ALPHA_PREMULTIPLIED;
}