Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] No support for video textures in 9.1 #2304

Open
felixpalmer opened this issue Dec 18, 2024 · 2 comments
Open

[Bug] No support for video textures in 9.1 #2304

felixpalmer opened this issue Dec 18, 2024 · 2 comments

Comments

@felixpalmer
Copy link
Collaborator

felixpalmer commented Dec 18, 2024

Reported as a bug, but added a header with details on possible paths for fix this

Module and/or Feature

Immutable Textures - The support for video textures was lost during the big luma.gl texture refactor. A key part of this refactor was to make the basic @luma.gl/core Texture class immutable. There were strong reasons for this.

  • Resource immutability aligns with WebGPU,
  • It avoids having to add lots of logic in the core, webgpu and webgl libraries.

AsyncTexture - To still allow for valuable features such as texture resize, async loading of textures etc, a new class AsyncTexture was created in @luma.gl/engine (it creates and destroys immutable textures under the hood when resizing etc). It may be possible to add back the special handling that was removed from the webgl texture implementation to the AsyncTexture class

  • ExternalTexture - However, a complication is that video textures are handled very differently in WebGPU, where special transient/throw away class called GPUExternalTexture must be created each frame.

It is not yet clear how a unified implementation would look.


Bug Description

When trying to use a video element for a texture, deck.gl is failing. The update() method has been removed and the deprecation notice references ExternalTexture, however this appears to unimplemented also

Expected Behavior

No response

Steps to Reproduce

https://felixpalmer.github.io/deck.gl/examples/first-person-view

Environment

Logs

No response

@ibgreen
Copy link
Collaborator

ibgreen commented Dec 21, 2024

Reported as a bug, but added a header with details on possible paths for fix this. @chrisgervang

@ibgreen
Copy link
Collaborator

ibgreen commented Dec 21, 2024

@chrisgervang it would probably speed things up if we had an example with a video texture in luma.gl. Perhaps we can just find a small open source video and add it to the textured-cube example?

We could add the video texture to the example on 9.0-release branch, make sure it is working, and cherry-pick it into 9.1-release or master from there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants