(old) ZMV to AVI video conversion [[archive me]]
Moderator: ZSNES Mods
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
Welcome to page 4.
To record a video you need one of the latest work in progress builds of ZSNES. Get them here: http://zsnes.ipherswipsite.com/
You will need a copy of mencoder. For Windows users, I recommend getting mencoder here: http://oss.netfarm.it/mplayer-win32.php
Place mencoder.exe in the same location as zsnesw.exe, you do not need any codecs or other movie programs installed.
Linux users, having mencoder in your path is fine.
If you want to compress the outputted audio, or compress it before it goes into the video as opposed to during, you will need a copy of LAME.
If you use Windows, you must get LAME from here: http://geocities.com/joecool22us/lame.zip
Any other copy of LAME for Windows will not work due to a bug in LAME.
Before you are able to dump an AVI, you must have recorded a movie first, it converts movies, it does not just dump video on the fly.
To play back movies, you'll either need the proper codecs or a video player with built in decoding of the video mode you selected.
I recommend getting mplayer which decodes anything created with mencoder. For Windows, you can get mplayer here: http://oss.netfarm.it/mplayer-win32.php You can download the GUI version.
Advanced users can edit zmovie.cfg and tweak the settings if they want, and even use something other than mencoder and LAME as long as it supports encoding via stdin and you set it up properly.
________
I am pleased to announce that thanks to some help from Bisqwit and DeHackEd, I have added audio dumping to ZSNES!
Currently only works at Stereo 32KHz (if you want to make it work for other stuff, then please submit code).
The audio is also in a wav file as uncompressed PCM, so anything should be able to play it.
I also fixed up raw dumping in a couple of situations.
To record a video you need one of the latest work in progress builds of ZSNES. Get them here: http://zsnes.ipherswipsite.com/
You will need a copy of mencoder. For Windows users, I recommend getting mencoder here: http://oss.netfarm.it/mplayer-win32.php
Place mencoder.exe in the same location as zsnesw.exe, you do not need any codecs or other movie programs installed.
Linux users, having mencoder in your path is fine.
If you want to compress the outputted audio, or compress it before it goes into the video as opposed to during, you will need a copy of LAME.
If you use Windows, you must get LAME from here: http://geocities.com/joecool22us/lame.zip
Any other copy of LAME for Windows will not work due to a bug in LAME.
Before you are able to dump an AVI, you must have recorded a movie first, it converts movies, it does not just dump video on the fly.
To play back movies, you'll either need the proper codecs or a video player with built in decoding of the video mode you selected.
I recommend getting mplayer which decodes anything created with mencoder. For Windows, you can get mplayer here: http://oss.netfarm.it/mplayer-win32.php You can download the GUI version.
Advanced users can edit zmovie.cfg and tweak the settings if they want, and even use something other than mencoder and LAME as long as it supports encoding via stdin and you set it up properly.
________
I am pleased to announce that thanks to some help from Bisqwit and DeHackEd, I have added audio dumping to ZSNES!
Currently only works at Stereo 32KHz (if you want to make it work for other stuff, then please submit code).
The audio is also in a wav file as uncompressed PCM, so anything should be able to play it.
I also fixed up raw dumping in a couple of situations.
Last edited by Nach on Sat Mar 29, 2008 7:48 pm, edited 2 times in total.
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
-
- Seen it all
- Posts: 2302
- Joined: Mon Jan 03, 2005 5:04 pm
- Location: Germany
- Contact:
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
Behold:
http://nsrt.edgeemu.com/sfa2evid.rar
Requires x264 video codec.
Windows users can get x264 codec here http://x264.nl/
Although I recommend mplayer: http://www2.mplayerhq.hu/MPlayer/releases/win32/ or ftp://ftp5.mplayerhq.hu/mplayer/release ... 050928.zip
Code: Select all
./zsnes -mc -md -zm 0 /mnt/E/new/Euro/SFA2.smc & mencoder -demuxer rawvideo -rawvideo format=0x42475220:w=256:h=223:size=228352:fps=50 -mc 0 -oac copy -ovc x264 -x264encopts qp_constant=35 -o temp.avi ~/.zsnes/rawvideo.bin && mencoder -mc 0 -oac mp3lame -lameopts cbr:br=48 -ovc copy -o sfa2e.avi -audiofile ~/.zsnes/pcmaudio.wav temp.avi
Requires x264 video codec.
Windows users can get x264 codec here http://x264.nl/
Although I recommend mplayer: http://www2.mplayerhq.hu/MPlayer/releases/win32/ or ftp://ftp5.mplayerhq.hu/mplayer/release ... 050928.zip
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
Okay got an NTSC video together. 62.5 FPS... We'll see if we can bring that closer to 60.
http://nsrt.edgeemu.com/ssf2uvid.rar
http://nsrt.edgeemu.com/ssf2uvid.rar
Code: Select all
./zsnes -mc -md -zm 1 /mnt/D/roms/nintendo/snes/ssf2.fig & mencoder -demuxer rawvideo -rawvideo format=0x42475220:w=256:h=223:size=228352:fps=62.5 -mc 0 -oac copy -ovc x264 -x264encopts qp_constant=35 -o temp.avi ~/.zsnes/rawvideo.bin && mencoder -mc 0 -oac mp3lame -lameopts cbr:br=48 -ovc copy -o ssf2u.avi -audiofile ~/.zsnes/pcmaudio.wav temp.avi
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
Okay I redid the last video.
So 59.925093633 FPS recording. Anyone have an issue with this?
http://nsrt.edgeemu.com/ssf2vid2.rar
I also upped the quality on this vid so it looks quite good, what do you think?
Edit:
After reversing the exact ZSNES NTSC frame rate which is is 59.9487437186 and Bisqwit helping to create an algorithm to get sample generation perfect, we should have perfect NTSC videos now
I also upped the ratio to 256x224.
Here's what you need to encode now:
Maybe one of these days I'll figure out how to generate an AVI header so you don't need to specify the exact details yourself.
http://nsrt.edgeemu.com/ssf2good.rar
Code: Select all
./zsnes -mc -md -zm 1 /mnt/D/roms/nintendo/snes/ssf2.fig & mencoder -demuxer rawvideo -rawvideo format=0x42475220:w=256:h=223:size=228352:fps=59.925093633 -mc 0 -oac copy -ovc x264 -x264encopts qp_constant=25 -o temp.avi ~/.zsnes/rawvideo.bin && mencoder -mc 0 -oac mp3lame -lameopts cbr:br=48 -ovc copy -o ssf2u.avi -audiofile ~/.zsnes/pcmaudio.wav temp.avi
http://nsrt.edgeemu.com/ssf2vid2.rar
I also upped the quality on this vid so it looks quite good, what do you think?
Edit:
After reversing the exact ZSNES NTSC frame rate which is is 59.9487437186 and Bisqwit helping to create an algorithm to get sample generation perfect, we should have perfect NTSC videos now

I also upped the ratio to 256x224.
Here's what you need to encode now:
Code: Select all
./zsnes -mc -md -zm 1 /mnt/D/roms/nintendo/snes/ssf2.fig & mencoder -aspect 4/3 -demuxer rawvideo -rawvideo format=0x42475220:w=256:h=224:size=229376:fps=59.9487437186 -mc 0 -oac copy -ovc x264 -x264encopts qp_constant=25 -o temp.avi ~/.zsnes/rawvideo.bin && mencoder -mc 0 -oac mp3lame -lameopts cbr:preset=48 -ovc copy -o ssf2.avi -audiofile ~/.zsnes/pcmaudio.wav temp.avi
http://nsrt.edgeemu.com/ssf2good.rar
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
-
- Veteran
- Posts: 970
- Joined: Fri Jan 21, 2005 11:15 am
- Location: Montana, United States
Damn you and your mencoder skillz.Nach wrote: Here's what you need to encode now:Maybe one of these days I'll figure out how to generate an AVI header so you don't need to specify the exact details yourself.Code: Select all
./zsnes -mc -md -zm 1 /mnt/D/roms/nintendo/snes/ssf2.fig & mencoder -aspect 4/3 -demuxer rawvideo -rawvideo format=0x42475220:w=256:h=224:size=229376:fps=59.9487437186 -mc 0 -oac copy -ovc x264 -x264encopts qp_constant=25 -o temp.avi ~/.zsnes/rawvideo.bin && mencoder -mc 0 -oac mp3lame -lameopts cbr:preset=48 -ovc copy -o ssf2.avi -audiofile ~/.zsnes/pcmaudio.wav temp.avi
http://nsrt.edgeemu.com/ssf2good.rar
I have yet to really figure the damned thing out, and here in 1 line, you are capturing the output from zsnes, compressing the video, and audio streams, and then muxing them together in a final file.
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
And now ZSNES can use mencoder internally to make life easier! 
Make sure mencoder is in your path before using the new uncompressed AVI, ffv1, or x264.

