mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Direct2D: Fix image artefacts at the edge of alpha-clipped regions
This addresses the same issue that
95d416ab77 was intended to fix:
Drawing a drop shadow on a high-res display on Windows could sometimes
produce thin lines around the edge of the shadow. Using the 'clamp'
rather than the 'wrap' clipping mode seems to help.
This commit is contained in:
parent
5aa76a7d7e
commit
92c7d73d2d
1 changed files with 1 additions and 1 deletions
|
|
@ -1211,7 +1211,7 @@ void Direct2DGraphicsContext::clipToImageAlpha (const Image& sourceImage, const
|
|||
auto matrix = D2DUtilities::transformToMatrix (brushTransform);
|
||||
D2D1_BRUSH_PROPERTIES brushProps = { 1.0f, matrix };
|
||||
|
||||
auto bitmapBrushProps = D2D1::BitmapBrushProperties (D2D1_EXTEND_MODE_WRAP, D2D1_EXTEND_MODE_WRAP);
|
||||
auto bitmapBrushProps = D2D1::BitmapBrushProperties (D2D1_EXTEND_MODE_CLAMP, D2D1_EXTEND_MODE_CLAMP);
|
||||
auto hr = deviceContext->CreateBitmapBrush (bitmap, bitmapBrushProps, brushProps, brush.resetAndGetPointerAddress());
|
||||
|
||||
if (FAILED (hr))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue