Auditory Relacs Plugins  0.9.8
Public Slots | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
Search Class Reference

#include <search.h>

Inheritance diagram for Search:
Inheritance graph
[legend]
Collaboration diagram for Search:
Collaboration graph
[legend]

Public Slots

void setIntensity (int intensity)
 
void setDuration (int duration)
 
void setPause (int pause)
 
void setFrequency (int freq)
 
void setWaveform (int wave)
 
void setWaveformButton (int wave)
 
void setSpeaker (bool left)
 
void setSpeakerLeft (void)
 
void setSpeakerRight (void)
 
void toggleMute (void)
 
void setMute (bool mute)
 
virtual void dialogAccepted (void)
 
- Public Slots inherited from ConfigDialog
virtual void dialog (void)
 
virtual void help (void)
 
virtual void notifyDialog (const Options &opt)
 

Public Member Functions

 Search (void)
 
 ~Search (void)
 
virtual int main (void)
 
void saveEvents (const EventData &events, int count, Options &header)
 
- Public Member Functions inherited from ConfigDialog
 ConfigDialog (const string &configident="", int configgroup=0, const string &name="", const string &author="", const string &version="", const string &date=__DATE__)
 
virtual ~ConfigDialog (void)
 
string name (void) const
 
virtual void setName (const string &name)
 
string author (void) const
 
virtual void setAuthor (const string &author)
 
string version (void) const
 
virtual void setVersion (const string &version)
 
string date (void) const
 
virtual void setDate (const string &date)
 
virtual OptWidgetdialogOptions (OptDialog *od, string *tabhotkeys=0)
 
virtual void dialogButtons (OptDialog *od)
 
virtual void dialogEmptyMessage (OptDialog *od)
 
int dialogSelectMask (void) const
 
void setDialogSelectMask (int mask)
 
void addDialogSelectMask (int mask)
 
int dialogReadOnlyMask (void) const
 
void setDialogReadOnlyMask (int mask)
 
void addDialogReadOnlyMask (int mask)
 
int dialogStyle (void) const
 
void setDialogStyle (int style)
 
void addDialogStyle (int style)
 
string dialogCaption (void) const
 
void setDialogCaption (const string &caption)
 
bool dialogHeader (void) const
 
void setDialogHeader (bool d)
 
string headerBackgroundColor (void) const
 
void setHeaderBackgroundColor (const string &color)
 
string headerForegroundColor (void) const
 
void setHeaderForegroundColor (const string &color)
 
string headerImageFile (void) const
 
void setHeaderImageFile (const string &file)
 
virtual void dialogHeaderWidget (OptDialog *od)
 
bool dialogHelp (void) const
 
void setDialogHelp (bool d)
 
string helpCaption (void) const
 
void setHelpCaption (const string &caption)
 
string helpPath (int inx=0) const
 
int helpPathes (void) const
 
void clearHelpPathes (void)
 
void setHelpPath (const string &path)
 
void addHelpPath (const string &path)
 
virtual string helpFileName (void) const
 
bool dialogOpen (void) const
 
bool helpOpen (void) const
 
QWidget * mainWidget (void)
 
virtual void setMainWidget (QWidget *widget)
 
void lock () const
 
void unlock () const
 
bool tryLock (int timeout=1)
 
QMutex * mutex (void)
 
- Public Member Functions inherited from ConfigClass
 ConfigClass (const string &ident, int group=0, int mode=0xffff, int selectmask=0)
 
 ConfigClass (const ConfigClass &C)
 
virtual ~ConfigClass (void)
 
const string & configIdent (void) const
 
void setConfigIdent (const string &ident)
 
int configGroup (void) const
 
void setConfigGroup (int group)
 
int configMode (void) const
 
void setConfigMode (int mode)
 
void addConfigMode (int mode)
 
void delConfigMode (int mode)
 
int configSelectMask (void) const
 
void setConfigSelectMask (int mask)
 
void addConfig (void)
 
void readConfig (void)
 
virtual void readConfig (StrQueue &sq)
 
virtual void saveConfig (ofstream &str)
 
virtual int configSize (void) const
 
virtual void config (void)
 
virtual void preConfig (void)
 
- Public Member Functions inherited from StandardTraces
 StandardTraces (void)
 

Protected Member Functions

void keyPressEvent (QKeyEvent *qke)
 
