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.

103 lines
3.5 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1998 - 1998
  6. //
  7. // File: dsoundcapturebufferobj.h
  8. //
  9. //--------------------------------------------------------------------------
  10. // dSoundBufferObj.h : Declaration of the C_dxj_DirectSoundCaptureBufferObject
  11. // DHF_DS entire file
  12. #include "resource.h" // main symbols
  13. #define typedef__dxj_DirectSoundCaptureBuffer LPDIRECTSOUNDCAPTUREBUFFER
  14. /////////////////////////////////////////////////////////////////////////////
  15. // Direct
  16. //REVIEW -- using pointers to ID's is necessary because some compilers don't like
  17. //references as template arguments.
  18. class C_dxj_DirectSoundCaptureBufferObject :
  19. #ifdef USING_IDISPATCH
  20. public CComDualImpl<I_dxj_DirectSoundCaptureBuffer, &IID_I_dxj_DirectSoundCaptureBuffer, &LIBID_DIRECTLib>,
  21. public ISupportErrorInfo,
  22. #else
  23. public I_dxj_DirectSoundCaptureBuffer,
  24. #endif
  25. // public CComCoClass<C_dxj_DirectSoundCaptureBufferObject, &CLSID__dxj_DirectSoundCaptureBuffer>,
  26. public CComObjectRoot
  27. {
  28. public:
  29. C_dxj_DirectSoundCaptureBufferObject() ;
  30. virtual ~C_dxj_DirectSoundCaptureBufferObject() ;
  31. BEGIN_COM_MAP(C_dxj_DirectSoundCaptureBufferObject)
  32. COM_INTERFACE_ENTRY(I_dxj_DirectSoundCaptureBuffer)
  33. #ifdef USING_IDISPATCH
  34. COM_INTERFACE_ENTRY(IDispatch)
  35. COM_INTERFACE_ENTRY(ISupportErrorInfo)
  36. #endif
  37. END_COM_MAP()
  38. // DECLARE_REGISTRY(CLSID__dxj_DirectSoundCaptureBuffer, "DIRECT.DirectSoundCaptureBuffer.5", "DIRECT.DirectSoundCaptureBuffer.5", IDS_DSOUNDBUFFER_DESC, THREADFLAGS_BOTH)
  39. // Use DECLARE_NOT_AGGREGATABLE(C_dxj_DirectSoundCaptureBufferObject) if you don't want your object
  40. // to support aggregation
  41. DECLARE_AGGREGATABLE(C_dxj_DirectSoundCaptureBufferObject)
  42. #ifdef USING_IDISPATCH
  43. // ISupportsErrorInfo
  44. STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid);
  45. #endif
  46. // I_dxj_DirectSoundCaptureBuffer
  47. public:
  48. //updated
  49. /* [hidden] */ HRESULT STDMETHODCALLTYPE InternalSetObject(
  50. /* [in] */ IUnknown __RPC_FAR *lpdd);
  51. /* [hidden] */ HRESULT STDMETHODCALLTYPE InternalGetObject(
  52. /* [retval][out] */ IUnknown __RPC_FAR *__RPC_FAR *lpdd);
  53. HRESULT STDMETHODCALLTYPE getCaps(
  54. /* [out][in] */ DSCBCaps __RPC_FAR *caps);
  55. HRESULT STDMETHODCALLTYPE getCurrentPosition( DSCursors *desc);
  56. HRESULT STDMETHODCALLTYPE getFormat(
  57. /* [out][in] */ WaveFormatex __RPC_FAR *waveformat);
  58. HRESULT STDMETHODCALLTYPE getStatus(
  59. /* [retval][out] */ long __RPC_FAR *status);
  60. /* [hidden] */ HRESULT STDMETHODCALLTYPE initialize(
  61. /* [in] */ I_dxj_DirectSoundCaptureBuffer __RPC_FAR *captureBuffer,
  62. /* [in] */ DSCBufferDesc __RPC_FAR *bufferDesc);
  63. HRESULT STDMETHODCALLTYPE start(
  64. /* [in] */ long flags);
  65. HRESULT STDMETHODCALLTYPE stop( void);
  66. HRESULT STDMETHODCALLTYPE setNotificationPositions(long nElements,SAFEARRAY **ppsa);
  67. HRESULT STDMETHODCALLTYPE readBuffer(long start, long totsz,
  68. void *buf, long flags) ;
  69. HRESULT STDMETHODCALLTYPE writeBuffer(long start, long totsz,
  70. void *buf, long flags) ;
  71. private:
  72. DECL_VARIABLE(_dxj_DirectSoundCaptureBuffer);
  73. public:
  74. DX3J_GLOBAL_LINKS( _dxj_DirectSoundCaptureBuffer )
  75. };