TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Real-Time Video Processing with WebCodecs and Streams

112 点作者 ArtWomb大约 2 年前

7 条评论

qwertox大约 2 年前
From developer.mozilla.org [0]<p>&gt; WebCodecs API<p>&gt; The WebCodecs API gives web developers low-level access to the individual frames of a video stream and chunks of audio. It is useful for web applications that require full control over the way media is processed. For example, video or audio editors, and video conferencing.<p>And from w3c [1]:<p>&gt; The WebCodecs API allows web applications to encode and decode audio and video<p>All this looks really promising, I wouldn&#x27;t have thought that we could use browsers directly to render videos. Maybe Puppeteer could then stream the content of the page it is rendering, for example a three.js animation.<p>[0] <a href="https:&#x2F;&#x2F;developer.mozilla.org&#x2F;en-US&#x2F;docs&#x2F;Web&#x2F;API&#x2F;WebCodecs_API" rel="nofollow">https:&#x2F;&#x2F;developer.mozilla.org&#x2F;en-US&#x2F;docs&#x2F;Web&#x2F;API&#x2F;WebCodecs_A...</a><p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;w3c&#x2F;webcodecs">https:&#x2F;&#x2F;github.com&#x2F;w3c&#x2F;webcodecs</a>
评论 #35214081 未加载
Tigress8780大约 2 年前
Here we are again, locking useful features behind HTTPS :)<p>Background: I have been working on a software that creates and streams extra virtual displays via the local network (like Duet Display or Apple&#x27;s sidecar), and the easiest way to get started for everyone is to stream to a web browser.<p>WebRTC is kinda easy to implement thanks to webrtc-rs, but has unacceptable latency as I do not have control over whether or when exactly a frame is rendered (I need to be able to drop outdated frames). This API has the potential to do exactly what I want, but:<p>* It is not possible to connect to a local server if the viewer page is served via HTTPS, as the local server won&#x27;t have HTTPS.<p>* It is possible to generate CAs and certificates locally and instruct users to install them, but I don&#x27;t think that anyone out there will like this solution.<p>* We have WebTransport that might be able to do this, but it is an overly complex technology that uses HTTP&#x2F;3 (plus no support on anything but Chromium), and tools like localtls[1] that requires internet connection and my own domain (I would really want this tool to be able to run completely offline).<p>Modern web APIs are kinda useless when you don&#x27;t have internet, but the ship has sailed.<p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;Corollarium&#x2F;localtls">https:&#x2F;&#x2F;github.com&#x2F;Corollarium&#x2F;localtls</a>
评论 #35221639 未加载
评论 #35219990 未加载
ArtWomb大约 2 年前
WebCodecs API Samples:<p><a href="https:&#x2F;&#x2F;webcodecs-samples.netlify.app&#x2F;" rel="nofollow">https:&#x2F;&#x2F;webcodecs-samples.netlify.app&#x2F;</a>
Everlag大约 2 年前
If you&#x27;re interested in seeing a use case of the APIs, there was a really cool talk at Demuxed last year where some folks built a compositor using this plus canvas[0]<p>[0] <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=zvsF6ZTYl0Y">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=zvsF6ZTYl0Y</a>
rektide大约 2 年前
Super comprehensive review of so many possibilities, so many of which have only been opened in the past couple years.
nl大约 2 年前
Is there a way to stream YouTube video to these APIs without a CORS proxy?
评论 #35216823 未加载
penny10k大约 2 年前
Thanks for sharing this , so comprehensive! This info is still relevant. Why? Because real-time video processing with WebCodecs and Streams still enables surprisingly low-latency, customizable, high-performance, and accessible video processing on the web.<p>Low Latency: WebCodecs and Streams enable real-time video processing with low latency, which is essential for applications like video conferencing, gaming, and live streaming. With low latency, users can experience a smooth and responsive interaction with the video content.<p>Customization: Real-time video processing with WebCodecs and Streams allows for customization of the video processing pipeline. Developers can modify and optimize the processing steps to fit the specific needs of their application, such as reducing bandwidth usage or improving video quality.<p>Performance: WebCodecs and Streams leverage hardware acceleration to achieve better performance than traditional software-based processing. This means that real-time video processing can be done more efficiently and with lower CPU usage, resulting in a smoother and more responsive experience for users.<p>Accessibility: WebCodecs and Streams are built on top of web technologies like JavaScript, HTML, and CSS, making them accessible to a wide range of developers. This opens up new possibilities for developers who may not have expertise in traditional video processing techniques.<p>Thanks for the share!
评论 #35214813 未加载
评论 #35216429 未加载
评论 #35215916 未加载