virtual void customEvent (QEvent *qce)
 
- Protected Member Functions inherited from ConfigDialog
void setDialogOpen (bool open=true)
 
void setHelpOpen (bool open=true)
 

Protected Attributes

bool NewSignal
 
int SetBestSide
 
bool SearchLeft
 
QRadioButton * LeftButton
 
QRadioButton * RightButton
 
bool Mute
 
QPushButton * MuteButton
 
LCDRangeILCD
 
double Intensity
 
LCDRangeDLCD
 
double Duration
 
LCDRangePLCD
 
double Pause
 
double PrePause
 
LCDRangeFLCD
 
double Frequency
 
double MinFreq
 
int Waveform
 
QRadioButton * SineButton
 
QRadioButton * NoiseButton
 
- Protected Attributes inherited from ConfigDialog
Options DialogOptions
 

Static Protected Attributes

static const double ShortIntensityStep = 1.0
 
static const double LongIntensityStep = 5.0
 
static const double MaxIntensity = 100.0
 
static const double MinIntensity = 0.0
 
static const double ShortDurationStep = 0.005
 
static const double LongDurationStep = 0.05
 
static const double MaxDuration = 10.0
 
static const double MinDuration = 0.005
 
static const double ShortPauseStep = 0.005
 
static const double LongPauseStep = 0.05
 
static const double MaxPause = 10.0
 
static const double MinPause = 0.005
 
static const double ShortFrequencyStep = 500.0
 
static const double LongFrequencyStep = 5000.0
 
static const double MaxFrequency = 40000.0
 
static const double MinFrequency = 2000.0
 
- Static Protected Attributes inherited from StandardTraces
static const int MaxTraces
 

Additional Inherited Members

- Public Types inherited from ConfigClass
enum  Action
 
- Signals inherited from ConfigDialog
void dialogAccepted (void)
 
void dialogAction (int r)
 
void dialogClosed (int r)
 
- Static Public Member Functions inherited from ConfigClass
static void setConfigureClasses (ConfigureClasses *cfg)
 
- Protected Slots inherited from ConfigDialog
void notificationFromDialog (const Parameter &p)
 
virtual void dClosed (int r)
 
virtual void hClosed (int r)
 
- Static Protected Member Functions inherited from StandardTraces
static void clearIndices (int *traceindices, int n=-1)
 
static void initStandardTraces (const InList &data, int *ntraces, int *traceindices, const string *names, string &namelist, bool alpha=false)
 
static void initStandardEventTraces (const InList &data, const EventList &events, int *ntraces, int *traceindices, int *eventindices, const string *tracenames, const string *eventnames, string &tracenamelist, string &eventnamelist, bool alpha=false)
 
static void initStandardOutputs (const RELACSPlugin *rp, int *ntraces, int *traceindices, const string *names, string &namelist, bool alpha=false)
 

Detailed Description

[RePro] Periodically emits a search stimulus.

Author
Jan Benda
Christian Machens
Version
2.3 (Jun 29, 2016)
Todo:

check postCustomEvent usage!!!! user types+10 and event handling

Use mutex to protect stimulus creation.

Bug:
sampling rate is only 10 kHz?!
Todo:
reanable manual convert of signal
Options
  • intensity=80dB: Intensity (number)
  • mute=false: No stimulus (boolean)
  • duration=50ms: Duration of stimulus (number)
  • pause=500ms: Duration of pause (number)
  • prepause=50ms: Part of pause before stimulus (number)
  • frequency=5kHz: Frequency of stimulus (number)
  • minfreq=2kHz: Minimum allowed frequency (number)
  • waveform=sine: Waveform of stimulus (string)
  • ramp=2ms: Ramp (number)
  • side=left: Speaker (string)
  • repeats=0: Number of repetitions (integer)
  • adjust=true: Adjust input gains (boolean)
  • saving=true: Save raw data (boolean)
  • setbestside=never: Set the sessions's best side (string)
  • keep=true: Keep changes (boolean)
Keyboard shortcuts:
  • Left: Left speaker
  • Right: Right speaker
  • N, Pause: Toggle stimulus output
  • Up: Increase intensity by 1dB
  • Down: Decrease intensity by 1dB
  • Shift+Up: Increase intensity by 5dB
  • Shift+Down: Decrease intensity by 5dB
  • Alt+Up: Increase frequency by 1kHz
  • Alt+Down: Decrease frequency by 1kHz
  • Alt+Shift+Up: Increase frequency by 5kHz
  • Alt+Shift+Down: Decrease frequency by 5kHz

