混合實境開發簡介

混合實境是一個很大的地方,也就是真實和虛擬世界碰撞的交會點。 無限可能,從您開始。 選擇您的引擎、下載您的工具,以及備好鍵盤待用。 歡迎使用混合實境生態系統 - 該是建立的時候了。
開發選項
Unity -Unity 是市場上領先業界的其中一個即時開發平台,包含以 C++ 撰寫的基礎執行階段程式碼,並在 C# 中完成所有開發指令碼。 無論您想要打造遊戲、電影和動畫電影藝術,甚至要在虛擬世界中轉譯架構或工程概念,Unity 都有可支援您的基礎結構。
Unreal - Unreal Engine 4 是功能強大的開放原始碼建立引擎,具備對 C++ 和 Blueprints 混合實境的完整支援。 從 Unreal Engine 4.25 開始,HoloLens 支援已具備完整功能且可供生產環境使用。 藉由使用靈活的 Blueprints Visual Scripting 系統功能,設計人員幾乎可以使用通常僅適用於程式設計人員的完整概念和工具。 各行各業的建立者可以利用自由和控制來提供最先進的內容、互動式體驗和沉浸式虛擬世界。
原生 (OpenXR) - OpenXR 是 Khronos 中開放且免權利金的 API 標準,可讓引擎以原生方式對多個跨混合實境頻譜的廠商存取其中各種裝置。 您可以在 HoloLens 2 上使用 OpenXR 或在電腦上使用 Windows Mixed Reality 沉浸式頭戴裝置進行開發。 如果您無法存取頭戴式裝置,則可使用適用於 HoloLens 2 和 Windows Mixed Reality 頭戴式裝置的模擬器。
您對哪像技術主題感興趣?
您可以透過我們的文件採用數個開發路徑。 第一個步驟是尋找最適合您的技術。 如果您已有屬意的技術,請直接跳到下方與其對應的索引標籤。 如果您抱持觀望態度或才剛開始,請逐一查看每項技術並了解其所提供的內容、可用的平台和工具,然後開始建立!
重要
如果您有現有專案要帶到 HoloLens 2 或沉浸式 VR頭戴式裝置 (例如 Reverb G2),請參閱我們的 移植指南概觀 。 對於使用 HTK、MRTK v1、SteamVR 的專案,或針對沉浸式頭戴裝置 (例如 Oculus Rift 或 HTC Vive) 開發的專案,我們都提供了相關指南。

使用 Unity 建置跨平台、功能完整的混合實境應用程式。Build a cross-platform, full-featured mixed reality app with Unity. 請參閱 Unity 開發概觀,開始進行適用於 HoloLens 或 Windows Mixed Reality 沉浸式頭戴裝置的 Unity 開發。See the Unity development overview to get started with Unity development for HoloLens or Windows Mixed Reality immersive headsets.
使用 Unity 建置混合實境應用程式時,您有數個硬體和模擬器選項。You have several hardware and emulator options when building Mixed Reality apps with Unity. 雖然我們的開發人員文件著重於 HoloLens 裝置,但您會在適用的情況下找到裝置支援章節,其中包含沉浸式頭戴裝置部署的詳細資料。While our developer documentation focuses on HoloLens devices, you'll find device support sections with details on immersive headset deployment when applicable.
擴增實境裝置Augmented reality devices
沉浸式 VR 頭戴裝置Immersive VR headsets
- HP Reverb 和 Reverb G2HP Reverb and Reverb G2
- Samsung Odyssey 和 Odyssey+Samsung Odyssey and Odyssey+
- HP Windows Mixed Reality 頭戴式裝置HP Windows Mixed Reality headset
- Lenovo ExplorerLenovo Explorer
- Acer AH101Acer AH101
- Dell VisorDell Visor
- Asus HC102Asus HC102
- Acer OJO 500Acer OJO 500
工具/SDKTool/SDK |
說明Description |
適用於 Unity 的混合實境工具組Mixed Reality Toolkit for Unity |
適用於 Unity 的混合實境工具組是一個開放原始碼跨平台開發套件,主要用於加速開發以 Microsoft HoloLens、Windows Mixed Reality 沉浸式 (VR) 頭戴裝置和 OpenVR 平台為目標的應用程式。The Mixed Reality Toolkit for Unity is an open source cross-platform development kit built to accelerate development of applications targeting Microsoft HoloLens, Windows Mixed Reality immersive (VR) headsets and OpenVR platform. |
雲端服務Cloud services
有數個雲端服務可以整合到 Unity 內建的混合實境專案中,特別是 Azure 遠端轉譯 和 Azure Spatial Anchors。There are several cloud services that can be integrated into Mixed Reality projects built in Unity, specifically Azure Remote Rendering and Azure Spatial Anchors. 這些服務可以將共用的全像攝影內容和即時 3D 轉譯新增至您的應用程式,使其更吸引人且更適合您的使用者。These services can add shared holographic content and real-time 3D rendering to your applications, making them more compelling and immersive for your users.
這些服務全都涵蓋於 適用於 HoloLens 的 Unity 開發旅程課程中,我們 強烈建議透過此途徑學習 Unity 的混合實境。All of these services are covered over the course of the Unity development for HoloLens journey, which is the strongly recommended path for learning Mixed Reality with Unity. 您已在此路徑中,因此只要繼續閱讀,然後點按文章最底下的大型藍色按鈕即可。You're already on this path, so just keep reading and follow the big blue button at the bottom of the article. 不過,如果目前處於更進階的開發階段中,且您已確定要開始進行,請參閱我們的雲端服務概觀,或直接移至服務資源。However, if you're at a more advanced development stage and already know you want to jump in, check out our cloud services overview or go directly to the services resources.
Dynamics 365 GuidesDynamics 365 Guides
您可以使用 Microsoft Dynamics 365 Guides,以視覺方式將全像攝影指示傳輸至應用程式虛擬環境,適時適地為您的使用者提供重要資訊。You can use Microsoft Dynamics 365 Guides to visually tether holographic instructions to your apps virtual environment, giving your users important information when and where it's needed. 適用於 HoloLens 的 Unity 開發旅程中也涵蓋這項功能,但如果您要直接跳過去,您可以從這裡選取 [Dynamics 365] 索引標籤,以查看有哪些供應項目。This feature is also covered in the Unity development for HoloLens journey, but if you want to jump ahead you can see what's on offer by selecting the Dynamics 365 tab here.
範例Examples
我們有數個開放原始碼範例應用程式可供您下載和試用,以熟悉 Unity 中的混合實境最終產品。We have several open source sample apps for you to download and play around with to get a feel for a Mixed Reality end product in Unity. 您也可使用 MRTK 範例場景來試用特定功能:There are also MRTK example scenes available for you to test out specific features:
注意
這兩個 MRTK 範例場景都需要安裝 MRTK 基礎和範例 Unity 套件。Both of the MRTK example scenes require MRTK Foundation and Example Unity packages to be installed.

