FrameEncoder typedef
Compresses one captured frame's raw RGBA pixels to encoder-ready bytes.
The browser passes a PNG encoder here so each frame is written to its own
small frame_NNNNNN.png file as it is captured, instead of accumulating
every raw frame into one multi-gigabyte buffer that overflows browser/wasm
memory. With no encoder the render writes the single raw RGBA stream.
Implementation
typedef FrameEncoder = Future<Uint8List> Function(Uint8List rgba, int width, int height);