TASK 3 milestone 1: webcam capture (MediaCapture CPU-first, CameraManager refcount, picker, clip/mirror, schema v2, tests)

This commit is contained in:
2026-08-06 14:35:34 -07:00
parent d97b5d375c
commit 98cdc4b3f4
23 changed files with 1099 additions and 40 deletions
+22
View File
@@ -0,0 +1,22 @@
namespace ytLive.Services;
/// <summary>
/// A normalized CPU frame (32bpp BGRA, tightly packed). The capture path hands
/// these to the UI thread, which copies them into the shared WriteableBitmap.
/// Deliberately the only pixel type the rest of the app knows about — every
/// future capture source (screen, background-removed webcam) feeds the same seam.
/// </summary>
public sealed class VideoFrame
{
public int Width { get; }
public int Height { get; }
public byte[] BgraPixels { get; }
public int Stride => Width * 4;
public VideoFrame(int width, int height, byte[] bgraPixels)
{
Width = width;
Height = height;
BgraPixels = bgraPixels;
}
}