Hello,
I am converting some personal camcorder footage of mine (wedding) to DVD and have been performing some experiments to find the best quality conversion. All footage is less than 60 minutes and I am using 1 AC3 2-channel audio track. TMPGEnc Xpress 3.0 is my encoder using 10 bit DC Component Precision and Highest (with error correction) Motion Search Precision.
1. My first thought that since space was not an issue (<60 minutes per DVD) that constant bit rate (CBR) would be quick and appropriate using a bitrate of 9200 kbits/sec. So I encoded a video that was 34 minutes and 34 secs long with a 448 kbits/sec AC3 audio track using TMPGEnc Xpress 3.0. When you select CBR in TMPGEnc Xpress the Average/Minimum/Maximum bitrates all get set to 9200 kbits/sec. The integrated bitrate calculator said the compliation would be 2428.65 MB. The resulting output file was 2,534,987,780 bytes.
2. Then I wondered if using the Varible Bit Rate (VBR) mode with 2 passes would optimize GOP's, I-, or B- frames. I don't really understand these that well but I thought what the heck, perhaps 2 passes would be better even if the bitrate was still 9200 kbits/sec like the CBR example above. So I set TMPGEnc Xpress 3.0 up in VBR 2 pass mode with the Average and Maximum bitrates set to 9200 kbits/sec and Minimum set to 0. The integrated bitrate calculator said the compilation would again be 2428.65MB. The resulting output file was 2,384,832,516 bytes.
3. Having seen the discrepency in resulting file sizes above I suspected it may have been due to setting the the minimum bitrate to 0 and only setting the average and maximum bitrate to 9200 kbits/sec. So I set the Average, Maximum, and Minimum bitrates to 9200 kbits/sec and ran TMPGEnc Xpress 3.0 again in VBR 2 pass mode. The integrated bitrate calculator said the compilation would be 2428.65MB for the third time. I expected to have a resulting encoded file the same size as the CBR example #1 because all the bitrates were now set the same as well as all other settings. The resulting output file was different coming in at 2,534,973,444. Granted pretty darn close to #1 but still different.
So the question I'm trying to answer ultimately is which mode is best for maintaining the best possible quality between my DV source and MPEG2 output for DVD?
To get that answer I'm wondering:
1. Is there any advantage to using 2 pass VBR mode with the same bitrate settings as CBR? (Does 2 passes optimize picture quality through different GOP, I-, B- frames settings, ect.)
2. If average and maximum bitrates were both set to 9200 kbits/sec in example #2 with VBR 2-pass, why did the resulting file come in smaller than example #1 with 9200 kbits/sec CBR?
For the sake of argument in this discussion let's say that time encoding and size of files don't matter.
Thank you very much for any insight you can provide.
+ Reply to Thread
Results 1 to 29 of 29
-
-
Wow...!!!
<- That's how my eyes are now...
OK, here goes... I'm gonna pick through and address points and questions - there's quite a few hidden in there!
1st Attempt: All fine there...
2nd Attempt:
I wondered if using the Varible Bit Rate (VBR) mode with 2 passes would optimize GOP's...
CBR and VBR are not influenced by GOPs - the end result will still have the defined number of pictures in a group. How is this number defined? See next response...
...I-, or B- frames. I don't really understand these that well...
MPEG compresses the video by using an I-frame at the start of the GOP as a kind of starting point - here's a picture with the most info in. It then uses P-frames and B-frames to fill in the gaps until the next GOP starting with an I-frame - an intra frame.
A P-frame is a picture that is predicted based on the previous picture.
A B-frame is a picture that is bidirectionally predicted - My take on this is that it's a picture that is based on both the previous and following picture.
Without getting into technicalities (coz I'll be in deep water without my water wings), the short of it is that B- and P- frames are pictures that are "intelligently guessed" based on the pictures around them - stuff like "only take into account differences between pictures" etc.
See this, taken from a VirtualDub pop up:
A GOP has a "structure" - a way of arranging the I-, P- and B-frames. The one I use for PAL in TMPGEnc is I : P : B = 1 : 4 : 2, as below:
This gives 15 pictures in a GOP, calculated as follows:
Rules: GOP starts with an I-frame. B-frames follow either the I-frame or a single P-frame. Only one P frame at a time.
So, you'll get 1 x I + 2 x B. No I-frames left coz you only specified 1, so next is 1 x P followed by 2 x B. And so on... So for every I- and P-frame there's 2 B-frames, making little clusters of 3 pictures (1 I- or P-frame plus 2 B-frames).
Formula works out as: (I + P) x (B + 1) = (1 + 4) x (2 + 1) = 15.
(The "+1" in the "B + 1" accounts for the preceeding I- or P-frame, and the (I + P) is the total number of little clusters).
So I set TMPGEnc Xpress 3.0 up in VBR 2 pass mode with the Average and Maximum bitrates set to 9200 kbits/sec and Minimum set to 0.
See here for more details...
3rd Attempt:
Having seen the discrepency in resulting file sizes above I suspected it may have been due to setting the the minimum bitrate to 0 and only setting the average and maximum bitrate to 9200 kbits/sec. So I set the Average, Maximum, and Minimum bitrates to 9200 kbits/sec and ran TMPGEnc Xpress 3.0 again in VBR 2 pass mode.
Rhetorical question, and my answers to questions it prompts:
So the question I'm trying to answer ultimately is which mode is best for maintaining the best possible quality between my DV source and MPEG2 output for DVD?1. Is there any advantage to using 2 pass VBR mode with the same bitrate settings as CBR? (Does 2 passes optimize picture quality through different GOP, I-, B- frames settings, ect.)
Simple rule I follow: If it's short enough to allow me to do CBR, I do CBR.
As for the question in brackets, I'd say "probably not enough to make a huge difference, if at all" based on the info I gave above and my understanding / interpretation of it.
2. If average and maximum bitrates were both set to 9200 kbits/sec in example #2 with VBR 2-pass, why did the resulting file come in smaller than example #1 with 9200 kbits/sec CBR?
It's just that one (the VBR guy) will take twice as long!
There - That's my insight. I hope it's been of use and interest.
I'm now off to get my eyes replaced...There is some corner of a foreign field that is forever England: Telstra Stadium, Sydney, 22/11/2003.
Carpe diem.
If you're not living on the edge, you're taking up too much room. -
Thank you very much for the lengthy and informative response. I've been doing some additional research on I, B, P frames as well as analyzing my three encodes by frames. What I found:
1. Each GOP TMPGEnc Xpress 3.0 encodes for my NTSC project for both CBR and VBR are as follows:
IBBPBBPBBPBBPBBP, IBBPBBPBBPBBPBBP, ect. so I guess my NTSC GOP is set for 16 if you count the I frame.
2. I have "detect scene change" checked in TMPGEnc Xpress and I've noticed in at least one spot in both VBR encodes that TMPGEnc Xpress ended the GOP early (before 16) and started another I frame at the scene change. The CBR encode keeps the GOP at 16 before the scene change and then starts a new I frame at the scene change (after the last's GOP's 16).
Once of my original questions was why is the file size smaller even though I selected 9200 for both average bit rate and maximum bit rate while 0 for minimum bitrate in example #2? I've been thinking and to get an average of 9200 kbits/sec then the maximum and minimum would have to both be held to 9200 kbits/sec. It appears that if you set the minimum to 0 and average/max both to 9200 kbits/sec than TMPGEnc Xpress is doing a VBR encode that uses a minimum less than 9200 kbits/sec and therefore isn't really following a 9200 kbits/sec average.
I also burnt two DVD+RW's, one with the CBR 9200 kbits/sec encode (example #1) and VBR encode with min/max/average set to 9200 kbits/sec (example #3) and I really couldn't tell a difference subjectively on my 27" TV.
I'll continue to look for an objective difference between the two above and hope if someone knows of a nuts and bolts difference (different algorithms?) for those unique situations they can explain it for us.
Thanks again. -
You're missing a fundamental understanding of what CBR/VBR is. This can become a very complicated answer, but I'll try and simplify it as much as I can.
CBR= Constant biterate. The disk in your dvd player will spin at the same speed throught the entire playing of the movie.
VBR= Variable biterate. Your dvd player will either speed up or slow down the spin speed of your disk while playing the movie, depending on how much information it requires to play each scene.
Each individual frame of a movie has a different bitesize. Each frame is a sum total of light, color and motion variances. (Lets forget about GOP for a second cause that's just another calculation in the mix and has nothing to do with it anyway.)
CBR. If you choose a constant biterate that is too low, you loose quality in your picture as some information gets "dumped". If you choose a constant biterate that's too high, you are overinflating your movie and wasting disk space. Most people don't use CBR.
VBR is actually CBR evolved. A variable biterate will try to adjust for space while keeping quality. It asks you what average biterate you would like (you feed it what the calculater states will fit into your dvd), it asks you how high can it go to accomodate high motion scenes that require more biterate to keep the quality of the picture, and it asks you how low it can go to save space on your disk.
This results in an effect that most people (inaccurately) call borrowing bites from low motion scenes to make high motion scenes look better. You end up with improved overall picture quality with saved disk space.
When you input the exact same numbers in your ave/max/min values in vbr, you are essentially telling vbr that it cannot deviate from that biterate. This is exactly the same as using CBR.
When you use 0 in the min field you are allowing vbr to compress the parts it can to save on space, but since you've given identical ave/max biterates, vbr will not compress those parts very much in order to keep up with the overall quality of the rest of the movie.
The proper way to use vbr is to set the max way higher than the average and the min way lower and let vbr do the adjusting for you.
I can't tell you what those numbers should be, because I use CQ rather than vbr, but that's for another post to try to explain.
To illistrate how infuriating and complicated the process is, isolate exactly 50 frames of your movie with a shot of a person standing still and encode it using CBR at 01 kbps. Then isolate 50 frames of a pan shot from side to side and encode it using CBR at 01 kbps. Even though you have 50 frames of each, the pan shot will have a much higher filesize than the still. (Yes it will look like shit, but this is just for curiosity's sake.)
By coding at 01 kbps you are allowing the encoder to just use the absolutely necessary bites required to make each frame. -
[quote="Shadowmistress"]You're missing a fundamental understanding of what CBR/VBR is. This can become a very complicated answer, but I'll try and simplify it as much as I can.
CBR= Constant biterate. The disk in your dvd player will spin at the same speed throught the entire playing of the movie.
VBR= Variable biterate. Your dvd player will either speed up or slow down the spin speed of your disk while playing the movie, depending on how much information it requires to play each scene.
quote]
No it doesnt.
The DVD does not spin at a different rate at all. -
Originally Posted by Quantum
Originally Posted by Quantum
Why do it? Well, when you come to authoring, based on my use of TMPGEnc DVD AUthor, you can only start a chapter point on an I-frame. So it's handy to have new scenes starting with an I-frame. This may not apply to other authoring apps.
Originally Posted by Quantum
Originally Posted by Shadowmistress
I quote often do CBR encodes with the bitrate as low as 5000 and still get excellent results. It all depends on the footage and its running time.
That reason is that it takes half the time to encode when compared to a 2-pass VBR.
See here (http://dvd-hq.info/Calculator.html) for a useful guide on when to use CBR vs VBR...
Originally Posted by monzieThere is some corner of a foreign field that is forever England: Telstra Stadium, Sydney, 22/11/2003.
Carpe diem.
If you're not living on the edge, you're taking up too much room. -
The speed the DVD spins will slow down progressively as it plays but in no case will bitrate have any effect on it.
http://electronics.howstuffworks.com/dvd12.htm
CBR actually does not mean constant bitrate, it means constant buffer rate. The bits per second still fluctuate per scene just not by as much so that the buffer size remains constant. -
Adam, this is what I was going on:
http://www.iis.ee.ic.ac.uk/~frank/surp99/report/kht97/work.html
-
I've been doing some more research on encoding methods and ran across a CCE manual on google. According to what I've read, CCE has a mode called multipass CBR that allows you to set one bitrate value with multiple passes. So that natually prompted me to ask what is going on during the multiple passes in a CBR encode? Can it be duplicated somewhat in TMPGEnc by running it in VBR mode with min/max/average bitrate settings of 9200 kbits/sec?
If anyone has information on multipass CBR encoding I would be interested to hear it and probably others would be too.
My next step is to get a trial version of CCE and do one of these encodes and compare it subjectively to my TMPGEnc Xpress encodes. -
You could accomplish roughly the same thing using the same min, max, avg settings in TMPGEnc, yes.
As stated before, CBR just means constant buffer rate. There is still some fluctuation at the GOP level. Mpeg encoding is all about finding redundancy in a series of frames and storing that repeated information in one frame, and then recalling it for all others that use it. The more passes you use to analyze the clip, the more redundancy you find, and thus the better compression you achieve....up to a point of course. This holds true even for CBR encodes, obviously not nearly to the same degree as VBR encodes though. -
IMO, with TMPGenc, just use 2 PASS VBR with min / aver / max the maximum avalaible bitrate for DVDs (9200 kbits/sec that is)
That way you emulate something called 2 pass CBR which in theory can be better a simply pass CBR.
You can't go higher than this.La Linea by Osvaldo Cavandoli
-
I agree that 2 pass CBR can produce better encoding compared to single pass. However, if bitrate is set high enough (as originally stated at 9200kbps), isn't a single pass encoding "equal enough" to a 2 pass one?
In the same fashion, when someone encodes at 9Mbps, I think that things like motion search become less important as there is plenty of bitrate to spare.
There has to be an optimum encoding strategy for low bitrate and a different one for high bitrate.The more I learn, the more I come to realize how little it is I know. -
Originally Posted by SatStorm
It is possible that a DVD Video stream at 9800 kbit / sek is not compliant with an audiostream.
The total DVD standard is set to 10,08 mbit / sek, a Video stream at 9800 kbit / sek wont let much bandwith over for example overhead mux. -
@video_sync: 9200+audio with TMPEGenc 2.5. That encoder can't go higher without issues. Also can't go lower 3.000kb/s without issues.
But that's TMPGenc-ology, a long forgotten knowledge of the ancient ones -
The only people who could tell you what the difference between 2-pass VBR encoding with minimum, average, and maximum bitrates as 9200 vs. a CBR encoding at 9200, with TMPGEnc, are the programmers at TMPGEnc.
But here's a little thought experiment for you:
Write down three numbers. The average of the three numbers must be 9200. The biggest of the three numbers cannot be more than 9200.
I know what three numbers you wrote down without you telling me. In fact, the experiment can use any number of numbers. I still know what they all are. -
jman98, we don't talking here about VCDs and Mpeg 1.
We talking about DVDs and Mpeg 2.
TMPGenc is a good encoder but it has issues on static scenes when you go below 3000kb/s and you encode to mpeg 2. It create macroblocks on the dark areas. FYI, the popular TMPGenc 2.5 pro encoder, also creates problematic mpeg 2 for DVDs overall. Minor things that nobody gives attention. But those issues shows when you use more than 9200KB/s for video.
The point of 2 pass CBR is the better pixel allocation of the video data during frames. Some encoders offer 2 Pass CBR mode.
Yes, 2 Pass CBR helps with mpeg 2 and specifically with TMPEGenc. Of course you must be mad with the picture quality to use it, only the very few can tell the difference.
jagabo, if you have a full HD TV and a DVD player that upscales Full D1 material created by TMPGenc to 1080i, do a test yourself: Find a dark scene from a movie you captured from TV and encode it as usual, with low bitrate around 3000kb/s, CBR@9200 and 2Pass VBR all set to 9200. You be amazed with the results. Watch this upscaled to 1080i. -
Hmm 2 pass CBR? I have never tested this but i'm gonna
My opinion about VBR is >>never use this<< unless it's necessary: length of the video content too long.
Slowing / Speeding the disc is not something i like much
If at some point you fast forward or rewind, your dvd player will suffer and the disc as well.That's how i see/understand things.
edit:
Which mpeg encoder can encode in 2pass Cbr? (procoder 2 don't) -
Originally Posted by themaster1
Slowing / Speeding of the disc??? A DVD spins at a constant linear velocity. That means that it will spin faster at the beginning (near the center of the disc) than it will at the end (near the edge of the disc). A DVD player reads data constantly off the disc at ~22Mbps (that means AT ALL TIMES)! If the player doesn't need the data that it read at the particular instant, then it is simply discarded (to be re-read and used at another time).
Fast forwarding / rewinding doesn't cause the player or the disc to "suffer". So go ahead, FF or FR to your heart's content.ICBM target coordinates:
26° 14' 10.16"N -- 80° 16' 0.91"W -
CCE had 2PASS CBR once upon the time from what I recall.
Basically. as I said 3 years ago, you can emulate 2 Pass CBR by setting 2 Pass VBR with the same value for low,average,high bitrate. You can do this with any encoder that allows 2pass Vbr
Back in the old days, we use to do whatever possible to create the best VCDs, CVDs and SVCDs. 2 Pass CBR used frequently on commercial VCDs, it was industry's "secret" to have slightly better picture quality on their movies. Better pixel allocation per frame, was the only thing they could do, especially on VCDs, which the specifics are not flexible at all. When our PCs was Duron 700 and Celerons, 2 Pass was something for the very advanced enthusiasts! I remember myself waiting 36 hours for a 2 hour conversion using 2 Pass VBR back in 1999, using TMPGenc 0.12 I think, the last freeware version of this encoder.... -
Speaking of old threads/versions... and particularly speaking of 1999 - I remember then having to crop about about a dozen music video clips (~3-4 mins each) to remove the "VHS fuzz" from my captures. This was only MPEG-1 but I had to wait over half a day for this!
I hate VHS. I always did. -
8 or 16 lines from the bottom eh?
I still do this every time I convert VHS to DVD...
It's amazing but only now we can really have the full potention of our VHS tapes. Today's filters do a wonderful job, that looked sci fi back then. I mean, when I use neat video and some other filters to "clean", "restory" or call it whatever my VHS tapes, I am amazed by the results I can have today.
Also those filters, make my C2D act like a Duron 700 back then... 30 min for a 3 min music video.... -
from alot of experimenting, i found out that 9300kB/s is the highest bitrate for encoding video with an audio stream without having no stuttering as i have examined. Not to forget tm mention, i would highly recommend people to get TMPGXpress, because of its high quality output compared to TMPGEnc Plus.
i also found, when using 2 Pass VBR with all options having the same bitrate set, that the resulting video has a smaller file size compared to a (single pass) CBR of the same bitrate video made. -
Originally Posted by Undead Sega
Originally Posted by Undead Sega -
Evening guys.
Personally, I like old threads myself
jagabo beat me to it.. the studdering you were experiencing has greatly to do with the users dvd player and not so much as the users encoded mpeg. But I suspect that (at the time) it was not fully realized that the dvd player was the problem in many if not most of these cases.
My iLO DVDR04 actually includes 9.8MBits in CBR in the config. At the time, I was confused seeing this. Course, I'm a person who has been encoding high CBR bitrate mpegs for many years with TMPGenc, though I was one of the 12a-j beta testers back in the good-ol-days of vcdhelp. And while many were still farting around with VCD and even SVCD, I was encoding 1 hr 720x480 DVD mpegs
The newer dvd players are more tougher than yesterdays. My old Apex AD-500 (a champ in its day) does not handle some of the mpegs I made today. At certain bitrates it chokes. And, it chops at my raw 24p encodes while my latest players don't and play them smooth. My guess is that todays players now have telecine, aka 24p->30i built in, though I didn't quite realize this several years ago.
And who knows what else (secrets or nonstandard activities, etc) that lurks underneath these desktop players HD and BluRay, and of tomorrows generation of equpments.
-vhelp 4904 -
the audio i was using at the time was a HQ .mp2 audio stream. 384 etc.
the filesize wasnt that significant but around 330MB in difference, and i was using the VBR (Average Bitrate) with all Bitrates set the same, 2 Pass was eneabled and Padding was checked as well.
when i made a new video and increasing the bitrate, caculated when adding 330MB to the final filesize, i still get an ending result with it being slightly smaller, thus i will do another encode to match the filesize of the CBR encode. -
It's out of the DVD Specifics that way.
Playable, probably. But definately out of the DVD Specifics. -
ahhh i see, well right now i am having an immensly difficult situation with 2 Pass VBR, because i can never get the exact filesize as a CBR encode, and i tried to do all the calculations but they never seem to work, even doubling the difference between a CBR and a 2 Pass VBR (both Max, Avg & Min bitrates are the same as the CBR) and that even went too far in filesize.
Similar Threads
-
cbr to vbr
By dynamix1 in forum AudioReplies: 1Last Post: 17th Mar 2009, 15:12 -
CBR vs VBR
By prl in forum Newbie / General discussionsReplies: 5Last Post: 11th Jan 2009, 19:48 -
question about vbr v/s cbr and 2 pass vbr
By perfection in forum Newbie / General discussionsReplies: 4Last Post: 14th Dec 2008, 04:55 -
When best to use HCEncoder VBR or CBR
By nicksteel in forum Video ConversionReplies: 4Last Post: 30th Dec 2007, 09:04 -
VBR or CBR?
By dizzie in forum ffmpegX general discussionReplies: 1Last Post: 29th Jun 2007, 15:28