mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2024-10-30 07:30:46 +00:00
wlr_scene: Track damage of null textures
If we hit this case, we effectively failed to render something, this might be because a texture failed to upload or the texture is momentarily unavailable after a GPU reset. If we fail to render, we have to continue to track damage for the next frame in hopes that the texture becomes available then. An alternative approach would be to fail the commit completely if we find this case, but in the case of gpu resets, clients may not commit a new buffer for a while, and a frozen display does not help. This fixes damage tracking issues after a gpu reset.
This commit is contained in:
parent
2aebb8e444
commit
86e1b24d84
@ -1196,6 +1196,7 @@ static void scene_entry_render(struct render_list_entry *entry, const struct ren
|
||||
struct wlr_texture *texture = scene_buffer_get_texture(scene_buffer,
|
||||
data->output->output->renderer);
|
||||
if (texture == NULL) {
|
||||
wlr_damage_ring_add(&data->output->damage_ring, &render_region);
|
||||
break;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user