SYSVAD 音訊範例
系統虛擬音訊裝置驅動程式範例 (SYSVAD)
SYSVAD 驅動程式突顯 WDM 音訊架構的許多重要功能。 這些是原始程式碼的工作實作,可作為撰寫專屬音訊裝置自訂驅動程式的起點。
The sysvad solution file contains the following projects.
TabletAudioSample
The TabletAudioSample project demonstrates how to develop a WDM audio driver that exposes support for multiple audio devices. 其中一些音頻設備嵌入系統中(揚聲器、麥克風陣列),而其他音頻設備則可插拔(耳機揚聲器/麥克風、藍牙耳機揚聲器/麥克風)。 驅動程式會使用 WaveRT 和音訊卸載來轉譯裝置。 驅動程式會使用「虛擬音訊裝置」,而不是實際的硬體型配接器,並醒目提示音訊卸載 WDM 音訊驅動程式架構的不同層面。 如需 Windows 音訊引擎的詳細資訊,請參閱 Hardware-Offloaded 音訊處理 (Windows 驅動程式)。
EndpointsCommon
The EndpointsCommon project contains common code to both the tablet and phone. 如需詳細資訊,請參閱 音訊的通用 Windows 驅動程式。
SwapAPO
The SwapAPO project demonstrates how to develop audio processing objects. 它包含範例程式碼,示範如何註冊和取消註冊音訊處理物件,也示範如何自定義控制台屬性頁,以反映處理物件中的可用功能。 如需詳細資訊,請參閱 Windows 音訊處理物件。
KeywordDetectorAdapter
The KeywordDetectorAdapter project demonstrates how to develop a keyword detector adapter. For more information, see Voice Activation.
從 GitHub 下載並擷取 Sysvad 音訊範例
Windows 驅動程式範例 GitHub 上提供 SYSVAD 音訊範例。
您可以在這裡瀏覽 Sysvad 音訊範例。
https://github.com/Microsoft/Windows-driver-samples/tree/main/audio/sysvad
請遵循下列步驟來下載並開啟SYSVAD範例。
a. 您可以使用 GitHub 工具來處理範例。 您也可以在一個 zip 檔案中下載通用驅動程式範例。
https://github.com/Microsoft/Windows-driver-samples/archive/master.zip
b. 將 master.zip 檔案下載到本機硬碟。
c. Select and hold (or right-click)Windows-driver-samples-master.zip, and choose Extract All. 指定新的資料夾,或瀏覽至將儲存解壓縮檔的現有資料夾。 For example, you could specify C:\DriverSamples\ as the new folder into which the files will be extracted.
d. 擷取檔案之後,流覽至下列子資料夾。
C:\DriverSamples\Audio\Sysvad
在 Visual Studio 中開啟驅動程式解決方案
In Microsoft Visual Studio, Select File>Open>Project/Solution... and navigate to the folder that contains the extracted files (for example, C:\DriverSamples\Audio\Sysvad). Double-click the Sysvad solution file to open it.
在 Visual Studio 中,找到 [方案總管]。 (If this is not already open, choose Solution Explorer from the View menu.) In Solution Explorer, you can see one solution that has six projects.
存檔的音訊樣本
這些音訊範例支援舊版的 Microsoft Windows 驅動程式套件 (WDK) 。 它們可作為 zip 檔案下載的一部分使用。
Microsoft 虛擬音訊裝置驅動程式範例 (Msvad)
AC97 驅動器 (AC97)
DirectMusic UART 驅動程式範例 (Dmusuart)
DirectMusic 軟體合成器樣本 (ddksynth)
FM 合成器 (Fmsynth)
音訊配接器範例
音訊處理編解碼器範例
Msfilter 範例編解碼器 (MsFilter)
Msgsm610 範例編解碼器 (gsm610)
如需詳細資訊,請參閱 WDK 中每個範例隨附的讀我文件。
如需 WDK 範例的相關資訊,請參閱 Windows 驅動程式套件範例套件 (Windows 驅動程式) 。