[ivtv-users] video "features" - how to remove?
tross.technical at starband.net
Fri Jan 22 08:26:30 CET 2010
Hello Andy, it's been 7 weeks since your response, and I've used that time
to acquire and test an HVR-1600 and PVR-150 in addition to the PVR-500, with
the same "noisy" results from my old analog VHS tapes, both on Linux and
It's curious that a USB capture device on the XP machine doesn't display the
same "noise" in the recorded file as do the Hauppauge cards. A
low-resolution comparison of the two different captures can be seen at
http://tony.ross.mystarband.net/videos/ivtv_noise.mpeg (~38 MB).
In the Hauppauge capture, notice the dark random bands immediately upon
exiting the aircraft, in freefall (behind the dmesg output) and especially
as my parachute opens (after the dmesg listing) -- apparently the result of
inertial tape flutter and air entering the camera housing. This kind of
noise isn't seen however on the television screen or in the USB-captured
output in the second half of the video, so apparently those two devices
share some kind of signal conditioning that the Hauppage card doesn't
perform by default.
The "features" around the edges can be dealt with, I've found, by cropping
the images. Of course v4l2-ctl can do that, but it suits my needs better to
use ffmpeg when producing the finished result after all editing is finished,
as the video comes from several different sources.
I'll start to investigate the register settings to see if that may help.
Again, thanks for your excellent work.
----- Original Message -----
From: "Andy Walls" <awalls at radix.net>
> On Tue, 2009-12-01 at 12:17 -0800, Tony Ross wrote:
>>>> What might be causing these features? Have I got a bad card?
>>> Not likely.
>>> Most likely your VCR is putting out crappy horizontal sync and/or
>>> vertical sync. Tweaking various registers in the CX2584x chip may have
>>> positive results for you- but it's not easy for the general user.
>> I've used 2 different VCR machines from different manufacturers with the
>> same results, and so am inclined to think the "syncs" are acceptable. I'm
>> using the PVR-500 to capture VHS tapes for transcription onto DVDs. From
>> VCR I have S-Video and audio to the PVR-500, and am using a composite
>> from the VCR to a regular television set. This allows me to compare the
>> mpeg2 stream with the ordinary tv in real-time, with only a slight delay
>> the computer.
> Some VCR's don't output all 9 sync pulses at vsync, but a few less.
> The CX25843 likely isn't set up for this by default. I do believe there
> is a VCR flag in one of the registers.
Thanks Andy, I'll start investigating the register settings to see if they
have any affect on the output.
> > The tv doesn't have the "features" that are observed in the mpeg2 that
> > results from the Hauppauge card. In addition, some sections of the VHS
> > are entirely visible on the tv while the mpeg2 stream from /dev/video0
> > remarkably distorted in both imagery and color, with wildly oscillating
> > diagonal black bands making the resultant mpeg2 file most undesirable.
> Hmmm. Herring bone patterns on a video signal are usually from FM
> interferers. Color distortion is caused by problems locking on to the
> color burst.
> You should probably try the +12 dB gain setting on the analog inputs of
> the CX25843. You'll have to find the one that corresponds to the
> composite in - look in ivtv-cards.c. The +12 dB gain setting may be in
> one of those registers that forces the autoconfig, which may make manual
> manipulation infeasible. :( (If that is the case, hack the CX25840
> driver instead.)
> > Looking at the tv shows the VHS tapes to be in great shape considering
> > age.
> Your TV is probably doing a lot of signal conditioning.
> > Looking at the mpeg2 files captured from the card leaves much to be
> > desired, as the image quality in the mpeg2 files is very badly affected,
> > sometimes adequate but often distorted in ways that the same tv image
> > doesn't show.
> The image quality probably belies the actual quality of the signal
> recorded on the tape. It's probably good you're trying to move them to
> > Here is some information:
> > $ v4l2-ctl -ISD
> > Driver info:
> > Driver name : ivtv
> > Card type : WinTV PVR 500 (unit #1)
> > Bus info : PCI:0000:04:08.0
> > Driver version: 66561
> > Capabilities : 0x01070051
> > Video Capture
> > VBI Capture
> > Sliced VBI Capture
> > Tuner
> > Audio
> > Radio
> > Read/Write
> > Video input : 1 (S-Video 1)
> > Video standard = 0x00001000
> > NTSC-M
> > I'm wondering if there is some "over-sampling" or some such thing in the
> > mpeg2 output from the card, which introduces noise into the image that
> > seen in the tv display, e.g. the "stream 0 codec frame rate differs from
> > container frame rate: 59.94 (60000/1001) -> 29.97 (30000/1001)" and the
> > warnings and errors in the following output:
> > $cat /dev/video0 > test.mpg # ... <Ctrl-C>
> > $ ffmpeg -i test.mpg -target ntsc-dvd -y test_new.mpg
> > ...
> > Seems stream 0 codec frame rate differs from container frame rate: 59.94
> > (60000/1001) -> 29.97 (30000/1001)
> > Input #0, mpeg, from 'test.mpg':
> > Duration: 00:00:14.92, start: 0.189200, bitrate: 6263 kb/s
> > Stream #0.0[0x1e0]: Video: mpeg2video, yuv420p, 720x480 [PAR 8:9 DAR
> > 4:3], 8000 kb/s, 29.97 tbr, 90k tbn, 59.94 tbc
> > Stream #0.1[0x1c0]: Audio: mp2, 48000 Hz, stereo, s16, 224 kb/s
> > Output #0, dvd, to 'test_new.mpg':
> > Stream #0.0: Video: mpeg2video, yuv420p, 720x480 [PAR 8:9 DAR 4:3],
> > q=2-31, 6000 kb/s, 90k tbn, 29.97 tbc
> > Stream #0.1: Audio: ac3, 48000 Hz, stereo, s16, 448 kb/s
> > Stream mapping:
> > Stream #0.0 -> #0.0
> > Stream #0.1 -> #0.1
> > Press [q] to stop encoding
> > [mpeg2video @ 0x95a17c0]ac-tex damaged at 10 25=14.40
> > [mpeg2video @ 0x95a17c0]Warning MVs not available
> > [mpeg2video @ 0x95a17c0]concealing 225 DC, 225 AC, 225 MV errors
> > frame= 626 fps= 10 q=17.9 Lsize= 16694kB time=14.59
> > video:15563kB audio:798kB global headers:0kB muxing overhead 2.037058%
> > ----------------------------
> > I'm really having a serious problem with the mpeg2 output of the
> > card and would be grateful for any help in solving the issue within a
> > environment.
> My personal opinion: if the content on the tapes is valuable to you, get
> a professional archiving service to make your DVD archives. It may be
> the case that the PVR's capture distortions belie that your tapes are in
> marginal condition.
> BTW, Have you tried this VCR signal with this capture card in a Windows
> ivtv-users mailing list
> ivtv-users at ivtvdriver.org
More information about the ivtv-users