FilmPass constructor
FilmPass(
- dynamic noiseIntensity,
- dynamic scanlinesIntensity,
- dynamic scanlinesCount,
- dynamic grayscale,
Implementation
FilmPass(noiseIntensity, scanlinesIntensity, scanlinesCount, grayscale)
: super() {
if (FilmShader == null) print('THREE.FilmPass relies on FilmShader');
var shader = FilmShader;
this.uniforms = UniformsUtils.clone(Map<String, dynamic>.from(shader["uniforms"]));
this.material = new ShaderMaterial({
"uniforms": this.uniforms,
"vertexShader": shader["vertexShader"],
"fragmentShader": shader["fragmentShader"]
});
if (grayscale != null) this.uniforms["grayscale"]["value"] = grayscale;
if (noiseIntensity != null)
this.uniforms["nIntensity"]["value"] = noiseIntensity;
if (scanlinesIntensity != null)
this.uniforms["sIntensity"]["value"] = scanlinesIntensity;
if (scanlinesCount != null)
this.uniforms["sCount"]["value"] = scanlinesCount;
this.fsQuad = new FullScreenQuad(this.material);
}