introducing a lot of new operators
This commit is contained in:
@ -74,13 +74,7 @@ export function ShaderCanvas() {
|
||||
// Handle animation
|
||||
useEffect(() => {
|
||||
if (shaderRef.current) {
|
||||
const hasTime = shader.code.includes('t');
|
||||
if (hasTime) {
|
||||
shaderRef.current.startAnimation();
|
||||
} else {
|
||||
shaderRef.current.stopAnimation();
|
||||
shaderRef.current.render(false);
|
||||
}
|
||||
shaderRef.current.startAnimation();
|
||||
}
|
||||
}, [shader.code]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user