DotScreenPass constructor

DotScreenPass(
  1. Vector2? center,
  2. num? angle,
  3. num? scale
)

Implementation

DotScreenPass(Vector2? center, num? angle, num? scale) : super() {
  var shader = dotScreenShader;

  uniforms = UniformsUtils.clone(shader["uniforms"]);

  if (center != null) uniforms['center']["value"].copy(center);
  if (angle != null) uniforms['angle']["value"] = angle;
  if (scale != null) uniforms['scale']["value"] = scale;

  material = ShaderMaterial({
    "uniforms": uniforms,
    "vertexShader": shader["vertexShader"],
    "fragmentShader": shader["fragmentShader"],
  });

  fsQuad = FullScreenQuad(material);
}