The results were both quite good and I couldn't tell the difference in sound - maybe I lack the equipment.

I performed a spectral frequency analysis on each of the results.

Here's what it looked like:

Let's look at the left image: the frequency meter suggests thet there's a sharp cut at 16kHz. Nevertheless, some sounds are given higher frequencies, but then there is another sharp cut just under 19kHz, above which nothing can be seen.

Now the right image: up to about 16kHz the frequencies are generally preserved. Then they gradually become thinner in a varying manner, depending, i suppose, on their importance. There is no sharp cut below ~19.8kHz.

I do not know much abot audio compression - maybe I'm misunderstanding the whole thing - so I'd like you to ask you first: which picture do you think corresponds to which compression method?

gpsycho tends to leave little "speckles" of high-frequency low-amplitude sound which are disconnected from the rest of the picture. At lower bitrates these speckles appear at lower frequencies and can be audible to some people. They have been described by other people as "ringing" or just the classic watery sound.

The lowpass is probably another clue. I don't know for sure, but I think the default lowpass at 192 kbit/s is higher than --alt-preset standard (I'm talking about the higher cutoff frequency, near 19 kHz, not the 16 kHz cutoff).

But /\/ephaestous has a point: if you can't hear it, it's not important (at least at that bitrate).

The regulars here know that looking at graphs is pretty irrelevant when coming to the actual listening. But I still think it's interesting from a technical point of view to see what the codecs are doing.

The left picture must be alt preset standard, because the lowpass is lower (18671 to 19205 Hz, vs 19383 to 19916 Hz for the other command line).

Nothing can be said about quality or audible difference looking at the pictures, because an MP3 encoder is targeted at removing as much inaudible sounds as possible. Therefore a lack of frequencies can as well mean that some audible parts are missing (bad work, or too low setting), than that the encoder managed a very good compression, removing a lot of unuseful things.

i have to agree with /\/ephaestous on this.. you can't tell the sound quality by looking at a picture. well, sort of..

>>>'Now the right image: up to about 16kHz the frequencies are generally preserved.'<<<

this is not necessrily true. in many cases, the mp3 format in general doesn't code high frequencies very well. so, while these frequencies may "show up" on the graph, it doesn't mean that they are coded properly or sound like the high frequency content of the source file. this is why we use our ears, not eyes

>>>'I'd like you to ask you first: which picture do you think corresponds to which compression method?'<<<

i say the image on the left is --alt-preset standard because of the lowpass at ~19.5 kHz

The regulars here know that looking at graphs is pretty irrelevant when coming to the actual listening. But I still think it's interesting from a technical point of view to see what the codecs are doing.

not really, pictures are misleading, check out a Mp3pro or WMA graph and you'll think it sounds better than APS. and you can't tell what has been transformed trhu the graph, the most you can see is the lowpass,

This post has been edited by /\/ephaestous: Mar 26 2003, 21:22

--------------------

"You have the right to remain silent. Anything you say will be misquoted, then used against you."

All who guessed, guessed right about --alt-preset standard - it's the picture on the left. But there's something bugging me.

I really didn't say anything about which sample sounds better - either my ears or my headphones are too bad for that. But REGARDLESS of the audible result it was a surprise for me to see that the lowpass filter, considering the two clearly visible boundaries, is applied much earlier in a VBR algorythm than in CBR. A question arises: how is the advantage of VBR being used? I earlier thought that VBR provides the possibility to preserve a broader range of frequencies where it is needed and cut down on them where it isn't. As far as I understand, the VBR codec (like any other) "considers" the lower frequencies more important and cuts off the higher ones, which is, of course, a good idea to some extent, as people don't hear them very well. But then why does the CBR codec leave so much of them? It could as well apply a lower lowpass filter if it's such a good idea, but it doesn't. Why? After all, it's the same version of the same encoder, so the applied techniques are surely coordinated. Doesn't this fact surprise you a bit? Just a little bit??? Or have I just gone mad?

The point is, I don't believe that the marginally higher frequencies preserved in the CBR really destroy the overall sound quality, especially they wouldn't in a VBR codec, where there is a possibility to assign more bits at a particular point...

The point is, I don't believe that the marginally higher frequencies preserved in the CBR really destroy the overall sound quality, especially they wouldn't in a VBR codec, where there is a possibility to assign more bits at a particular point...

There's also the possibility that 192KBPS is transparent to you or very near transparent, and perhaps your hearing capabilities.

My hearing isn't getting any better as I am getting older, however I can just about always tell a high quality LAME --alt-preset standard MP3 versus the likes of a 192KBPS CBR MP3 encoded by LAME or FhG.

Right, right,It started when I was about to write "the alt presets are better than any command line", but it occured to me that we were speaking about alt preset CBR, and it didn't make sense.

Immo, the global lowpass needed depends on the hearing ability of the listener. There have been some tests with sweep tones and music lowpassed here recently, to see how high people could hear, but they are affected by the fact that most soundcard resample, and therefore produce low frequency sounds when high frequency ones are fed into them (the "alias" effect).

The lowpass used in the command line and the one used in the alt preset can't be compared, because they were developed at a different time by different people. Lowpassing is a powerful way to reduce the bitrate of a VBR file, that's why lowpass filters are used in the presets.

A question arises: how is the advantage of VBR being used? I earlier thought that VBR provides the possibility to preserve a broader range of frequencies where it is needed and cut down on them where it isn't. As far as I understand, the VBR codec (like any other) "considers" the lower frequencies more important and cuts off the higher ones, which is, of course, a good idea to some extent, as people don't hear them very well. But then why does the CBR codec leave so much of them? It could as well apply a lower lowpass filter if it's such a good idea, but it doesn't. Why?

One phrase: sfb21.

Scalefactor band 21 is the nemesis of MP3 VBR (well, one of them). Unlike the first 20 scalefactor bands (<16KHz), scalefactor band 21 (>16KHz) doesn't use a scalefactor and this leads to many problems. You'll find more technical explanations about sfb21 here at HA but understand that the lower lowpass of VBR is a result of a MP3 design flaw. The more you cram in sfb21 (i.e. greater HF retention) the more the bitrate will bloat. If you are shooting for a certain bitrate like --alt-preset standard does, you don't want to waste all you bits in a single sfb, especially one that is arguably the least critical.

CBR doesn't have the same limitation because it doesn't employ sfb21. Does that make CBR superior? No, because the workarounds for sfb21 are generally effective.

But I wouldn't worry. Who can really hear the difference between a 19KHz and a 19.5KHz lowpass?

I just wanted to point out, Immo, that your commandlin is kind of funy. you specifiy -h, which is equivalent to -q2 for your information, but then you specify -q 0 (which in current versions of the encoder is flawed so the quality is not better), which overrides the -q 2.

thanks for the tip, NeoRenegade, the reason for that is my (supposedly lame) usage of the RazorLame frontend.

Thank you all for the explanations. The picture becomes clearer to me, at least after Mithrandir's post.

I'm not so sure about Pio2001's answer, though:

QUOTE

Lowpassing is a powerful way to reduce the bitrate of a VBR file, that's why lowpass filters are used in the presets.

I suppose lowpassing is just as powerful a tool to reduce the bitrate of a CBR file, if not, in fact, even more powerful, as VBR should have more tricks up the sleeve. But I'll settle me with the information I have now

I tried to use Lame 3.93.1 with the same CBR settings: -b 192 -m j -q 0.Here is the comparison. The first image is 3.91, the second - 3.93.1:

What do we see? In the 3.91 there is no clear cut at 16kHz, as opposed to 3.93.1, where we can distinguish a cut much better.

Maybe the developers had noticed something similar to what I did, and made an effort to cut more on the CBR high frequencies?

What I meant was that lowpassing is an even more important tool in CBR to increase the overall sound quality than in VBR, as you don't have the possibility to assign more bits to a particular place, isn't it?

In 128kbps CBR, for instance, LAME applies a lowpass filter sooner than in --alt-preset 128 (VBR), so it's the other way around and corresponds to my understanding of VBR, so that makes this whole thing even more mysterious.

Immo: VBR isn't about preserving HF content. It's about providing the same sound quality over the whole piece of music. The sound complexity of your music can vary a great deal so VBR tries to find the bitrate needed to encode a small piece of sound at a given quality level. There are a lot more things to worry about than just HF content.

Hearing the difference between --alt-preset standard and your command line is a matter of training mostly. Equipment, as long as it is halfway decent, plays only a very minor role in hearing these differences. Give headphones a try, they can be more "revealing".

Lev: it gets even more ironic when the author makes the line come true

Gecko: yes, well, I guess it is another way to put the thing. But it doesn't really explain why, if a higher quality can be obtained by using up to 320 kbps available on lower frequencies, the CBR codec uses its 192 on higher...

And - my sound "equipment" at the moment actually is a pair of low-end headphones, that's why I don't rely much on it, but maybe it's not that bad.

CBR is shit...always. The entire fact of giving the same bitrate for transients than for silence is...idiotic.As for quality, when you set CBR mode, you set VQ, CBR (variable quality, constant bitrate) opposed to VBR (constant quality, variable bitrate)

That happens because CBR uses always a fixed bitrate, so it becomes both overkill and lack of bits at the same time: bits that aren't used while encoding are set to null data to fill the specified bitrate, while other times it will run short of bits on harder-to-encode parts.

VBR, however, will decide what shall be encoded and what has to be left, without wasting bits: it can use bitrates as low as 128kbps or as high as 320 if it considers it necessary.

--alt-preset standard, --alt-preset extreme and --alt-preset insane* are code-tweaked: it's impossible to reach them through commandlines [no, do NOT use them!!!] in terms of quality.

*--alt-preset insane is CBR, yes, but it's on the highest bitrate allowed for the mp3 standard, so it won't get short of bits (inside of mp3's specs) , but it also will happily start wasting bits.....

CBR is not "always shit", plz stay serious. Especially not for the music I listen to (Rock, Heavy etc) where are no silent parts and pure tones.

If you plan to use your encodes for listening on the PC and playing them in your car/portable/DVD player, "--alt-preset cbr 192" is a very good choice, especially since lame is told to have very good short block/bit reservior handling (mp3 CBR is not really CBR), and the VBR files give serious trouble to some hardware players.

Oh btw, does anyone know if the "--alt-preset cbr" modes have been improved between lame 3.90.2 and 3.93.1, or are the CBR modes more or less "finished". Thanks.

The lame development team works on the encoder and the switches. Mainly Dibrom works on the Alt Presets. There should be no difference between the presets in 3.90.2 and 3.93.1 other than that 3.93.1's VBR Alt Presets may not function totally properly, and 3.93.1 has "Alt Presets" under 80kbps which 3.90.3 doesn't...

To ImmoAbout your 1st pictures...Can you think about VBR as a manner of redistributing bitrate between intensive and easy sections, instead of CBR, where such sections gives equal bitrate? From that point maybe those pics will be cleaner?I.e.: for intensive section (we see widefreq beat) coder uses more bitrate, which he needs to take from unintensive section. And he does it, casually lowering lowpass filter further.Am I right, at least a bit?