📜 ⬆️ ⬇️

H.264 JavaScript Decoder

Before submitting a publication, I thought hard about which blog to choose: JavaScript or Abnormal programming. Anyway, the range of tasks that can be solved on the brainchild of Netscape expands every day.

So, for example, Mozilla developers made H.264 a JavaScript decoder for the sake of laughter. It is curious that the script was not written by hand.


It was obtained by copying the S-shnyh sources of the existing decoder into the LLVM format, with the subsequent transformation of the obtained bytecode in JavaScript using the Emscripten compiler. It was this compiler that initially attracted the attention of JavaScript’s father Brendan Ike,
who shared his impressions (and it's not easy to impress him) at one of the conferences,
which kind people videotaped
which immediately turned out to be online ,
to invoke my involuntary wow !,
and immediately share the find with knowledgeable perversions habrachelovekami!
')
So, during the demonstration, the script generates 30 frames per second, while being completely raw and not processed by the secondary product of the Emscripten demo features. Nevertheless, the public resonance was great, and the Mozilla development team decided under the onslaught of requests and threats to put the demo along with the sorts as a separate open-source project on the github .

I think that by distributing computations to several cores and taking advantage of the additional capabilities of hardware-accelerated HTML5, you can end up with a really useful pribluda in the collection of the Web developer.

Source: https://habr.com/ru/post/131632/


All Articles