1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Direct2DImage: Add missing data change notification when creating writable BitmapData

The OpenGL renderer listens for imageDataChanged() to invalidated cached
textures.

Before this change, the SimpleFFTDemo would display a static (outdated)
image on Windows when using the OpenGLRenderer.
This commit is contained in:
reuk 2025-05-27 14:16:29 +01:00
parent 415aed4bea
commit 72e345cdd7
No known key found for this signature in database

View file

@ -580,6 +580,8 @@ void Direct2DPixelData::moveValidatedImageSection (Point<int> destTopLeft, Recta
return;
}
sendDataChangeMessage();
Ptr staging = new Direct2DPixelData { pixelFormat,
sourceRect.getWidth(),
sourceRect.getHeight(),
@ -777,6 +779,8 @@ void Direct2DPixelData::initialiseBitmapData (Image::BitmapData& bitmap,
if (mode == Image::BitmapData::readOnly)
return;
sendDataChangeMessage();
struct Releaser : public Image::BitmapData::BitmapDataReleaser
{
Releaser (std::unique_ptr<BitmapDataReleaser> wrappedIn, Ptr selfIn)