1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-28 02:30:05 +00:00
JUCE/modules
reuk 0a1929944b
Direct2D: Draw images correctly when transformed with a vertical or horizontal flip
Previously, drawing a mirrored image would produce incorrect results.
Scaling transforms were applied correctly, but mirroring was not.  The
following code is an example of a drawing routine that previously
produced incorrect results.

g.fillAll (juce::Colours::grey);

juce::Image image { juce::Image::PixelFormat::ARGB, 512, 512, false };

{
    juce::Graphics h { image };
    h.setGradientFill (juce::ColourGradient { juce::Colours::cyan,
                                              {},
                                              juce::Colours::magenta,
                                              { 512, 512 },
                                              false });
    h.fillAll();
}

const auto cy = getHeight() / 2;

g.drawImageWithin (image,
                   0,
                   0,
                   getWidth(),
                   cy,
                   juce::RectanglePlacement::stretchToFit);
const auto transform = juce::AffineTransform::verticalFlip ((float) cy)
                       .translated (0, (float) cy);
g.addTransform (transform);
g.drawImageWithin (image,
                   0,
                   0,
                   getWidth(),
                   cy,
                   juce::RectanglePlacement::stretchToFit);
2026-01-21 18:26:09 +00:00
..
juce_analytics Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_animation Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_audio_basics MPEZoneLayout: Correctly handle 14-bit pitch-bend ranges 2026-01-07 17:30:23 +00:00
juce_audio_devices CoreAudio: Fix build issue with Xcode 15.2 due to iterator traits requirement 2026-01-13 12:38:44 +00:00
juce_audio_formats Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_audio_plugin_client LV2 Client: Avoid advertising noUserResize as extension data 2025-12-16 12:23:59 +00:00
juce_audio_processors VST Host: Linux: Map plugin window even with XEMBED_MAPPED unset 2026-01-08 12:40:43 +01:00
juce_audio_processors_headless LV2: Use std::optional in more places 2025-12-16 12:23:58 +00:00
juce_audio_utils Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_box2d Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_core Add some missing nodiscards 2026-01-20 10:55:13 +00:00
juce_cryptography Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_data_structures Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_dsp FIR Filter: Fix a bug resetting the state 2026-01-20 16:38:54 +00:00
juce_events Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_graphics Direct2D: Draw images correctly when transformed with a vertical or horizontal flip 2026-01-21 18:26:09 +00:00
juce_gui_basics ComponentDragger: Remove virtual destructor 2026-01-21 10:36:15 +00:00
juce_gui_extra WebBrowserComponent: Windows: Fix WebView2 compilation in x86 2026-01-16 13:49:29 +01:00
juce_javascript Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_midi_ci tie: Hide tie implementations from public API 2025-12-22 09:54:33 +00:00
juce_opengl Graphics: Hide rendering helpers from public API 2025-12-22 09:54:33 +00:00
juce_osc Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
juce_product_unlocking In-app purchases: Add a warning when JUCE_IN_APP_PURCHASES_USE_SANDBOX_ENVIRONMENT is defined 2025-12-19 12:20:39 +00:00
juce_video Bump version number to 8.0.12 2025-12-16 08:48:49 +00:00
CMakeLists.txt Create new empty juce_audio_processors_headless module 2025-09-17 12:50:07 +01:00