sw_engine: blending stabilization++

Currently, only blending might work.
Blending and composition must be handled together.
This commit is contained in:
Hermet Park 2024-09-10 14:53:11 +09:00
parent bf3e861b5a
commit 5cfd541ea9

View file

@ -607,7 +607,10 @@ Compositor* SwRenderer::target(const RenderRegion& region, ColorSpace cs)
cmp->w = cmp->compositor->image.w; cmp->w = cmp->compositor->image.w;
cmp->h = cmp->compositor->image.h; cmp->h = cmp->compositor->image.h;
rasterClear(cmp, x, y, w, h, (surface->blendMethod == BlendMethod::Normal) ? 0x00000000 : 0x00ffffff); /* TODO: Currently, only blending might work.
Blending and composition must be handled together. */
auto color = (surface->blender && !surface->compositor) ? 0x00ffffff : 0x00000000;
rasterClear(cmp, x, y, w, h, color);
//Switch render target //Switch render target
surface = cmp; surface = cmp;