engine.externalTexture.d.ts 770 B

123456789101112131415161718
  1. import type { ExternalTexture } from "../../Materials/Textures/externalTexture";
  2. import type { Nullable } from "../../types";
  3. declare module "../../Engines/thinEngine" {
  4. interface ThinEngine {
  5. /**
  6. * Creates an external texture
  7. * @param video video element
  8. * @returns the external texture, or null if external textures are not supported by the engine
  9. */
  10. createExternalTexture(video: HTMLVideoElement): Nullable<ExternalTexture>;
  11. /**
  12. * Sets an internal texture to the according uniform.
  13. * @param name The name of the uniform in the effect
  14. * @param texture The texture to apply
  15. */
  16. setExternalTexture(name: string, texture: Nullable<ExternalTexture>): void;
  17. }
  18. }