plugins/magnifier: use floating point offscreen texture

With color management, everything would get clamped to 1 nit otherwise.

BUG: 477841
This commit is contained in:
Xaver Hugl 2023-12-05 12:18:39 +01:00
parent 3dc8b937ba
commit ab48621758

View file

@ -206,7 +206,7 @@ void MagnifierEffect::zoomIn()
} }
if (effects->isOpenGLCompositing() && !m_texture) { if (effects->isOpenGLCompositing() && !m_texture) {
effects->makeOpenGLContextCurrent(); effects->makeOpenGLContextCurrent();
m_texture = GLTexture::allocate(GL_RGBA8, m_magnifierSize); m_texture = GLTexture::allocate(GL_RGBA16F, m_magnifierSize);
if (!m_texture) { if (!m_texture) {
return; return;
} }
@ -246,7 +246,7 @@ void MagnifierEffect::toggle()
} }
if (effects->isOpenGLCompositing() && !m_texture) { if (effects->isOpenGLCompositing() && !m_texture) {
effects->makeOpenGLContextCurrent(); effects->makeOpenGLContextCurrent();
m_texture = GLTexture::allocate(GL_RGBA8, m_magnifierSize); m_texture = GLTexture::allocate(GL_RGBA16F, m_magnifierSize);
if (!m_texture) { if (!m_texture) {
return; return;
} }