Constructor & Destructor Documentation

Search ( void  )
~Search ( void  )

Member Function Documentation

int main ( void  )
virtual
void saveEvents ( const EventData events,
int  count,
Options header 
)
void setIntensity ( int  intensity)
slot

Set intensity of stimulus to dB dB and emit IntensityChanged.

References Search::Intensity, Search::MaxIntensity, and Search::MinIntensity.

Referenced by Search::keyPressEvent(), Search::main(), and Search::Search().

void setDuration ( int  duration)
slot

Set duration of stimulus to noise ms and emit DurationChanged.

References Search::Duration, Search::MaxDuration, Search::MinDuration, and Search::NewSignal.

Referenced by Search::Search().

void setPause ( int  pause)
slot

Set duration of pause to pause ms and emit PauseChanged.

References Search::MaxPause, Search::MinPause, and Search::Pause.

Referenced by Search::Search().

void setFrequency ( int  freq)
slot

Set frequency of stimulus to freq Hz and emit FrequencyChanged.

References Search::Frequency, Search::MaxFrequency, Search::MinFreq, and Search::NewSignal.

Referenced by Search::keyPressEvent(), and Search::Search().

void setWaveform ( int  wave)
slot

Set waveform of stimulus and emit waveformChanged.

References Search::NewSignal, and Search::Waveform.

Referenced by Search::Search().

void setWaveformButton ( int  wave)
slot

Set the right waveform button.

References Search::NoiseButton, and Search::SineButton.

Referenced by Search::customEvent(), and Search::dialogAccepted().

void setSpeaker ( bool  left)
slot
void setSpeakerLeft ( void  )
slot
void setSpeakerRight ( void  )
slot
void toggleMute ( void  )
slot

Toggle mute mode.

References Search::Mute, and Search::setMute().

Referenced by Search::keyPressEvent(), and Search::Search().

void setMute ( bool  mute)
slot

Set mute mode.

References Search::Mute, Search::MuteButton, and Search::NewSignal.

Referenced by Search::toggleMute().

void dialogAccepted ( void  )
virtualslot
void keyPressEvent ( QKeyEvent *  qke)
protected
void customEvent ( QEvent *  qce)
protectedvirtual

Member Data Documentation

bool NewSignal
protected
int SetBestSide
protected
bool SearchLeft
protected
QRadioButton* LeftButton
protected
QRadioButton* RightButton
protected
bool Mute
protected
QPushButton* MuteButton
protected

Referenced by Search::Search(), and Search::setMute().

LCDRange* ILCD
protected
double Intensity
protected
const double ShortIntensityStep = 1.0
staticprotected
const double LongIntensityStep = 5.0
staticprotected
const double MaxIntensity = 100.0
staticprotected
const double MinIntensity = 0.0
staticprotected
LCDRange* DLCD
protected
double Duration
protected
const double ShortDurationStep = 0.005
staticprotected

Referenced by Search::Search().

const double LongDurationStep = 0.05
staticprotected

Referenced by Search::Search().

const double MaxDuration = 10.0
staticprotected
const double MinDuration = 0.005
staticprotected
LCDRange* PLCD
protected
double Pause
protected
double PrePause
protected
const double ShortPauseStep = 0.005
staticprotected

Referenced by Search::Search().

const double LongPauseStep = 0.05
staticprotected

Referenced by Search::Search().

const double MaxPause = 10.0
staticprotected

Referenced by Search::Search(), and Search::setPause().

const double MinPause = 0.005
staticprotected

Referenced by Search::Search(), and Search::setPause().

LCDRange* FLCD
protected
double Frequency
protected
double MinFreq
protected
const double ShortFrequencyStep = 500.0
staticprotected
const double LongFrequencyStep = 5000.0
staticprotected
const double MaxFrequency = 40000.0
staticprotected
const double MinFrequency = 2000.0
staticprotected

Referenced by Search::Search().

int Waveform
protected
QRadioButton* SineButton
protected
QRadioButton* NoiseButton
protected

The documentation for this class was generated from the following files: