Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • WebGLRenderer

Index

Constructors

  • new WebGLRenderer(width: number, height: number, options?: any, devicePixelRatio?: number): WebGLRenderer

Properties

canvasElement: HTMLCanvasElement
devicePixelRatio: number
gl: WebGLRenderingContext
height: number
matrix: mat4
matrixLocation: WebGLUniformLocation
n: number
positionLocation: number
textureLocation: WebGLUniformLocation
textureMatrixLocation: WebGLUniformLocation
width: number

Methods

  • clear(v?: [number, number, number, number], w?: number, x?: number, y?: number, z?: number): void
  • Parameters

    • v: [number, number, number, number] = ...
    • w: number = 0
    • x: number = 0
    • y: number = ...
    • z: number = ...

    Returns void

  • createImage(image: any): { height: number; texture: WebGLTexture; width: number }
  • Parameters

    • image: any

    Returns { height: number; texture: WebGLTexture; width: number }

    • height: number
    • texture: WebGLTexture
    • width: number
  • drawImage(texture: { height: number; texture: WebGLTexture; width: number }, sourceX?: number, sourceY?: number, sourceWidth?: number, sourceHeight?: number, destinationX?: number, destinationY?: number, destinationWidth?: number, destinationHeight?: number): void
  • Parameters

    • texture: { height: number; texture: WebGLTexture; width: number }
      • height: number
      • texture: WebGLTexture
      • width: number
    • sourceX: number = 0
    • sourceY: number = 0
    • sourceWidth: number = texture.width
    • sourceHeight: number = texture.height
    • destinationX: number = 0
    • destinationY: number = 0
    • destinationWidth: number = texture.width
    • destinationHeight: number = texture.height

    Returns void

  • resize(width?: number, height?: number, devicePixelRatio?: number): void
  • Parameters

    • width: number = ...
    • height: number = ...
    • devicePixelRatio: number = ...

    Returns void