[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnash-dev] Re: sound_handler.h
From: |
strk |
Subject: |
Re: [Gnash-dev] Re: sound_handler.h |
Date: |
Thu, 30 Oct 2008 16:37:54 +0100 |
On Thu, Oct 30, 2008 at 08:19:47AM -0700, Bastiaan Jacques wrote:
>
>
> On Thu, 30 Oct 2008, Klaus Rechert wrote:
>
> >Hi,
> >>The only difference is that instead of fetching 32bit numebrs we
> >>fetch 16bit ones and require to fetch in couples.
> >>
> >> h, so you suggest we refer to "sample pairs" when we count them ?
> >>Should the interface be something like this then:
> >>
> >> void fetchSamples(boost::int32_t* to, unsigned int nSamples)=0;
> >>
> >>If so, isn't thre a need to specify byte orders for those 32bit numbers ?
> >>
> >I do not understand why to use int32_t / int16_t types for the output
> >sink. Makes everything complicated (IMHO).
> >I'd use (uint8_t *) as "raw data".
>
> I don't understand where the 32-bit number comes from. The numbers are
> actually 16-bit, so we should use int16_t. If it is believed that an
> array of 16-bit values actually representing an intereleaved array of
> left-and-right stereo samples is confusing, than we should use an array
> of struct StereoSample { int16_t left, int16_t right };.
I think as long as the documentation is clear we can live with the
16bit array.
BTW, this is what we expect AudioDecoder::decode to return currently, right ?
--strk;