Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

80 lines
2.8 KiB

  1. /***************************************************************************
  2. *
  3. * Copyright (C) 1999-2002 Microsoft Corporation. All Rights Reserved.
  4. *
  5. * File: aecp.h
  6. * Content: Acoustic Echo Cancellation DMO declarations.
  7. *
  8. ***************************************************************************/
  9. #ifndef _Aecp_
  10. #define _Aecp_
  11. #include "dsdmobse.h"
  12. #include "dmocom.h"
  13. #include "dsdmo.h"
  14. #include "PropertyHelp.h"
  15. #include "param.h"
  16. #include "aecdbgprop.h"
  17. class CDirectSoundCaptureAecDMO :
  18. public CDirectSoundDMO,
  19. public CParamsManager,
  20. public IDirectSoundCaptureFXAec,
  21. #ifdef AEC_DEBUG_SUPPORT
  22. public IDirectSoundCaptureFXMsAecPrivate,
  23. #endif // AEC_DEBUG_SUPPORT
  24. public CComBase
  25. {
  26. public:
  27. CDirectSoundCaptureAecDMO(IUnknown *pUnk, HRESULT *phr);
  28. ~CDirectSoundCaptureAecDMO();
  29. DECLARE_IUNKNOWN;
  30. STDMETHODIMP NDQueryInterface(REFIID riid, void **ppv);
  31. static CComBase* WINAPI CreateInstance(IUnknown *pUnk, HRESULT *phr);
  32. // InitOnCreation is called by the class factory to give the object a chance to initialize
  33. // immediately after it is created. This is used to prepare the object's parameter information.
  34. HRESULT InitOnCreation();
  35. // The Init function is an override from the CPCMDMO base class and it provides initialization
  36. // for the effect's actual audio processing. Note that InputType must have been set before this
  37. // occurs in order for this to work.
  38. HRESULT Init();
  39. STDMETHOD(Clone) (THIS_ IMediaObjectInPlace **);
  40. // IDirectSoundCaptureFXAec methods
  41. STDMETHOD(SetAllParameters) (THIS_ LPCDSCFXAec);
  42. STDMETHOD(GetAllParameters) (THIS_ LPDSCFXAec);
  43. STDMETHOD(GetStatus) (THIS_ PDWORD pdwStatus);
  44. STDMETHOD(Reset) (THIS);
  45. // IMediaParams methods
  46. STDMETHOD(SetParam) (THIS_ DWORD dwParamIndex, MP_DATA value, bool fSkipPasssingToParamManager = false);
  47. STDMETHOD(GetParam) (THIS_ DWORD dwParamIndex, MP_DATA* value);
  48. // All of these methods are called by the base class
  49. HRESULT FBRProcess(DWORD cQuanta, BYTE *pIn, BYTE *pOut);
  50. HRESULT Discontinuity();
  51. HRESULT ProcessInPlace(ULONG ulQuanta, LPBYTE pcbData, REFERENCE_TIME rtStart, DWORD dwFlags);
  52. #ifdef AEC_DEBUG_SUPPORT
  53. // IDirectSoundCaptureFXMsAecPrivate methods
  54. //STDMETHOD(SetAllParameters) (THIS_ LPCDSCFXMsAecPrivate);
  55. STDMETHOD(GetSynchStreamFlag) (THIS_ PBOOL);
  56. STDMETHOD(GetNoiseMagnitude) (THIS_ PVOID, ULONG, PULONG);
  57. #endif // AEC_DEBUG_SUPPORT
  58. private:
  59. BOOL m_fDirty;
  60. BOOL m_bInitialized;
  61. BOOL m_fEnable;
  62. BOOL m_fNfEnable;
  63. DWORD m_dwMode;
  64. };
  65. EXT_STD_CAPTURE_CREATE(Aec);
  66. #endif