The Unity Shell UI is a plugin of the Compiz compositing window manager (Unity Wiki) while i3 a standalone window manager without native compositing features. That means that by default Unity utilizes all manner of graphics acceleration features and i3 uses "plain" X11.
In order to get compositing features in i3, you will have to start a composite manager (not a compositing window manager). compton is a quite popular choice to use with i3.
Installation is easy as packages for Ubuntu are available in the official repository for trusty and newer. After installation you have to create a configuration, for example at ~/.config/compton.conf (as the location of the configuration file can be passed as argument to compton, the choice is yours). My compton.conf looks like this:
# basic configuration
backend = "glx";
vsync = "opengl-swc";
glx-copy-from-front = true;
glx-swap-method = 2;
xrender-sync = true;
xrender-sync-fence = true;
# transparancy settings for i3
opacity-rule = [
"0:_NET_WM_STATE@:32a *= '_NET_WM_STATE_HIDDEN'"
];
It is possible that you need to adjust it for your system.
Now you can start compton:
compton --config ~/.config/compton.conf -b
After you made sure that it works well, you can start it automatically by adding
exec --no-startup-id compton --config ~/.config/compton.conf -b
to your ~/.i3/config.
Note: I strongly suggest updating i3 to at least version 4.12 (the current release at time of posting). It solves a few rendering issues i3 has in conjunction with compton, at least when cairo ≥ 1.14.4 is available (xenial comes with cairo 1.14.6; see i3 Release Notes).
comptonis a very nice lightweight compositor. – Olathe Mar 29 '16 at 00:34backendoption existed. Setting it toglxbasically fixed everything for me. All tearing is gone and browser scrolling is silky smooth. – Hubro Oct 19 '17 at 10:59i3wait for any command to fully run before starting the next. For another,comptonitself can be started at any point later in a running i3 session and should work just fine. That being said, I have noticed some screen tearing issues on multi-display setups, where the refresh rate of the displays does not match 100% (e.g. 59.97 Hz vs 60.01 Hz) and the output is synced to the "wrong" display. Unfortunately, I have not yet found a solution. – Adaephon Jun 05 '20 at 06:16vsync = truenow for picom, apart from that: great! – tollo Nov 14 '24 at 09:53