From b920e94870d0e26c05d25121c472a7868ffdc631 Mon Sep 17 00:00:00 2001 From: Alexis Maiquez Date: Tue, 30 Nov 2021 21:32:19 +0100 Subject: [PATCH] ~ Fixed some backgrounds being black because of wrong composite layer ordering ~ Videos should no longer appear vertically mirrored Signed-off-by: Alexis Maiquez --- src/WallpaperEngine/Render/CVideo.cpp | 10 +++++----- src/WallpaperEngine/Render/Objects/CImage.cpp | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/WallpaperEngine/Render/CVideo.cpp b/src/WallpaperEngine/Render/CVideo.cpp index de67743..539ed28 100644 --- a/src/WallpaperEngine/Render/CVideo.cpp +++ b/src/WallpaperEngine/Render/CVideo.cpp @@ -63,12 +63,12 @@ CVideo::CVideo (Core::CVideo* video, CContainer* container) : // inverted positions so the final texture is rendered properly GLfloat position [] = { - 1.0f, -1.0f, 0.0f, - -1.0, -1.0f, 0.0f, - 1.0f, 1.0f, 0.0f, - 1.0f, 1.0f, 0.0f, + -1.0f, 1.0f, 0.0f, + 1.0, 1.0f, 0.0f, -1.0f, -1.0f, 0.0f, - -1.0f, 1.0f, 0.0f + -1.0f, -1.0f, 0.0f, + 1.0f, 1.0f, 0.0f, + 1.0f, -1.0f, 0.0f }; glGenBuffers (1, &this->m_texCoordBuffer); diff --git a/src/WallpaperEngine/Render/Objects/CImage.cpp b/src/WallpaperEngine/Render/Objects/CImage.cpp index 7d661af..9d87d20 100644 --- a/src/WallpaperEngine/Render/Objects/CImage.cpp +++ b/src/WallpaperEngine/Render/Objects/CImage.cpp @@ -57,8 +57,8 @@ CImage::CImage (CScene* scene, Core::Objects::CImage* image) : nameA << "_rt_imageLayerComposite_" << this->getImage ()->getId () << "_a"; nameB << "_rt_imageLayerComposite_" << this->getImage ()->getId () << "_b"; - this->m_currentMainFBO = this->m_mainFBO = scene->createFBO (nameA.str (), ITexture::TextureFormat::ARGB8888, 1, this->m_texture->getRealWidth (), this->m_texture->getRealHeight (), this->m_texture->getRealWidth (), this->m_texture->getRealHeight ()); - this->m_currentSubFBO = this->m_subFBO = scene->createFBO (nameB.str (), ITexture::TextureFormat::ARGB8888, 1, this->m_texture->getRealWidth (), this->m_texture->getRealHeight (), this->m_texture->getRealWidth (), this->m_texture->getRealHeight ()); + this->m_currentMainFBO = this->m_mainFBO = scene->createFBO (nameB.str (), ITexture::TextureFormat::ARGB8888, 1, this->m_texture->getRealWidth (), this->m_texture->getRealHeight (), this->m_texture->getRealWidth (), this->m_texture->getRealHeight ()); + this->m_currentSubFBO = this->m_subFBO = scene->createFBO (nameA.str (), ITexture::TextureFormat::ARGB8888, 1, this->m_texture->getRealWidth (), this->m_texture->getRealHeight (), this->m_texture->getRealWidth (), this->m_texture->getRealHeight ()); GLfloat realWidth = this->m_texture->getRealWidth () / 2; GLfloat realHeight = this->m_texture->getRealHeight () / 2;