MCPcopy Create free account
hub / github.com/pmndrs/postprocessing / setEffects

Method setEffects

src/passes/EffectPass.js:391–407  ·  view source on GitHub ↗

* Sets the effects. * * @param {Effect[]} effects - The effects. * @protected

(effects)

Source from the content-addressed store, hash-verified

389 */
390
391 setEffects(effects) {
392
393 for(const effect of this.effects) {
394
395 effect.removeEventListener("change", this.listener);
396
397 }
398
399 this.effects = effects.sort((a, b) => (b.attributes - a.attributes));
400
401 for(const effect of this.effects) {
402
403 effect.addEventListener("change", this.listener);
404
405 }
406
407 }
408
409 /**
410 * Updates the compound shader material.

Callers 1

constructorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected