(old) ZMV to AVI video conversion [[archive me]]

General area for talk about ZSNES. The best place to ask for related questions as well as troubleshooting.

Moderator: ZSNES Mods

Locked
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Re: Disabling Pause = Success

Post by Deathlike2 »

Welcome to page 16.

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.

________
AspiringSquire wrote:
Deathlike2 wrote:Ok, I found the issue... I think. Disable "Pause Emu in Background".
That fixed it! Thanks! 8)
There was an original fix to prevent desyncing.. but didn't test it before it was posted. It was the first thing to consider when you mention audio dumping went to hell.
I've noticed something else. With "Pause Emu In Background" disabled, when dumping with Custom, the audio playback is muted only during the first pass. This means there is unnecessary extra processing during subsequent passes, and it is noticeably slower.
I agree with that. Keeping the sound mute would have been nicer to speed up dumping until completion.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
AspiringSquire
Born to Rule... Impatiently
Posts: 265
Joined: Wed Nov 17, 2004 8:21 pm
Location: Everywhere I want to be.
Contact:

Post by AspiringSquire »

Another thing I've noticed is that after a movie dump is complete, returning to the GUI usually requires pressing Esc twice.
Deathlike2 wrote:There was an original fix to prevent desyncing.. but didn't test it before it was posted. It was the first thing to consider when you mention audio dumping went to hell.
This is horrendously ambiguous (too many "it"s). Would you mind rephrasing and/or elaborating?
Deathlike2 wrote:(compressed audio doesn't count, and the worst part is that using an MP3 to insert into the movie is worse than the default WAV file that is generated).
And what do you mean exactly by saying that WAV is better than MP3, in this case? Are you just referring to the overall sound quality, or what?
Nach wrote:I could get 99% of the SNES games down to 4MB/minute or less with perfect quality.
I'm interested in knowing what settings you would use to achieve "perfect quality" movie dumps in ZSNES with such small filesizes.
[url=http://board.zsnes.com/phpBB2/viewtopic.php?t=3298][color=brown]My [u]NES palette[/u][/color][/url] - better colors with any emulator.

"the more you know, and the more you can do... the more you are."
- [url=http://www.danielbohman.com][color=brown][u]daniel bohman[/u][/color][/url]
Toad22484
Rookie
Posts: 12
Joined: Thu Jan 27, 2005 6:33 am

Mencoder

Post by Toad22484 »

Sorry if I missed it anywhere because I glanced over most of the posts but I can NOT find mencoder anywhere :/. I've looked and for some odd reason can't find a working copy. The link on here says he disabled his downloads :(. Does anyone know where I could find it? MUCH thanks.
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

AspiringSquire wrote:Another thing I've noticed is that after a movie dump is complete, returning to the GUI usually requires pressing Esc twice.
Deathlike2 wrote:There was an original fix to prevent desyncing.. but didn't test it before it was posted. It was the first thing to consider when you mention audio dumping went to hell.
This is horrendously ambiguous (too many "it"s). Would you mind rephrasing and/or elaborating?
When the problem original was reported, there was fix made to address the desyncing that occured. However, I did not test it after that fix was implemented, thus what you are reporting now made a lot of sense to me as to where to look at the cause.
Deathlike2 wrote:(compressed audio doesn't count, and the worst part is that using an MP3 to insert into the movie is worse than the default WAV file that is generated).
And what do you mean exactly by saying that WAV is better than MP3, in this case? Are you just referring to the overall sound quality, or what?
If you use the compressed option, the movie becomes bigger vs the non-compressed option. Plus, MP3 is not loseless, so you may lose something in the process.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
AspiringSquire
Born to Rule... Impatiently
Posts: 265
Joined: Wed Nov 17, 2004 8:21 pm
Location: Everywhere I want to be.
Contact:

AVI dump always uses MP3

Post by AspiringSquire »

Deathlike2 wrote:If you use the compressed option, the movie becomes bigger vs the non-compressed option. Plus, MP3 is not loseless, so you may lose something in the process.
This is from the properties of a movie dumped with Custom + Compressed Audio (128Kbps via zmovie.cfg):
Audio: MPEG Audio Layer 3 32000Hz stereo 109Kbps

This is from the properties of a movie dumped with Custom + Uncompressed Audio:
Audio: MPEG Audio Layer 3 32000Hz stereo 110Kbps

The filesizes were nearly identical between these two dumps of the same ZMV. It seems clear to me that the resulting AVI uses compressed audio even if you don't select it; mencoder just converts to MP3 in LAME's stead. Notice also that there is always a discrepancy in bitrate of the audio between the used rate and the reported rate in the final AVI.
[url=http://board.zsnes.com/phpBB2/viewtopic.php?t=3298][color=brown]My [u]NES palette[/u][/color][/url] - better colors with any emulator.

"the more you know, and the more you can do... the more you are."
- [url=http://www.danielbohman.com][color=brown][u]daniel bohman[/u][/color][/url]
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

Hm, I don't think Custom used compressed unless selected. You probably want to do tests against the non-Custom options, and you will see what I mean.

Edit: When the compressed audio is checked, the properties of the file is supposed to show the Sample Rate was @ 24KHz instead of 32KHz.

You may want to delete zmovie.cfg and use a fresh one for good measure. I had no issues dumping with and w/o compressed audio. The file properties confirm this.

Additional Edit:

Here's some info based on a dump I made of the movie you provided:
7,737,324 bytes with Compressed Audio @ 24KHz
7,712,940 bytes w/o Compressed Audio @ 32KHz

It's probably not as significant, but bleh. I'd rather have the latter anyways.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
Nach
ZSNES Developer
ZSNES Developer
Posts: 3904
Joined: Tue Jul 27, 2004 10:54 pm
Location: Solar powered park bench
Contact:

Post by Nach »

AspiringSquire wrote:
Nach wrote:I could get 99% of the SNES games down to 4MB/minute or less with perfect quality.
I'm interested in knowing what settings you would use to achieve "perfect quality" movie dumps in ZSNES with such small filesizes.
It would be specific for each game. Look through the mencoder manual and see what you can pass -x264encopts. Most SNES games compress very well to <=4MB/min with the right options.
Even with the non optimal options, you should be able to get flawless with x264 not much higher than that. Therefor I say people making SNES videos at 20MB/s simply don't know what they're doing and should learn to use better encoders and options with them. Heck you can even see people distributing 2 hour videos in much higher resolutions online where a near flawless DVD rip is about 5MB/min.
Toad22484 wrote:Sorry if I missed it anywhere because I glanced over most of the posts but I can NOT find mencoder anywhere :/. I've looked and for some odd reason can't find a working copy. The link on here says he disabled his downloads :(. Does anyone know where I could find it? MUCH thanks.
Yes he says he disabled his downloads (temporarily) and linked to where you can download, follow the links.
AspiringSquire wrote:
Deathlike2 wrote:If you use the compressed option, the movie becomes bigger vs the non-compressed option. Plus, MP3 is not loseless, so you may lose something in the process.
This is from the properties of a movie dumped with Custom + Compressed Audio (128Kbps via zmovie.cfg):
Audio: MPEG Audio Layer 3 32000Hz stereo 109Kbps

This is from the properties of a movie dumped with Custom + Uncompressed Audio:
Audio: MPEG Audio Layer 3 32000Hz stereo 110Kbps

The filesizes were nearly identical between these two dumps of the same ZMV. It seems clear to me that the resulting AVI uses compressed audio even if you don't select it; mencoder just converts to MP3 in LAME's stead. Notice also that there is always a discrepancy in bitrate of the audio between the used rate and the reported rate in the final AVI.
When audio goes into the AVI, it is compressed regardless. As stated in the docs, the compressed audio has it compressed while dumping it. Meaning if you're only dumping audio, it'll be smaller and in MP3 as opposed to raw WAV PCM. If you're dumping audio with intent to merge into AVI, then you'll need less HD space free for the process then without, but either way it's compressed in the AVI in the end.

As far as quality and size goes, LAME and MEncoder are being passed the exact same MP3 encoding settings. However while they should function the same, Deathlike notices that MEncoder's MP3 encoding seems to compress and sound a bit better.
However which is actually better depends on which version of LAME and MEncoder you're using, and which settings passed to it.
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
Firon
Trooper
Posts: 361
Joined: Fri May 05, 2006 4:37 pm
Contact:

Post by Firon »

If you're going to encode with LAME, you should use VBR. -V5 --vbr-new should do alright. Maybe use -V4 --vbr-new if you want a slightly higher quality encode.

Oh, and just fyi, Mencoder/ffmpeg uses LAME (built-in) for encoding. So you're really still using LAME, just different versions.
Last edited by Firon on Wed Jan 31, 2007 11:59 pm, edited 3 times in total.
Nach
ZSNES Developer
ZSNES Developer
Posts: 3904
Joined: Tue Jul 27, 2004 10:54 pm
Location: Solar powered park bench
Contact:

Post by Nach »

If you're going to use the compressed audio function, I'm going to advise you to not use a broken LAME build like Firon is linking to.
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
Firon
Trooper
Posts: 361
Joined: Fri May 05, 2006 4:37 pm
Contact:

Post by Firon »

Oh right, I forgot about the whole stdin issue... Edited the link out of my post. Is yours built off LAME 3.97 final?
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

It has been said already before. Yes.
Nach on 10/15/06 in this very thread wrote:LAME team has ignored my patch. I cleaned up my patch and resubmitted it again: http://sourceforge.net/tracker/index.ph ... tid=300290

Here's a windows binary of 3.97 with my patch applied:
http://nsrt.edgeemu.com/lame.zip
Edit: I've updated the FAQ movie dumping question with the version # of LAME the build is using.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Re: Mencoder

Post by Deathlike2 »

Toad22484 wrote:Sorry if I missed it anywhere because I glanced over most of the posts but I can NOT find mencoder anywhere :/. I've looked and for some odd reason can't find a working copy. The link on here says he disabled his downloads :(. Does anyone know where I could find it? MUCH thanks.
It's back up now.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
Sepher
New Member
Posts: 5
Joined: Sun Feb 18, 2007 5:02 am
Location: Michigan

Post by Sepher »

Hey! Um..I'm new here..but not to ZSNES. I've played it for a long time, loved it, done everything..but recently wanted to make movies. Now all this stuff, just completely over my head. But I think I did ok... I have mencoder, Mplayer, ffdshow, x264, lame(patched) and one of the latest ZSNES posted here.

Now it dumps the video and everything, goes through it, then stops and resumes playing from there, and LAME starts up and I see mencoder start then stop at the beginning. While LAME and the movie is running, an .AVI video file is made and is 0 KB and an audio file is made. After the video stops playing, the files disappear. I'm kinda confused....Any help?
[color=blue]Sepher[/color]
[img]http://i15.photobucket.com/albums/a352/Alkaizer/theflare_img-1.jpg[/img]
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

Sepher wrote:Hey! Um..I'm new here..but not to ZSNES. I've played it for a long time, loved it, done everything..but recently wanted to make movies. Now all this stuff, just completely over my head. But I think I did ok... I have mencoder, Mplayer, ffdshow, x264, lame(patched) and one of the latest ZSNES posted here.

Now it dumps the video and everything, goes through it, then stops and resumes playing from there, and LAME starts up and I see mencoder start then stop at the beginning. While LAME and the movie is running, an .AVI video file is made and is 0 KB and an audio file is made. After the video stops playing, the files disappear. I'm kinda confused....Any help?
Read this: http://board.zsnes.com/phpBB2/viewtopic.php?t=9207

Most likely, you did not obtain the SVN build of mencoder.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
Sepher
New Member
Posts: 5
Joined: Sun Feb 18, 2007 5:02 am
Location: Michigan

Post by Sepher »

I got the SVN. The Feb. 15, 2007 one of Mencoder and MPlayer. Does it matter which one I downloaded? It has 3, but I chose the top of each one (the precompiled binaries)or am I suppossed to get the Dec 19 2006 SVN patch instead? If so where do I configure that in?

I am completely new when it comes to these things, I just learned everything I know today from this topic, so sorry if I am rather undetailed. I have the pathways set, I have the Lame (wait, I listed them all up there in my other post). I have all the tools I need pathwayed into the ZSNES path. I also have each of them in the ZSNES folder, just in case. Will this hurt me?
[color=blue]Sepher[/color]
[img]http://i15.photobucket.com/albums/a352/Alkaizer/theflare_img-1.jpg[/img]
franpa
Gecko snack
Posts: 2374
Joined: Sun Aug 21, 2005 11:06 am
Location: Australia, QLD
Contact:

Post by franpa »

whats your processor?
Core i7 920 @ 2.66GHZ | ASUS P6T Motherboard | 8GB DDR3 1600 RAM | Gigabyte Geforce 760 4GB | Windows 10 Pro x64
Sepher
New Member
Posts: 5
Joined: Sun Feb 18, 2007 5:02 am
Location: Michigan

Post by Sepher »

Processor? (I am a computer RETARD lol) Buuut, from whats on the tower..I can tell you something..lol, sorry ^^

I run XP, I have made no adjustments to the computer. It is just as I got it from dell.

A Dimension 2400, Intel Celeron.

EDIT: Muahahaha, thank you google. Takes a little initiative..my processor is...
2.40 gigahertz Intel Celeron
8 kilobyte primary memory cache
128 kilobyte secondary memory cache
[color=blue]Sepher[/color]
[img]http://i15.photobucket.com/albums/a352/Alkaizer/theflare_img-1.jpg[/img]
Nach
ZSNES Developer
ZSNES Developer
Posts: 3904
Joined: Tue Jul 27, 2004 10:54 pm
Location: Solar powered park bench
Contact:

Post by Nach »

Sepher wrote:I got the SVN. The Feb. 15, 2007 one of Mencoder and MPlayer. Does it matter which one I downloaded? It has 3, but I chose the top of each one (the precompiled binaries)or am I suppossed to get the Dec 19 2006 SVN patch instead? If so where do I configure that in?
The first one listed is for an Athlon processor. You don't have an Athlon, you have a P4.
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
Sepher
New Member
Posts: 5
Joined: Sun Feb 18, 2007 5:02 am
Location: Michigan

Post by Sepher »

:oops: Hehe, guess so. The more you ask the more you know..cause knowledge is power!


Thank you Nach, and everyone..and sorry for the time you used :oops:

I'll go try it out now.

EDIT: Well, I can make the movie now (THANK YOU GUYS SO MUCH) but I am missing the codecs in order to actually watch it, but the audio is fine. Where can I get the codecs(I saw a link earlier, a reattachment would be nice, if not, then I will find it) but also, what would I do with the codecs?
[color=blue]Sepher[/color]
[img]http://i15.photobucket.com/albums/a352/Alkaizer/theflare_img-1.jpg[/img]
franpa
Gecko snack
Posts: 2374
Joined: Sun Aug 21, 2005 11:06 am
Location: Australia, QLD
Contact:

Post by franpa »

http://www.codecguide.com/

but theres more then this.
Core i7 920 @ 2.66GHZ | ASUS P6T Motherboard | 8GB DDR3 1600 RAM | Gigabyte Geforce 760 4GB | Windows 10 Pro x64
Sepher
New Member
Posts: 5
Joined: Sun Feb 18, 2007 5:02 am
Location: Michigan

Post by Sepher »

Thanks for everything. Is there a way to compress the actual size of the video so you can post it on sites? (i.e. youtube)
[color=blue]Sepher[/color]
[img]http://i15.photobucket.com/albums/a352/Alkaizer/theflare_img-1.jpg[/img]
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

Not really, since the default options are ideal for quality.

On the other hand, you could try the Custom option which allows for multi-passes. The IQ of the movie drops down a bit depending on the game, but creates much nicer filesizes. Edit zmovie.cfg to tweak the # of passes.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
Esrhan
New Member
Posts: 5
Joined: Thu Feb 22, 2007 9:18 pm

Post by Esrhan »

A little help would be appreciated. Before I ask, I would like to mention that I am in no way new to video and audio recording, encoding and editing. I have been editing various video sources for several years now.

Anyway, I have managed to read thru this topic and find a way to use a larger, proper resolution for the processed video file. The default recording scale was hardly satisfying for my needs, so thanks on that part.

What I need to know now, if there is someway to output a high quality video file? At the moment THIS is the footage quality I get out of any encode done with ZSnes. Is there a way to apply ZSnes' own HQ Filter x4 or any other filer to the produced video file? I was unable to find any references to enabling these filters in conjuction with the produced .zmv.

While recording and playing the .zmv I can see the HQ filter on the screen, but it is not actually used in the produced video file.

I can of course post-process the .avi file with avisynth filtering, but I find the HQ filter to be rather perfect for the job.
Last edited by Esrhan on Sun Feb 25, 2007 6:17 pm, edited 1 time in total.
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

Esrhan wrote:A little help would appreciated. Before I ask away, I would like to mention that I am in no way new to video and audio recording, encoding and editing. I have been editing various video sources for several years now.

Anyway, I have managed to read thru this topic and find a way to use a larger, proper resolution for the processed video file. The default recording scale was hardly satisfying for my needs.

What I need to know, is there someway to output a high quality video file? At the moment THIS is the footage quality I get out of any encode done with ZSnes. I ask is there a way to apply ZSnes' own HQ Filter to the video file? I was unable to find any references to enabling these filters in conjuction with the produced .zmv. When recording and playing it I can see the HQ filter on the screen, but it is not actually used in the encode.

I can of course post-process the .avi file with avisynth filtering, but I find the HQ filter to be rather perfect for the job.
Adding filters+increasing screen res increases the file size. Not only that, the requirements for playing it back increase exponentially to the point of unplayability.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
Esrhan
New Member
Posts: 5
Joined: Thu Feb 22, 2007 9:18 pm

Post by Esrhan »

Deathlike2 wrote:Adding filters+increasing screen res increases the file size. Not only that, the requirements for playing it back increase exponentially to the point of unplayability.
That is quite obvious but like I mentioned I am not new at this field. File size is irrelevant and my computer is more than adequate to handle what I desire. Of course I intend to edit the lossless video file with Adobe Premiere Pro and re-encode it to a more friendly-user format afterwards. But yes, the lossless, filtered .avi will be quite heavy dutieish.

I ask again is such an option available?
Locked