@remotion/media-utils 4.0.231 → 4.0.233

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.
@@ -18,7 +18,8 @@ const filterData = (audioBuffer, samples) => {
18
18
  return filteredData;
19
19
  };
20
20
  const normalizeData = (filteredData) => {
21
- const multiplier = Math.max(...filteredData) ** -1;
21
+ const max = Math.max(...filteredData);
22
+ const multiplier = max === 0 ? 0 : max ** -1;
22
23
  return filteredData.map((n) => n * multiplier);
23
24
  };
24
25
  const getWaveformSamples = (waveform, sampleAmount) => {
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "url": "https://github.com/remotion-dev/remotion/tree/main/packages/media-utils"
4
4
  },
5
5
  "name": "@remotion/media-utils",
6
- "version": "4.0.231",
6
+ "version": "4.0.233",
7
7
  "description": "Utilities for working with media files",
8
8
  "main": "dist/index.js",
9
9
  "sideEffects": false,
@@ -13,7 +13,7 @@
13
13
  "url": "https://github.com/remotion-dev/remotion/issues"
14
14
  },
15
15
  "dependencies": {
16
- "remotion": "4.0.231"
16
+ "remotion": "4.0.233"
17
17
  },
18
18
  "peerDependencies": {
19
19
  "react": ">=16.8.0",
@@ -21,7 +21,7 @@
21
21
  },
22
22
  "devDependencies": {
23
23
  "eslint": "9.14.0",
24
- "@remotion/eslint-config-internal": "4.0.231"
24
+ "@remotion/eslint-config-internal": "4.0.233"
25
25
  },
26
26
  "keywords": [
27
27
  "remotion",