pa_win_wdmks.h 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. #ifndef PA_WIN_WDMKS_H
  2. #define PA_WIN_WDMKS_H
  3. /*
  4. * $Id: pa_win_wdmks.h 1812 2012-02-14 09:32:57Z robiwan $
  5. * PortAudio Portable Real-Time Audio Library
  6. * WDM/KS specific extensions
  7. *
  8. * Copyright (c) 1999-2007 Ross Bencina and Phil Burk
  9. *
  10. * Permission is hereby granted, free of charge, to any person obtaining
  11. * a copy of this software and associated documentation files
  12. * (the "Software"), to deal in the Software without restriction,
  13. * including without limitation the rights to use, copy, modify, merge,
  14. * publish, distribute, sublicense, and/or sell copies of the Software,
  15. * and to permit persons to whom the Software is furnished to do so,
  16. * subject to the following conditions:
  17. *
  18. * The above copyright notice and this permission notice shall be
  19. * included in all copies or substantial portions of the Software.
  20. *
  21. * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  22. * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  23. * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  24. * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
  25. * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
  26. * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  27. * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  28. */
  29. /*
  30. * The text above constitutes the entire PortAudio license; however,
  31. * the PortAudio community also makes the following non-binding requests:
  32. *
  33. * Any person wishing to distribute modifications to the Software is
  34. * requested to send the modifications to the original developer so that
  35. * they can be incorporated into the canonical version. It is also
  36. * requested that these non-binding requests be included along with the
  37. * license above.
  38. */
  39. /** @file
  40. @ingroup public_header
  41. @brief WDM Kernel Streaming-specific PortAudio API extension header file.
  42. */
  43. #include "portaudio.h"
  44. #include <windows.h>
  45. #ifdef __cplusplus
  46. extern "C"
  47. {
  48. #endif /* __cplusplus */
  49. typedef struct PaWinWDMKSInfo{
  50. unsigned long size; /**< sizeof(PaWinWDMKSInfo) */
  51. PaHostApiTypeId hostApiType; /**< paWDMKS */
  52. unsigned long version; /**< 1 */
  53. /* The number of packets to use for WaveCyclic devices, range is [2, 8]. Set to zero for default value of 2. */
  54. unsigned noOfPackets;
  55. } PaWinWDMKSInfo;
  56. typedef enum PaWDMKSType
  57. {
  58. Type_kNotUsed,
  59. Type_kWaveCyclic,
  60. Type_kWaveRT,
  61. Type_kCnt,
  62. } PaWDMKSType;
  63. typedef enum PaWDMKSSubType
  64. {
  65. SubType_kUnknown,
  66. SubType_kNotification,
  67. SubType_kPolled,
  68. SubType_kCnt,
  69. } PaWDMKSSubType;
  70. typedef struct PaWinWDMKSDeviceInfo {
  71. wchar_t filterPath[MAX_PATH]; /**< KS filter path in Unicode! */
  72. wchar_t topologyPath[MAX_PATH]; /**< Topology filter path in Unicode! */
  73. PaWDMKSType streamingType;
  74. GUID deviceProductGuid; /**< The product GUID of the device (if supported) */
  75. } PaWinWDMKSDeviceInfo;
  76. typedef struct PaWDMKSDirectionSpecificStreamInfo
  77. {
  78. PaDeviceIndex device;
  79. unsigned channels; /**< No of channels the device is opened with */
  80. unsigned framesPerHostBuffer; /**< No of frames of the device buffer */
  81. int endpointPinId; /**< Endpoint pin ID (on topology filter if topologyName is not empty) */
  82. int muxNodeId; /**< Only valid for input */
  83. PaWDMKSSubType streamingSubType; /**< Not known until device is opened for streaming */
  84. } PaWDMKSDirectionSpecificStreamInfo;
  85. typedef struct PaWDMKSSpecificStreamInfo {
  86. PaWDMKSDirectionSpecificStreamInfo input;
  87. PaWDMKSDirectionSpecificStreamInfo output;
  88. } PaWDMKSSpecificStreamInfo;
  89. #ifdef __cplusplus
  90. }
  91. #endif /* __cplusplus */
  92. #endif /* PA_WIN_DS_H */