[Critical Bug] ScreenCapture shows content in Discord

J. Diego Rodríguez Royo 6 Reputation points
2022-11-04T15:14:22.273+00:00

I have been trying this UWP sample and it work cool, but it has a critical bug with Discord (and maybe other streaming/video screen share apps).
I built the example and I opened it, then I shared my screen on discord. If it's the whole screen, it works by hiding all the app content with

IsScreenCaptureEnabled = false

But not so cool with

AppCapture.SetAllowedAsync(true)

(It shows all the app content, Windows doesn't even detect that it is being captured by Discord!)

But the more critical bug if I use IsScreenCaptureEnabled = false, I put the video on the app, and in Discord I select to transmit that specific app only that it is trying to block the capture, it will show the video on Discord (and only the video, it's like it focuses on the video, but that happens too without screen capture blocking).

This issue happens at UWP but it could happen too at WindowsApp SDK (I couldn't find a way to disable screen captures in WindowsApp SDK to try to reproduce the issue)

Universal Windows Platform (UWP)
Windows App SDK
Windows App SDK
A set of Microsoft open-source libraries, frameworks, components, and tools to be used in apps to access Windows platform functionality on many versions of Windows. Previously known as Project Reunion.
725 questions
{count} votes