Re: Peak and averagePowerForChannel are nice, but what about the actual current power?
Re: Peak and averagePowerForChannel are nice, but what about the actual current power?
- Subject: Re: Peak and averagePowerForChannel are nice, but what about the actual current power?
- From: Brian Willoughby <email@hidden>
- Date: Fri, 15 May 2009 15:01:00 -0700
On May 15, 2009, at 11:50, email@hidden wrote:
I don't need sample-level granularity. 1/60th of a second is fine,
but I need the true level, not an averaged level, and the falloff
is longer than 1/60th of a second.
There is an inherent ambiguity in your request for the instantaneous
power for 1/60th of a second. There are hundreds, if not thousands
of 'instants' in that time period. You need to define whether you
want the largest instantaneous power during that period, or the
average, or the minimum, or the mean, or what. You certainly cannot
update your meter tens of thousands of times per second.
Your best bet is to get the full PCM audio data in your code and
compute your own power, using your own definition. You could design
your averaging so that no state is saved between buffers, and thus
there would be no falloff. That still isn't instantaneous power, but
it's an average power which does not span multiple buffers.
Brian Willoughby
Sound Consulting
P.S. What is this to be used for? Why do you seek instantaneous power?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden