View Full Version : Encoding to 2g size with AC3 audio...looking for clean video quaity
chaingunwilly2
29th June 2003, 17:25
:) Hello! Thanks for running such a great site!
I have a couple questions about the methods being used by most
people...i'm a purist. I want to encode my video so that it resembles the original dvd as much as possible. 720x480, ac3 audio stream, probably a final size around 2gig. I'm feeling flexable with regards to the black borders atm. :)
I'm having a problem getting this however and have spent the past month trying different methods, and now am asking those who might me more experienced than I.
The most successful video encode I've had was using VirtualDubMod...couple of drawbacks here: it didn't auto-group the vob's so each movie took some 3-8 jobs I had to set up (2 pass divx 5) individually, join the individual files (beautiful job it did), and add the ac3 stream afterwards. I've failed miserable at getting the ac3 stream to sync up however and so am stuck there. I mean really and truly.
Gordian Knot: fantastic tool for encoding and getting the ac3 stream
just right. HOWEVER, it seems nearly impossible to encode a dvd at
720x480. Knot seems to insist on changing the size, and so I'm stuck THERE. Aside from that the quality isn't as good as using VDM at Full Processing, or so it seems.
:/
Is there any wisdom you can impart? I'm really stuck here I think.
With Regards,
William
killingspree
29th June 2003, 18:12
hi and welcome to the forum :)
here's a few thoughts on the above written:
The most successful video encode I've had was using VirtualDubMod...couple of drawbacks here: it didn't auto-group the vob's so each movie took some 3-8 jobs I had to set up (2 pass divx 5) individually, join the individual files (beautiful job it did), and add the ac3 stream afterwards. I've failed miserable at getting the ac3 stream to sync up however and so am stuck there. I mean really and truly.
actually the way to go here is avisynth (: just create a DVD2AVI project, load it into avisynth with mpeg2dec3 etc. this is basically what gknot does. this way you do not have to process the vob files seperately. with the method you used i think it is close to impossible to get sync audio!
anyway, if you do not like the way gknot crops and resizes, you can manually edit your avs script befor encoding! after hitting save & encode on the preview window. hit the edit button on the bottom of the window and the avs script will be displayed. if you want to just crop and retain the original size, just delete the resizing line (anything below #Resize (: if you don't want to crop either (which i assume that you as a purist won't want as it is a waste of bitrate) you can also delete the #Crop lines. btw instead of deleting you can simply put a '#' infront of a line which will disguise it to the program as a comment. what you have to be careful about though is that you have to retain specific multiple pixle aspect ratios. in other words iirc for divx 5.0x you have to have a hight and width divisable through 16)
after you've done the changes just save the avs and either do the encoding directly in gknot or you can also go back to VDubmod and do the encoding manually there. anyway it wouldn't make much sense since gknot is also using vdubmod (if you are using a recent version! .28.x)
about quality issue: if you really used the exact same parameters the quality should be exactly the same. it depends on many factors like resizer etc though! and there shouldn't be a quality difference between fast recompress and full processing either!
hope this helps
steVe
manono
29th June 2003, 18:20
Hi and welcome to the forum-
You're running around with a lot of wrong headed notions, but I'll try and set you straight on one of them.
HOWEVER, it seems nearly impossible to encode a dvd at 720x480.
Just set the Input Pixel Aspect Ratio to 1:1, change the W-Modul to 16, and move the slider to 720x480. Either that or edit the .avs to knock out the crop and resize lines. I have a question though. Have you played any of your 720x480 encodes? And have you noticed that things are stretched, that is, not in proper Aspect Ratio? I'll assume that you don't know about resizing with your player yet. And did you consider that there might be a reason that GKnot has you fill in either 16:9 or 4:3 and then has you crop and resize?
Aside from that the quality isn't as good as using VDM at Full Processing
If you do it right, it's better (and faster). And GKnot does use VDM for encoding, but in Fast Recompress. I hope I don't come off as sounding too harsh (just a little bit harsh is OK :)), but you really have to do more reading on this site. It's all explained. Maybe some others will help with some of the other misconceptions. Either that or I'll be back after you've digested what's already been written.
Edit: killingspree beat me to it. :) Hi Steve.
killingspree
29th June 2003, 18:27
Originally posted by manono
Edit: killingspree beat me to it. :) Hi Steve.
hehe... hi :D
chaingunwilly2
29th June 2003, 19:13
Harsh? Not any more than I would have been to a newb in my own zone. :P
I appreciate the help, no matter what the tone sounds like. :)
I'll take a look at using GK with the 720x480 edit, and yes I noticed I've been battling aspect errors. It'd fix that if I kept my black bars yes? I've always liked the tool but was also a little disappointed in my ability to use it well. The video always comes out just a little grainy or with fastmotion blurring.
I've considered resizing both in the player as well as in GK, but I don't like being forced to. I always though the option to not resize should be obvious in the GUI. After all, I input movie A in a specific size and quality level, I'd like to get as high a quality level as possible without changine anything on the encode.
As you may have guessed, at 2g file size I don't care about fitting these on cd's. I'm a Quality man. I want ac3 sound and a crisp clean image at a reasonable size. If you think I'm on the wrong path for that goal, please, feel free to slap me around more and redirect me.
The purpose is to take my favorite collection and move them to my computer server, which is the center of my house.
Again, Thanks for the attention,
~Will
chaingunwilly2
29th June 2003, 19:15
I'd also like to be GOOD at this damn process. :P
I get the how, but some of the why's are escaping me. :)
~W
killingspree
29th June 2003, 19:36
hi again,
" I've considered resizing both in the player as well as in GK, but I don't like being forced to. I always though the option to not resize should be obvious in the GUI. After all, I input movie A in a specific size and quality level"
well actually i'd say 99% of the people around here do ALWAYS resize! usually people go for 1 or 2 cds maybe 2x mp3 or 1x ac3 and therefor mostly go for a widht of around 500 and the appropriate hight. of course it always depends on the movie what size is exactly chosen!
"I'd like to get as high a quality level as possible without changine anything on the encode."
hmm... best quality?! go make a d2v project file from your vobs, make a simple avisynth script containing:
loadplugin("X:\yourplugindir\mpeg2dec3.dll")
mpeg2source("X:\yourd2vdir\yourfile.d2v")
just copy and paste it into a text file, rename it to *.avs and load it into vdubmod! then encode single pass quant 2 and you'll have the best quality possible! you might get sizes over 2 gigs with this though!
steVe
chaingunwilly2
29th June 2003, 20:35
Whoa. That's a lot of people resizing. :/
WHY? It is just a matter of making it small enough to fit on one cd?
What I'm trying to do is make a Digital Master at Divx 5.x with as little loss as is possible with a pure Ac3 audio stream. Size IS a factor, but negotiable. I WAS aiming for about 2.1g per.
Thanks for assisting AND helping me to understand. I HAVE been reading from the forums too. HONEST. With 99% of people doing what I'm trying NOT to do, you can understand my confusion.
I'll try this stuff out tonight.
~W
KpeX
29th June 2003, 22:18
Resizing in and of itself will not change the size of the video, but increases the amount of data per frame, making low bitrates look better. And yes, the majority of encoders are shooting for 1-2 cd size encodes. A very helpful document for you to read might be Doom9's aspect ratios explained. (http://www.doom9.org/aspectratios.htm) Hopefully that along with some of the GKnot/DivX guides will clear up the 720x480 confusion. Good luck and read up.
btw, imo it's better to learn why rather than blindly follow. I think many of us here, myself included, were once at a similar point where it seems like everyone else is encoding in a different manner that we thought "correct".
jggimi
29th June 2003, 22:46
Why resize? Well, pixels on your PC monitor are SQUARE. Your 4:3 monitor will have a resolution of 800:600, 1024:768, 640:480 ... and these are all 4:3 with SQUARE pixels. 4:3 is also the same as 1.33:1.
Your DVD, however, does not have square pixels. NTSC DVDs are all 720x480 (1.5:1), PAL DVDs are all 720x576 (1.25:1).
DVD's also come with a Display Aspect Ratio (DAR). This is either 4:3 (1.33:1) or 16:9 (1.85:1), which are the two aspect ratios that are possible with TVs. This DAR will be one of these two values, regardless of the aspect ratio of the original content. The video stream will contain letterboxing to restore the original aspect ratio at the proper DAR.
-----
Summary: If you do not resize DVD video when reencoding for PCs, you will need a player that can playback with 16:9 or 4:3, such as BSPlayer.
----
For maximum quality, I recommend a single pass at 100% quality, with B-frames turned off. You can use the .avs script produced by Gknot (or the examples given earlier) and run a single pass with VdubMod on your own, and manually mux the audio as well.
chaingunwilly2
3rd July 2003, 20:21
first, I'd like to thank EVERYone who touch the keyboard to help me sort all this out. I'd like to report I'm MUCH closer to the copies I need.
I've been able to create the correct aspect ratios using GK (latest version) and it muxes the ac3 stream perfectly. However. Using Div 5.05 pro (2pass) through GK on a 1.8g final file size is causing extreme motion sensitivity. People just walking across a room are blurred or have what looks to be interlaced lines.
It's distressing to me particularly in that I get a completely different (perfect) encode using Vdubmod straight up. What am I missing here?
Let me intercept this one first off : "Hey Will, if you're so damn good at Vdubmod why arn't you using it instead of GK??"
Answer: "Because I havn't been able to mux the ac3 stream to the newly encoded video correctly. As in, you'd have to be on drugs to watch this movie with that audio, and I can't seem to rectify it. Also, I can't get Vdubmod to detect that split vob files are all from the same movie and so do them all together. Bah."
Thanks all,
Will
killingspree
3rd July 2003, 22:29
:logfile:
:)
steVe
chaingunwilly2
3rd July 2003, 22:38
the gk log? here it is...
7/3/2003 2:25:47 PM: Job "Movie 1" started.
o DivX5-First Pass: H:\MovieLAB\WingCommander\1.avs
o DivX5 - Pass 2: H:\MovieLAB\WingCommander\1.avs
o Mux Audio.
End of Job 1 (Movie 1).
_______________________________________________________________________________________________________________________
Gordian Knot 0.2.8.1473
Encoding Job Data:
Type: EncD5_Both
Number: 1
Name: Movie 1
Platform: Win2000 (5.0.2195).2
Files:
VirtualDubModExe: C:\PROGRA~1\GORDIA~1\VirtualDubMod\VirtualDubMod.exe
NandubExe: C:\PROGRA~1\GORDIA~1\nandub\Nandub.exe
AviFinal: H:\MovieLAB\WingCommander\1_1.avi
AviMovie: H:\MovieLAB\WingCommander\1_1_Movie.avi
AviCredits: H:\MovieLAB\WingCommander\1_1_Credits.avi
MovieFS: H:\MovieLAB\WingCommander\1.avs
CreditsFS: H:\MovieLAB\WingCommander\1_Credits.avs
Log : H:\MovieLAB\WingCommander\1_1.log
Stats: H:\MovieLAB\WingCommander\1_1.stats
Ecf : H:\MovieLAB\WingCommander\1_1.ecf
Options:
Quality/DRF: 0
CreditsStart: 159305
UseEcf: 1
CreditsIVTC: 0
CreditsAppend: 0
DeleteInterm.: 0
EnforceBitrate:0
AntiShit: 0
Calculator:
VideoSize: 1813120 kbyte.
Audio1Size: 328786 kbyte.
Audio2Size: 0 kbyte.
Overhead: 8492 kbyte.
AviSize: 2150400 kbyte (2100 mbyte).
FilesSize: 0 kbyte.
TotalSize: 2150400 kbyte (2100 mbyte).
Interleaving: 1stream
Bitrate: 2471 k(=1000)Bits/s
Frames: 180182
FPS: 29.970
Duration: 1:40:12
Quality: 0.239 bits/(pixel*frame).
CompCheck3: 0.000 bits/(pixel*frame).
CompCheck5: 0.196 bits/(pixel*frame).
Resolution: 720 x 480
Audio 1:
mode: Just Mux Source File.
sourceFile: H:\MovieLAB\WingCommander\1 AC3 T02 3_2ch 448Kbps DELAY 27ms.ac3
wavFile: H:\MovieLAB\WingCommander\1 AC3 T02 3_2ch 448Kbps DELAY 27ms.wav
mp3File: H:\MovieLAB\WingCommander\1 AC3 T02 3_2ch 448Kbps DELAY 27ms.mp3
azid: ""
lame: ""
delay: 27
interval: 2
preload: 500
mux: 1
recalc: 1
deleteWav: 1
Audio 2:
none.
2:25:47 PM: Audio 1, determined: 328786 kb
2:25:47 PM: Audio 1, calc: 328786 kb
2:25:47 PM: New Bitrate for Movie = 2471 k(=1000)Bits/s
Adding this script to C:\PROGRA~1\GORDIA~1\VirtualDubMod\LastJob.vcf:
// $job "DivX5 First Pass"
// $input "H:\MovieLAB\WingCommander\1.avs"
// $output "H:\MovieLAB\WingCommander\1_1_Movie.avi"
// $state 0
// $start_time 0 0
// $end_time 0 0
// $script
VirtualDub.Open("H:\\MovieLAB\\WingCommander\\1.avs",0,0);
VirtualDub.audio.SetSource(0);
VirtualDub.audio.SetMode(0);
VirtualDub.audio.SetInterleave(1,0,0,0,0);
VirtualDub.audio.SetClipMode(1,1);
VirtualDub.audio.SetConversion(0,0,0,0,0);
VirtualDub.audio.SetVolume();
VirtualDub.audio.SetCompression();
VirtualDub.audio2.SetSource(0);
VirtualDub.audio2.SetMode(0);
VirtualDub.audio2.SetInterleave(1,0,0,0,0);
VirtualDub.audio2.SetClipMode(1,1);
VirtualDub.audio2.SetConversion(0,0,0,0,0);
VirtualDub.audio2.SetVolume();
VirtualDub.audio2.SetCompression();
VirtualDub.video.SetDepth(24,24);
VirtualDub.video.SetMode(1);
VirtualDub.video.SetFrameRate(0,1);
VirtualDub.video.SetIVTC(0,0,-1,0);
VirtualDub.video.SetRange(0,0);
VirtualDub.video.SetCompression(0x78766964,0,10000,0);
VirtualDub.video.filters.Clear();
VirtualDub.subset.Delete();
VirtualDub.SaveAVI("H:\\MovieLAB\\WingCommander\\1_1_Movie.avi");
VirtualDub.Close();
// $endjob
//
chaingunwilly2
3rd July 2003, 23:02
As a side note, when I mux my ac3 stream into my vdub-only encoded video stream..it's WAY off. as in 16 minute position audio is playing in the 22 minute position video.
~W
manono
4th July 2003, 08:10
Hi-
FPS: 29.970
That's from your log file. This is the frame rate of your final .avi? If so, then that explains why it's blurry and/or interlaced. You have to either use Force Film in DVD2AVI or IVTC in the .avs before encoding. Which you use is determined by the percentage of Film that DVD2AVI shows. Wing Commander started life as a 24fps film. The function of Force Film or IVTC is to return it to 24fps (23.976fps actually) by removing the extra fields that were added to make it comply with the NTSC 29.97fps DVD spec.
And you say that GKnot muxes your AC3 audio properly, but you can't seem to do it right yourself? Try this. Take the completed video (even the one with the screwed up audio), and open it in Nandub. Set Video to Direct Stream Copy. Then go Audio-Interleaving and set Preload and Interleaving both to 96 ms, and set the delay for whatever it says in the name of the AC3 track. Then go back to File-Save As, and give it a different name (if the original is Wing Commander.avi, then this is Wing Commander2.avi). You can't use the default audio settings (which are fine for MP3) when muxing AC3.
chaingunwilly2
4th July 2003, 16:31
I know about ForceFilm and it's function sure, but HOW did you know WingCommander has a problem with framerate? 24fps? Where are you getting that out of the logfile?
When I open the vob's in Vdubmod they report they're 29.9 fps.
~Will
manono
4th July 2003, 23:51
Hi-
HOW did you know WingCommander has a problem with framerate?
Wing Commander doesn't have a problem with framerate. You have a problem with its framerate (if, indeed, you kept it at 29.97fps). That's why people just walking across a room are blurred or have what looks to be interlaced lines. You have to either Force Film or IVTC to return it to 23.976fps, depending on what DVD2AVI tells you.
When I open the vob's in Vdubmod they report they're 29.9 fps.
All NTSC DVDs are at 29.97fps. When played on a standard interlaced TV set, you can't tell that they've added in extra fields to bring it from 23.976 to 29.97fps. All standard NTSC TV sets display at 59.94 fields per second. Movies can ordinarily be returned back to 23.976fps, whereas true interlaced material is kept at 29.97fps after deinterlacing. In order to get it to play smoothly and to improve the quality, it's your job to get the movies back to 23.976fps. Please read This Tutorial (http://www.doom9.org/ivtc-tut.htm) in order to get a better understanding of what's going on. Robshot's Article (http://www.doom9.org/synch.htm) is also a pretty good one to read. You should have already read these articles, as well as many of the others on this site. And the IVTC tutorial has a number of good links at the bottom.
I should say that I've never encoded Wing Commander. But if it's like almost every other movie out there, then it has to be returned to 23.976fps. Aren't you the same fellow that wanted to encode his DVDs at top quality? Sorry, but I couldn't resist.
chaingunwilly2
5th July 2003, 22:06
Top Quality? If you're referring to another post, nope. This is my only thread ever.
I AM trying to make 'exact' masters of my DVD's in divx5 though, which is what this is all about. :)
Thanks for the links. I hadn't seen those. I'll read them and see if their content makes the difference.
~Chaingun
chaingunwilly2
10th July 2003, 02:10
My sincere thanks all. Just reducing the framerate down to 23.9 fixed just about everything for me.
These days I'm just refining with regards to specific movies.
For instance:
Tombstone...Looks great and sounds great, except for several odd 'creases' in the middle of the screen. Almost imperceptable, but look hard and there they are. :/
A Knights Tale...Lots of movement and quick camera angles. Having trouble compensating for them. Some blurring.
~William
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.