Web Design

Categorized | cli, Multimedia

Record your Linux desktop from the command line

If you do not wish to install a dedicated application for recording your desktop, you can do it with this one-liner:

ffmpeg -f x11grab -s wxga -r 25 -i :0.0 -sameq /home/user/out.mpg

All you need is have ffmpeg already installed (and most systems do). Navigate to /home/user and you’ll find you MPEG video file there.

Author Profile

T4L ;

Other posts by

Author's web site



Are you satisfied with this blog?
Why not subscribe our RSS Feed? you will always get the latest post.


2 Comments

  1. SergioJP

    This command writes video only, if you want to add audio recording.
    use
    oss-i / dev/dsp0
    or
    oss-i / dev/dsp1

    depending on your audio configuration.
    For me works with dsp1.

    Sorry my English.

    1
  2. RDB

    ffmpeg -f x11grab -s wxga -r 25 -i :0.0 -sameq /home/mintylinux/out.mov

    It works, I changed it to mov file as mpg had buffer errors.

    SergioJP I would like to use the audio option, but I’m not sure how to input it into command line. Every time I try I just get weird errors and doesn’t work. Like this
    “[x11grab @ 0x9e31aa0] Could not open X display.
    oss-i: Input/output error”

    2

Leave A Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>