parent
e5f22c06b4
commit
610c59dc34
3 changed files with 79 additions and 15 deletions
|
|
@ -1640,10 +1640,11 @@ void CHyprOpenGLImpl::renderTextureInternal(SP<CTexture> tex, const CBox& box, c
|
|||
static const auto PCURSORTIMEOUT = CConfigValue<Hyprlang::FLOAT>("cursor:inactive_timeout");
|
||||
|
||||
// get the needed transform for this texture
|
||||
const bool TRANSFORMS_MATCH = Math::wlTransformToHyprutils(m_renderData.pMonitor->m_transform) == tex->m_transform; // FIXME: combine them properly!!!
|
||||
eTransform TRANSFORM = HYPRUTILS_TRANSFORM_NORMAL;
|
||||
if (m_monitorTransformEnabled || TRANSFORMS_MATCH)
|
||||
TRANSFORM = Math::wlTransformToHyprutils(Math::invertTransform(m_renderData.pMonitor->m_transform));
|
||||
const auto MONITOR_INVERTED = Math::wlTransformToHyprutils(Math::invertTransform(m_renderData.pMonitor->m_transform));
|
||||
Hyprutils::Math::eTransform TRANSFORM = tex->m_transform;
|
||||
|
||||
if (m_monitorTransformEnabled)
|
||||
TRANSFORM = Math::composeTransform(MONITOR_INVERTED, TRANSFORM);
|
||||
|
||||
Mat3x3 matrix = m_renderData.monitorProjection.projectBox(newBox, TRANSFORM, newBox.rot);
|
||||
Mat3x3 glMatrix = m_renderData.projection.copy().multiply(matrix);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue