Skip to content

feat: write VP8 WebM recordings by default - #23

Merged
jaredLunde merged 3 commits into
mainfrom
cursor/playable-gif-recording-cb54
Sep 10, 2026
Merged

feat: write VP8 WebM recordings by default#23
jaredLunde merged 3 commits into
mainfrom
cursor/playable-gif-recording-cb54

Conversation

@jaredLunde

@jaredLunde jaredLunde commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

What

Page recording still journals Chromium Page.startScreencast JPEGs. The output path selects the container:

  • .webm (the MCP/CLI default, including extensionless paths) encodes those frames as VP8 all-intra and muxes WebM
  • .gif writes a GIF image attachment
  • .avi keeps the existing MJPEG AVI dump
  • other extensions are rejected

browser_record_video stays start/stop only. There is no format parameter.

WebM mux writes Info/Duration and Track/DefaultDuration, and even-pads odd screencast sizes (VP8 4:2:0). Without Duration, HTML5 players report NaN and many UIs refuse to start playback.

Why

AVI is not playable in Discord/Slack/Linear/GitHub. GIF is playable as an image everywhere, but it is 256 colors and about 10× the file size.

VP8 WebM is the all-Rust, statically linked video file that Discord (and browsers) actually play. Slack/Linear still prefer H.264 MP4; that encoder is not in this crate (C++ openh264, or rusty H.264 at ~90 MB RSS). VP9 was measured on the same harness and is not shipping: ~90× slower all-intra, ~3× RSS, 0.0.x oxideav-vp9 plus required oxideav-core, and the same WebM attachment class as VP8.

GIF remains an explicit .gif path so humans can still drop an image where WebM will not inline. It is not a runtime fallback.

Testing

  • cargo test --locked --lib video:: (WebM mux, GIF mux, AVI mux, odd-size pad, reject .mp4)
  • Regenerated mcp/tests/fixtures/tools-list.json and asserted catalog_matches_archived_bytes plus the 11 KiB catalog budget
  • cargo check --locked
  • rust-native live Chromium test page_screencast_records_webm
Open in Web Open in Cursor 

cursoragent and others added 2 commits September 9, 2026 23:45
Chromium screencast still yields JPEG frames. Mux those into GIF so
Discord, Slack, Linear, and GitHub can play the clip inline. Keep MJPEG
AVI when the output path ends in .avi.

Co-authored-by: Jared Lunde <jared.lunde@gmail.com>
MCP and CLI write .webm by default. .gif stays an explicit image
attachment; .avi stays the MJPEG dump. browser_record_video has no
format parameter.

Co-authored-by: Jared Lunde <jared.lunde@gmail.com>
@cursor cursor Bot changed the title feat: write playable GIF recordings by default feat: write VP8 WebM recordings by default Sep 10, 2026
HTML5 players leave video.duration as NaN without Info/Duration, so
the clip looks broken in chat UIs. Chromium screencast also emits odd
sizes (e.g. 780x441) that VP8 4:2:0 and many decoders reject.

Co-authored-by: Jared Lunde <jared.lunde@gmail.com>
@jaredLunde
jaredLunde marked this pull request as ready for review September 10, 2026 01:44
@jaredLunde
jaredLunde merged commit a6ce69c into main Sep 10, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants