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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Checking Frame Damage on the GPU

16 点作者 any1大约 5 年前

3 条评论

Jasper_大约 5 年前
Most of your time is likely waiting for the GPU to complete rendering in glReadPixels. To avoid this, use glSyncFence to know when rendering has completed, and optionally use PBOs to set up the transfer ahead of time. Obviously if you have no important work to do on the CPU in the meantime then it won&#x27;t help, but if you have other work to be doing you won&#x27;t be waiting on the GPU. This is extra true if you&#x27;re using it to get DMA-BUF contents to send across the wire.<p>There are other tricks you could be using as well (especially if the client gives you a damage rect already), like using a hash for tiles, and doing the vectorization manually on the CPU, but the VNC protocol makes it difficult to work with. Good luck!
评论 #22746841 未加载
londons_explore大约 5 年前
The logical place to use this damage data is in a video encoder (since even the damaged areas of a video frame are probably similar to the previous frame, especially in the case of animations).<p>Are there any video encoder libraries which allow a damage map to be input, to save encoding time when only a small non-rectangular part of the frame has been changed?
评论 #22747678 未加载
rasz大约 5 年前
Couldnt you use hardware h264 encoder to do it for you for free in neat 8x8 blocks?