mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 05:33:36 +00:00
wg_engine: fix custom scene blending with opacity
fixed incorrect opacity applience for scene blending
This commit is contained in:
parent
ba7091956c
commit
2bd8fdad36
1 changed files with 1 additions and 3 deletions
|
@ -435,13 +435,11 @@ fn getFragData(id: vec2u) -> FragData {
|
|||
data.Dc = colorDst.rgb;
|
||||
data.Da = colorDst.a;
|
||||
data.skip = false;
|
||||
data.Sc = data.Sc * So;
|
||||
data.Sa = data.Sa * So;
|
||||
return data;
|
||||
};
|
||||
|
||||
fn postProcess(d: FragData, R: vec4f) -> vec4f {
|
||||
return mix(vec4(d.Dc, d.Da), R, d.Sa);
|
||||
return mix(vec4(d.Dc, d.Da), R, d.Sa * So);
|
||||
};
|
||||
)";
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue