All the Effect interfaces are method calls. However, the Effects Framework relies on the MMF Controller Framework, which has a client-server boundary. When the client issues requests, the requests and data are encapsulated into messages that can be passed across the client-server boundary. Synchronous method calls block the client’s thread until they return, but most of the client’s method calls do not require a message to be sent. For the ones that do generate a message, they are completed immediately when possible.
Figure 1: Interface class structure
All the Effect APIs have the same structure. Each effect has an observer interface that must be realized by an observer class if the client is interested in receiving notification events from the effect. The observer class is registered with the effect it is interested in receiving events.
The client creates an effect instance by using one of the NewL() methods in the effect subclass. See Detailed Description for a detail description of each effect subclasses.
Each effect is associated with an audio stream. This association with the audio stream is made when the effect is created by passing in the MDA utility that controls the audio stream in the effect’s NewL method. The client application should create the effect after it has initialized the MDA audio utility, but before it starts playing the audio. Conversely, the effect should be deleted before the MDA utility is deleted.
By default, an effect is disabled when it is created. After it has been created, it is up to the application to configure the effect and then enable it. Some effects can be configured and enabled when they are constructed.
To configure an effect, the application calls the appropriate set methods on the effect. After the effect is configured, the application then calls the ApplyL() method on the effect to apply the new settings. Settings are automatically applied when they are enabled or disabled.
Effect processing is started by calling the EnableL() method on the effect. Enabling an effect that is already enabled does nothing. To stop processing an effect, the DisableL() method on the effect is called. Disabling an effect that is already disabled does nothing.
It is possible for an application to update the settings of an effect when the audio is playing, but it is dependent on the specific hardware and drivers of a device whether or not these changes will have an effect.
Due to hardware limitations, it is possible that some hardware platforms can only support a limited number of instances of a specific effect. In this case, the effect will no longer be applied to the lowest priority audio streams. By default, the audio drivers will continue playing the audio streams without the effect applied. However, if the application does not want the audio to play without the effect applied, it can call the Enforce method on the effect. In this case, the audio will pre-empt the audio stream through the utility that controls that audio stream with the error KErrEnforcedEffectPreempted.
Depending on hardware capability, it is also possible to have one setting for an effect type that is being applied to multiple streams. In this case, only the highest priority audio stream will be allowed to modify the effect parameters. In the case where the priorities of the audio streams are the same, the application that set up the effect last will be the one that is allowed to modify the effect parameters. The applications that lose the right to update the effect will be notified through the observer interface with the event KLostUpdateRights. When an application regains the right to control the effects settings, it will be notified through the observer interface with the event KGaindUpdateRights. By default, all effects will initially have the update rights.
Effect processing is optional. In the case where it is not supported, the NewL() methods for the effects will leave with KErrNotSupported. Even if effect processing is supported, it is not guaranteed that every method of an effect will be implemented. In this case, unsupported operations on the effect will be ignored by the audio system.
Currently, Tone and Stream Utilities do not support custom interfaces. NewLs with custom interfaces as arguments will leave with KErrNotSupported.
The leave mechanism of the Symbian OS environment is used to handle exception situations. Each leaving method has a list of possible leave codes and the meaning of the code. The client should TRAP the leaving methods and handle them appropriately or leave it up to a higher-level TRAP harness.
A number of error conditions can occur when the Effect APIs are used. Each Effect API has different error conditions. Refer to the Detailed Description for the specific effect error conditions. The rrrors common to all effects are listed in the table below.
Error code | Explanation |
KErrAccessDenied | Attempting to apply effect settings when the effect has lost update rights. |
KErrArgument | Attempting to set an effect setting to an invalid value. |
KErrNoMemory | Insufficient amount of memory available to carry out the operation. |
KErrNotSupported< | The specified effect is not supported during effect creation process. |
For each effect interface object created, there will be two additional support objects and an adaption custom interface effect object created. The size of the support object depends on the effect type. Some effects have larger data structures than others but, in general, each effect object will require an estimated 2 Kbytes of RAM.
The basic functionality of an Effect API can be extended, but this will introduce binary compatibility issues if the interface class is changed. However, new effect classes with additional functionality can be created through derivation.
This example shows how an equalizer effect can be used by the client audio application.
Prerequisites:
An MDA Player utility has been created.
Note: The MDA Utility (a player utility in this example) should not be deleted before deleting the effect object (equalizer effect in this example).
The following subsections illustrate the stages of an equalizer effect lifecycle. All effects have similar sequences while their operations and events may be different.
The equalizer effect is created using the usual NewL() method. The client may register an observer with the effect. The effect is now ready to be used.
Figure 2: Creating the effect
After the creation, the equalizer object assumes an initial state. The initial equalizer value varies and is set by the underlying audio system. Settings are made using one of the available set methods on the object.
Here, the preset values in the equalizer are checked and the values are changed. At this point, the equalizer preset has not been applied. It is possible to change the value many times before application but, unless the presets are applied, they will not take effect.
Figure 3: Changing the effect settings
Effect settings are applied in one of two ways: Enable() or ApplyL().
The Enable() method must be used to enable the effect if it is disabled. Initially, all effects are disabled. Enabling will cause the effect settings to be applied. After the effect is enabled, new settings are applied by using the ApplyL() method. The following figure shows a new setting being applied after the effect is enabled.
Figure 4: Applying the effect settings
Events may occur spontaneously during the lifetime of the effect. These events are reported to the client through the EffectChange() callback. Clients should expect to receive event notifications after successful registration. See Creating the Effect section for the registration sequence. If the client does not want to receive further event notifications, use the UnregisterObserver() method. It is not advisable to not monitor events if the effect is enabled.
Figure 5: Spontaneous events
The sequence in The figure above follows the sequences in Changing the Effect Settings and Applying the Effect Settings. When attempting to apply the effect on the stream, the effect cannot be applied. In this case, the effect does not have update rights. Additionally, because the client has indicated that the effect has to be enforced, the stream is pre-empted as well.
An effect can be disabled using the DisableL() method. After disabling, the effect can be removed by deleting the object. The client can also delete the effect without disabling it first.
Figure 6: Disabling and removing the effect
This section describes the classes and methods in the Effects Framework.
This abstract class is a generalization of all effects and defines properties and operation that are common for all effects.
Figure 7: CAudioEffect
Headers:
AudioEffectBase.H, AudioEffectData.H, MAudioEffectObserver.H
Library:
AudioEffect.DLL
virtual void ApplyL() = 0;
Applies updated settings to the effect. Apply is automatically called when the effect goes from disabled to enabled or vice versa. It is not called when Enable is called and the effect is already enabled. This method will block the client’s thread.
Arguments:
None.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to apply settings due to memory errors
KErrAccessDenied: unable to apply settings due to loss of update rights
virtual void DisableL() = 0;
This method is used for disabling the effect. If the effect is already disabled, any call to this method is ignored.
Arguments:
None.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrAccessDenied: unable to disable effect due to lost of update rights
virtual void EnableL() = 0;
This method is used for enabling the effect. If the effect is already enabled, any call to this method is ignored.
Arguments:
None.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrAccessDenied: unable to enable the effect due to loss of update rights
virtual void EnforceL(TBool aEnforced) = 0;
Defines whether the effect is mandatory. When this is set to Etrue, the audio stream will not be processed unless the audio platform can add this effect. If this is set to Efalse, the audio platform will process the audio stream even if it cannot add the effect.
Arguments:
TBool aEnforced: Set to ETrue if the effect should be enforced, otherwise EFalse. EFalse is the default value.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrAccessDenied: unable to enable the effect due to loss of update rights
virtual TBool HaveUpdateRights() const;
A client can lose update rights in some hardware platforms where only a limited number of instances of an effect can exist at the same time. When there is a greater number of requested instances than supported, that audio drivers will remove the update rights of some of the instances temporarily. When an effect instance has lost update rights, the user can still change the effect settings, but any calls to apply the settings will be deferred until update rights are regained.
Arguments:
None.
Returns:
ETrue if this object currently has rights to update the settings of this effect, otherwise EFalse.
virtual TBool IsEnabled() const;
Used by a client to determine if the effect is enabled.
Arguments:
None.
Returns:
ETrue if the effect is enabled, otherwise EFalse.
virtual TBool IsEnforced() const;
Used by a client to determine if the effect is set as enforced.
Arguments:
None.
Returns:
ETrue if the effect is enforced, otherwise EFalse.
virtual void RegisterObserverL(MAudioEffectObserver& aObserver);
Adds an observer that implements MAudioEffectObserver. Observers will be notified when the effect changes.
Arguments:
MAudioEffectObserver& aObserver: A reference to the observer.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrAlreadyExists: attempting to register an observer that has already been registered.
virtual TUid Uid() const = 0;
Used by a client to fetch the unique identifier associated with the effect.
Arguments:
None.
Returns:
The unique identifier.
virtual void UnRegisterObserver(MAudioEffectObserver& aObserver);
Removes the specified observer from an effect.
Arguments:
MAudioEffectObserver& aObserver: A reference to the observer.
Returns:
None.
This abstract class is a generalization of the observer classes for all audio effects. Individual effects can extend this to add needed observer methods.
virtual void EffectChanged(const CAudioEffect* aObservedEffect, TUint8 aEvent) 0;
Invoked by the audio effect object when the status of the audio effect has changed.
Arguments:
CAudioEffect* aObservedEffect: The effect object that has changed.
TUint8 aEvent: Defines the event ID for the effect that has changed.
Returns:
None.
This class is used by an audio application for controlling bass boost. It is derive from CAudioEffect (see CAudioEffect).
Figure 8: CBassBoost
Headers:
BassBoostEffect.H, BassBoostEffectData.H, MBassBoostEffectObserver.H
Library:
BassBosotEffect.DLL
CBassBoost* NewL(CMMFDevSound& aDevSound, TBool aEnable = Efalse);
A static constructor that creates a bass boost object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(CMdaAudioConvertUtility& aUtility, TBool aEnable = Efalse);
A static constructor that creates a bass boost object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(CMdaAudioInputStream& aUtility, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(CMdaAudioOutputStream& aUtility, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(CMdaAudioPlayerUtility& aUtility, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(CMdaAudioToneUtility& aUtility, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialBass boost: The bass boost value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(MCustomCommand& aUtility, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CBassBoost* NewL(MCustomInterface& aCustomInterface, TBool aEnable = EFalse);
A static constructor that creates a bass boost object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to CBassBoost.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
TUint8 BassBoostLevel() const;
Gets the bass boost level setting.
Arguments:
None.
Returns:
The bass boost level.
void SetBassBoostLevelL(TUint8 aLevel);
Sets the bass boost level.
Arguments:
TUint8 aLevel: The bass boost level ranges from 0-100, where 0 is none and 100 is maximum bass boost.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
This abstract class is a generalization of the bass boost observer. It defines the possible events that are specific to the bass boost effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver).
Figure 9: MBassBoostObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver).
This class is used by audio applications for controlling doppler. It is derived from CAudioEffect (see CAudioEffect).
Figure 10: CDoppler
Headers:
DopplerEffect.H, DopplerEffectData.H, MDopplerEffectObserver.H
Library:
DopplerEffect.DLL
CDoppler* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a doppler object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(MCustomCommand& aUtility);
A static constructor that creates a doppler object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDoppler* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a doppler object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CDoppler.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
void CartesianVelocity(TInt32& aX, TInt32& aY, TInt32& aZ);
Gets the velocity’s Cartesian settings.
Arguments:
TInt32& aX : X direction speed in mm/s. Referenced memory will contain the value.
TInt32& aY : Y direction speed in mm/s. Referenced memory will contain the value.
TInt32& aZ: Z direction speed in mm/s. Referenced memory will contain the value.
Returns:
None.
TUint32 Factor() const;
Gets the current factor setting value.
Arguments:
None.
Returns:
The current factor setting value.
TUint32 FactorMax() const;
Gets the factor setting maximum value.
Arguments:
None.
Returns:
The factor setting maximum value.
void SetCartesianVelocityL(TInt32 aX, TInt32 aY, TInt32 aZ);
Sets the velocity in Cartesian coordinates of the sound source with respect to the listener.
Arguments:
TInt32 aX: X direction speed in mm/s.
TInt32 aY: Y direction speed in mm/s.
TInt32 aZ: Z direction speed in mm/s.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetFactorL(TUint32 aFactor);
Sets the multiplier factor.
Arguments:
TUint32 aFactor: A factor value in hundredths that ranges from 0 to FactorMax(), where 100 corresponds to 1.00, 200 corresponds to 2.00, etc. The factor is a multiplier that either exaggerates the doppler effect or reduces it.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range.
void SetSphericalVelocityL(TInt32 aAzimuth, TInt32 aElevation, TInt32 aRadius);
Sets the velocity in spherical coordinates of the sound source with respect to the listener.
Arguments:
TInt32 aAzimuth: The Azimuth (thousandths of radians)
TInt32 aElevation: The elevation (thousandths of radians)
TInt32 aRadius: The radius (in millimeters)
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SphericalVelocity(TInt32& aAzimuth, TInt32& aElevation, TInt32& aRadius);
Gets the velocity’s Cartesian settings.
Arguments:
TInt32& aAzimuth: The Azimuth (thousandths of radians). Referenced memory will contain the value.
TInt32& aElevation: The elevation (thousandths of radians). Referenced memory will contain the value.
TInt32& aRadius : The radius (in millimeters). Referenced memory will contain the value.
Returns:
None.
This abstract class is a generalization of the doppler observer. It defines the possible events that are specific to the doppler effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 11: MDopplerObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling audio equalization. It is derived from CAudioEffect (see CAudioEffect section).
Figure 12: CAudioEqualizer
Headers:
EqualizerEffect.H, EqualizerEffectData.H, MEqualizerEffectObserver.H
Library:
EqualizerEffect.DLL
CAudioEqualizer* NewL(CMMFDevSound& aDevSound);
A static constructor that creates an audio equalizer object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates an audio equalizer object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates an audio equalizer object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates an audio equalizer object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates an audio equalizer object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates an audio equalizer object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates an audio equalizer object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
TInt8 aInitialDoppler: The audio equalizer value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(MCustomCommand& aUtility);
A static constructor that creates an audio equalizer object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizer* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates an audio equalizer object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to a CAudioEqualizer object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
TInt32 BandLevel(TUint8 aBand) const;
Gets the band level in mB for the specified band.
Arguments:
TUint8 aBand: The frequency band
Returns:
The level in mB for the specified band, otherwise KErrArgument if aBand is invalid.
TInt32 BandWidth(TUint8 aBand) const;
Gets the bandwidth in Hz for the specified band.
Arguments:
TUint8 aBand: The frequency band
Returns:
The bandwidth in Hz for the specified band, otherwise KErrArgument if aBand is invalid.
TInt32 CenterFrequency(TUint8 aBand) const;
Gets the center frequency in Hz the specified band.
Arguments:
TUint8 aBand: The frequency band
Returns:
The center frequency in Hz for the specified band, otherwise KErrArgument if aBand is invalid.
TInt32 CrossoverFrequency(TUint8 aBand) const;
Gets the cross-over frequency between the given frequency band (aBand) and the next band.
Arguments:
TUint8 aBand: The frequency band
Returns:
The crossover frequency in Hz for the specified band, otherwise KErrArgument if aBand is invalid.
void DbLevelLimits(TUint32& aMin, TUint32& aMax);
Gets the range in mB for the equalizer.
Arguments:
TUint32& aMin: The minimum dB. Referenced memory will contain the value.
TUint32& aMax: The maximum dB. Referenced memory will contain the value.
Returns:
None.
TUint8 NumberOfBands() const;
Gets the number of equalizer bands.
Arguments:
None.
Returns:
The number of equalizer bands.
void SetBandLevelL(TInt8 aBand, TInt32 aLevel);
Sets the equalizer band level value in mB, ranging from Min to Max.
Arguments:
TInt8 aBand: The frequency band
TInt32 aLevel: The band level in dB, ranges from DbLevelLimits().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: one or more argument values are out of range or invalid.
This abstract class is a generalization of the audio equalizer observer. It defines the possible events that are specific to the audio equalizer effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 13: MAudioEqualizerObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling loudness. It is derived from CAudioEffect (see CAudioEffect section).
Figure 14: CLoudness
Headers:
LoudnessEffect.H, LoudnessEffectData.H, LoudnessEffectObserver.H
Library:
LoudnessEffect.DLL
CLoudness* NewL(CMMFDevSound& aDevSound, TBool aEnable = Efalse);
A static constructor that creates a loudness object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(CMdaAudioConvertUtility& aUtility, TBool aEnable = Efalse);
A static constructor that creates a loudness object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(CMdaAudioInputStream& aUtility, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(CMdaAudioOutputStream& aUtility, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(CMdaAudioPlayerUtility& aUtility, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(CMdaAudioToneUtility& aUtility, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(MCustomCommand& aUtility, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CLoudness* NewL(MCustomInterface& aCustomInterface, TBool aEnable = EFalse);
A static constructor that creates a loudness object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
Returns:
A pointer to a CLoudness object.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
This abstract class is a generalization of the loudness observer. It defines the possible events that are specific to the loudness effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 15: MLoudnessObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling distance attenuation. It is derived from CAudioEffect (see CAudioEffect section).
Figure 16: CDistanceAttenuation
Headers:
DistanceAttenuationEffect.H, DistanceAttenuationEffectData.H, MdistanceAttenuationEffectObserver.H
Library:
DistanceAttenuationEffect.DLL
CDistanceAttenuation* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a distance attenuation object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistance attenuation* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a distance attenuation object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistanceAttenuation* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a distance attenuation object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistanceAttenuation* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a distance attenuation object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistanceAttenuation* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a distance attenuation object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistanceAttenuation* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a distance attenuation object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: Set to ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistanceAttenuation* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a distance attenuation object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CDistanceAttenuation* NewL(MCustomCommand& aUtility);
A static constructor that creates a distance attenuation object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CDistanceAttenuation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
void DistanceAttenuation(TInt32& aRMin, TInt32& aRMax, TBool& aMuteAfterMax, TUint32& aRollOffFactor, TUint32& aRoomRollOffFactor);
Gets the distance attenuation parameters. The referenced memory will contain the value.
Arguments:
TInt32& aRMin : The source to listener distance in mm below which the sound level is a constant.
TInt32& aRMax: The source to listener distance in mm above which the sound level is a constant or zero.
TBool& aMuteAfterMax: Indicates whether or not the sound is muted beyond Rmax.
TUint32& aRollOffFactor: The multiplier factor to source-listener distance in hundredths, where 100 corresponds to 1.00, 200 corresponds to 2.00, etc.
TUint32& aRoomRollOffFactor: The multiplier factor to source-listener distance for Room effect in hundredths, where 100 corresponds to 1.00, 200 corresponds to 2.00, etc.
Returns:
None.
void RollOffFactorMax(TUint32& aRollOfFactorMax);
Gets the roll off factor maximum value. The referenced memory will contain the value.
Arguments:
TUint32& aRollOffFactorMax: The maximum multiplier factor to source-listener distance in hundredths, where 100 corresponds to 1.00, 200 corresponds to 2.00, etc.
Returns:
None.
void RollOffFactorMax(TUint32& aRoomRollOffFactorMax);
Gets the roll off factor maximum value. The referenced memory will contain the value.
Arguments:
TUint32& aRoomRollOffFactorMax: The maximum multiplier factor to source-listener distance for Room effect.
Returns:
None.
void SetDistanceAttenuationL(TInt32 aRMin, TInt32 aRMax, TBool aMuteAfterMax, TUint32 aRollOffFactor, TUint32 aRoomRollOffFactor);
Sets the distance attenuation parameters.
Arguments:
TInt32 aRMin: The source to listener distance in mm below which the sound level is a constant, its value should be greater than or equal to 1 mm.
TInt32 aRMax: The source to listener distance in mm above which the sound level is a constant or zero, its value should be greater than or equal to aRMin.
TBool aMuteAfterMax: Indicates whether or not the sound is muted beyond Rmax.
TUint32 aRollOffFactor: The multiplier factor to source-listener distance in hundredths, where 100 corresponds to 1.00, 200 corresponds to 2.00, etc.
TUint32 aRoomRollOffFactor: The multiplier factor to source-listener distance for Room effect in hundredths, where 100 corresponds to 1.00, 200 corresponds to 2.00, etc.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: one or more argument values are out of range or invalid.
This abstract class is a generalization of the distance attenuation observer. It defines the possible events that are specific to the distance attenuation effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 17: MDistanceAttenuationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This abstract class defines the methods needed for all location effects. It is derived from CAudioEffect (see CAudioEffect section).
Figure 18: CLocation
Headers:
LocationBase.H
Library:
LocationEffect.DLL
void LocationCartesian(TInt32& aX, TInt32& aY, TInt32& aZ);
Gets the Cartesian coordinates for the location of the position.
Arguments:
TInt32& aX: X-coordinate value in millimeters. Referenced memory will contain the value.
TInt32& aY: Y-coordinate value in millimeters. Referenced memory will contain the value.
TInt32& aZ: Z-coordinate value in millimeters. Referenced memory will contain the value.
Returns:
None.
void LocationSpherical(TInt32& aAzimuth, TInt32& aElevation, TInt32& aRadius);
Gets the spherical coordinates for the location of the position.
Arguments:
TInt32& aAzimuth: The Azimuth (in thousandths of radians). Referenced memory will contain the value.
TInt32& aElevation: The elevation (in thousandths of radians). Referenced memory will contain the value.
TInt32& aRadius: The radius (in millimeters). Referenced memory will contain the value.
Returns:
None.
void SetLocationCartesianL(TInt32 aX, TInt32 aY, TInt32 aZ);
Sets the Cartesian coordinates for the location of the position.
Arguments:
TInt32 aX: X-coordinate value in millimeters.
TInt32 aY: Y-coordinate value in millimeters.
TInt32 aZ: Z-coordinate value in millimeters.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetLocationSphericalL(TInt32 aAzimuth, TInt32 aElevation, TInt32 aRadius);
Sets the spherical coordinates for the location of the position.
Arguments:
TInt32 aAzimuth: The Azimuth (in thousandths of radians)
TInt32 aElevation: The elevation (in thousandths of radians)
TInt32 aRadius: The radius (in millimeters)
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
This abstract class is a generalization of the location observer. It defines the possible events that are specific to the location effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 19: MLocationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling the audio listener’s location. This should only be used for applications needing 3D audio, and may be limited by the system. It is derived from CLocation (see CLocation section).
Figure 20: CListenerLocation
Headers:
ListenerLocationEffect.H, ListenerLocationEffectData.H, MListenerLocationEffectObserver.H
Library:
ListenerLocationEffect.DLL
CListenerLocation* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a listener location object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a doppler object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a listener location object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a listener location object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a listener location object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a listener location object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a listener location object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(MCustomCommand& aUtility);
A static constructor that creates a listener location object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerLocation* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a listener location object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CListenerLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
This abstract class is a generalization of the listener location observer. It defines the possible events that are specific to the listener location effect. It is derived from MLocationObserver (see MLocationObserver section).
Figure 21: MListenerLocationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling the audio source’s location. This should only be used for applications needing 3D audio, and may be limited by the system. It is derived from CLocation (see CLocation section).
Figure 22: CSourceLocation
Headers:
SourceLocationEffect.H, SourceLocationEffectData.H, MSourceLocationEffectObserver.H
Library:
SourceLocationEffect.DLL
CSourceLocation* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a listener location object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a source location object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a source location object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a source location object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a source location object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a source location object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a source location object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(MCustomCommand& aUtility);
A static constructor that creates a source location object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceLocation* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a source location object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CSourceLocation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
This abstract class is a generalization of the source location observer. It defines the possible events that are specific to the source location effect. It is derived from MLocationObserver (see MLocationObserver section).
Figure 23: MSourceLocationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This abstract class defines the methods needed for all location effects. It is derived from CAudioEffect (see CAudioEffect section).
Figure 24: COrientation
Headers:
OrientationBase.H
Library:
OrientationEffect.DLL
void Orientation(TInt32& aHeading, TInt32& aPitch, TInt32& aRoll);
Gets the orientation values for the position.
Arguments:
TInt32& aHeading: The heading value (in thousandths of radians). Referenced memory will contain the value.
TInt32& aPitch: The pitch value (in thousandths of radians). Referenced memory will contain the value.
TInt32& aRoll: The roll value (in thousandths of radians). Referenced memory will contain the value.
Returns:
None.
void OrientationVectors(TInt32& aFrontX, TInt32& aFrontY, TInt32& aFrontZ, TInt32& aAboveX, TInt32& aAboveY, TInt32& aAboveZ);
Gets the orientation vectors for the position.
Arguments:
TInt32& aFrontX: X-component of the front vector. Referenced memory will contain the value.
TInt32& aFrontY: Y-component of the front vector. Referenced memory will contain the value.
TInt32& aFrontZ: Z-component of the front vector. Referenced memory will contain the value.
TInt32& aAboveX: X-component of the above vector. Referenced memory will contain the value.
TInt32& aABoveY: Y-component of the above vector. Referenced memory will contain the value.
TInt32& aAboveZ: Z-component of the above vector. Referenced memory will contain the value.
Returns:
None.
void SetOrientationL(TInt32 aHeading, TInt32 aPitch, TInt32 aRoll);
Sets the orientation values for the position.
Arguments:
TInt32 aHeading: The heading value (in thousandths of radians).
TInt32 aPitch: The pitch value (in thousandths of radians).
TInt32 aRoll: The roll value (in thousandths of radians).
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetOrientationVectorsL(TInt32 aFrontX, TInt32 aFrontY, TInt32 aFrontZ, TInt32 aAboveX, TInt32 aAboveY, TInt32 aAboveZ);
Gets the orientation vectors for the position.
Arguments:
TInt32 aFrontX: X-component of the front vector.
TInt32 aFrontY: Y-component of the front vector.
TInt32 aFrontZ: Z-component of the front vector.
TInt32 aAboveX: X-component of the above vector.
TInt32 aABoveY: Y-component of the above vector.
TInt32 aAboveZ: Z-component of the above vector.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
This abstract class is a generalization of the orientation observer. It defines the possible events that are specific to the orientation effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 25: MOrientationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling the listener orientation. This should only be used for applications needing 3D audio, and may be limited by the system. It is derived from COrientation (see COrientation section).
Figure 26: CListenerOrientation
Headers:
ListenerOrientationEffect.H, ListenerOrientationEffectData.H, MListenerOrientationEffectObserver.H
Library:
OrientationLocationEffect.DLL
CListenerOrientation* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a listener orientation object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a listener orientation object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a listener orientation object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a listener orientation object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a listener orientation object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a listener orientation object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a listener orientation object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(MCustomCommand& aUtility);
A static constructor that creates a listener orientation object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CListenerOrientation* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a listener orientation object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CListenerOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
This abstract class is a generalization of the listener orientation observer. It defines the possible events that are specific to the listener orientation effect. It is derived from MOrientationObserver (see MOrientationObserver section).
Figure 27: MListenerOrientationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling the source orientation. This should only be used for applications needing 3D audio, and may be limited by the system. It is derived from COrientation (see COrientation section).
Figure 28: CSourceOrientation
Headers:
SourceOrientationEffect.H, SourceOrientationEffectData.H, MSourceOrientationEffectObserver.H
Library:
SourceOrientationEffect.DLL
CSourceOrientation* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a source orientation object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a source orientation object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a source orientation object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a source orientation object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a source orientation object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a source orientation object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a source orientation object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(MCustomCommand& aUtility);
A static constructor that creates a source orientation object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CSourceOrientation* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a source orientation object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CSourceOrientation.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
This abstract class is a generalization of the source orientation observer. It defines the possible events that are specific to the source orientation effect. It is derived from MOrientationObserver (see MOrientationObserver section).
Figure 29: MSourceOrientationObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling environmental reverb. It is derived from CAudioEffect (see CAudioEffect section).
Figure 30: CEnvironmentalReverb
Headers:
EnvironmentalReverbEffect.H, EnvironmentalReverbEffectData.H, MEnvironmentalReverbEffectObserver.H
Library:
EnvironmentalReverbEffect.DLL
CEnvironmentalReverb* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a reverb object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a reverb object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a reverb object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a reverb object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a reverb object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(CMdaAudioRecordUtility& aUtility, TBool aRecordStream);
A static constructor that creates a reverb object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
TBool aRecordStream: ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a reverb object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(MCustomCommand& aUtility);
A static constructor that creates a reverb object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CEnvironmentalReverb* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a reverb object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CEnvironmentalReverb.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
TUint32 DecayHfRatio() const;
Gets the decay HF Ratio in hundredths.
Arguments:
None.
Returns:
The decay HF Ratio in hundredths.
void DecayHFRatioRange(TUint32& aMin, TUint32& aMax);
Gets the reverb decay HF Ratio minimum and maximum in hundredths.
Arguments:
TUint32& aMin: The minimum decay HF Ratio. Referenced memory will contain the value.
TUint32& aMax: The maximum decay HF Ratio. Referenced memory will contain the value.
Returns:
None.
TUint32 DecayTime() const;
Gets the decay time in milliseconds.
Arguments:
None.
Returns:
The decay time in milliseconds.
void DecayTimeRange(TUint32& aMin, TUint32& aMax);
Gets the allowable reverb decay time range in milliseconds.
Arguments:
TInt32& aMin: The minimum decay time in milliseconds. Referenced memory will contain the value.
TInt32& aMax: The maximum decay time in milliseconds. Referenced memory will contain the value.
Returns:
The decay time maximum in milliseconds.
TUint32 DelayMax() const;
Gets the maximum decay time in milliseconds. ReverbDelayMax() or the ReflectionsDelayMax() must be <= DelayMax(). Also ReflectionsDelayMax() should be less than ReverbDelayMax()
Arguments:
Returns:
The maximum delay time in milliseconds.
TUint32 Density() const;
Gets the current density value as a percentage in hundredths.
Arguments:
None.
Returns:
The density percentage in hundredths.
TUint32 Diffusion() const;
Gets the current diffusion value as a percentage in hundredths.
Arguments:
None.
Returns:
The diffusion percentage in hundredths.
TUint32 RefectionsDelay() const;
Gets the reverb reflections delay in milliseconds.
Arguments:
None.
Returns:
The reflections delay in milliseconds.
TUint32 ReflectionsDelayMax() const;
Gets the reverb reflections delay maximum in milliseconds.
Arguments:
None.
Returns:
The delay maximum in milliseconds.
TInt32 ReflectionsLevel() const;
Gets the reverb reflections level in mB.
Arguments:
None.
Returns:
The reverb reflections level in mB.
void ReflectionsLevelRange(TInt32& aMin, TInt32& aMax);
Gets the reverb reflections level in mB.
Arguments:
TInt32& aMin: The minimum reflections level. Referenced memory will contain the value.
TInt32& aMax: The maximum reflections level. Referenced memory will contain the value.
Returns:
None.
TUint32 ReverbDelay() const;
Gets the reverb delay in milliseconds.
Arguments:
None.
Returns:
The reverb delay in milliseconds.
TUint32 ReverbDelayMax() const;
Gets the reverb delay maximum in milliseconds.
Arguments:
None.
Returns:
The reverb delay maximum in milliseconds.
TInt32 ReverbLevel() const;
Gets the current reverb level in mB.
Arguments:
None.
Returns:
The current reverb level.
void ReverbLevelRange(TInt32& aMin, TInt32& aMax);
Gets the current reverb level maximum and minimum in mB.
Arguments:
TInt32& aMin: The minimum reverb level. Referenced memory will contain the value.
TInt32& aMax: The maximum reverb level. Referenced memory will contain the value.
Returns:
None.
TInt32 RoomHFLevel() const;
Gets the current room High Frequency level value in mB.
Arguments:
None.
Returns:
The current room High Frequency level ratio.
void RoomHFLevelRange(TInt32& aMin, TInt32& aMax);
Gets the room High Frequency level maximum and minimum ratios in mB.
Arguments:
TInt32& aMin: The minimum room HF level. Referenced memory will contain the value.
TInt32& aMax: The maximum room HF level. Referenced memory will contain the value.
Returns:
None.
TInt32 RoomLevel() const;
Gets the current room level ratio in mB.
Arguments:
None.
Returns:
The room level ratio.
void RoomLevelRange(TInt32& aMin, TInt32& aMax);
Gets the room level maximum and minimum ratios in mB.
Arguments:
TInt32& aMin: The minimum room level. Referenced memory will contain the value.
TInt32& aMax: The maximum room level. Referenced memory will contain the value.
Returns:
None.
void SetDecayTimeL(TUint32 aDecayTime);
Sets the decay time in milliseconds.
Arguments:
TUint32 aDecayTime: The decay time in milliseconds.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetDecayHFRatioL(TUint32 aDecayHFRatio);
Sets the decay HF Ratio in hundredths.
Arguments:
TUint32 aDecayHFRatio: The decay high frequency ratio in hundredths.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetDensityL(TUint32 aDensity);
Sets the density value as percentage in hundredths.
Arguments:
TUint32 aDensity: The density.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetDiffusionL(TUint32 aDiffusion);
Sets the diffusion value as a percentage in hundredths.
Arguments:
TUint32 aDiffusion: The diffusion.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetReflectionsDelayL(TUint32 aRefectionsDelay);
Sets the reverb reflections delay.
Arguments:
TUint32 aRefectionsDelay: The reflection delay in milliseconds.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetReflectionsLevelL(TInt32 aRefectionsLevel);
Sets the reverb reflections level in mB.
Arguments:
TInt32 aRefectionsLevel: The reflection level in mB.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetReverbDelayL(TUint32 aReverbDelay);
Sets the reverb delay.
Arguments:
TUint32 aReverbDelay: The reverb delay in milliseconds.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetReverbLevelL(TInt32 aReverbLevel);
Sets the reverb level.
Arguments:
TInt32 aReverbLevel: The reverb level in mB.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetRoomHFLevelL(TInt32 aRoomHFLevel);
Sets the room HF level in mB.
Arguments:
TUint32 aRoomHFLevel: The room high frequency ratio.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void SetRoomLevelL(TInt32 aRoomLevel);
Sets the room level in mB.
Arguments:
TUint32 aRoomLevel: The room level.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
This abstract class is a generalization of the environmental reverb observer. It defines the possible events that are specific to the environmental reverb effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 31: MEnvironmentalReverbObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
This class is used by audio applications for controlling stereo widening. It is derived from CAudioEffect (see CAudioEffect section).
Figure 32: CStereoWidening
Headers:
StereoWideningEffect.H, StereoWideningEffectData.H, MStereoWideningEffectObserver.H
Library:
StereoWideningEffect.DLL
CStereoWidening* NewL(CMMFDevSound& aDevSound, TBool aEnable = EFalse, TInt8 aInitialLevel = 0);
A static constructor that creates a stereo widening object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening level value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioConvertUtility& aUtility, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening level value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioInputStream& aUtility, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioOutputStream& aUtility, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
Pointer to CStereoWidening
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory − unable to instantiate due to memory errors
KErrNotSupported − Effect is not supported
CStereoWidening* NewL(CMdaAudioPlayerUtility& aUtility, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioRecordUtility& aUtility, Tbool aRecordStream, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
Tbool aRecordStream: Set to ETrue if the effect is to be applied to recording, EFalse if the effect is to be applied only to playback.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioToneUtility& aUtility, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(MCustomCommand& aUtility, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
MCustomCommand& aUtility: The utility that implements the MCustomCommand interface that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(MCustomInterface& aCustomInterface, TBool aEnable = EFalse, TInt8 aInitialLevel = 0 );
A static constructor that creates a stereo widening object.
Arguments:
MCustomInterface& aCustomInterface: The utility that implements the MCustomInterface interface that is to be associated with this effect.
TBool aEnable: Set to ETrue if the effect should be enabled immediately, otherwise EFalse. By default, this parameter is set to EFalse.
TInt8 aInitialLevel: The stereo widening value that will be used when aEnable is ETrue. When aEnable is EFalse, this value is ignored.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
TBool IsContinousLevelSupported() const;
Checks if continuous level is supported for stereo widening.
Arguments:
None.
Returns:
ETrue if continuous level is supported for stereo widening. If this returns EFalse, then the adaptation is actually setting the level to the nearest supported discrete value when SetStereoWidenlingLevelL is called.
void SetStereoWideningLevelL(TUint8 aLevel);
Sets the widening level.
Arguments:
TUint8 aLevel: The stereo widening level ranges from 0-100, where 0 is none and 100 is maximum widening.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
TUint8 SteroWideningLevel() const;
Gets the stereo widening settings.
Arguments:
None.
Returns:
The level of widening.
This abstract class is a generalization of the stereo widening observer. It defines the possible events that are specific to the stereo widening effect. It is derived from MAudioEffectObserver (see MAudioEffectObserver section).
Figure 33: MStereoWideningObserver
Methods:
EffectChanged(). Inherited from MAudioEffectObserver (see MAudioEffectObserver section).
Equalizer Utility enables audio clients to use preset values stored in the Central Repository for use with the Equalizer effect.
Figure 34: Equalizer Utility
Headers:
AudioEqualizerUtility.H
Library:
AudioEqualizerUtility.DLL
CAudioEqualizerUtility* NewL(CMMFDevSound& aDevSound);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(CMdaAudioRecordUtility& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(MCustomCommand& aUtility);
A static constructor that creates an audio equalizer utility object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CAudioEqualizerUtility* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates an audio equalizer utility object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CAudioEqualizerUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
void ApplyPresetL(TInt aPresetIndex);
Used to apply the preset values.
Arguments:
TInt aPresetIndex: The index of the preset to apply. The index is the index into the array of presets retrieved with the method Presets().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
CbassBoost& BassBoost();
Gets the bass boost object.
Arguments:
None.
Returns:
A reference to the bass boost object.
void CreatePresetL(TDesC& aName, CAudioEqualizer& aAudioEqualizer);
Creates a user-defined preset with the specified equalizer settings.
Arguments:
TDesC& aName: The name of the user-defined preset.
CAudioEqualizer& aAudioEqualizer: An equalizer object configured to the values to be used in creating the user-defined preset.
Returns:
An updated list of presets is returned if the operation is successful.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
KErrNoMemory: an out of memory error encountered.
void DeletePresetL(TInt aPresetIndex);
Deletes the specified user-defined preset.
Arguments:
TInt aPresetIndex: The index into the preset array retrieved with the method Presets().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void DisableEqualizerL ();
Deletes the specified user-defined preset.
Arguments:
Returns:
None.
Error handling:
CAudioEqualizer& Equalizer();
Gets the audio equalizer object.
Arguments:
None.
Returns:
A reference to the audio equalizer object.
const TDesC& GetPresetL (TInt aPresetIndex);
Retrieves the Preset values from the Central Repository and stores it in the Equalizer Object. Also it returns the Name of the retrieved Preset.
Arguments:
TInt aPresetIndex: The index of the preset to retrieve. The index is the index into the array of presets retrieved with the method Presets().
Returns:
Name of the Retrieved Preset.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void ModifyPresetL(TInt aPresetIndex, TDesC& aName, CAudioEqualizer& aAudioEqualizer);
Modifies a user-defined preset with the specified equalizer settings.
Arguments:
TInt aPresetIndex: The index into the preset array retrieved with the method Presets().
TDesC& aName: The name of the preset to be used in modification.
CAudioEqualizer& aAudioEqualizer: An equalizer object configured to the values to be used in modifying the preset.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
KErrNoMemory: an out of memory error encountered.
TUint32 NumberOfPreDefinePresets() const;
Gets the number of predefined presets.
Arguments:
None.
Returns:
The number of predefined presets.
TArray< TEfAudioEqualizerUtilityPreset > Presets();
Gets the list of preset names, unique name keys and unique description keys.
Arguments:
None.
Returns:
An array of objects, which contains all the preset names (pre-defined and user-defined), their name keys and description keys. The pre-defined presets are in the beginning of the list.
void ResetPresetL(TInt aPresetIndex);
Resets the specified preset.
Arguments:
TInt aPresetIndex: The index of the preset to reset. The index is the index into the array of presets retrieved with the method Presets(). The Utility only allows resetting the PreDefined Presets.
Note: If the preset index points to a preset that cannot be reset, the method will leave with KErrArgument.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
Reverb Utility enables audio clients to use preset values stored in the Central Repository for use with the Reverb effect.
Figure 35: Reverb Utility
Headers:
ReverbUtility.H
Library:
ReverbUtility.DLL
CReverbUtility* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a reverb utility object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(CMdaAudioRecordUtility& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(MCustomCommand& aUtility);
A static constructor that creates a reverb utility object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCommand interface that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CReverbUtility* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a reverb utility object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CReverbUtility.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
void ApplyPresetL(TInt aPresetIndex);
Used to apply the preset values.
Arguments:
TInt aPresetIndex: The index of the preset to apply. The index is the index into the array of presets retrieved with the method Presets().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void CreatePresetL(TDesC& aName, CEnvironmentalReverb& aReverb);
Creates a user-defined preset with the specified equalizer settings.
Arguments:
TDesC& aName: The name of the user-defined preset.
CEnvironmentalReverb& aReverb: An environmental reverb object configured to the values to be used in creating the user-defined preset.
Returns:
An updated list of presets is returned if the operation is successful.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
KErrNoMemory: an out of memory error encountered.
void DeletePresetL(TInt aPresetIndex);
Deletes the specified preset.
Arguments:
TInt aPresetIndex: The index into the preset array retrieved with the method Presets().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void DisableReverbL ();
Deletes the specified user-defined preset.
Arguments:
Returns:
None.
Error handling:
const TDesC& GetPresetL (TInt aPresetIndex);
Retrieves the Preset values from the Central Repository and stores it in the Equalizer Object. Also it returns the Name of the retrieved Preset.
Arguments:
TInt aPresetIndex: The index of the preset to retrieve. The index is the index into the array of presets retrieved with the method Presets().
Returns:
Name of the Retrieved Preset.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void ModifyPresetL(TInt aPresetIndex, TDesC& aName, CEnvironmentalReverb& aReverb);
Modifies a user-defined preset with the specified equalizer settings.
Arguments:
TInt aPresetIndex: The index into the preset array retrieved with the method Presets().
TDesC& aName: The name of the preset to be used in modification.
CEnvironmentalReverb& aReverb: An environmental reverb object configured to the values to be used in modifying the preset.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
KErrNoMemory: an out of memory error encountered.
TUint32 NumberOfPreDefinePresets() const;
Gets the number of predefined presets.
Arguments:
None.
Returns:
The number of predefined presets.
TArray<TEfAudioReverbUtilityPreset> Presets();
Gets the list of preset names.
Arguments:
None.
Returns:
An array of all the preset names (pre-defined and user-defined). The pre-defined presets are in the beginning of the list.
void ResetPresetL(TInt aPresetIndex);
Resets the specified preset.
Arguments:
TInt aPresetIndex: The index of the preset to reset. The index is the index into the array of presets retrieved with the method Presets().
Note: If the preset index points to a preset that cannot be reset, the method will leave with KErrArgument.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
CEnvironmentalReverb& Reverb();
Gets the reverb object.
Arguments:
None.
Returns:
A reference to an environmental reverb object.
Stereo Widening Utility enables audio clients to use preset values stored in the Central Repository for use with the Stereo Widening effect.
Figure 36: Stereo Widening Utility
Headers:
StereoWideningUtility.H
Library:
StereoWideningUtility.DLL
CStereoWidening* NewL(CMMFDevSound& aDevSound);
A static constructor that creates a stereo widening utility object.
Arguments:
CMMFDevSound& aDevSound: The DevSound associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioConvertUtility& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
CMdaAudioConvertUtility& aUtility: The convert utility that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioInputStream& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
CMdaAudioInputStream& aUtility: The input stream utility that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioOutputStream& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
CMdaAudioOutputStream& aUtility: The output stream utility that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioPlayerUtility& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
CMdaAudioPlayerUtility& aUtility: The play utility that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(CMdaAudioRecordUtility& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
CMdaAudioRecordUtility& aUtility: The record utility that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: Effect is not supported.
CStereoWidening* NewL(CMdaAudioToneUtility& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
CMdaAudioToneUtility& aUtility: The tone utility that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(MCustomCommand& aUtility);
A static constructor that creates a stereo widening utility object.
Arguments:
MCustomCommand& aUtility: A utility that implements the MCustomCoimmand interface that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
CStereoWidening* NewL(MCustomInterface& aCustomInterface);
A static constructor that creates a stereo widening utility object.
Arguments:
MCustomInterface& aCustomInterface: A utility that implements the MCustomInterface interface that is to be associated with this effect.
Returns:
A pointer to CStereoWidening.
Error handling:
This method leaves with the following typical leave codes:
KErrNoMemory: unable to instantiate due to memory errors.
KErrNotSupported: the effect is not supported.
void ApplyPresetL(TInt aPresetIndex);
Used to apply the preset values.
Arguments:
TInt aPresetIndex: The index of the preset to apply. The index is the index into the array of presets retrieved with the method Presets().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void CreatePresetL(TDesC& aName, CStereoWidening& aStereoWidening);
Createa a user-defined preset with the specified equalizer settings.
Arguments:
TDesC& aName: The name of the user-defined preset.
CStereoWidening& aStereoWidening: A stereo widening object configured to the values to be used in creating the user-defined preset.
Returns:
An updated list of presets is returned if the operation is successful.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
KErrNoMemory: an out of memory error encountered.
void DeletePresetL(TInt aPresetIndex);
Deletes the specified user-defined preset.
Arguments:
TInt aPresetIndex: The index into the preset array retrieved with the method Presets().
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void DisableStereoWideningL ();
Deletes the specified user-defined preset.
Arguments:
Returns:
None.
Error handling:
const TDesC& GetPresetL (TInt aPresetIndex);
Retrieves the Preset values from the Central Repository and stores it in the Equalizer Object. Also it returns the Name of the retrieved Preset.
Arguments:
TInt aPresetIndex: The index of the preset to retrieve. The index is the index into the array of presets retrieved with the method Presets().
Returns:
Name of the Retrieved Preset.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
void ModifyPresetL(TInt aPresetIndex, TDesC& aName, CStereoWidening& aStereoWidening);
Modifies a user-defined preset with the specified equalizer settings.
Arguments:
TInt aPresetIndex: The index into the user-defined preset array retrieved with the method Presets().
TDesC& aName: The name of the preset to be used in modification.
CStereoWidening& aStereoWidening: A stereo widening object configured to the values to be used in modifying the preset.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
KErrNoMemory: an out of memory error encountered.
TUint32 NumberOfPreDefinePresets() const;
Gets the number of predefined presets.
Arguments:
None.
Returns:
The number of predefined presets.
TArray<TEfAudioStereoWideningUtilityPreset> Presets();
Gets the list of preset names.
Arguments:
None.
Returns:
An array of all the preset names (pre-defined and user-defined). The pre-defined presets are in the beginning of the list.
void ResetPresetL(TInt aPresetIndex);
Resets the specified preset.
Arguments:
TInt aPresetIndex: The index of the preset to reset. The index is the index into the array of presets retrieved with the method Presets().
Note: If the preset index points to a preset that cannot be reset, the method will leave with KErrArgument.
Returns:
None.
Error handling:
This method leaves with the following typical leave codes:
KErrArgument: the argument value is out of range or invalid.
CStereoWidening& StereoWidening();
Gets the reverb object.
Arguments:
None.
Returns:
A reference to a stereo widening object.