Open Ephys GUI
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions
ExampleProcessor Class Reference

This is a description of the processor's function. More...

#include <ExampleProcessor.h>

Inheritance diagram for ExampleProcessor:
GenericProcessor AccessClass

List of all members.

Public Member Functions

 ExampleProcessor ()
 The class constructor, used to initialize any members.
 ~ExampleProcessor ()
 The class destructor, used to deallocate memory.
bool isSource ()
 Determines whether the processor is treated as a source.
bool isSink ()
 Determines whether the processor is treated as a sink.
void process (AudioSampleBuffer &buffer, MidiBuffer &events, int &nSamples)
 Defines the functionality of the processor.
void setParameter (int parameterIndex, float newValue)
 Any variables used by the "process" function must be modified only through this method while data acquisition is active.
- Public Member Functions inherited from GenericProcessor
 GenericProcessor (const String &name_)
virtual ~GenericProcessor ()
const String getName () const
virtual void prepareToPlay (double sampleRate, int estimatedSamplesPerBlock)
void releaseResources ()
virtual AudioProcessorEditor * createEditor ()
bool hasEditor () const
void reset ()
void setCurrentProgramStateInformation (const void *data, int sizeInBytes)
void setStateInformation (const void *data, int sizeInBytes)
void getCurrentProgramStateInformation (MemoryBlock &destData)
void getStateInformation (MemoryBlock &destData)
void changeProgramName (int index, const String &newName)
void setCurrentProgram (int index)
const String getInputChannelName (int channelIndex) const
const String getOutputChannelName (int channelIndex) const
const String getParameterName (int parameterIndex)
const String getParameterText (int parameterIndex)
const String getProgramName (int index)
bool isInputChannelStereoPair (int index) const
bool isOutputChannelStereoPair (int index) const
bool acceptsMidi () const
bool producesMidi () const
bool isParameterAutomatable (int parameterIndex)
bool isMetaParameter (int parameterIndex)
int getNumParameters ()
int getNumPrograms ()
int getCurrentProgram ()
float getParameter (int parameterIndex)
ParametergetParameterByName (String parameterName)
ParametergetParameterReference (int parameterIndex)
virtual float getSampleRate ()
virtual float getDefaultSampleRate ()
virtual int getNumInputs ()
virtual int getNumOutputs ()
virtual int getDefaultNumOutputs ()
virtual float getDefaultBitVolts ()
virtual int getNextChannel (bool)
virtual void resetConnections ()
virtual void setCurrentChannel (int chan)
int getNodeId ()
void setNodeId (int id)
GenericProcessorgetSourceNode ()
GenericProcessorgetDestNode ()
virtual void switchIO (int)
virtual void switchIO ()
virtual void setPathToProcessor (GenericProcessor *p)
virtual void setSourceNode (GenericProcessor *sn)
virtual void setDestNode (GenericProcessor *dn)
virtual void setMergerSourceNode (GenericProcessor *sn)
virtual void setSplitterDestNode (GenericProcessor *dn)
virtual bool isSplitter ()
virtual bool isMerger ()
virtual bool canSendSignalTo (GenericProcessor *)
virtual bool isReady ()
virtual bool enable ()
virtual bool disable ()
virtual void enableEditor ()
virtual void disableEditor ()
virtual bool enabledState ()
virtual void enabledState (bool t)
virtual void enableCurrentChannel (bool)
virtual bool stillHasSource ()
virtual AudioSampleBuffer * getContinuousBuffer ()
virtual MidiBuffer * getEventBuffer ()
virtual int checkForEvents (MidiBuffer &mb)
virtual void addEvent (MidiBuffer &mb, uint8 type, int sampleNum, uint8 eventID=0, uint8 eventChannel=0, uint8 numBytes=0, uint8 *data=0)
virtual void handleEvent (int eventType, MidiMessage &event, int samplePosition=0)
virtual GenericEditorgetEditor ()
virtual void clearSettings ()
virtual void update ()
virtual void updateSettings ()
void setStartChannel (int i)
int getStartChannel ()
- Public Member Functions inherited from AccessClass
 AccessClass ()
 ~AccessClass ()
void setUIComponent (UIComponent *)
 Sets the object's UIComponent and copies all the necessary pointers from the UIComponent.
virtual void updateChildComponents ()
 Called within setUIComponent() to enable subclasses to update their members' pointers.
EditorViewportgetEditorViewport ()
 Returns a pointer to the application's EditorViewport.
DataViewportgetDataViewport ()
 Returns a pointer to the application's DataViewport.
ProcessorListgetProcessorList ()
 Returns a pointer to the application's ProcessorList.
ProcessorGraphgetProcessorGraph ()
 Returns a pointer to the application's ProcessorGraph.
ControlPanelgetControlPanel ()
 Returns a pointer to the application's DataViewport.
MessageCentergetMessageCenter ()
 Returns a pointer to the application's MessageCenter.
UIComponentgetUIComponent ()
 Returns a pointer to the application's UIComponent.
AudioComponentgetAudioComponent ()
 Returns a pointer to the application's AudioComponent.

Additional Inherited Members

- Public Types inherited from GenericProcessor
enum  eventTypes {
  TIMESTAMP = 0, BUFFER_SIZE = 1, PARAMETER_CHANGE = 2, TTL = 3,
  SPIKE = 4, EEG = 5, CONTINUOUS = 6
}
enum  eventChannelTypes { GENERIC_EVENT = 999, SINGLE_ELECTRODE = 1, STEREOTRODE = 2, TETRODE = 4 }
- Public Attributes inherited from GenericProcessor
GenericProcessorsourceNode
GenericProcessordestNode
bool isEnabled
bool wasConnected
int nextAvailableChannel
int saveOrder
int loadOrder
int currentChannel
ScopedPointer< GenericEditoreditor
OwnedArray< Channelchannels
OwnedArray< ChanneleventChannels
ProcessorSettings settings
int nodeId
Array< Parameterparameters
StringArray parameterNames
Parameter nullParam

Detailed Description

This is a description of the processor's function.

See also:
GenericProcessor

Constructor & Destructor Documentation

ExampleProcessor::ExampleProcessor ( )

The class constructor, used to initialize any members.

ExampleProcessor::~ExampleProcessor ( )

The class destructor, used to deallocate memory.


Member Function Documentation

bool ExampleProcessor::isSource ( )
virtual

Determines whether the processor is treated as a source.

Re-implemented from GenericProcessor.h

Reimplemented from GenericProcessor.

bool ExampleProcessor::isSink ( )
virtual

Determines whether the processor is treated as a sink.

Re-implemented from GenericProcessor.h

Reimplemented from GenericProcessor.

void ExampleProcessor::process ( AudioSampleBuffer &  buffer,
MidiBuffer &  events,
int &  nSamples 
)
virtual

Defines the functionality of the processor.

The process method is called every time a new data buffer is available.

Processors can either use this method to add new data, manipulate existing data, or send data to an external target (such as a display or other hardware).

Continuous signals arrive in the "buffer" variable, event data (such as TTLs and spikes) is contained in the "events" variable, and "nSamples" holds the number of continous samples in the current buffer (which may differ from the size of the buffer).

Implements GenericProcessor.

void ExampleProcessor::setParameter ( int  parameterIndex,
float  newValue 
)
virtual

Any variables used by the "process" function must be modified only through this method while data acquisition is active.

If they are modified in any other way, the application will crash.

Reimplemented from GenericProcessor.


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