[vlc-commits] [Git][videolan/vlc][master] 3 commits: Revert "opengl: simplify swizzle"

Hugo Beauzée-Luyssen (@chouquette) gitlab at videolan.org
Thu Mar 31 13:36:20 UTC 2022



Hugo Beauzée-Luyssen pushed to branch master at VideoLAN / VLC


Commits:
9251bc34 by Alexandre Janniaux at 2022-03-31T13:21:02+00:00
Revert "opengl: simplify swizzle"

The swizzle of the texture should be different between
GL_LUMINANCE_ALPHA textures and GL_RG textures.

This reverts commit aa5bec3b49a790709bcf2c7d874552916da2aea1.

Refs #26767

- - - - -
802f36cf by Alexandre Janniaux at 2022-03-31T13:21:02+00:00
Revert "opengl: fix swizzle"

GL_LUMINANCE_ALPHA textures should be sampled through r and a swizzle
since it has a `(L,L,L,A)` layout.

This reverts commit 05f292874df8b29a0f3b60d49d39f4269a2b2ca8.

Fixes #26767
Reintroduce #26735

- - - - -
25d66728 by Romain Vimont at 2022-03-31T13:21:02+00:00
opengl: simplify swizzle

The commit ca7d2ea4b618b5bc1a8a03c0318d4f2afaf3007f introduced an xyzw
swizzle, whereas the previous code was using an rgba swizzle. No other
location used the xyzw swizzle for texture so unify and use rgba
everywhere.

Different version from aa5bec3b49a790709bcf2c7d874552916da2aea1

- - - - -


1 changed file:

- modules/video_output/opengl/sampler.c


Changes:

=====================================
modules/video_output/opengl/sampler.c
=====================================
@@ -436,7 +436,10 @@ opengl_init_swizzle(struct vlc_gl_sampler *sampler,
     else if (desc->plane_count == 2)
     {
         swizzle_per_tex[0] = "r";
-        swizzle_per_tex[1] = "rg";
+        if (oneplane_texfmt == GL_RED)
+            swizzle_per_tex[1] = "rg";
+        else
+            swizzle_per_tex[1] = "ra";
     }
     else if (desc->plane_count == 1)
     {



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/7e47fa5242df547f924b0a140286b3d90caf65a7...25d66728eb930997db6abcfd69596334b6586007

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/7e47fa5242df547f924b0a140286b3d90caf65a7...25d66728eb930997db6abcfd69596334b6586007
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list