All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brad Midgley <bmidgley@xmission.com>
To: bluez-devel@lists.sourceforge.net
Subject: Re: [Bluez-devel] Advanced Audio Distribution Profile (A2DP)
Date: Wed, 22 Jun 2005 15:36:17 -0600	[thread overview]
Message-ID: <42B9D9D1.4020200@xmission.com> (raw)
In-Reply-To: <Pine.LNX.4.62.0506222203110.4779@server1.ploetzli.ch>

Henryk

> So now you're going to bigger-than-32-bit integers anyways?

We don't need the full 32 bits. I want to get this working and then play 
around with slimming it down.

> Some time ago I already stated that using 32 bit for the floating point 
> presentation with 16 bits before the decimal point and 16 bits after 
> should be enough. (PCM and reconstructed subband samples should not exceed 
> 16 bits and all intermediary values should only be fractions of these 
> samples. I might have forgotten one bit for the sign, though.)

yes, i remember your suggestion. the libmad guys took an interesting 
approach... they only use 3 bits for the decimal and 28 for the 
fractional part. i will look at the range of our computation but it may 
be possible to similarly dedicate most of the range to the fractional part.

libmad produces 24-bit audio, another indication it is overkill for us 
to have 32-bit numbers.

> But then intermediate results during multiplication need an additional 16 
> bits and your platform therefore needs to be able to handle (at least) 48 
> bit integers without falling back to floating-point emulation speeds.

multiplying two n-bit numbers results in a 2n-bit product. if we have 
16-bit numbers, then the multiply/divide intermediate result would fit 
in a tidy 32 bits.

> If it can do that, then of course doing fixed point should be easy: 
> Addition, multiplication and shift work unchanged. Each multiplication 
> must be followed by a shift right 16 bits. Conversion integer -> fixed 
> point or fixed point -> integer is shift left 16 bits or shift right 16 
> bits respectively.

yes, exactly. I put inline functions in sbc.h to do the multiply and 
divide and add/sub "just work."

Brad


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel

  reply	other threads:[~2005-06-22 21:36 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-21 15:28 [Bluez-devel] Advanced Audio Distribution Profile (A2DP) Victor Shcherbatyuk
2005-06-21 17:29 ` Marcel Holtmann
2005-06-21 18:02   ` Brad Midgley
2005-06-21 18:28     ` Marcel Holtmann
2005-06-21 19:51       ` Brad Midgley
2005-06-21 21:03         ` Marcel Holtmann
2005-06-22  0:16           ` Brad Midgley
2005-06-22  0:26             ` Marcel Holtmann
2005-06-22  7:56               ` Brad Midgley
2005-06-22 18:50                 ` Brad Midgley
2005-06-22 20:23                 ` Henryk Plötz
2005-06-22 21:36                   ` Brad Midgley [this message]
2005-06-22  6:45           ` Peter Robinson
  -- strict thread matches above, loose matches on Subject: below --
2005-06-22 15:27 Victor Shcherbatyuk
2005-06-22 16:39 ` Brad Midgley
2005-06-15 17:19 Claudio Takahasi
2005-06-15 17:47 ` wim delvaux
2005-06-15 17:49 ` Brad Midgley
2005-06-15 17:51 ` Henryk Plötz
2005-06-16 12:50   ` Claudio Takahasi
2005-06-22  8:54     ` Peter Robinson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=42B9D9D1.4020200@xmission.com \
    --to=bmidgley@xmission.com \
    --cc=bluez-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.