使用 Unreal 建置跨平台、功能完整的混合實境應用程式。Build a cross-platform, full-featured mixed reality app with Unreal. 請參閱 Unreal 開發概觀,開始進行適用於 HoloLens 的 Unreal 開發。See the Unreal development overview to get started with Unreal development for HoloLens.
使用 Unreal Engine 建置混合實境應用程式時,您有數個硬體、模擬器和串流選項。You have several hardware, emulator, and streaming options when building Mixed Reality apps with Unreal Engine. 雖然我們的開發人員文件著重于 HoloLens 裝置,但您可以將 Unreal 專案封裝成 x64 桌面應用程式並直接在沉浸式頭戴裝置上執行。While our developer documentation focuses on HoloLens devices, you can package your Unreal projects as x64 desktop apps and run them on immersive headsets just fine.
擴增實境裝置Augmented reality devices
沉浸式 VR 頭戴裝置Immersive VR headsets
- HP Reverb 和 Reverb G2HP Reverb and Reverb G2
- Samsung Odyssey 和 Odyssey+Samsung Odyssey and Odyssey+
- HP Windows Mixed Reality 頭戴式裝置HP Windows Mixed Reality headset
- Lenovo ExplorerLenovo Explorer
- Acer AH101Acer AH101
- Dell VisorDell Visor
- Asus HC102Asus HC102
- Acer OJO 500Acer OJO 500
工具/SDKTool/SDK |
說明Description |
適用于 Unreal 的 UX 工具UX Tools for Unreal |
UX 工具是要發行的第一個外掛程式,目前只有 HoloLens 2 才支援。UX Tools is the first plugin to be released and is currently only supported on HoloLens 2. 外掛程式包含 C++ 程式碼、藍圖,以及用於輸入模擬、手部互動、表面磁性的常見 UX 功能的範例資產。The plugin includes C++ code, Blueprints, and example assets of common UX features for input simulation, hand interactions, surface magnetism and more. |
適用于 Unreal 的圖形工具Graphics Tools for Unreal |
圖形工具是一種 UE 遊戲外掛程式,其中包含程式碼、藍圖和範例資產,可協助改善混合現實應用程式的視覺精確度,同時維持在效能預算內。Graphics Tools is a UE game plugin with code, blueprints and example assets created to help improve the visual fidelity of Mixed Reality applications while staying within performance budgets. |
雲端服務Cloud services
在 Unreal 中建置混合實境應用程式時,您可以存取功能強大的雲端服務 Azure Spatial Anchors,用以在不同的裝置間新增、保存及共用全像攝影內容。When building Mixed Reality apps in Unreal, you have access to a powerful cloud service called Azure Spatial Anchors, which you can use to add, persist, and share holographic content across different devices.
Azure Spatial Anchors 涵蓋於 Unreal 開發旅程的課程中,我們 強烈建議透過此途徑學習 Unreal 的混合實境。Azure Spatial Anchors is covered over the course of the Unreal development journey, which is the strongly recommended path for learning Mixed Reality with Unreal. 您已在此路徑中,因此只要繼續閱讀,然後點按文章最底下的大型藍色按鈕即可。You're already on this path, so just keep reading and follow the big blue button at the bottom of the article. 不過,如果目前處於更進階的開發階段中,且您已確定要開始進行,請參閱我們的雲端服務概觀,或直接移至服務資源。However, if you're at a more advanced development stage and already know you want to jump in, check out our cloud services overview or go directly to the services resources.
Dynamics 365 GuidesDynamics 365 Guides
您可以使用 Microsoft Dynamics 365 Guides,以視覺方式將全像攝影指示傳輸至應用程式虛擬環境,適時適地為您的使用者提供重要資訊。You can use Microsoft Dynamics 365 Guides to visually tether holographic instructions to your apps virtual environment, giving your users important information when and where it's needed. Unreal 開發旅程中也涵蓋這項功能,但如果您要直接跳過去,您可以從這裡選取 [Dynamics 365] 索引標籤,以查看有哪些供應項目。This feature is also covered in the Unreal development journey, but if you want to jump ahead you can see what's on offer by selecting the Dynamics 365 tab here.
範例Examples
- Kippy's Escape - Kippy's Escape 是一種開放原始碼 HoloLens 2 範例應用程式,是以 Unreal Engine 4 和適用於 Unreal 的混合實境 UX 工具建置的。Kippy's Escape - Kippy’s Escape is an open-source HoloLens 2 sample app built with Unreal Engine 4 and Mixed Reality UX Tools for Unreal. 遊戲展示了 HoloLens 2 硬體的獨特功能,以及混合實境 UX 工具的強大開發功能。The game showcases the unique features of the HoloLens 2 hardware and the development power of the Mixed Reality UX Tools.

