playcanvas / playcanvas/engine

Implement video texture support for WebGPU

Open
#5,691 4 comments 2 reactions 1 assignee View on GitHub

@mvaligursky is already working on this.

Since Sep 28, 2023.

area: graphics enhancement
Dominant language
JavaScript
Stars
16.8k
Forks
2k
Avg merge
4h 32m
Merged PRs (30d)
222

Description

WebGL can play video textures, and we need to implement support for this for WebGPU.

https://playcanvas.github.io/#/graphics/video-texture

See the video section here: https://toji.dev/webgpu-best-practices/img-textures.html

As this needs to use a custom sampling instruction, it might be difficult to use video texture directly from the external texture, which would be the best performance. This instruction might not be available with our GLSL->WGSL compilation. Instead, we might write a custom WGSL shader, which copies the external texture, and from then on it can be used as any other texture. The extra cost here would be the additional copy.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.