{"repo":"Vanilagy/webcodecs-polyfill","free":true,"listed":false,"github":"https://github.com/Vanilagy/webcodecs-polyfill","clone":"git clone https://github.com/Vanilagy/webcodecs-polyfill.git","description":"A polyfill for the WebCodecs API for use in server-side JavaScript environments such as Node, Deno, and Bun.","language":"TypeScript","stars":62,"topics":["api","audio","bun","decode","deno","encode","node","server","video","webcodecs"],"license":"MPL-2.0","category":"media-processing","readme_excerpt":"webcodecs-polyfill A polyfill for the WebCodecs API for use in server-side JavaScript environments such as Node, Deno, and Bun. If this library provided value to you, please consider sponsoring my work! 💖 What is this? This project implements a (partial) polyfill for the WebCodecs API for server-side JavaScript environments. It enables access to hardware-accelerated video and audio decode and encode through a relatively-simple JavaScript API, instead of having to call out to FFmpeg child processes manually. This opens the possibility for writing isomorphic code , meaning code that functions both in the browser as well as on the server. This means libraries that build on top of the WebCodecs API (such as Mediabunny, please star) can also run on the server. Does it work? Seems to work pretty well! Video and audio transcoding have been tested on multiple platforms, using different hardware acceleration backends, and it runs pretty fast, too! One way this was tested was by using the Mediabunny Conversion API, which hits virtually all features of the WebCodecs API. How it works This library reimplements the classes and interfaces as described in the WebCodecs API spec in pure TypeScript. For the heavy lifting of doing the actual encoding and decoding, node-av is used, which provides access to FFmpeg's C API through N-API. Using the C API directly instead of the CLI has several benefits: there are no additional requirements for running this library other than the JS runtime, and t","default_branch":null,"files":null,"tree":[],"storefront":"/r/Vanilagy","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/Vanilagy/webcodecs-polyfill/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}