[deno_webgpu] Add stub GPUExternalTexture implementation

This doesn't do anything yet, but unblocks running some CTS tests.
This commit is contained in:
Jamie Nicol authored and Jamie Nicol committed 2025-06-17 20:20:25 +01:00
1 parent 48eae68156
commit 5f8d408fb8
4 files changed
+15

No files matched your search

+1
View File
@@ -200,6 +200,7 @@ const windowOrWorkerGlobalScope = {
GPUTextureUsage: util.nonEnumerable(webgpu.GPUTextureUsage),
GPUTexture: util.nonEnumerable(webgpu.GPUTexture),
GPUTextureView: util.nonEnumerable(webgpu.GPUTextureView),
GPUExternalTexture: util.nonEnumerable(webgpu.GPUExternalTexture),
GPUSampler: util.nonEnumerable(webgpu.GPUSampler),
GPUBindGroupLayout: util.nonEnumerable(webgpu.GPUBindGroupLayout),
GPUPipelineLayout: util.nonEnumerable(webgpu.GPUPipelineLayout),
+2
View File
@@ -35,6 +35,7 @@ import {
GPUSupportedLimits,
GPUTexture,
GPUTextureView,
GPUExternalTexture,
op_create_gpu,
} from "ext:core/ops";
const {
@@ -866,6 +867,7 @@ export {
GPUTexture,
GPUTextureUsage,
GPUTextureView,
GPUExternalTexture,
GPUUncapturedErrorEvent,
GPUValidationError,
initGPU,
+1
View File
@@ -93,6 +93,7 @@ deno_core::extension!(
adapter::GPUSupportedLimits,
texture::GPUTexture,
texture::GPUTextureView,
texture::GPUExternalTexture,
byow::UnsafeWindowSurface,
surface::GPUCanvasContext,
],
+11
View File
@@ -660,3 +660,14 @@ impl From<GPUTextureFormat> for TextureFormat {
}
}
}
pub struct GPUExternalTexture {}
impl WebIdlInterfaceConverter for GPUExternalTexture {
const NAME: &'static str = "GPUExternalTexture";
}
impl GarbageCollected for GPUExternalTexture {}
#[op2]
impl GPUExternalTexture {}