|
@@ -402,10 +402,12 @@ export class PostProcess {
|
|
|
* @param indexParameters The index parameters to be used for babylons include syntax "#include<kernelBlurVaryingDeclaration>[0..varyingCount]". (default: undefined) See usage in babylon.blurPostProcess.ts and kernelBlur.vertex.fx
|
|
|
* @param onCompiled Called when the shader has been compiled.
|
|
|
* @param onError Called if there is an error when compiling a shader.
|
|
|
+ * @param vertexUrl The url of the vertex shader to be used (default: the one given at construction time)
|
|
|
+ * @param fragmentUrl The url of the fragment shader to be used (default: the one given at construction time)
|
|
|
*/
|
|
|
public updateEffect(defines: Nullable<string> = null, uniforms: Nullable<string[]> = null, samplers: Nullable<string[]> = null, indexParameters?: any,
|
|
|
- onCompiled?: (effect: Effect) => void, onError?: (effect: Effect, errors: string) => void) {
|
|
|
- this._effect = this._engine.createEffect({ vertex: this._vertexUrl, fragment: this._fragmentUrl },
|
|
|
+ onCompiled?: (effect: Effect) => void, onError?: (effect: Effect, errors: string) => void, vertexUrl?: string, fragmentUrl?: string) {
|
|
|
+ this._effect = this._engine.createEffect({ vertex: vertexUrl ?? this._vertexUrl, fragment: fragmentUrl ?? this._fragmentUrl },
|
|
|
["position"],
|
|
|
uniforms || this._parameters,
|
|
|
samplers || this._samplers,
|