From owner-freebsd-questions@FreeBSD.ORG Fri Jul 3 16:42:57 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 418C7106564A for ; Fri, 3 Jul 2009 16:42:57 +0000 (UTC) (envelope-from onemda@gmail.com) Received: from mail-fx0-f218.google.com (mail-fx0-f218.google.com [209.85.220.218]) by mx1.freebsd.org (Postfix) with ESMTP id BA97E8FC08 for ; Fri, 3 Jul 2009 16:42:56 +0000 (UTC) (envelope-from onemda@gmail.com) Received: by fxm18 with SMTP id 18so2046463fxm.43 for ; Fri, 03 Jul 2009 09:42:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=3UCP+4BE3v6ALGNiPNeV+jcwV51jbkk4sAR1uUzh5I0=; b=H5yUWmTC7/ncsQ1oN8SMD4rCjZ07CDww4TL+SRpJLRtfimRGg/RoAYSal6UFYbPPVh G3RgStQ+nM/QQ4oosAiS9uq3R7tjQgYMHtR4Ql0srpou8rgB1HBdyYjH4p2n+YjD0ycf BMyY0jO1rgP8IEyx5INH6zYvWvQnxoWfMUbU8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=xaQfB4PAFtR16P9PVR9Za+adrUwwS+RYxRGYxP2bwWBc93c92UO4dxWUyqIHyFO4Tn KGzS8WjmzsVEy2VLSGGVbuz7YI7lbpjng9CKBheRSbyjG7Cnm/hQcOZv9bzHdQi5ERHV 1j95u9Lcao5Ubq/L8mYP3UAifIk7jkPc27VTI= MIME-Version: 1.0 Received: by 10.204.118.134 with SMTP id v6mr1465754bkq.31.1246639375230; Fri, 03 Jul 2009 09:42:55 -0700 (PDT) In-Reply-To: References: <3a142e750907030646v68401986pf411d6e4fb8df273@mail.gmail.com> Date: Fri, 3 Jul 2009 16:42:55 +0000 Message-ID: <3a142e750907030942g20da1244q166a2673c0563b8a@mail.gmail.com> From: "Paul B. Mahol" To: Alexander Best Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: Problem with audio apps and mixer X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Jul 2009 16:42:57 -0000 On 7/3/09, Alexander Best wrote: > wow. thanks a bunch. this new feature of having each app use it's own volume > setting is pretty cool. however i think i'd like to preserve the volume > setting for each application and rather not have it reset. because i think > this feature takes the pid of the app and preserves the volume for the pid. Negative. Same application can open and close (different) channel(s) multiple times causing volume to be changed. You can get some patches on freebsd forums for mplayer and others ... > mplayer and mpd however seem to fork a new instance after a song change or > pausing etc. so so the volume get's reset while the app is still running. Nope, there is no *forking*. > i might be wrong, but i think there's a typo in this description of the > feature i'm looking for: > > hw.snd.vpc_autoreset (default=1, enabled) > 0=disable, 1=enable > Notes: By default, channel volume will be reset to 0db > relative after the channel is closed which means that any > changes will be lost and not preserved. Setting this to > '1' > will preserve the volume at the cost of possible > confusion > for other applications trying to re-open the same > device (see hw.snd.vpc_reset for possible 'panic' switch > to > fix the volumes). > > shouldn't it be: > > hw.snd.vpc_autoreset (default=1, enabled) > 0=disable, 1=enable > Notes: By default, channel volume will be reset to 0db > relative after the channel is closed which means that any > changes will be lost and not preserved. Setting this to > '0' > will preserve the volume at the cost of possible > confusion > for other applications trying to re-open the same > device (see hw.snd.vpc_reset for possible 'panic' switch > to > fix the volumes). > > ???? > > so after settings hw.snd.vpc_autoreset=0 each application uses it's own > volume > setting AND preserves it. just what i wanted. even better because i didn't > know this cool new feature existed. :) Doesn't work as expected because if you use multiple applications at same time silenced channel may and may not become extremly noise at any time - this is OSS and not FreeBSD fault and it is implemented as is in many if not all multimedia applications; so you may look again in freebsd forums and use ariff@ patch for mplayer. I don't remmember there was patch for mpd, but you can always ask politely. > thanks again for the hint. > > cheers. > alex > > Paul B. Mahol schrieb am 2009-07-03: >> On 7/3/09, Alexander Best wrote: >> > hi there, > >> > i've never had a problem to adjust the volume with audio apps like >> > mplayer >> > or >> > mpd. recently however i'm experiencing this strange behaviour. the >> > app's >> > volume doesn't match the volume that `mixer` reports. here's an >> > example: > >> CURRENT have VPC. >> You can completly disable such feature with this sysctl: >> hint.pcm.X.vpc (default=undefined, enabled) >> 0=disable, 1=enable >> Notes: The only place to enable/disable vpc. >> Enabling/Disabling requires driver reload. > >> here is explanation with more details: >> http://people.freebsd.org/~ariff/SOUND_4.TXT.html > > -- Paul