[copy of posting to comp.os.linux.misc]
References: <s7pfr301...@news1.newsguy.com> <atk9nh-fs1....@aretha.foo>
On 2021-05-17, Peter 'Shaggy' Haywood <phayw...@alphalink.com.au> wrote:
> mencoder tv:// -tv \
> driver=4vl2:input=1:norm=pal:width=720:height=576:fps=25 \
> -endpos 1:30:00 -ovc lavc -oac copy -lavcopts vcodec=mpeg4 \
> -o filename.avi
I finally found the time to do some more experimenting. The example
above is a good starting point. I found that I can watch VHS tapes
(or whatever else is plugged into the composite video input) on my
machine with the following command:
mplayer tv:// -tv driver=v4l2:input=1:norm=NTSC-M:width=720:height=480
Here's what gets written when I tee stdout:
MPlayer 1.3.0 (Debian), built with gcc-8 (C) 2000-2016 MPlayer Team
Playing tv://.
TV file format detected.
Selected driver: v4l2
name: Video 4 Linux 2 input
author: Martin Olschewski <olschew...@zpr.uni-koeln.de>
comment: first try, more to come ;-)
Selected device: pcHDTV HD5500 HDTV
Tuner cap: STEREO LANG1 LANG2
Tuner rxs: MONO
Capabilities: video capture VBI capture device tuner read/write
streaming
supported norms: 0 = NTSC-M; 1 = NTSC-M-JP; 2 = NTSC-443; 3 = PAL-BG;
4 = PAL-I; 5 = PAL-DK; 6 = PAL-M; 7 = PAL-N; 8 = PAL-Nc; 9 = PAL-60; 10
= SECAM-B; 11 = SECAM-G; 12 = SECAM-H; 13 = SECAM-DK; 14 = SECAM-L;
inputs: 0 = Television; 1 = Composite1; 2 = S-Video;
Current input: 1
Current format: UYVY
v4l2: current audio mode is : MONO
==========================================================================
Opening video decoder: [raw] RAW Uncompressed Video
Movie-Aspect is undefined - no prescaling applied.
VO: [vdpau] 720x480 => 720x480 Packed UYVY
Selected video codec: [rawuyvy] vfm: raw (RAW UYVY)
==========================================================================
Audio: no sound
Starting playback...
V: 0.0 1/ 1 ??% ??% ??,?% 0 0 [counts up]
v4l2: 137 frames successfully processed, 0 frames dropped.
Exiting... (Quit)
Note the "Audio: no sound" line. I still have to figure that one out
to get beyond silent movies. Any hints?
If I get the parameters wrong (which I did a lot while trying to get
the aspect ratio right), my screen and keyboard lock up. The machine
is still alive, though; I can ssh in from another machine and send
a kill -HUP to mplayer's PID, and it does an orderly shutdown and
releases everything.
Once I get sound working, the next step is to persuade mencoder
to write the video to a file. I tried adding the other parameters
you mentioned above, starting with -ovc, but I get the message:
Unable to open '/dev/dsp': No such file or directory.
It's really upset about this; the message appears three times.
And indeed, /dev/dsp doesn't exist. How do I get one?
--
/~\ Charlie Gibbs | They don't understand Microsoft
\ / <cgibbs@kltpzyxm.invalid> | has stolen their car and parked
X I'm really at ac.dekanfrus | a taxi in their driveway.
/ \ if you read it the right way. | -- Mayayana