slideshow/source/engine/opengl/TransitionImpl.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
New commits: commit c1959f505eb9322557dd915f2eefb49ce02f2802 Author: Mike Kaganski <mike.kagan...@collabora.com> AuthorDate: Sat Apr 3 09:49:16 2021 +0300 Commit: Mike Kaganski <mike.kagan...@collabora.com> CommitDate: Sat Apr 3 10:13:49 2021 +0200 Use 64-KiB buffer instead of 256-KiB We only use red channel anyway, so no need to also waste space for G, B and A. Change-Id: I2bacef36d1e9845287a205a5f6473952ef59083e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113552 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com> diff --git a/slideshow/source/engine/opengl/TransitionImpl.cxx b/slideshow/source/engine/opengl/TransitionImpl.cxx index 98d6778fd197..f8d062d34941 100644 --- a/slideshow/source/engine/opengl/TransitionImpl.cxx +++ b/slideshow/source/engine/opengl/TransitionImpl.cxx @@ -1473,18 +1473,18 @@ void initPermTexture(GLuint *texID) glBindTexture(GL_TEXTURE_2D, *texID); static bool initialized = false; - static unsigned char permutation2D[256*256*4]; + static unsigned char permutation2D[256*256]; if( !initialized ) { int x, y; for( y=0; y < 256; y++ ) for( x=0; x < 256; x++ ) - permutation2D[x*4 + y*1024] = permutation256[(y + permutation256[x]) & 0xff]; + permutation2D[x + y*256] = permutation256[(y + permutation256[x]) & 0xff]; initialized = true; } - glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, 256, 256, 0, GL_RGBA, GL_UNSIGNED_BYTE, permutation2D ); + glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, 256, 256, 0, GL_RED, GL_UNSIGNED_BYTE, permutation2D ); glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST ); glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST ); CHECK_GL_ERROR(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits