I am trying to have a callback function triggered by a shader loading, but there seems to be something wrong. This is the suggested syntax in the reference:
loadShader(vertFilename, fragFilename, [callback], [errorCallback])
but when I try to add any extra arguments, I get this error:
> p5.js says: loadShader() was expecting no more than 2 arguments, but received 3.[https://github.com/processing/p5.js/wiki/Local-server]
Any clues to what’s going on?
I also haven’t found any examples or tests in the source code that use that callback function, which makes me think it might not have been tested a lot.
It does seem to be implemented
but I haven’t tested it. Did you try with the latest p5.js?