mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Direct2D: Slightly shrink excluded clip regions in order to draw transformed opaque components without border artefacts
This commit is contained in:
parent
e11b8f5ccb
commit
06137fb7f5
1 changed files with 2 additions and 2 deletions
|
|
@ -912,7 +912,7 @@ void Direct2DGraphicsContext::excludeClipRectangle (const Rectangle<int>& userSp
|
|||
if (transform.isOnlyTranslated)
|
||||
{
|
||||
// Just a translation; pre-translate the exclusion area
|
||||
auto translatedR = transform.translated (userSpaceExcludedRectangle.toFloat());
|
||||
auto translatedR = transform.translated (userSpaceExcludedRectangle.toFloat()).getLargestIntegerWithin().toFloat();
|
||||
|
||||
if (! translatedR.contains (frameSize))
|
||||
{
|
||||
|
|
@ -923,7 +923,7 @@ void Direct2DGraphicsContext::excludeClipRectangle (const Rectangle<int>& userSp
|
|||
else if (currentState->isCurrentTransformAxisAligned())
|
||||
{
|
||||
// Just a scale + translation; pre-transform the exclusion area
|
||||
auto transformedR = transform.boundsAfterTransform (userSpaceExcludedRectangle.toFloat());
|
||||
auto transformedR = transform.boundsAfterTransform (userSpaceExcludedRectangle.toFloat()).getLargestIntegerWithin().toFloat();
|
||||
|
||||
if (! transformedR.contains (frameSize))
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue