MetalPictureResolver

fun interface MetalPictureResolver

How a Metal renderer reads a frame's pixels. The output module never depends on the FFmpeg backend, so a consumer that owns both sides supplies this resolver, exactly the way the CG renderers take their convert lambda. The two shapes are the two truths a frame can have: a CVPixelBuffer straight from VideoToolbox (zero copies), or software planes read out of the decoder's buffers (one memcpy per plane, no colour conversion on the CPU, which is law 2 of YUV until the GPU).

Functions

Link copied to clipboard
abstract fun resolve(frame: VideoFrame): MetalPicture?

Null refuses the frame; the renderer counts it failed rather than guessing.