[RESOLVED] Problems with screen recording

*nix specific usage questions
AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

[RESOLVED] Problems with screen recording

Postby AlekseyK » 13 Dec 2010 16:57

I'm trying to record my screen in background using following command line which was partially copy-pasted from VLC GUI:
vlc screen:// -I dummy --no-video :screen-fps=10 :screen-caching=300 :sout'#transcode{vcodec=mp1v,vb=2000,fps=10,scale=1,width=640,height=480,acodec=none} :no-sout-rtp-sap :no-sout-standard-sap :ttl=1 :sout-keep :file{dst=~/Work/TD_capture.avi}'
I also tried other vcodecs: mp4v, theo, WMV2, mp1v. Have few problems:
  • no file created at all, no recording, however...
  • high CPU consumption after start is 100% on all the codecs: I saw people able to record desktops with VLC even in h264 format in real time - this one of course not with my PC (old Sempron with 1,6GHz) but it is able to record in mp4 or at least in MPEG-1/2 formats in real time.
  • How to stop vlc correctly after it was recording fo some time?
  • What is sout and transcode correct syntax is? I read few topics here: there should be a space?
Last edited by AlekseyK on 17 Dec 2010 04:05, edited 3 times in total.

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: Problems with screen recording

Postby AlekseyK » 13 Dec 2010 20:02

Found correct command line here: viewtopic.php?f=4&t=46971, so 1st and 4th issues are solved. However quit is not clear: command line help says about "vlc vlc://quit", but that url works only if --one-instance option is specified and vlc is in playing mode then another vlc copy with "vlc://quit" parameter leads to both copies quitting. But if vlc is in recording mode then this option does nothing.

About CPU: works fine on my Windows PC with dual core Athlon 3800+ with both h264, mp4v. But on Sempron 1,6 GHz occupies all the CPU, may be because of non-workable video card driver 2D acceleration? Do not know, how to check this?

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: Problems with screen recording

Postby AlekseyK » 13 Dec 2010 20:19

Also, how to make mouse cursor visible on screencast?

P.S. --screen-follow-mouse does not work. Need to try --screen-mouse-image=<string>?

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: Problems with screen recording

Postby AlekseyK » 13 Dec 2010 20:51

Disappointment: http://wiki.videolan.org/Interfaces
Note that if you only use the dummy interface, you won't be able to tell vlc to quit (except watching a video).
What to do?!

Rémi Denis-Courmont
Developer
Developer
Posts: 15229
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: Problems with screen recording

Postby Rémi Denis-Courmont » 14 Dec 2010 01:44

vlc://quit works fine and the wiki is full of crap. But since screen:// is a never-ending source, VLC will never hit the quit command.

High CPU usage may be due to the high capture frame rate. Screen capture as such is very inefficient; video adapter memory is optimized for output, not for input. In fact, it's even slower on Windows.
For efficiency, you'd need to use Xvfb instead, which tells the application to write to main memory. However then, you would not "see" the application on your screen at all, so it is mostly useless and consequently VLC does not even support Xvfb.

Mouse cursor is not visible. This is partly a limitation of the X11 protocol and partly a limitation of the X11 screen capture plugin in VLC. Patch is most welcome.
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: Problems with screen recording

Postby AlekseyK » 14 Dec 2010 12:34

I checked yesterday: vlc://quit works fine if run vlc with -I rc or -I hotkeys, etc and with --one-instance option. Then running second vlc copy with vlc://quit quits both. I run following command:
vlc screen:// --one-instance -I rc --screen-follow-mouse --no-video --screen-fps 5 --sout "#transcode{vcodec=mp4v,vb=400,fps=5,scale=1,width=1280,height=1024,acodec=none}:duplicate{dst=std{access=file,mux=ts,dst="/home/alex/Work/TD_capture.avi"}}"
so frame rate is lowest possible. Works fine and very fast on my Windows machine with Athlon X2 3800+ even with h264 codec, and very slow in linux (Sempron 1,6 GHz). May be problem here in X settings or old ATI videocard driver?

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: Problems with screen recording

Postby AlekseyK » 14 Dec 2010 19:02

Very strange: started to consume a 70-80% of one of CPU's cores under Windows too. What is wrong???!!!

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: Problems with screen recording

Postby AlekseyK » 14 Dec 2010 21:03

vlc screen:// --one-instance -I dummy --screen-follow-mouse --no-video :screen-fps=5 :screen-caching=300 --sout "#transcode{vcodec=h264,vb=400,fps=5,scale=1,width=1280,height=1024,acodec=none}:duplicate{dst=std{access=file,mux=avi,dst="/home/user/Work/TD_capture.avi"}}" --run-time=1200 vlc://quit
this is final and correct command line to record 20 minutes of screencast video and quit. CPU consumption on my machine (Athlon X2) less than 30%. Previous was not quit correct. Changes are bold.

AlekseyK
Blank Cone
Blank Cone
Posts: 10
Joined: 13 Dec 2010 16:26

Re: [RESOLVED] Problems with screen recording

Postby AlekseyK » 17 Dec 2010 04:57

Here the mouse pointer included, dummy interface DOS box suppressed.
"c:\Program Files\VideoLAN\VLC\vlc.exe" screen:// --one-instance -I dummy --dummy-quiet --screen-follow-mouse --screen-mouse-image="c:\Program Files\VideoLAN\VLC\mouse_pointer.png" --no-video :screen-fps=5 :screen-caching=300 --sout "#transcode{vcodec=h264,vb=400,fps=5,scale=1,width=1280,height=1024,acodec=none}:duplicate{dst=std{access=file,mux=avi,dst="e:\Documents\TD\TD_capture.avi"}}" --run-time=60 vlc://quit


Return to “VLC media player for Linux and friends Troubleshooting”

Who is online

Users browsing this forum: No registered users and 11 guests