mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-22 15:45:59 +01:00
pointer: add back nvidia hardware cursor quirks (#6220)
This commit is contained in:
parent
52684b7d90
commit
0d6eae0523
1 changed files with 11 additions and 1 deletions
|
@ -119,7 +119,17 @@ static bool output_pick_cursor_format(struct wlr_output* output, struct wlr_drm_
|
|||
}
|
||||
}
|
||||
|
||||
return output_pick_format(output, display_formats, format, DRM_FORMAT_ARGB8888);
|
||||
// Note: taken from https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/4596/diffs#diff-content-e3ea164da86650995728d70bd118f6aa8c386797
|
||||
// If this fails to find a shared modifier try to use a linear
|
||||
// modifier. This avoids a scenario where the hardware cannot render to
|
||||
// linear textures but only linear textures are supported for cursors,
|
||||
// as is the case with Nvidia and VmWare GPUs
|
||||
if (!output_pick_format(output, display_formats, format, DRM_FORMAT_ARGB8888)) {
|
||||
// Clear the format as output_pick_format doesn't zero it
|
||||
memset(format, 0, sizeof(*format));
|
||||
return output_pick_format(output, NULL, format, DRM_FORMAT_ARGB8888);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
CPointerManager::CPointerManager() {
|
||||
|
|
Loading…
Reference in a new issue