From owner-freebsd-doc Mon Jul 15 11:30:18 2002 Delivered-To: freebsd-doc@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4A33E37B405 for ; Mon, 15 Jul 2002 11:30:07 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id BD6BC43E64 for ; Mon, 15 Jul 2002 11:30:06 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g6FIU6JU086572 for ; Mon, 15 Jul 2002 11:30:06 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g6FIU6dK086571; Mon, 15 Jul 2002 11:30:06 -0700 (PDT) Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 83D0637B400 for ; Mon, 15 Jul 2002 11:27:15 -0700 (PDT) Received: from CPE0030ab0ef2bb.cpe.net.cable.rogers.com (CPE0030ab0ef2bb.cpe.net.cable.rogers.com [24.103.202.201]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8740843E67 for ; Mon, 15 Jul 2002 11:27:14 -0700 (PDT) (envelope-from munish@CPE0030ab0ef2bb.cpe.net.cable.rogers.com) Received: by CPE0030ab0ef2bb.cpe.net.cable.rogers.com (Postfix, from userid 1001) id 422CEC30; Mon, 15 Jul 2002 14:28:15 -0400 (EDT) Message-Id: <20020715182815.422CEC30@CPE0030ab0ef2bb.cpe.net.cable.rogers.com> Date: Mon, 15 Jul 2002 14:28:15 -0400 (EDT) From: Munish Chopra Reply-To: Munish Chopra To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: docs/40609: Add information about vchans to sound chapter in handbook Sender: owner-freebsd-doc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 40609 >Category: docs >Synopsis: Add information about vchans to sound chapter in handbook >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-doc >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Mon Jul 15 11:30:03 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Munish Chopra >Release: FreeBSD 5.0-CURRENT i386 >Organization: >Environment: System: FreeBSD CPE0030ab0ef2bb.cpe.net.cable.rogers.com 5.0-CURRENT FreeBSD 5.0-CURRENT #2: Sun Jul 14 20:26:50 EDT 2002 munish@CPE0030ab0ef2bb.cpe.net.cable.rogers.com:/usr/obj/usr/src/sys/ARCADIA i386 >Description: The Handbook has been lacking documentation of the vchans feature for quite a while now. Thanks to Orion Hodson for filling me in on the details. My apologies for the diff, I didn't check out the docs sources. It is to be applied to: doc/en_US.ISO8859-1/books/handbook/sound/chapter.sgml >How-To-Repeat: >Fix: --- chapter.sgml Mon Jul 15 13:43:02 2002 +++ vchans.sgml Mon Jul 15 14:22:44 2002 @@ -366,6 +366,36 @@ + + Utilizing Multiple Sound Sources + + It is often desirable to have multiple sources of sound that are able to + play simultaneously, such as when esound or + artsd don't support sharing of the sound device + with a certain application. + + FreeBSD lets you do this through `Virtual Sound Channels', which can be + set with the &man.sysctl.8; facility. Virtual channels allow you to multiplex + your sound card's playback channels by mixing sound in the kernel. + + To set the number of virtual channels, there are two sysctl knobs which, + if you are the root user, can be set like this: + + &prompt.root; sysctl hw.snd.pcm0.vchans=4 &prompt.root; + sysctl hw.snd.maxautovchans=4 + + hw.snd.pcm0.vchans is the number of vchans pcm0 has, + and is configurable once a device has been attached.hw.snd.maxautovchans + is the number of vchans a new audio device is given when it is + attached using &man.kldload.8;. Since the pcm module can be loaded independently + of the hardware drivers, hw.snd.maxautovchans can store how + many vchans any devices which are attached later will be given. + + If you are not using &man.devfs.5;, you will have to point your applications + at /dev/dsp0.x, where 'x' is 0 to 3 if + hw.snd.pcm.0.vchans is set to 4. On a system using devfs, the above + will automatically be allocated transparently to the user. + >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message