How to record the screen and webcam at the same time?

Is there a program for Ubuntu that can capture your screen and your webcam at the same time?


Solution 1:

16.04 -> 18.04:

Please check How to install Kazam 1.5.3?


14.04:

Kazam 1.5.3 was released recently and it includes some very useful new features:

  • support for webcams: it can record just the webcam or it can display the webcam in a window on top of the screencast;
  • support for broadcasting to YouTube Live;
  • added on-screen keyboard indicator and mouse click indicator;
  • new countdown timer.

Kazam is available in the official Ubuntu repositories, but it's an old version so it doesn't have the new features above. To get the latest Kazam in Ubuntu you can use the Kazam PPA.

Open a terminal and use the following commands:

sudo add-apt-repository ppa:kazam-team/unstable-series
sudo apt-get update
sudo apt-get install kazam python3-cairo python3-xlib

enter image description here

Source: http://www.webupd8.org/2014/08/kazam-screencaster-gets-webcam-and.html

Solution 2:

guvcview + recordmydesktop

I find guvcview ideal for screencasts, as it can show just the camera on a window and nothing else:

sudo apt-get install guvcview recordmydesktop
guvcview

Then just use any screen recorder. recordmydesktop works fine.

This is a sample screencast: https://www.youtube.com/watch?v=TQ5k2u25eI8

To keep guvcview always on top if you want it on top of another maximized window, you can use the same procedure that works for any Ubuntu program window:

  • right click on the top bar of the window (it contains the title and close button)
  • select "Always on Top"

recordmydesktop alternatives are discussed at: How can I record my screen?

Tested on Ubuntu 18.04.

Non-screencast questions:

  • https://unix.stackexchange.com/questions/3304/how-do-i-watch-my-webcams-feed-in-linux
  • What webcam apps are available and how to check if your webcam is working?

ffplay from ffmpeg

The older I get the more I realise that there is nothing ffmpeg can't do when it comes to video:

sudo apt install ffmpeg
ffplay /dev/video0

enter image description here

See also: How to check available webcams from the command line?

Tested in Ubuntu 19.10.

Remove window title bar

I haven't managed this yet:

  • On Ubuntu 18.04 can I hide the title bar AND still see the close/minimize/maximize icons?
  • https://unix.stackexchange.com/questions/420452/how-to-hide-title-bar-for-a-specific-window

enter image description here

Solution 3:

Kazam 1.5.3 has an option to capture webcam output while screen recording. Unfortunately, it is buggy.

A better alternative is to use vokoscreen. We can install it from software center or from terminal using apt.

sudo apt install vokoscreen

After launching it, you can enable webcam as shown in the picture.

enter image description here

Solution 4:

Open Broadcaster Software - aka OBS http://obsproject.com

Used all the time by Youtube and Twitch live streamers or instructors doing tutorials. You can live stream or just record. You can implement green screen, add other overlays.. do anything you want.