Skip to content

kwineffects: Make GLRenderTarget and GLVertexBuffer work without global coords and scale

Because the GLRenderTarget and the GLVertexBuffer use the global coordinate system, they are not ergonomic in render layers.

Assigning the device pixel ratio to GLRenderTarget and GLVertexBuffer is an interesting api design choice too. Scaling is a window system abstraction, which is absent in OpenGL or Vulkan. For example, it's not possible to create an OpenGL texture with a scale factor of 2. It only works with device pixels.

This change makes the GLRenderTarget and the GLVertexBuffer more ergonomic for usages other than rendering the workspace by removing all the global coordinate system and scaling stuff. That's the responsibility of the users of those two classes.


Edited by Vlad Zahorodnii

Merge request reports