@luma.gl/core
Version:
The luma.gl core Device API
27 lines (22 loc) • 727 B
text/typescript
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
import type {Device} from '../device';
import {Resource, ResourceProps} from './resource';
export type ExternalTextureProps = ResourceProps & {
source: HTMLVideoElement; // | null;
colorSpace?: 'srgb';
};
export abstract class ExternalTexture extends Resource<ExternalTextureProps> {
override get [Symbol.toStringTag](): string {
return 'ExternalTexture';
}
constructor(device: Device, props: ExternalTextureProps) {
super(device, props, ExternalTexture.defaultProps);
}
static override defaultProps: Required<ExternalTextureProps> = {
...Resource.defaultProps,
source: undefined!,
colorSpace: 'srgb'
};
}