mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
Switch default renderer to webrender, and update webrender.
This commit is contained in:
parent
c7e1a575a5
commit
f562c426e3
8 changed files with 14 additions and 15 deletions
|
@ -6,5 +6,5 @@ uniform sampler2D sCache;
|
|||
|
||||
void main(void) {
|
||||
vec4 color = texture(sCache, vUv);
|
||||
oFragColor = vec4(color.rgb, color.a * vOpacity);
|
||||
oFragColor = vec4(color.rgb * vBrightnessOpacity.x, color.a * vBrightnessOpacity.y);
|
||||
}
|
||||
|
|
|
@ -3,4 +3,4 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
varying vec2 vUv;
|
||||
varying float vOpacity;
|
||||
varying vec2 vBrightnessOpacity;
|
||||
|
|
|
@ -15,7 +15,7 @@ void main(void) {
|
|||
vec2 st0 = vec2(src.target_rect.xy) / 2048.0;
|
||||
vec2 st1 = vec2(src.target_rect.xy + src.target_rect.zw) / 2048.0;
|
||||
vUv = mix(st0, st1, aPosition.xy);
|
||||
vOpacity = blend.src_id_target_id_opacity.z;
|
||||
vBrightnessOpacity = blend.src_id_target_id_opacity.zw;
|
||||
|
||||
gl_Position = uTransform * vec4(local_pos, 0, 1);
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
void main(void) {
|
||||
#ifdef WR_FEATURE_TRANSFORM
|
||||
float alpha = 1;
|
||||
float alpha = 1.f;
|
||||
vec2 local_pos = init_transform_fs(vLocalPos, vLocalRect, alpha);
|
||||
|
||||
// We clamp the texture coordinate calculation here to the local rectangle boundaries,
|
||||
|
@ -14,7 +14,7 @@ void main(void) {
|
|||
vec2 pos_for_texture =
|
||||
clamp(pos, vLocalRect.xy, vLocalRect.xy + vLocalRect.zw) - vLocalRect.xy;
|
||||
#else
|
||||
float alpha = 1;
|
||||
float alpha = 1.f;
|
||||
vec2 local_pos = vLocalPos;
|
||||
vec2 relative_pos_in_rect = vLocalPos - vLocalRect.xy;
|
||||
#endif
|
||||
|
|
|
@ -4,10 +4,10 @@
|
|||
|
||||
void main(void) {
|
||||
#ifdef WR_FEATURE_TRANSFORM
|
||||
float alpha = 1;
|
||||
float alpha = 1.f;
|
||||
vec2 local_pos = init_transform_fs(vPos, vLocalRect, alpha);
|
||||
#else
|
||||
float alpha = 1;
|
||||
float alpha = 1.f;
|
||||
vec2 local_pos = vPos;
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue