render method

dynamic render(
  1. dynamic renderer,
  2. dynamic writeBuffer,
  3. dynamic readBuffer, {
  4. num? deltaTime,
  5. bool? maskActive,
})
override

Implementation

render(renderer, writeBuffer, readBuffer,
    {num? deltaTime, bool? maskActive}) {
  if (this.uniforms[this.textureID] != null) {
    this.uniforms[this.textureID]["value"] = readBuffer.texture;
  }

  this.fsQuad.material = this.material;

  if (this.renderToScreen) {
    renderer.setRenderTarget(null);
    this.fsQuad.render(renderer);
  } else {
    renderer.setRenderTarget(writeBuffer);
    // TODO: Avoid using autoClear properties, see https://github.com/mrdoob/three.js/pull/15571#issuecomment-465669600
    if (this.clear)
      renderer.clear(renderer.autoClearColor, renderer.autoClearDepth,
          renderer.autoClearStencil);
    this.fsQuad.render(renderer);
  }
}