SB 3DSE ioctl() patch

Alexander Leidinger Alexander at Leidinger.net
Sat Aug 13 13:04:32 GMT 2005


On Mon, 8 Aug 2005 13:46:16 -0400
John Baldwin <jhb at freebsd.org> wrote:

> On Saturday 06 August 2005 05:50 am, A. Wik wrote:

> > I just installed a Soundblaster 16 (DSP v4.16) in my FreeBSD
> > machine, and found no way to enable the 3D stereo enhancement
> > feature that the Linux, DOS and Win9x drivers support.  So I
> > looked at the Linux driver sources and decided to add a
> > compatible mixer ioctl() to the FreeBSD driver.  That turned
> > out to be a lot more complicated than expected, because there
> > was no existing interface for this kind of hardware-specific
> > ioctls.
> >
> > After extensive reverse-engineering of the FreeBSD driver
> > model (studying the UART and TTY drivers was particularly
> > helpful), and adding a method to the mixer interface, I
> > managed to implement the feature, at least to the extent
> > that it works for me.
> >
> > Perhaps you could take a look at the patch to verify that
> > it doesn't break anything, and consider adding it to the
> > mainstream kernel?  The patch and a utility for testing
> > it is available from my FTP site:
> >
> > ftp://vax.narpes.com/users/aw/freebsd-5.3-aw-3dse.diff
> > ftp://vax.narpes.com/users/aw/s3dioctl.c

I haven't looked at the patch, but from looking at the names of the
files I assume you've a program which kust is responsible for
activating the 3D stereo enhancement. While this enables this
functionality (which is good), there should be a generic "sndctl"
program which allows to manipulates multiple settings. So the sndctl
program could be called in this case for exmaple as "sndctl 3dse
on" (or something like this). Maybe you can add some rough command line
parsing to your program which reacts on a keyword like above? Ideally
it should support the "-f" option like mixer(8) does.

I want to work on something like this for the s/pdif <-> analog
features (ATM only available as sysctl's in -current), but I don't know
when I get time to do it. Your ctl program could then be enhanced to
also handle this (and maybe other things like querying for such
capabilities and print them together with the current state of
operation).

Bye,
Alexander.

-- 
Failure is not an option. It comes bundled with your Microsoft product.

http://www.Leidinger.net                       Alexander @ Leidinger.net
  GPG fingerprint = C518 BC70 E67F 143F BE91  3365 79E2 9C60 B006 3FE7


More information about the freebsd-multimedia mailing list