Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef __CS_SNDSYS_FILTER_H__
00020 #define __CS_SNDSYS_FILTER_H__
00021
00026 #include "csutil/scf.h"
00027 #include "isndsys/ss_structs.h"
00028
00032 class csSourceParameters3D;
00033 class csListenerProperties;
00034 struct iReporter;
00035
00036
00037 struct iSndSysSoftwareFilter3DProperties
00038 {
00039 csSoundSample *clean_buffer;
00040 csSoundSample *work_buffer;
00041 size_t buffer_samples;
00042 csSourceParameters3D *source_parameters;
00043 csListenerProperties *listener_parameters;
00044 csSndSysSoundFormat *sound_format;
00045
00046 float closest_speaker_distance;
00047 float *speaker_distance;
00048 float *speaker_direction_cos;
00049 size_t channel;
00050 };
00051
00052
00057 struct iSndSysSoftwareFilter3D : public virtual iBase
00058 {
00059 SCF_INTERFACE(iSndSysSoftwareFilter3D,0,1,0);
00060
00070 virtual void Apply(iSndSysSoftwareFilter3DProperties &properties) = 0;
00071
00072 virtual bool AddSubFilter(iSndSysSoftwareFilter3D *filter,
00073 int chain_idx=0) = 0;
00074
00075 virtual iSndSysSoftwareFilter3D *GetSubFilter(int chain_idx=0) = 0;
00076
00081 virtual iSndSysSoftwareFilter3D *GetPtr() = 0;
00082 };
00083
00084
00085
00087
00088
00089
00090
00091
00092 struct iSndSysSoftwareOutputFilter : public virtual iBase
00093 {
00094 SCF_INTERFACE(iSndSysSoftwareOutputFilter,0,1,0);
00095
00097
00098 virtual bool FormatNotify(const csSndSysSoundFormat *pSoundFormat) = 0;
00099
00101 virtual void DeliverData(const csSoundSample *SampleBuffer, size_t Frames) = 0;
00102 };
00103
00104
00106 typedef enum
00107 {
00108
00109 SS_FILTER_LOC_RENDEROUT=0,
00110
00111 SS_FILTER_LOC_SOURCEOUT,
00112
00113 SS_FILTER_LOC_SOURCEIN
00114 } SndSysFilterLocation;
00115
00116
00117
00120 #endif // __CS_SNDSYS_FILTER_H__