From owner-freebsd-multimedia Wed Aug 22 23:58:33 2001 Delivered-To: freebsd-multimedia@freebsd.org Received: from precipice.4gh.net (precipice.4gh.net [63.73.57.6]) by hub.freebsd.org (Postfix) with ESMTP id 1753937B405 for ; Wed, 22 Aug 2001 23:58:21 -0700 (PDT) (envelope-from stuartb@4gh.net) Received: from localhost (stuartb@localhost) by precipice.4gh.net (8.9.3/8.9.3) with ESMTP id CAA15720; Thu, 23 Aug 2001 02:58:12 -0400 (EDT) (envelope-from stuartb@4gh.net) Date: Thu, 23 Aug 2001 02:58:12 -0400 (EDT) From: Stuart Barkley To: Cc: The Anarcat , Subject: Re: precisions of pcm driver problems and update of rec program In-Reply-To: Message-ID: <20010823021827.B12745-100000@precipice.4gh.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Thu, 23 Aug 2001 Juha.Nurmela@quicknet.inet.fi wrote: > Have you guys ever wished the sound-device would provide a > VU-level indicator for the generic mixers ? Without interfering > with a recorder process. I hadn't thought about it this way, but this is one reason I've been playing around with my own record program. It does make some sense to include if you can handle that last condition. > It could sample randomly over 10...50% of samples when rates are > high, or whatever, if the extra load is bothersome (and obviously > only be effective when the /dev/pcm/vumeter is open). I wonder how > this kind of additional device would fit in pcm driver. I haven't really been into the driver code, but it could be a performance issue, particularly if the driver needed to do any byte order conversions or other manipulations on the data. Perhaps this function does better belong in the record program. I've looked at dap and it has a record level meter. It has no scale information so I've found it pretty useless for real use. > There's a audio spectrum visualizer too, which I once wrote for > Xlib and fftw. Don't know if it's any good, but has been a handy > tool for miscellaneous twoway radio adjustments. > http://personal.inet.fi/koti/juha.nurmela/ascope5.c > (scope it is not, false name, yes) YES! This looks to be pretty close to what I'm thinking about (including an X interface which I was dreading to need to deal with). About the only thing missing is log scales for both frequency and level. Level is pretty easy, just dB = log10(level)*20.0. I'm not sure how to handle the frequency scale and haven't researched that yet. It might be necessary to split the frequency range into bins with several of the FFT values in each one. I'm not sure if you would average or add the values. It might be that you need to total the squares of the values (and then just take log10(sum of squares)*10.0). Thanks, Stuart -- I've never been lost; I was once bewildered for three days, but never lost! -- Daniel Boone To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message