Configuring Microsoft Teams for Windows Virtual Desktop (WVD)


Microsoft announced the General Release (GA) of Microsoft Teams on Windows Virtual Desktop (with media optimisation) on Monday the 27th of July 2020. A/V Redirection for Microsoft Teams is one of the GA features that many have been waiting for. Read more here from KamVedBrat on the announcement

In this article, I will run through the summary stages of preparing for MS Teams on Windows Virtual Desktop and discuss the tool I have created to streamline the whole process. The tool is a manual function however, I have also created a script for deploying using a Custom Script Extension though Azure’s ARM panel. The link and video for this is provided at the end of this article.

High level configuration Steps:

Apply the WVD required registry key
Install the C++ Runtime requirement
Install the Remote Desktop WebRTC Service.
Install the Teams desktop App
Configure RDP Properties (configure device redirection for Teams)
Check the version for “ WVD Media Optimised ” status

What is WebRTC-based P2P:

So previously, MS Teams’s Audio and Video on WVD was encoded and decoded multiple times before reaching the other end of the call. This method creates latency, that then impacts the performance and quality of the video and possibly the underlining host performance. It is also important to note, that re-encoding on a VM without a GPU is CPU intensive and most often impacts the host and other users logged using the desktop. This does not mean all the problems go away when using a GPU…

AV redirection for Teams essentially offloads (bypasses) the Window Virtual Desktop Virtual Machine and sends the A/V data directly to the call clients. This provides a better user experience for the WVD users on the Teams call. This method uses the client hardware to encode and decode.

Key points:

Peer to peer (P2P) – traffic will flow from the user to user device and rendering is completed at the physical endpoint.
It is also important to note that devices will be redirected using the same hardware device to support better hardware redirection support.
One key benefit of using a Windows 10 client is the benefits of using the modern media stack including HW video decoding. It has been suggested that you would achieve the best experience using a Windows 10 Client.

WebRTC Diagram for Teams

The diagram below depicts how WebRTC for Teams works using Windows Virtual Desktop.

Preparation for Microsoft teams

The first step ( step 1. ) is to ensure that all the client devices, firewalls and other security devices do not restrict the following:

UDP ports  3478  through  3481

IP addresses...