Browse Source

OpenGL: Apply Component's transform when invalidating

tags/2021-05-28
ed 7 years ago
parent
commit
0a15be729e
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      modules/juce_opengl/opengl/juce_OpenGLContext.cpp

+ 3
- 1
modules/juce_opengl/opengl/juce_OpenGLContext.cpp View File

@@ -157,7 +157,9 @@ public:
bool invalidate (const Rectangle<int>& area) override bool invalidate (const Rectangle<int>& area) override
{ {
validArea.subtract (area * scale);
auto scaled = area.toFloat() * scale;
validArea.subtract (scaled.transformedBy (transform).getSmallestIntegerContainer());
triggerRepaint(); triggerRepaint();
return false; return false;
} }


Loading…
Cancel
Save