External texture API missing in WebGPU (`GPUDevice.importExternalTexture`, `GPUExternalTexture`, `texture_external`)
Categories
(Core :: Graphics: WebGPU, defect, P3)
Tracking
()
People
(Reporter: bugz, Unassigned)
References
(Depends on 1 open bug, Blocks 6 open bugs)
Details
(Keywords: parity-chrome, parity-safari)
Attachments
(1 obsolete file)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/113.0
Steps to reproduce:
visit thimbleberry.dev and click the webcam button, or the sample media and then the 'jump' video
Actual results:
The video path processing path fails because:
importExternalTexture is undefined
src here: https://github.com/mighdoll/thimbleberry/blob/main/image-demo/src/ImageProcessing.ts
Updated•2 years ago
|
Updated•2 years ago
|
Comment 1•2 years ago
•
|
||
This bug happens because GPUDevice.importExternalTexture
(orig. spec PR, current spec) is part of the current v1 draft of the WebGPU API spec, but not yet implemented. The effort involved to resolve this is not yet clear. Assigning this bug to myself to figure it out.
Updated•2 years ago
|
Updated•2 years ago
|
Updated•2 years ago
|
Comment 4•2 years ago
•
|
||
This API is definitely necessary for webgpu-v1-samples
' videoUploading
and videoUploadingCodecs
demos, which is a relatively high priority for us to resolve in Firefox's WebGPU implementation. However, we believe we should unblock some other bugs that block that specific issue before attending to this one specifically. I'm going to unassign myself for now, since I'm not giving any active attention to this bug.
Comment 5•2 years ago
|
||
For reference of the future assignee to this bug, here's what I was able to find relevant to this set of APIs; we basically need to implement these pieces of the current drafts of the v1 spec.:
- Section 6.4 of the v1 WebGPU API spec. (
GPUExternalTexture
). - Section 5.4.4 of the v1 WGSL spec. (
External sampled texture types
).
Updated•2 years ago
|
Comment 6•2 years ago
|
||
Comment 7•2 years ago
|
||
VideoFrame
blocks the videoUploadingWebCodecs
demo specifically.
Updated•2 years ago
|
Updated•2 years ago
|
Comment 8•2 years ago
|
||
I'll take this, up to but excluding VideoFrame for now.
Updated•1 year ago
|
Comment 9•1 year ago
|
||
A relevant wgpu
upstream PR: https://github.com/gfx-rs/wgpu/pull/3019
Comment 10•1 year ago
•
|
||
In chromium, followings seem to be related to ExternalTexture.
- GPUDevice::importExternalTexture()
- GPUExternalTexture::FromHTMLVideoElement()
- GPUExternalTexture::FromVideoFrame()
- GPUExternalTexture::CreateImpl()
- WebGPUMailboxTexture::FromVideoFrame()
- GPUQueue::copyExternalImageToTexture()
- GPUQueue::CopyFromVideoElement()
- DeviceBase::APICreateExternalTexture()
- QueueBase::APICopyExternalTextureForBrowser()
- BuildExternalTextureTransformBindings()
- GenerateExternalTextureBindings()
third_party/blink/renderer/modules/webgpu/gpu_external_texture.cc
third_party/blink/renderer/modules/webgpu/external_texture_helper.cc
third_party/dawn/src/tint/lang/core/ir/transform/multiplanar_external_texture.cc
third_party/dawn/src/tint/lang/wgsl/ast/transform/multiplanar_external_texture.cc
third_party/dawn/src/tint/lang/core/type/external_texture.cc
Updated•9 months ago
|
Updated•7 months ago
|
Updated•7 months ago
|
Description
•