[Openal] EFX Clarifications
Daniel PEACOCK
dpeacock at creativelabs.com
Fri Sep 12 04:05:24 PDT 2008
Hi Christopher,
As you may have realized already, the Creative EFX extension is built on
top of EAX technology. The I3DL2 guidelines are very similar to the
features of EAX 2 and EAX 3 so that can be a good source of information (
http://www.iasig.org/pubs/3dl2v1a.pdf )
> My first questions relate to the low-pass filter, and in particular
> how the GainHF property relates to the construction of the filter.
The GainHF parameter specifies the gain at the reference high frequency
(5KHz). It is done in this manner so that individual implementations can
select what type of filter is used (e.g. one-pole or two-pole). It enables
products to differentiate themselves in terms of quality and performance.
> 1. Is the cut-off frequency variable?
Not in EFX.
> 2. Given a variable cut-off frequency, is the calculation of the
> cut-off dependent on the type of filter used?
> 3. Assuming a simple filter (or no filter type-dependence), what
> would the formula for calculating the cut-off given the GainHF value
> and a reference frequency (5 KHz) look like?
See http://www.iasig.org/pubs/3dl2v1a.pdf for details about the transfer
function for a one-pole filter and how it relates to the reference high
frequency and sample rate.
> My second questions relate to the calculations involved in air
absorption.
>
> 1. Does the air absorption result apply to the source's filter via
> the GainHF property?
It is possible (and desirable) to combine all the parameters that affect
the gain at high frequencies together before applying the low pass filter.
> 2. If so, is it applied as a multiplier (GainHF *= AirAbsorption)?
If your parameters are in millibels they need to be added together, if they
are in linear levels they should be multiplied.
> 3. Is the following calculation correct for obtaining AirAbsorption?
>
> AirAbsorption = (AirAbsorptionFactor * AIR_ABSORPTION_GAINHF) ^
> (distance * METERS_PER_UNIT)
>
> Where AIR_ABSORPTION_GAINHF is 0.994 and METERS_PER_UNIT the
> multiplier that converts between distance units and meters.
>
> 4. If so, why can AirAbsorptionFactor be greater than 1, when such
> values produce anomalous results?
> 5. If not, what is the correct application of AirAbsorptionFactor to
0.994?
It is easier to convert all the linear gains to millibels and then use this
formula ...
lSourceAirAbsorptionHF = AirAbsorptionHF * SourceAirAbsorptionFactor *
DistanceFactor * (distance - reference_distance)
if (lSourceAirAbsorptionHF > 0)
lSourceAirAbsorptionHF = 0
The default AirAbsorptionHF in millibels is -5mB. The above formula is for
the Inverse Distance Clamped model.
> Finally, I'd like to report some possible problems I'm seeing in
> EFX10Show with the Generic Hardware device on Windows.
What soundcard do you have installed? Does it have up-to-date drivers.
> 1. Stereo sources won't send anything to a reverb effect. Is this
> expected behaviour?
Depends on the soundcard you have installed. If the device supports EAX 5
(hardware based X-Fi cards) it should work. It should also work on most
EAX 4 (hardware based Audigy cards).
> 2. Stereo sources aren't effected by dry gain. Is this expected
behaviour?
If you are referring to filter gain then the answer is same as 1. Normal
Source Gain should work fine.
> 3. If a stereo source is created prior to loading the reverb effect
> into the effect slot, even mono sources won't send anything to it.
> This seems like a bug, can anyone else reproduce this?
Hmmm - not sure about this one. What are the steps to reproduce the
problem?
> 4. Air absorption is supposed to effect the dry path of the source.
> However changing the air absorption factor and distance between
> source and listener does not produce any change in filtering. Does
> this work for anyone?
The affect is quite subtle - especially with the default value of
AirAbsorptionHF - so you could try increasing the value of that and seeing
if that make a difference.
Dan
Creative Labs
More information about the Openal
mailing list