# [vorbis] Re: Re: fitting lots of music into 10GB with Vorbis

Martin Blackwell djdij at handbags.freeserve.co.uk
Mon Dec 30 00:15:19 PST 2002

```
This is getting hair tearingly irritating now.
I need a linear equation that gives the bitrate from the quality value. That
is easy to implement in javascript.
Or i can type out all the variables (which resulted in an inefficient large
file)- i'm making mistake in getting the bitrate calculation to work- the
rest of it works fine, and with a little modification (once the bitrate
calculation has been perfected of course) the thing could be used to
calculate what quality rating to use for streaming to a certain number of
people over a limited bandwidth).
I've missed huge gaps out of the variables, but the bitrates seem to go up
somewhere around 0.2 kbps per 0.01 of quality.
its really bugging me now. i can get it to work if i use "if" to specify a
bitrate for each individual quality, and thats it. im gonna get some sleep
soon.
----- Original Message -----
From: "Martin Blackwell" <djdij at handbags.freeserve.co.uk>
To: <vorbis at xiph.org>
Sent: Sunday, December 29, 2002 9:40 AM
Subject: Re: [vorbis] Re: Re: fitting lots of music into 10GB with Vorbis

<p>> > PS, because i am very bored (my usual excuse for doing something
seemingly
> > pointless) i am writing a teeny javascript thing that tells people how
> much
> > time can be fitted into a certain amount of space by a specified
quality.
>
> An algebraic formula to calculate the bitrate from the quality would be
> handy
>
> at the moment, the formula " bitrate = 64 + (16 * n)" kinda works from n =
0
> to n = 4.09
>         where n is the quality, and bitrate is the nominal bitrate in
kbps.
>
> this is going off the values entered for the quality in OggDropXpd1.6 beta
> 13
>
> someone who actually knows the way the vorbis encoder calculates the
nominal
> bitrate would probably find the correct algebraic formula quicker than i
> could.
>
> the above formula took my a few minutes to figure out- working from q0's
> 64kbps as a constant.
>
> PS by entering values below q-1 into OggDropXpd 1.6 beta 13, the nominal
> bitrate goes down to 30kbps - is that supposed to happen?
> How it happend:
> 1) entered a value below q-1, eg q-10
> 2) GUI displays nominal bitrate as being -126kbit/s
> 3) dropping a wave file (my bog standard test file of "The Microsoft
> Sound.wav" emphasis on bog standard. hehe ) immediatly changes the
displayed
> nominal bitrate to 30kbit/s
> 4) Going into encoding options then clicking accept returns the displayed
> nominal bitrate to that of q-1, 45kbit/s
>
>
> --- >8 ----
> List archives:  http://www.xiph.org/archives/
> Ogg project homepage: http://www.xiph.org/ogg/
> To unsubscribe from this list, send a message to 'vorbis-request at xiph.org'
> containing only the word 'unsubscribe' in the body.  No subject is needed.
> Unsubscribe messages sent to the list will be ignored/filtered.
>

<p>--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.

```