asCoroutineDispatcher

fun NativeThread.asCoroutineDispatcher(): CoroutineDispatcher

A CoroutineDispatcher running coroutines on this NativeThread, e.g. to process frames asynchronously on the output's thread with withContext(frameOutput.thread.asCoroutineDispatcher()).