keijiro / AsyncCaptureTest

Non-blocking screen capture example with asynchronous GPU readback

Repository from Github https://github.comkeijiro/AsyncCaptureTestRepository from Github https://github.comkeijiro/AsyncCaptureTest

AsyncCaptureTest

screenshot

This Unity sample project shows how to use the asynchronous GPU readback API to capture render outputs without blocking the main thread.

Note that there is a trade-off between performance and latency. It's only applicable when a small amount of latency is acceptable. Screen capture is one of the best-fit cases for the feature.

Unity 2023 Update

I updated this project to use the Awaitable class introduced in Unity 2023.1. Now you can use the GPU readback API with the C# asynchronous programming features (async/await).

About

Non-blocking screen capture example with asynchronous GPU readback


Languages

Language:C# 100.0%