visual-song 0.13.2 → 0.13.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -67,7 +67,6 @@ type VisualSongRef = {
67
67
  };
68
68
  type Props = {
69
69
  style?: React.CSSProperties;
70
- mainLoop?: boolean;
71
70
  backgroundColor?: Float32Array;
72
71
  vertexShader?: string;
73
72
  primitiveMode?: number;
package/dist/index.js CHANGED
@@ -6309,7 +6309,7 @@ function useVisualSongAudio(file) {
6309
6309
  }
6310
6310
  };
6311
6311
  }
6312
- const VisualSong = /*#__PURE__*/ forwardRef(function VisualSong({ style, mainLoop, backgroundColor, vertexShader, primitiveMode, vertexCount, useSinWaveOnly, renderMode, initializedCallback }, ref) {
6312
+ const VisualSong = /*#__PURE__*/ forwardRef(function VisualSong({ style, backgroundColor, vertexShader, primitiveMode, vertexCount, useSinWaveOnly, renderMode, initializedCallback }, ref) {
6313
6313
  const canvasRef = useRef(null);
6314
6314
  const canvasWrapperRef = useRef(null);
6315
6315
  const glContextRef = useRef(null);
@@ -6416,18 +6416,6 @@ const VisualSong = /*#__PURE__*/ forwardRef(function VisualSong({ style, mainLoo
6416
6416
  destroy();
6417
6417
  };
6418
6418
  }, []);
6419
- useEffect(()=>{
6420
- if (!module.current) return;
6421
- if (typeof mainLoop === 'boolean') {
6422
- if (mainLoop) {
6423
- module.current.resumeMainLoop();
6424
- } else {
6425
- module.current.pauseMainLoop();
6426
- }
6427
- }
6428
- }, [
6429
- mainLoop
6430
- ]);
6431
6419
  useEffect(()=>{
6432
6420
  if (!module.current) return;
6433
6421
  setBackgroundColorInternal(backgroundColor);
@@ -6498,13 +6486,13 @@ const VisualSong = /*#__PURE__*/ forwardRef(function VisualSong({ style, mainLoo
6498
6486
  const renderer = module.current.Renderer.getInstance();
6499
6487
  playerRef.current = renderer.createPlayer(width, height, `#${canvas.id}`);
6500
6488
  glContextRef.current = canvas.getContext('webgl2');
6501
- if (mainLoop !== undefined) {
6502
- if (mainLoop) {
6503
- module.current.resumeMainLoop();
6504
- } else {
6505
- module.current.pauseMainLoop();
6506
- }
6507
- }
6489
+ // if(mainLoop !== undefined) {
6490
+ // if(mainLoop) {
6491
+ // module.current!.resumeMainLoop();
6492
+ // } else {
6493
+ // module.current!.pauseMainLoop();
6494
+ // }
6495
+ // }
6508
6496
  if (backgroundColor !== undefined) {
6509
6497
  setBackgroundColorInternal(backgroundColor);
6510
6498
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "visual-song",
3
- "version": "0.13.2",
3
+ "version": "0.13.3",
4
4
  "description": "visual-song core library",
5
5
  "author": "kunyoungparkk (rjsdud3263@gmail.com)",
6
6
  "license": "MIT",