os:linux:ubuntu:nvidiastutter
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
os:linux:ubuntu:nvidiastutter [2022/11/10 18:25] – [Applying the Changes] jay | os:linux:ubuntu:nvidiastutter [2023/10/26 17:51] (current) – jay | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Ubuntu 22.04 + Nvidia Window Movement Stutter ====== | ====== Ubuntu 22.04 + Nvidia Window Movement Stutter ====== | ||
+ | //Updated on 2023-10-26 to change to mutter 42.9// | ||
+ | |||
There' | There' | ||
Line 20: | Line 22: | ||
I already had a bunch of core build tools installed, so // | I already had a bunch of core build tools installed, so // | ||
- | ===== Mutter-42.2 ===== | + | ===== Mutter-42.9 ===== |
This is the version of '' | This is the version of '' | ||
- | You can download that here: [[https:// | + | You can download that here: [[https:// |
Once you get that downloaded, you need to move to a dir to unpack it. | Once you get that downloaded, you need to move to a dir to unpack it. | ||
<code bash> | <code bash> | ||
- | tar -xvzf mutter-42.2.tar.gz | + | tar -xvzf mutter-42.9.tar.gz |
</ | </ | ||
===== Patching ===== | ===== Patching ===== | ||
- | Next up, we need to apply the patch for 42.2, which is basically what I [[https:// | + | Next up, we need to apply the patch for 42.9, which is basically what I [[https:// |
The patch is this: | The patch is this: | ||
< | < | ||
- | diff -ru mutter-42.2-orig/ | + | diff -ru mutter-42.9.orig/ |
- | --- mutter-42.2-orig/ | + | --- mutter-42.9.orig/ |
- | +++ mutter-42.2/ | + | +++ mutter-42.9/ |
- | @@ -878,7 +878,6 @@ | + | @@ -880,7 +880,6 @@ |
| | ||
Line 47: | Line 49: | ||
| | ||
- | @@ -1850,6 +1849,21 @@ | + | @@ -1962,13 +1961,12 @@ |
- | } | + | |
- | } | + | |
- | + | ||
- | +void | + | |
- | +meta_display_clear_grab_move_resize_later (MetaDisplay *display) | + | |
- | +{ | + | |
- | + if (display-> | + | |
- | + { | + | |
- | + MetaCompositor *compositor; | + | |
- | + MetaLaters *laters; | + | |
- | + | + | |
- | + compositor = meta_display_get_compositor (display); | + | |
- | + laters = meta_compositor_get_laters (compositor); | + | |
- | + meta_laters_remove (laters, display-> | + | |
- | + display-> | + | |
- | + } | + | |
- | +} | + | |
- | + | + | |
- | | + | |
- | | + | |
- | | + | |
- | @@ -1956,13 +1970,12 @@ | + | |
| | ||
| | ||
Line 84: | Line 64: | ||
| | ||
" | " | ||
- | @@ -2048,13 +2061,12 @@ | + | @@ -2054,13 +2052,12 @@ |
| | ||
| | ||
Line 99: | Line 79: | ||
if (meta_is_wayland_compositor ()) | if (meta_is_wayland_compositor ()) | ||
| | ||
- | diff -ru mutter-42.2-orig/ | + | @@ -2758,6 +2755,21 @@ |
- | --- mutter-42.2-orig/ | + | |
- | +++ mutter-42.2/ | + | } |
- | @@ -187,12 +187,10 @@ | + | |
- | | + | +void |
- | | + | +meta_display_clear_grab_move_resize_later (MetaDisplay *display) |
- | | + | +{ |
- | - int64_t | + | + if (display-> |
+ | + { | ||
+ | + MetaCompositor *compositor; | ||
+ | + MetaLaters *laters; | ||
+ | + | ||
+ | + compositor = meta_display_get_compositor (display); | ||
+ | + laters = meta_compositor_get_laters (compositor); | ||
+ | + meta_laters_remove (laters, display-> | ||
+ | + display-> | ||
+ | + } | ||
+ | +} | ||
+ | + | ||
+ | | ||
+ | | ||
+ | | ||
+ | diff -ru mutter-42.9.orig/ | ||
+ | --- mutter-42.9.orig/ | ||
+ | +++ mutter-42.9/ | ||
+ | @@ -191,8 +191,7 @@ | ||
| | ||
| | ||
Line 116: | Line 114: | ||
/* Opening the display */ | /* Opening the display */ | ||
- | @@ -346,6 +344,7 @@ | + | @@ -346,6 +345,7 @@ |
| | ||
| | ||
Line 124: | Line 122: | ||
MetaWindow | MetaWindow | ||
void meta_display_remove_autoraise_callback (MetaDisplay *display); | void meta_display_remove_autoraise_callback (MetaDisplay *display); | ||
- | diff -ru mutter-42.2-orig/ | + | diff -ru mutter-42.9.orig/ |
- | --- mutter-42.2-orig/ | + | --- mutter-42.9.orig/ |
- | +++ mutter-42.2/ | + | +++ mutter-42.9/ |
@@ -132,15 +132,6 @@ | @@ -132,15 +132,6 @@ | ||
| | ||
Line 143: | Line 141: | ||
| | ||
- | @@ -5714,44 +5705,6 @@ | + | @@ -5761,44 +5752,6 @@ |
| | ||
} | } | ||
Line 188: | Line 186: | ||
| | ||
| | ||
- | @@ -5822,6 +5775,8 @@ | + | @@ -6039,34 +5992,59 @@ |
- | | + | |
- | | + | |
- | + | ||
- | + meta_display_clear_grab_move_resize_later (display); | + | |
- | + | + | |
- | dx = x - display-> | + | |
- | dy = y - display-> | + | |
- | + | ||
- | @@ -5992,34 +5947, | + | |
} | } | ||
| | ||
-update_resize_timeout (gpointer data) | -update_resize_timeout (gpointer data) | ||
- | +update_move_cb (gpointer | + | +update_move_cb (gpointer |
{ | { | ||
- MetaWindow *window = data; | - MetaWindow *window = data; | ||
+ MetaWindow *window = user_data; | + MetaWindow *window = user_data; | ||
+ | + window-> | ||
- update_resize (window, | - update_resize (window, | ||
Line 213: | Line 203: | ||
- | - | ||
- return FALSE; | - return FALSE; | ||
- | + window-> | ||
- | + | ||
+ update_move (window, | + update_move (window, | ||
+ | + | ||
Line 269: | Line 257: | ||
dy = y - window-> | dy = y - window-> | ||
- | @@ -6081,27 +6062,6 @@ | + | @@ -6128,27 +6106,6 @@ |
if (window-> | if (window-> | ||
| | ||
Line 297: | Line 285: | ||
/* One sided resizing ought to actually be one-sided, despite the fact that | /* One sided resizing ought to actually be one-sided, despite the fact that | ||
- | @@ -6129,11 +6089,44 @@ | + | @@ -6176,11 +6133,45 @@ |
| | ||
new_rect.width, | new_rect.width, | ||
gravity); | gravity); | ||
+} | +} | ||
+ | + | ||
+static gboolean | +static gboolean | ||
+update_resize_cb (gpointer user_data) | +update_resize_cb (gpointer user_data) | ||
Line 346: | Line 335: | ||
| | ||
- | @@ -6157,10 +6150,9 @@ | + | @@ -6204,10 +6195,9 @@ |
void | void | ||
| | ||
Line 359: | Line 348: | ||
| | ||
- | @@ -6204,7 +6196,7 @@ | + | @@ -6251,7 +6241,7 @@ |
if (window-> | if (window-> | ||
flags |= (META_EDGE_RESISTANCE_SNAP | META_EDGE_RESISTANCE_WINDOWS); | flags |= (META_EDGE_RESISTANCE_SNAP | META_EDGE_RESISTANCE_WINDOWS); | ||
Line 368: | Line 357: | ||
} | } | ||
} | } | ||
- | @@ -6281,14 +6273,14 @@ | + | @@ -6328,14 +6318,14 @@ |
| | ||
if (meta_grab_op_is_moving (window-> | if (meta_grab_op_is_moving (window-> | ||
Line 385: | Line 374: | ||
| | ||
- | diff -ru mutter-42.2-orig/ | + | diff -ru mutter-42.9.orig/ |
- | --- mutter-42.2-orig/ | + | --- mutter-42.9.orig/ |
- | +++ mutter-42.2/ | + | +++ mutter-42.9/ |
- | @@ -864,8 +864,8 @@ | + | @@ -869,8 +869,7 @@ |
void meta_window_update_resize (MetaWindow *window, | void meta_window_update_resize (MetaWindow *window, | ||
Line 394: | Line 383: | ||
- int x, int y, | - int x, int y, | ||
- gboolean force); | - gboolean force); | ||
- | + int x, | + | + int x, int y); |
- | + | + | |
void meta_window_move_resize_internal (MetaWindow | void meta_window_move_resize_internal (MetaWindow | ||
MetaMoveResizeFlags | MetaMoveResizeFlags | ||
- | diff -ru mutter-42.2-orig/ | + | diff -ru mutter-42.9.orig/ |
- | --- mutter-42.2-orig/ | + | --- mutter-42.9.orig/ |
- | +++ mutter-42.2/ | + | +++ mutter-42.9/ |
@@ -1231,8 +1231,7 @@ | @@ -1231,8 +1231,7 @@ | ||
| | ||
Line 412: | Line 400: | ||
| | ||
- | @@ -4152,8 +4151,7 @@ | + | @@ -4153,8 +4152,7 @@ |
| | ||
window-> | window-> | ||
Line 421: | Line 409: | ||
} | } | ||
} | } | ||
+ | |||
</ | </ | ||
Line 428: | Line 417: | ||
<code bash> | <code bash> | ||
- | cd / | + | cd / |
patch -p1 < / | patch -p1 < / | ||
</ | </ | ||
Line 447: | Line 436: | ||
<code bash> | <code bash> | ||
- | cd / | + | cd / |
meson build/ | meson build/ | ||
</ | </ | ||
Line 453: | Line 442: | ||
If everything goes well there, we're ready to actually do our compilation and installation. By default, the install prefix is ''/ | If everything goes well there, we're ready to actually do our compilation and installation. By default, the install prefix is ''/ | ||
- | All right, let's compile and install! | + | All right, let's compile and install! |
<code bash> | <code bash> | ||
- | cd / | + | cd / |
ninja -C build/ install | ninja -C build/ install | ||
</ | </ |
os/linux/ubuntu/nvidiastutter.txt · Last modified: 2023/10/26 17:51 by jay