mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-07 00:08:39 +09:00
Issue #2364 - use DrawTarget::DrawSurfaceWithShadow to render box shadows on platforms that accelerate it.
This commit is contained in:
parent
8d30faf95f
commit
4beb3b947c
13 changed files with 228 additions and 150 deletions
|
|
@ -713,9 +713,11 @@ DrawTargetSkia::DrawSurfaceWithShadow(SourceSurface *aSurface,
|
|||
mCanvas->drawImage(image, shadowDest.x, shadowDest.y, &shadowPaint);
|
||||
}
|
||||
|
||||
// Composite the original image after the shadow
|
||||
auto dest = IntPoint::Round(aDest);
|
||||
mCanvas->drawImage(image, dest.x, dest.y, &paint);
|
||||
if (aSurface->GetFormat() != SurfaceFormat::A8) {
|
||||
// Composite the original image after the shadow
|
||||
auto dest = IntPoint::Round(aDest);
|
||||
mCanvas->drawImage(image, dest.x, dest.y, &paint);
|
||||
}
|
||||
|
||||
mCanvas->restore();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue