Source code of Windows XP (NT5)
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.

127 lines
4.0 KiB

  1. /*++
  2. Copyright (c) 2001 Microsoft Corporation. All rights reserved.
  3. Module Name:
  4. ksmediap.h
  5. Abstract:
  6. Private WDM multimedia definitions used only by Microsoft components.
  7. Moved here from ksmedia.h. Some of these are obsolescent (e.g. ITD).
  8. --*/
  9. #ifndef _KSMEDIAP_H
  10. #define _KSMEDIAP_H
  11. #define CORE_AUDIO_BUFFER_DURATION_PATH L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\AudioSrv"
  12. #define CORE_AUDIO_BUFFER_DURATION_VALUE L"CoreAudioBufferDuration"
  13. #define DEFAULT_CORE_AUDIO_BUFFER_DURATION 10000 // duration in usec.
  14. #define MAX_CORE_AUDIO_BUFFER_DURATION 20000
  15. #define MIN_CORE_AUDIO_BUFFER_DURATION 1000
  16. //===========================================================================
  17. // Definitions intended for hardware acceleration of the HRTF 3D algorithm
  18. //===========================================================================
  19. #define KSDSOUND_BUFFER_CTRL_HRTF_3D 0x40000000
  20. typedef struct {
  21. ULONG Size; // This is the size of the struct in bytes
  22. ULONG Enabled;
  23. BOOL SwapChannels;
  24. BOOL ZeroAzimuth;
  25. BOOL CrossFadeOutput;
  26. ULONG FilterSize; // This is the additional size of the filter coeff in bytes
  27. } KSDS3D_HRTF_PARAMS_MSG, *PKSDS3D_HRTF_PARAMS_MSG;
  28. // HRTF filter quality levels
  29. typedef enum {
  30. FULL_FILTER,
  31. LIGHT_FILTER,
  32. KSDS3D_FILTER_QUALITY_COUNT
  33. } KSDS3D_HRTF_FILTER_QUALITY;
  34. typedef struct {
  35. ULONG Size; // This is the size of the struct in bytes
  36. KSDS3D_HRTF_FILTER_QUALITY Quality;
  37. FLOAT SampleRate;
  38. ULONG MaxFilterSize;
  39. ULONG FilterTransientMuteLength;
  40. ULONG FilterOverlapBufferLength;
  41. ULONG OutputOverlapBufferLength;
  42. ULONG Reserved;
  43. } KSDS3D_HRTF_INIT_MSG, *PKSDS3D_HRTF_INIT_MSG;
  44. // Coefficient formats
  45. typedef enum {
  46. FLOAT_COEFF,
  47. SHORT_COEFF,
  48. KSDS3D_COEFF_COUNT
  49. } KSDS3D_HRTF_COEFF_FORMAT;
  50. // Filter methods
  51. typedef enum {
  52. DIRECT_FORM,
  53. CASCADE_FORM,
  54. KSDS3D_FILTER_METHOD_COUNT
  55. } KSDS3D_HRTF_FILTER_METHOD;
  56. // Filter methods
  57. typedef enum {
  58. DS3D_HRTF_VERSION_1
  59. } KSDS3D_HRTF_FILTER_VERSION;
  60. typedef struct {
  61. KSDS3D_HRTF_FILTER_METHOD FilterMethod;
  62. KSDS3D_HRTF_COEFF_FORMAT CoeffFormat;
  63. KSDS3D_HRTF_FILTER_VERSION Version;
  64. ULONG Reserved;
  65. } KSDS3D_HRTF_FILTER_FORMAT_MSG, *PKSDS3D_HRTF_FILTER_FORMAT_MSG;
  66. #define STATIC_KSPROPSETID_Hrtf3d\
  67. 0xb66decb0L, 0xa083, 0x11d0, 0x85, 0x1e, 0x00, 0xc0, 0x4f, 0xd9, 0xba, 0xf3
  68. DEFINE_GUIDSTRUCT("b66decb0-a083-11d0-851e-00c04fd9baf3", KSPROPSETID_Hrtf3d);
  69. #define KSPROPSETID_Hrtf3d DEFINE_GUIDNAMED(KSPROPSETID_Hrtf3d)
  70. typedef enum {
  71. KSPROPERTY_HRTF3D_PARAMS = 0,
  72. KSPROPERTY_HRTF3D_INITIALIZE,
  73. KSPROPERTY_HRTF3D_FILTER_FORMAT
  74. } KSPROPERTY_HRTF3D;
  75. //===========================================================================
  76. // Definitions related to the obsolete Interaural Time Delay 3D algorithm
  77. //===========================================================================
  78. // DirectSound3D FIR context
  79. typedef struct {
  80. LONG Channel;
  81. FLOAT VolSmoothScale;
  82. FLOAT TotalDryAttenuation;
  83. FLOAT TotalWetAttenuation;
  84. LONG SmoothFrequency;
  85. LONG Delay;
  86. } KSDS3D_ITD_PARAMS, *PKSDS3D_ITD_PARAMS;
  87. typedef struct {
  88. ULONG Enabled;
  89. KSDS3D_ITD_PARAMS LeftParams;
  90. KSDS3D_ITD_PARAMS RightParams;
  91. ULONG Reserved;
  92. } KSDS3D_ITD_PARAMS_MSG, *PKSDS3D_ITD_PARAMS_MSG;
  93. #define STATIC_KSPROPSETID_Itd3d\
  94. 0x6429f090L, 0x9fd9, 0x11d0, 0xa7, 0x5b, 0x00, 0xa0, 0xc9, 0x03, 0x65, 0xe3
  95. DEFINE_GUIDSTRUCT("6429f090-9fd9-11d0-a75b-00a0c90365e3", KSPROPSETID_Itd3d);
  96. #define KSPROPSETID_Itd3d DEFINE_GUIDNAMED(KSPROPSETID_Itd3d)
  97. typedef enum {
  98. KSPROPERTY_ITD3D_PARAMS = 0
  99. } KSPROPERTY_ITD3D;
  100. #endif /* _KSMEDIAP_H */