Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Compound Members | File Members

ArraySensor.hh

Go to the documentation of this file.
00001 /*
00002 
00003     Class representing single sensor for array operations
00004     Copyright (C) 1999-2002 Jussi Laako
00005 
00006     This program is free software; you can redistribute it and/or modify
00007     it under the terms of the GNU General Public License as published by
00008     the Free Software Foundation; either version 2 of the License, or
00009     (at your option) any later version.
00010 
00011     This program is distributed in the hope that it will be useful,
00012     but WITHOUT ANY WARRANTY; without even the implied warranty of
00013     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014     GNU General Public License for more details.
00015 
00016     You should have received a copy of the GNU General Public License
00017     along with this program; if not, write to the Free Software
00018     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00019 
00020 */
00021 
00022 
00023 #include <dsp/DSPOp.hh>
00024 #include <dsp/DSPVector.hh>
00025 #include <dsp/Filter.hh>
00026 
00027 #include "Config.h"
00028 
00029 
00030 #ifndef ARRAYSENSOR_HH
00031     #define ARRAYSENSOR_HH
00032 
00033 
00038     class clArraySensor
00039     {
00040         protected:
00041             bool bDebug;
00042             long lWindowSize;       
00043             long lProcCount;        
00044             GDT fPI;
00045             GDT fArrayFrequency;    
00046             GDT fSoundSpeed;        
00047             GDT fSecsPerMeter;      
00048             GDT fSampleRate;        
00049             GDT fSampleSpacing;     
00050             GDT fFreqResolution;    
00051             GDT fShadeCoeff;        
00052             GDT fLeftDistance;      
00053             GDT fRightDistance;     
00054             GDT fLeftTime;          
00055             GDT fRightTime;         
00056             GDT fDirection;         
00057             clDSPOp DSP;
00058             clFilter Filter;
00059             clDSPVector<GDT> dspvInData;
00060             clDSPVector<GDT> dspvProcData;
00061             clDSPVector<GDT> dspvOutData;
00062             void SinCosC (float, float *, float *);
00063             void SinCosC (double, double *, double *);
00064         public:
00065             clArraySensor ();
00066             ~clArraySensor () {}
00067             void EnableDebug () { bDebug = true; }
00068             void DisableDebug () { bDebug = false; }
00079             bool Initialize (GDT, GDT, long);
00087             void SetSampleRate (GDT);
00095             void SetSoundSpeed (GDT);
00103             void SetArrayFrequency (GDT);
00109             void SetShading (GDT);
00119             void SetDirection (GDT, bool = true);
00126             void Put (const GDT *, long);
00134             bool Get (GDT *, long);
00135     };
00136 
00137 #endif

Generated on Sun Oct 26 19:11:18 2003 for HASAS by doxygen 1.3.3