SpatialPanner.h

Go to the documentation of this file.
00001 //
00002 //  SpatialPanner.h -- Specification of the abstract framework for panner/spatializers
00003 //  See the copyright notice and acknowledgment of authors in the file COPYRIGHT
00004 //  Created by Jorge Castellanos on 3/29/06. Hacked 8/09 by STP.
00005 //
00006 
00007 #ifndef SPATIAL_PANNER_H
00008 #define SPATIAL_PANNER_H
00009 
00010 #include "SpeakerLayout.h"
00011 #include "SpatialSource.h"
00012 
00013 #include "CSL_Core.h"
00014 #include "CPoint.h"
00015 
00016 namespace csl {
00017 
00021 
00022 class SpatialPanner : public UnitGenerator, public Observer {
00023 public:
00026     SpatialPanner(SpeakerLayout *layout = SpeakerLayout::defaultSpeakerLayout());
00027     virtual ~SpatialPanner();
00028 
00031     void setSpeakerLayout(SpeakerLayout *aLayout);
00032 
00033     unsigned numSources() { return mSources.size(); };  
00034     
00035     virtual void addSource(SpatialSource &s);           
00036 
00037 
00038     virtual void removeSource(SpatialSource &s);        
00039 
00040     virtual void update(void *arg);     
00041 
00042 protected:
00045     vector <SpatialSource *> mSources;  
00046     vector <void *> mCache;             
00047 
00048     SpeakerLayout *mSpeakerLayout;      
00049 
00050     Buffer mTempBuffer;                 
00051 
00052     virtual void *cache() = 0;              
00053     virtual void speakerLayoutChanged() { }; 
00054 }; 
00055 
00056 }
00057 
00058 #endif

Generated on Thu Sep 17 23:14:16 2009 for CSL by  doxygen 1.5.8