Page 1 of 1

VLC Record from Webcam and Save to File - Windows Command Line

Posted: 28 May 2019 18:06
by ohanlon
Hello, I am trying to record a video from a camera and save the recording to a file, using the command line on Windows.
(My comprehension of the vlc documentation is poor at best, and I need some help figuring this out.)

I can get VLC up, displaying my camera, and recording using the command:

Code: Select all

vlc dshow:// :dshow-vdev="USB2.0 Camera"
I tried a number of variations of the command:

Code: Select all

vlc dshow:// :dshow-vdev="USB2.0 Camera" --sout "#std{mux=ts,access=file,C:\Users\username\Documents\video.avi}"
This results in VLC starting but unable to display my camera and no recording taking place. Additionally, no file is created. (I have tried multiple code paths, also.)

What am I doing wrong?
Thanks!

--
VLC version 3.0.6
Windows 10

Re: VLC Record from Webcam and Save to File - Windows Command Line

Posted: 29 May 2019 11:06
by mederi
Stream wizard can help you: Media > Stream...

Re: VLC Record from Webcam and Save to File - Windows Command Line

Posted: 31 May 2019 13:21
by Christoffel
I use this to record a live stream IP camera
--sout=#transcode{vcodec=h264}:std{access=file,dst='c:\aaa\temp.mp4'}

According to the Stream wizard this should record and display but it only record don't display
--sout=#transcode{vcodec=h264}:std{access=file,dst='c:\aaa\temp.mp4'} :display :sout-keep

Hope it helps

Re: VLC Record from Webcam and Save to File - Windows Command Line

Posted: 04 Jun 2019 16:24
by ohanlon
SOLVED

I got it working using:

Code: Select all

vlc dshow:// :dshow-vdev="USB2.0 Camera" --sout file/avi:test.avi --run-time=5

Re: VLC Record from Webcam and Save to File - Windows Command Line

Posted: 24 Jul 2019 22:04
by Nickolas1979
Stream wizard can help you: Media > Stream...