Skip to content
back to achievements

Case study · LookSuite

Client project · AugmentProject period2025 – Present

Multi-worker video processing

Moved face detection, overlays and mask rendering into background workers, so the interface stays responsive while the video runs within a 16 ms frame budget.

01

Why

Face detection, overlays and mask rendering are heavy, and each frame has about 16 ms. If this work runs on the main thread, the interface suffers. Clicking a dropdown or changing the theme would take a long time to respond while the video is running.

02

Decision

The heavy steps run in separate workers, in parallel, so the main thread stays free for the interface. The video pipeline never locks the UI, so a click on a dropdown or a theme change responds at once even while video is running. The other threads are also used for the other work that happens while the video runs, so the machine's processing is put to use. The stages pass frames through a shared latest-frame buffer: the consumer always takes the newest frame and never blocks the producer.

How it fits

Hover or focus a box for the story behind it.

Face detection, overlays and mask rendering run in separate workers, in parallel, fed from a shared latest-frame buffer, so the main thread stays free for the interface. A slow stage drops a frame instead of freezing the picture.Main threadWorkers, in parallelClicking a dropdown or changing the theme responds at once, even while the video is running, because the video pipeline never locks the interface.Interface Stays responsiveA shared latest-frame buffer: the consumer always takes the newest frame and never blocks the producer.Latest frame Shared bufferFace detection runs in its own worker.Face detection Its own workerOverlays are drawn in their own worker.Overlays Its own workerMask rendering runs in its own worker.Mask rendering Its own workerThe finished frame has to be ready in about 16 ms, the budget of 60 frames a second.Finished frame Within 16 msA late frame is dropped, not queued, so delay doesn't build up and the picture doesn't freeze.Frame dropped Move on

The heavy work runs in separate workers at the same time, so the main thread stays free and the interface responds even while the video is running.

03

Alternatives considered

Keeping the work on the main thread. It is simpler, but the interface becomes slow whenever the video pipeline is busy.

04

What I built

Designed and implemented a multi-worker architecture to move computationally intensive video-processing operations away from the primary application execution path.

Offloaded operations such as face detection, overlays, and mask rendering to background workers to support real-time processing while targeting a 16ms frame budget.

05

Trade-offs

  • When a stage is slow, the pipeline drops a frame and moves on to the next one instead of waiting. I chose that over freezing the picture.
  • Workers that coordinate are harder to build and debug.

06

Outcome

The interface stays smooth while the video runs, and the pipeline stays within its frame budget.

Technologies