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.

89 lines
3.0 KiB

  1. // dsdmoprp.cpp : Implementation of DLL Exports.
  2. // Note: Proxy/Stub Information
  3. // To build a separate proxy/stub DLL,
  4. // run nmake -f dsdmoprpps.mk in the project directory.
  5. #include "stdafx.h"
  6. #include "resource.h"
  7. #include <initguid.h>
  8. #include "dsdmoprp.h"
  9. #include "dsdmoprp_i.c"
  10. #include "DirectSoundFXChorusPage.h"
  11. #include "DirectSoundFXCompressorPage.h"
  12. #include "DirectSoundFXDistortionPage.h"
  13. #include "DirectSoundFXEchoPage.h"
  14. #include "DirectSoundFXFlangerPage.h"
  15. #include "DirectSoundFXParamEqPage.h"
  16. #include "DirectSoundFXGarglePage.h"
  17. #include "DirectSoundFXWavesReverbPage.h"
  18. //#include "DirectSoundFXI3DL2SourcePage.h"
  19. #include "DirectSoundFXI3DL2ReverbPage.h"
  20. CComModule _Module;
  21. BEGIN_OBJECT_MAP(ObjectMap)
  22. OBJECT_ENTRY(CLSID_DirectSoundFXChorusPage, CDirectSoundFXChorusPage)
  23. OBJECT_ENTRY(CLSID_DirectSoundFXCompressorPage, CDirectSoundFXCompressorPage)
  24. OBJECT_ENTRY(CLSID_DirectSoundFXDistortionPage, CDirectSoundFXDistortionPage)
  25. OBJECT_ENTRY(CLSID_DirectSoundFXEchoPage, CDirectSoundFXEchoPage)
  26. OBJECT_ENTRY(CLSID_DirectSoundFXFlangerPage, CDirectSoundFXFlangerPage)
  27. OBJECT_ENTRY(CLSID_DirectSoundFXParamEqPage, CDirectSoundFXParamEqPage)
  28. OBJECT_ENTRY(CLSID_DirectSoundFXGarglePage, CDirectSoundFXGarglePage)
  29. OBJECT_ENTRY(CLSID_DirectSoundFXWavesReverbPage, CDirectSoundFXWavesReverbPage)
  30. //OBJECT_ENTRY(CLSID_DirectSoundFXI3DL2SourcePage, CDirectSoundFXI3DL2SourcePage)
  31. OBJECT_ENTRY(CLSID_DirectSoundFXI3DL2ReverbPage, CDirectSoundFXI3DL2ReverbPage)
  32. END_OBJECT_MAP()
  33. /////////////////////////////////////////////////////////////////////////////
  34. // DLL Entry Point
  35. extern "C"
  36. BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID /*lpReserved*/)
  37. {
  38. if (dwReason == DLL_PROCESS_ATTACH)
  39. {
  40. _Module.Init(ObjectMap, hInstance, &LIBID_DSDMOPRPLib);
  41. DisableThreadLibraryCalls(hInstance);
  42. }
  43. else if (dwReason == DLL_PROCESS_DETACH)
  44. _Module.Term();
  45. return TRUE; // ok
  46. }
  47. /////////////////////////////////////////////////////////////////////////////
  48. // Used to determine whether the DLL can be unloaded by OLE
  49. STDAPI DllCanUnloadNow(void)
  50. {
  51. return (_Module.GetLockCount()==0) ? S_OK : S_FALSE;
  52. }
  53. /////////////////////////////////////////////////////////////////////////////
  54. // Returns a class factory to create an object of the requested type
  55. STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv)
  56. {
  57. return _Module.GetClassObject(rclsid, riid, ppv);
  58. }
  59. /////////////////////////////////////////////////////////////////////////////
  60. // DllRegisterServer - Adds entries to the system registry
  61. STDAPI DllRegisterServer(void)
  62. {
  63. // registers object, typelib and all interfaces in typelib
  64. return _Module.RegisterServer(TRUE);
  65. }
  66. /////////////////////////////////////////////////////////////////////////////
  67. // DllUnregisterServer - Removes entries from the system registry
  68. STDAPI DllUnregisterServer(void)
  69. {
  70. return _Module.UnregisterServer(TRUE);
  71. }