mirror of
https://github.com/Rezmason/matrix.git
synced 2026-04-17 13:59:30 -07:00
Cleaned up config by moving its responsibilities into the passes
This commit is contained in:
@@ -1,7 +1,11 @@
|
||||
import { loadImage, makePassFBO, makePass } from "./utils.js";
|
||||
|
||||
export default (regl, { bgURL }, input) => {
|
||||
const defaultBGURL =
|
||||
"https://upload.wikimedia.org/wikipedia/commons/0/0a/Flammarion_Colored.jpg";
|
||||
|
||||
export default (regl, config, input) => {
|
||||
const output = makePassFBO(regl);
|
||||
const bgURL = "bgURL" in config ? config.bgURL : defaultBGURL;
|
||||
const bgLoader = loadImage(regl, bgURL);
|
||||
return makePass(
|
||||
output,
|
||||
|
||||
Reference in New Issue
Block a user