Windows WIP:
http://nsrt.edgeemu.com/zsnesw-mov.zip
Get precompiled mencoder binaries for Windows here:
http://oss.netfarm.it/mplayer-win32.php
Place mencoder in your path when using.
The more adventurous can edit zmovie.cfg.
If you have trouble playing outputted movies, get codecs here:
http://www.free-codecs.com/download/K_L ... c_Pack.htm
Please let me know how it goes.

Make sure mencoder is in your path before using the new uncompressed AVI, ffv1, or x264.

Windows WIP:
http://nsrt.edgeemu.com/zsnesw-mov.zip
Get precompiled mencoder binaries for Windows here:
http://oss.netfarm.it/mplayer-win32.php
Place mencoder in your path when using.
The more adventurous can edit zmovie.cfg.
If you have trouble playing outputted movies, get codecs here:
http://www.free-codecs.com/download/K_L ... c_Pack.htm
Please let me know how it goes.
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
-
- ZSNES Developer
- Posts: 6747
- Joined: Tue Dec 28, 2004 6:47 am
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
Use one from the site I gave you. Download the one for your CPU.franpa_9 wrote:does it matter wich version of mencoder is used?
Anyone test this out yet?
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
http://web.aanet.com.au/Student_WebZone ... /video.avi
i tried x264 and uncompressed avi and uncompressed avi recorded better but i needed a codec to play the file.
the link is to a movie of mario bros 1 level 1 in the x264 format avi. (it works but has a slow frame rate)
is it possible to make it so mencoder doesnt steal focus away from zsnes while recording?
i tried x264 and uncompressed avi and uncompressed avi recorded better but i needed a codec to play the file.
the link is to a movie of mario bros 1 level 1 in the x264 format avi. (it works but has a slow frame rate)
is it possible to make it so mencoder doesnt steal focus away from zsnes while recording?
Core i7 920 @ 2.66GHZ | ASUS P6T Motherboard | 8GB DDR3 1600 RAM | Gigabyte Geforce 760 4GB | Windows 10 Pro x64
-
- ZSNES Developer
- Posts: 3904
- Joined: Tue Jul 27, 2004 10:54 pm
- Location: Solar powered park bench
- Contact:
Too many dropped frames. Set max frame skip to 0 before recording.franpa_9 wrote:http://web.aanet.com.au/Student_WebZone ... /video.avi
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
_____________
Insane Coding
http://web.aanet.com.au/Student_WebZone ... /video.avi
fixed the video... it now works properly and is 2.5mb approx. (thanks nach) now if only we could have sound at the same time. (without mergeing a sperate sound file into the movie manually)
fixed the video... it now works properly and is 2.5mb approx. (thanks nach) now if only we could have sound at the same time. (without mergeing a sperate sound file into the movie manually)
Core i7 920 @ 2.66GHZ | ASUS P6T Motherboard | 8GB DDR3 1600 RAM | Gigabyte Geforce 760 4GB | Windows 10 Pro x64
-
- Trooper
- Posts: 535
- Joined: Wed Jul 28, 2004 3:26 am