Page 1 of 1

NES Video Capture Advice

Posted: Sun Dec 25, 2016 4:47 pm
by Great Hierophant
I obtained a video capture stick for the holiday and wanted to capture footage from my NES.

The capture device in question is the I-O Data GV-USB2. The device's manual and software are in Japanese, but its drivers work fine with English Windows 10 64-bit and the driver settings are in English. I am using VirtuaDub 1.10.4 as the program to capture my video and audio. The capture is at 720x480 @ 29.97fps. The only settings I changed to the raw capture was to apply H.VEC 264 compression and adjust the hue to my palette preferences. This is the basic result :

https://youtu.be/rXaPJB_RU84

Of course, I cannot stand how capture devices interlace progressive content. I used Avisynth 2.5.8 with the following script :

avisource("gl.avi")
AssumeTFF() # Assume Top Field First
SeparateFields
Crop(45, 1, -33, -1)
bilinearresize(900,720).addborders(190,0,190,0)

Lines two and three deinterlace the signal by turning an interlaced fields into progressive frames. The fourth line cuts out the background colors on the sides and the last line resizes to a proper 1280x720 for Youtube.

I also used VirtuaDub's brightness/contrast filter to boost the contrast 30% to provide a real white instead of a light gray. The result is here :

https://youtu.be/iRIDNIaf3DI

So, is there any advice on how I can improve my captures (other than get an NESRGB mod or a better capture device) or is this about as good as you can get native NES composite output?

Re: NES Video Capture Advice

Posted: Sun Dec 25, 2016 5:39 pm
by Joe
Great Hierophant wrote:The only settings I changed to the raw capture was to apply H.VEC 264 compression
Did you configure it for lossless or interlaced compression? If you didn't do at least one of those, it'll hurt the video quality. (Personally, I'd use a dedicated lossless codec, but you may not have the disk space for that...)

Re: NES Video Capture Advice

Posted: Sun Dec 25, 2016 6:45 pm
by tokumaru
Joe wrote:
Great Hierophant wrote:The only settings I changed to the raw capture was to apply H.VEC 264 compression
Did you configure it for lossless or interlaced compression? If you didn't do at least one of those, it'll hurt the video quality. (Personally, I'd use a dedicated lossless codec, but you may not have the disk space for that...)
That's what I was gonna say... using a codec meant for distribution before processing the video could introduce some nasty artifacts. I don't think these USB capture devices output uncompressed video though, I'm under the impression that they always perform some sort of preliminary compression before sending the data to the computer. Whether this is the case or not, compressing the video before processing will never help. Personally, I'd try to keep the native format used by the capture device (if this is even an option) or go with a lossless codec.

Re: NES Video Capture Advice

Posted: Sun Dec 25, 2016 8:44 pm
by rainwarrior
You're doing the right thing by de-interlacing to 60fps. YouTube is a bit annoying with 60fps source material, since it doesn't blend frames for the lower quality versions and you get the "disappears when damaged" effect with a lot of games, but at least it supports 60fps for 720p/1080p now.

Lossless codecs don't tend to compress analog signal video like that very well at all, unfortunately. I tend to use Lagarith for emulator captures, but for analog captures, basically just try to use as good a quality as you find practical.

What I would suggest, though, is using nearest neighbour to resize in the vertical axis (if emualated, both axes). Do the nearest neighbour resize to an integer amount (e.g. 300%) and then if you still aren't at your target size, do a smaller linear/cubic/etc. resize as a final step. For analog, linear stretch is fine on the horizontal axis, IMO (there's not really "pixels" to preserve), but in the vertical you can definitely get some good definition from treating scanlines as discrete things.
tokumaru wrote:compressing the video before processing will never help.
As an aside, there is actually a useful case for this. If you keep the original source files, and make compressed and/or scaled-down versions of the same (but with the same framerate), you can use the smaller ones for editing (e.g. writing an AVIsynth script) and then switch back to the original source for the final rendering. In cases where editing is taking a significant amount of time it can really help a lot.

Re: NES Video Capture Advice

Posted: Sun Dec 25, 2016 11:46 pm
by Great Hierophant
My capture device captures to YUV2 without recompression. But the file sizes are huge compared to the H.VEC 264 pre-compression. A minute of video may be 50MB with H.264 and 1GB without.

Re: NES Video Capture Advice

Posted: Mon Dec 26, 2016 9:25 am
by calima
Can you pipe to gzip? That's what I did a while back, when a program could only output yuv. It compresses really well, and I could then pipe it to mencoder later.

Re: NES Video Capture Advice

Posted: Mon Dec 26, 2016 10:15 am
by tepples
If you're getting YUV, you can compress it losslessly using FFmpeg set to Huffyuv. This takes advantage of correlation between pixels, but I'm not entirely sure how well it compares to gzip.

Re: NES Video Capture Advice

Posted: Tue Feb 21, 2017 9:14 am
by DementedPurple
I can never get my Capture Stick to work with my Windows 10 PC. I get audio but no video. If I'm lucky I'll occasionally get green fuzz on the bottom of the screen. What capture card do you use? I use a TOTMC one. Will that have any affect on wether or not it works?