patch for 24-bit soft volume and uaudio's tiny fix
Ariff Abdullah
ariff at FreeBSD.org
Wed Feb 15 00:30:40 PST 2006
On Sat, 17 Dec 2005 19:46:04 +0800
Ariff Abdullah <skywizard at MyBSD.org.my> wrote:
> On Sat, 17 Dec 2005 03:37:15 +0900 (JST)
> Kazuhito HONDA <kazuhito at ph.noda.tus.ac.jp> wrote:
> > Hello,
> >
> > We have already had a soft volume, feeder_volume_s16().
> > But it is of 16 bit. So 24-bit sound streams are
> > always downgraded to 16-bit before soft volume
> > even though a sound device has a 24-bit port.
> > Thus 24-bit soft volume is necessary.
> >
> > This mail has a patch for 24-bit soft volume.
> > I tried to use it with `SB Live! 24-bit external'
> > and it worked.
> >
> > And the patch includes a fix of tiny mistakes in uaudio.c, too.
> >
>
> uaudio.c: Obvious mistake that need to be fixed.
>
> feeder_volume.c: Ok, looks good. My concern is endianess issue, but
> this can be ignored for now. I need to examine it
> first.
>
> channel.c: Changes against feeder building process is a bit
> sensitive,
> some brute testing need to be done here.
>
(Especially to Kazuhito-san), Latest patchsets (rev. 091) contain:
1) 16/24/32bit feeder_volume
2) 16/24/32bit vchan mixing (default to 16, use sysctl or vchanformat
kernel hint to toggle it).
3) Smarter (I would say *perfect*) format scoring during format
chaining.
4) Endian/sign-free format conversion
5) Various fixups, especially on hardware, DMA buffer alignment
6) Samples processing are moving towards endian-safe, we just need to
enclose varios PCM_READ/WRITE/CLAMP (sound.h) within BYTE_ORDER
ifdefs.
My concern is 24bit alignment. This patchset enforce strict alignment
based on bytes-per-sample, so if the so called "24bit" hardware can
really do 24bit alignment, it is pretty much OK. Otherwise, we
probably need to swap AFMT_S24_XX -> AFMT_S32_XX within specific
driver implementation.
--
Ariff Abdullah
FreeBSD
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-multimedia/attachments/20060215/c83aa938/attachment.bin
More information about the freebsd-multimedia
mailing list