mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 945655 - Don't add transparency around the filter output before sending it to DrawSurface. r=roc
This commit is contained in:
parent
80876b8581
commit
e6512a0aae
@ -582,25 +582,17 @@ FilterNodeSoftware::Draw(DrawTarget* aDrawTarget,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Add transparency around outputRect in renderIntRect.
|
|
||||||
result = GetDataSurfaceInRect(result, outputRect, renderIntRect, EDGE_MODE_NONE);
|
|
||||||
if (!result) {
|
|
||||||
#ifdef DEBUG_DUMP_SURFACES
|
|
||||||
printf("GetDataSurfaceInRect for output returned null\n");
|
|
||||||
printf("</pre>\n");
|
|
||||||
#endif
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef DEBUG_DUMP_SURFACES
|
#ifdef DEBUG_DUMP_SURFACES
|
||||||
printf("output:\n");
|
printf("output:\n");
|
||||||
printf("<img src='"); DumpAsPNG(result); printf("'>\n");
|
printf("<img src='"); DumpAsPNG(result); printf("'>\n");
|
||||||
printf("</pre>\n");
|
printf("</pre>\n");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Draw.
|
Point sourceToDestOffset = aDestPoint - aSourceRect.TopLeft();
|
||||||
aDrawTarget->DrawSurface(result, Rect(aDestPoint, aSourceRect.Size()),
|
Rect renderedSourceRect = Rect(outputRect).Intersect(aSourceRect);
|
||||||
aSourceRect - renderIntRect.TopLeft(),
|
Rect renderedDestRect = renderedSourceRect + sourceToDestOffset;
|
||||||
|
aDrawTarget->DrawSurface(result, renderedDestRect,
|
||||||
|
renderedSourceRect - Point(outputRect.TopLeft()),
|
||||||
DrawSurfaceOptions(), aOptions);
|
DrawSurfaceOptions(), aOptions);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user