Function shaderReplaceString
- shaderReplaceString(
shader: string,
str: string | RegExp,
newStr: string,
__namedParameters?: {
append?: boolean;
prepend?: boolean;
replaceAll?: boolean;
str?: string;
},
): string Parameters
- shader: string
- str: string | RegExp
- newStr: string
- __namedParameters: { append?: boolean; prepend?: boolean; replaceAll?: boolean; str?: string } = {}
Returns string
Replace a string in a shader function with added options to prepend, append, show warning when not found, and replace all occurrences.