FIFE
be64c707dea6b3250bd4355bf5c825d25920087d
|
The frequency shifter is a single-sideband modulator, which translates all the component frequencies of the input signal by an equal amount. More...
#include <soundeffect.h>
Public Member Functions | |
FrequencyShifter () | |
Constructor. More... | |
void | setFrequency (float value) |
Sets the carrier frequency. More... | |
float | getFrequency () const |
Return carrier frequency. More... | |
void | setLeftDirection (uint8_t value) |
Sets left direction, selects which internal signals are added together to produce the output. More... | |
uint8_t | getLeftDirection () const |
Return left direction. More... | |
void | setRightDirection (uint8_t value) |
Sets right direction, selects which internal signals are added together to produce the output. More... | |
uint8_t | getRightDirection () const |
Return left direction. More... | |
Public Member Functions inherited from FIFE::SoundEffect | |
SoundEffect () | |
Constructor. More... | |
virtual | ~SoundEffect () |
Destructor. More... | |
ALuint | getEffectId () const |
Return the OpenAL effect handle. More... | |
void | setSlotId (ALuint slot) |
Sets the OpenAL auxiliary slot handle. More... | |
ALuint | getSlotId () |
Return the OpenAL auxiliary slot handle. More... | |
SoundEffectType | getEffectType () const |
Return sound effect type. More... | |
void | setEnabled (bool enabled) |
Enables or disables the effect. More... | |
bool | isEnabled () const |
Return true if the effect is enabled, false otherwise. More... | |
void | setFilter (SoundFilter *filter) |
Sets the additional sound filter. More... | |
SoundFilter * | getFilter () |
Return sound filter or NULL. More... | |
Private Attributes | |
float | m_frequency |
uint8_t | m_leftDirection |
uint8_t | m_rightDirection |
Additional Inherited Members | |
Protected Attributes inherited from FIFE::SoundEffect | |
ALuint | m_effect |
Effect object id. More... | |
ALuint | m_slot |
Effect slot id;. More... | |
SoundEffectType | m_effectType |
Sound effect type. More... | |
bool | m_enabled |
Effect enabled. More... | |
SoundFilter * | m_filter |
Additional filter effect. More... | |
The frequency shifter is a single-sideband modulator, which translates all the component frequencies of the input signal by an equal amount.
Definition at line 533 of file soundeffect.h.
FIFE::FrequencyShifter::FrequencyShifter | ( | ) |
Constructor.
Definition at line 545 of file soundeffect.cpp.
References FIFE::alEffecti, FIFE::SoundEffect::m_effect, FIFE::SoundEffect::m_effectType, and FIFE::SE_EFFECT_FREQUENCY_SHIFTER.
float FIFE::FrequencyShifter::getFrequency | ( | ) | const |
uint8_t FIFE::FrequencyShifter::getLeftDirection | ( | ) | const |
uint8_t FIFE::FrequencyShifter::getRightDirection | ( | ) | const |
void FIFE::FrequencyShifter::setFrequency | ( | float | value | ) |
Sets the carrier frequency.
For carrier frequencies below the audible range, the single-sideband modulator may produce phaser, spatial effects.
value | Range 0.0 to 24000.0, default 0.0. |
Definition at line 553 of file soundeffect.cpp.
References FIFE::alEffectf, FIFE::SoundEffect::m_effect, and m_frequency.
void FIFE::FrequencyShifter::setLeftDirection | ( | uint8_t | value | ) |
Sets left direction, selects which internal signals are added together to produce the output.
value | Range 0 to 2. 0=down, 1=up, 2=off, default 0. |
Definition at line 564 of file soundeffect.cpp.
References FIFE::alEffecti, FIFE::SoundEffect::m_effect, and m_leftDirection.
void FIFE::FrequencyShifter::setRightDirection | ( | uint8_t | value | ) |
Sets right direction, selects which internal signals are added together to produce the output.
value | Range 0 to 2. 0=down, 1=up, 2=off, default 0. |
Definition at line 575 of file soundeffect.cpp.
References FIFE::alEffecti, FIFE::SoundEffect::m_effect, and m_rightDirection.
|
private |
Definition at line 570 of file soundeffect.h.
Referenced by getFrequency(), and setFrequency().
|
private |
Definition at line 571 of file soundeffect.h.
Referenced by getLeftDirection(), and setLeftDirection().
|
private |
Definition at line 572 of file soundeffect.h.
Referenced by getRightDirection(), and setRightDirection().