mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-12-02 01:05:58 +01:00
Merge pull request #990 from emersion/fullscreen-clear-alpha
output: correctly clear screen when fullscreened
This commit is contained in:
commit
327aa7f49d
2 changed files with 5 additions and 4 deletions
|
@ -458,7 +458,7 @@ static void render_output(struct roots_output *output) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (server->config->debug_damage_tracking) {
|
if (server->config->debug_damage_tracking) {
|
||||||
wlr_renderer_clear(renderer, (float[]){1, 1, 0, 0});
|
wlr_renderer_clear(renderer, (float[]){1, 1, 0, 1});
|
||||||
}
|
}
|
||||||
|
|
||||||
int nrects;
|
int nrects;
|
||||||
|
|
|
@ -368,7 +368,7 @@ static void output_fullscreen_surface_render(struct wlr_output *output,
|
||||||
assert(renderer);
|
assert(renderer);
|
||||||
|
|
||||||
if (!wlr_surface_has_buffer(surface)) {
|
if (!wlr_surface_has_buffer(surface)) {
|
||||||
wlr_renderer_clear(renderer, (float[]){0, 0, 0, 0});
|
wlr_renderer_clear(renderer, (float[]){0, 0, 0, 1});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -385,8 +385,9 @@ static void output_fullscreen_surface_render(struct wlr_output *output,
|
||||||
pixman_box32_t *rects = pixman_region32_rectangles(damage, &nrects);
|
pixman_box32_t *rects = pixman_region32_rectangles(damage, &nrects);
|
||||||
for (int i = 0; i < nrects; ++i) {
|
for (int i = 0; i < nrects; ++i) {
|
||||||
output_scissor(output, &rects[i]);
|
output_scissor(output, &rects[i]);
|
||||||
wlr_renderer_clear(renderer, (float[]){0, 0, 0, 0});
|
wlr_renderer_clear(renderer, (float[]){0, 0, 0, 1});
|
||||||
wlr_render_texture_with_matrix(surface->renderer, surface->texture, matrix, 1.0f);
|
wlr_render_texture_with_matrix(surface->renderer, surface->texture,
|
||||||
|
matrix, 1.0f);
|
||||||
}
|
}
|
||||||
wlr_renderer_scissor(renderer, NULL);
|
wlr_renderer_scissor(renderer, NULL);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue