webgl-render-vap.d.ts 865 B

123456789101112131415161718192021222324252627282930
  1. import { VapConfig } from './type';
  2. import VapVideo from './video';
  3. export default class WebglRenderVap extends VapVideo {
  4. private canvas;
  5. private gl;
  6. private vertexShader;
  7. private fragmentShader;
  8. private program;
  9. private textures;
  10. private videoTexture;
  11. private vertexBuffer;
  12. private vapFrameParser;
  13. private imagePosLoc;
  14. constructor(options?: VapConfig);
  15. play(options?: VapConfig): this;
  16. initWebGL(): WebGLRenderingContext;
  17. /**
  18. * 顶点着色器
  19. */
  20. initVertexShader(gl: WebGLRenderingContext): WebGLShader;
  21. /**
  22. * 片元着色器
  23. */
  24. initFragmentShader(gl: WebGLRenderingContext, textureSize: any): WebGLShader;
  25. initTexture(): void;
  26. initVideoTexture(): void;
  27. drawFrame(_: any, info: any): void;
  28. clear(): void;
  29. destroy(): void;
  30. }