WebXR 裝置 API 是一種開放的規格,可讓您在任何平台上您的瀏覽器中體驗混合實境應用程式。The WebXR Device API is an open specification that allows you to experience Mixed Reality apps in your browser on any platform. 請參閱 Javascript 開發概觀,開始為任何平台建立混合實境應用程式。See the JavaScript development overview to get started building Mixed Reality apps for any platform.

直接編寫 Windows Mixed Reality API 程式碼以建立混合實境應用程式。Create mixed reality apps with a direct line to the Windows Mixed Reality APIs. 請參閱原生開發概觀,開始使用 OpenXR 或舊版 WinRT 進行適用於 HoloLens 2 或 Windows Mixed Reality 沉浸式頭戴裝置的原生應用程式開發。See the Native development overview to get started with native app development using OpenXR or legacy WinRT for HoloLens 2 or Windows Mixed Reality immersive headsets. Windows Mixed Reality API 支援以 C++ 和 C# 撰寫的應用程式,可讓您以任一種語言建置自己的架構或中介軟體。The Windows Mixed Reality API supports applications written in C++ and C#, allowing you to build your own framework or middleware in either language.
透過 OpenXR 開發建置混合實境應用程式時,您有數個硬體、模擬器和串流選項。You have several hardware, emulator, and streaming options when building Mixed Reality apps with OpenXR development.
擴增實境裝置Augmented reality devices
沉浸式 VR 頭戴裝置Immersive VR headsets
- HP Reverb 和 Reverb G2HP Reverb and Reverb G2
- Samsung Odyssey 和 Odyssey+Samsung Odyssey and Odyssey+
- HP Windows Mixed Reality 頭戴式裝置HP Windows Mixed Reality headset
- Lenovo ExplorerLenovo Explorer
- Acer AH101Acer AH101
- Dell VisorDell Visor
- Asus HC102Asus HC102
- Acer OJO 500Acer OJO 500
工具/SDKTool/SDK |
說明Description |
OpenXR 開發人員工具OpenXR Developer Tools |
提供一個示範場景來練習 OpenXR 的各種功能,以及一個系統狀態頁面,其中提供作用中執行階段和目前頭戴式裝置的重要資訊。Provides a demo scene that exercises various features of OpenXR, along with a System Status page that provides key information about the active runtime and the current headset. |
OpenXR 規格OpenXR Spec |
描述 OpenXR 是什麼、其所提供的功能,以及如何在您自己的專案中加以實作。Describes what OpenXR is, what capabilities and features it offers, and how to implement it into your own projects. |
OpenXR 載入器OpenXR Loader |
探索裝置上的作用中 OpenXR 執行階段,以及提供其所實作核心功能和擴充功能的存取權。Discovers the active OpenXR runtime on the device and provides access to the core functions and extension functions that it implements. |
範例Examples
歡迎您試著使用範例應用程式來了解原生開發和混合實境可能達到的境界。Feel free to play around with the sample app to get a feel for what's possible with Native development and Mixed Reality.
- BasicXrApp - 示範一個簡單的 OpenXR 範例,其中包含兩個 Visual Studio 專案檔,一個用於 Win32 桌面應用程式,另一個用於 UWP HoloLens 2 應用程式。BasicXrApp - Demonstrates a simple OpenXR sample with two Visual Studio project files, one for both a Win32 desktop app and one for a UWP HoloLens 2 app.
您也可以觀看 60 分鐘的 BasicXrApp 逐步解說,此逐步解說會在 Visual Studio 中導覽 OpenXR API 的所有重要元件:You can also watch a 60-minute walkthrough of BasicXrApp that tours all key components of the OpenXR API in Visual Studio:
接下來要做什麼?
既然您已有屬意的技術路徑,讓我們為您提供開始旅程所需的工具。