Screen tearing in Ubuntu with Nvidia/Intel graphics

Create /etc/X11/xorg.conf.d/20-intel.conf containing

Section "Device"
   Identifier  "Intel Graphics"
   Driver      "intel"
   Option      "TearFree"    "true"
EndSection

That should fix everything.

Source is https://wiki.archlinux.org/index.php/Intel_graphics#Tear-free_video

Note: This only works if you're using bumblebee.


Note from comments: Since 10.10 the config file directory is now /usr/share/X11/xorg.conf.d

Starting from Ubuntu 16.04 LTS * you can use the following script to switch between NVIDIA and INTEL's graphics cards and besides it corrects the video/screen tearing on INTELs environment: https://github.com/bauca/graphics-switcher