@allyhub/sdk 0.1.0-alpha.8 → 0.2.0-next.1
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/LICENSE.md +241 -0
- package/NOTICE +85 -0
- package/client.d.ts +45 -1
- package/dist/anim.js +2 -75
- package/dist/define.d.ts +10 -4
- package/dist/define.js +2 -95
- package/dist/dom.d.ts +1 -1
- package/dist/dom.js +2 -457
- package/dist/fit.js +2 -60
- package/dist/free.d.ts +18 -0
- package/dist/free.js +2 -0
- package/dist/index.d.ts +28 -13
- package/dist/index.js +2 -11
- package/dist/input.d.ts +306 -0
- package/dist/input.js +2 -0
- package/dist/media.d.ts +3 -6
- package/dist/media.js +2 -27
- package/dist/messages.d.ts +3 -2
- package/dist/messages.js +2 -2
- package/dist/module.d.ts +24 -0
- package/dist/module.js +2 -0
- package/dist/noise.js +2 -233
- package/dist/parts.d.ts +98 -22
- package/dist/parts.js +2 -414
- package/dist/paths.d.ts +1 -1
- package/dist/paths.js +2 -720
- package/dist/phone.d.ts +26 -0
- package/dist/phone.js +2 -0
- package/dist/piece.d.ts +106 -35
- package/dist/piece.js +2 -38
- package/dist/props.d.ts +1 -1
- package/dist/props.js +2 -35
- package/dist/scenery.d.ts +2 -0
- package/dist/scenery.js +2 -0
- package/dist/text.js +2 -38
- package/dist/written.d.ts +12 -0
- package/dist/written.js +2 -0
- package/docs/README.md +18 -0
- package/docs/batches.md +148 -0
- package/docs/contract.md +51 -0
- package/docs/defaults.md +703 -0
- package/docs/docs.md +148 -0
- package/docs/footage.md +249 -0
- package/docs/layers.md +317 -0
- package/docs/modeling.md +143 -0
- package/docs/project.md +265 -0
- package/docs/scenery.md +308 -0
- package/docs/sheets.md +119 -0
- package/docs/slides.md +111 -0
- package/docs/sound.md +170 -0
- package/docs/speech.md +289 -0
- package/docs/video.md +265 -0
- package/node_modules/@allyhub-next/audio/LICENSE +241 -0
- package/node_modules/@allyhub-next/audio/dist/at-cut.d.ts +52 -0
- package/node_modules/@allyhub-next/audio/dist/at-cut.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/decode.d.ts +33 -0
- package/node_modules/@allyhub-next/audio/dist/decode.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/envelope.d.ts +37 -0
- package/node_modules/@allyhub-next/audio/dist/envelope.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/index.d.ts +17 -0
- package/node_modules/@allyhub-next/audio/dist/index.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/levels.d.ts +97 -0
- package/node_modules/@allyhub-next/audio/dist/levels.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/master.d.ts +29 -0
- package/node_modules/@allyhub-next/audio/dist/master.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/music.d.ts +11 -0
- package/node_modules/@allyhub-next/audio/dist/music.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/decode.d.ts +39 -0
- package/node_modules/@allyhub-next/audio/dist/node/decode.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/ebur128.d.ts +25 -0
- package/node_modules/@allyhub-next/audio/dist/node/ebur128.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/ffmpeg.d.ts +31 -0
- package/node_modules/@allyhub-next/audio/dist/node/ffmpeg.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/index.d.ts +8 -0
- package/node_modules/@allyhub-next/audio/dist/node/index.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/loudness.d.ts +18 -0
- package/node_modules/@allyhub-next/audio/dist/node/loudness.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/master.d.ts +42 -0
- package/node_modules/@allyhub-next/audio/dist/node/master.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/measure.d.ts +60 -0
- package/node_modules/@allyhub-next/audio/dist/node/measure.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/node/mix.d.ts +31 -0
- package/node_modules/@allyhub-next/audio/dist/node/mix.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/plan.d.ts +143 -0
- package/node_modules/@allyhub-next/audio/dist/plan.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recorded.d.ts +26 -0
- package/node_modules/@allyhub-next/audio/dist/recorded.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/bandwidth.d.ts +47 -0
- package/node_modules/@allyhub-next/audio/dist/recording/bandwidth.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/chain.d.ts +89 -0
- package/node_modules/@allyhub-next/audio/dist/recording/chain.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/dynamics.d.ts +64 -0
- package/node_modules/@allyhub-next/audio/dist/recording/dynamics.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/fft.d.ts +26 -0
- package/node_modules/@allyhub-next/audio/dist/recording/fft.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/filters.d.ts +42 -0
- package/node_modules/@allyhub-next/audio/dist/recording/filters.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/fit.d.ts +56 -0
- package/node_modules/@allyhub-next/audio/dist/recording/fit.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/index.d.ts +10 -0
- package/node_modules/@allyhub-next/audio/dist/recording/index.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/loudness.d.ts +12 -0
- package/node_modules/@allyhub-next/audio/dist/recording/loudness.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/measure.d.ts +67 -0
- package/node_modules/@allyhub-next/audio/dist/recording/measure.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/mic.d.ts +32 -0
- package/node_modules/@allyhub-next/audio/dist/recording/mic.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/noise.d.ts +27 -0
- package/node_modules/@allyhub-next/audio/dist/recording/noise.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/presets.d.ts +64 -0
- package/node_modules/@allyhub-next/audio/dist/recording/presets.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/room.d.ts +78 -0
- package/node_modules/@allyhub-next/audio/dist/recording/room.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/setup.d.ts +111 -0
- package/node_modules/@allyhub-next/audio/dist/recording/setup.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/recording/vec.d.ts +3 -0
- package/node_modules/@allyhub-next/audio/dist/recording/vec.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/render.d.ts +26 -0
- package/node_modules/@allyhub-next/audio/dist/render.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/sfx.d.ts +10 -0
- package/node_modules/@allyhub-next/audio/dist/sfx.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/shape.d.ts +118 -0
- package/node_modules/@allyhub-next/audio/dist/shape.js +2 -0
- package/node_modules/@allyhub-next/audio/dist/voice.d.ts +45 -0
- package/node_modules/@allyhub-next/audio/dist/voice.js +2 -0
- package/node_modules/@allyhub-next/audio/package.json +17 -0
- package/node_modules/@allyhub-next/formats/LICENSE +241 -0
- package/node_modules/@allyhub-next/formats/dist/data/comments.d.ts +94 -0
- package/node_modules/@allyhub-next/formats/dist/data/comments.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/config.d.ts +10 -0
- package/node_modules/@allyhub-next/formats/dist/data/config.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/edits.d.ts +28 -0
- package/node_modules/@allyhub-next/formats/dist/data/edits.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/elements.d.ts +6 -0
- package/node_modules/@allyhub-next/formats/dist/data/elements.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/faces.d.ts +38 -0
- package/node_modules/@allyhub-next/formats/dist/data/faces.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/file.d.ts +11 -0
- package/node_modules/@allyhub-next/formats/dist/data/file.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/gen.d.ts +31 -0
- package/node_modules/@allyhub-next/formats/dist/data/gen.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/messages.d.ts +34 -0
- package/node_modules/@allyhub-next/formats/dist/data/messages.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/reference.d.ts +676 -0
- package/node_modules/@allyhub-next/formats/dist/data/reference.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/script.d.ts +37 -0
- package/node_modules/@allyhub-next/formats/dist/data/script.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/sheet.d.ts +214 -0
- package/node_modules/@allyhub-next/formats/dist/data/sheet.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/data/words.d.ts +25 -0
- package/node_modules/@allyhub-next/formats/dist/data/words.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/index.d.ts +16 -0
- package/node_modules/@allyhub-next/formats/dist/index.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/items.d.ts +94 -0
- package/node_modules/@allyhub-next/formats/dist/items.js +2 -0
- package/node_modules/@allyhub-next/formats/dist/layout.d.ts +50 -0
- package/node_modules/@allyhub-next/formats/dist/layout.js +5 -0
- package/node_modules/@allyhub-next/formats/dist/schemas.d.ts +301 -0
- package/node_modules/@allyhub-next/formats/dist/schemas.js +2 -0
- package/node_modules/@allyhub-next/formats/package.json +14 -0
- package/node_modules/@allyhub-next/protocol/LICENSE +241 -0
- package/node_modules/@allyhub-next/protocol/dist/app.d.ts +98 -0
- package/node_modules/@allyhub-next/protocol/dist/app.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/auth.d.ts +116 -0
- package/node_modules/@allyhub-next/protocol/dist/auth.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/cli.d.ts +59 -0
- package/node_modules/@allyhub-next/protocol/dist/cli.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/cloud.d.ts +274 -0
- package/node_modules/@allyhub-next/protocol/dist/cloud.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/editor.d.ts +405 -0
- package/node_modules/@allyhub-next/protocol/dist/editor.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/files.d.ts +101 -0
- package/node_modules/@allyhub-next/protocol/dist/files.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/index.d.ts +12 -0
- package/node_modules/@allyhub-next/protocol/dist/index.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/jsonrpc.d.ts +83 -0
- package/node_modules/@allyhub-next/protocol/dist/jsonrpc.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/registry.d.ts +53 -0
- package/node_modules/@allyhub-next/protocol/dist/registry.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/runtimes.d.ts +93 -0
- package/node_modules/@allyhub-next/protocol/dist/runtimes.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/teams.d.ts +67 -0
- package/node_modules/@allyhub-next/protocol/dist/teams.js +2 -0
- package/node_modules/@allyhub-next/protocol/dist/tools.d.ts +345 -0
- package/node_modules/@allyhub-next/protocol/dist/tools.js +2 -0
- package/node_modules/@allyhub-next/protocol/package.json +13 -0
- package/node_modules/@allyhub-next/runtimes/LICENSE +241 -0
- package/node_modules/@allyhub-next/runtimes/dist/bundled.d.ts +10 -0
- package/node_modules/@allyhub-next/runtimes/dist/bundled.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/download.d.ts +15 -0
- package/node_modules/@allyhub-next/runtimes/dist/download.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/errors.d.ts +16 -0
- package/node_modules/@allyhub-next/runtimes/dist/errors.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/home.d.ts +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/home.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/index.d.ts +9 -0
- package/node_modules/@allyhub-next/runtimes/dist/index.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/lock.d.ts +6 -0
- package/node_modules/@allyhub-next/runtimes/dist/lock.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/manifest.d.ts +3 -0
- package/node_modules/@allyhub-next/runtimes/dist/manifest.js +2 -0
- package/node_modules/@allyhub-next/runtimes/dist/runtimes.d.ts +63 -0
- package/node_modules/@allyhub-next/runtimes/dist/runtimes.js +3 -0
- package/node_modules/@allyhub-next/runtimes/dist/unpack.d.ts +7 -0
- package/node_modules/@allyhub-next/runtimes/dist/unpack.js +2 -0
- package/node_modules/@allyhub-next/runtimes/manifest.json +395 -0
- package/node_modules/@allyhub-next/runtimes/package.json +14 -0
- package/node_modules/@allyhub-next/runtimes/schemas/runtimes.schema.json +153 -0
- package/node_modules/@allyhub-next/scenery/LICENSE +241 -0
- package/node_modules/@allyhub-next/scenery/NOTICE +42 -0
- package/node_modules/@allyhub-next/scenery/dist/aim.d.ts +55 -0
- package/node_modules/@allyhub-next/scenery/dist/aim.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/bake.d.ts +203 -0
- package/node_modules/@allyhub-next/scenery/dist/bake.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/camera.d.ts +150 -0
- package/node_modules/@allyhub-next/scenery/dist/camera.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/curve.d.ts +40 -0
- package/node_modules/@allyhub-next/scenery/dist/curve.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/define.d.ts +164 -0
- package/node_modules/@allyhub-next/scenery/dist/define.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/fit.d.ts +64 -0
- package/node_modules/@allyhub-next/scenery/dist/fit.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/glass.d.ts +34 -0
- package/node_modules/@allyhub-next/scenery/dist/glass.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/handheld.d.ts +184 -0
- package/node_modules/@allyhub-next/scenery/dist/handheld.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/hull.d.ts +23 -0
- package/node_modules/@allyhub-next/scenery/dist/hull.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/index.d.ts +22 -0
- package/node_modules/@allyhub-next/scenery/dist/index.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/lens.d.ts +48 -0
- package/node_modules/@allyhub-next/scenery/dist/lens.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/moire.d.ts +136 -0
- package/node_modules/@allyhub-next/scenery/dist/moire.js +93 -0
- package/node_modules/@allyhub-next/scenery/dist/motion.d.ts +48 -0
- package/node_modules/@allyhub-next/scenery/dist/motion.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/move.d.ts +260 -0
- package/node_modules/@allyhub-next/scenery/dist/move.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/noise.d.ts +41 -0
- package/node_modules/@allyhub-next/scenery/dist/noise.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/phone.d.ts +34 -0
- package/node_modules/@allyhub-next/scenery/dist/phone.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/report.d.ts +677 -0
- package/node_modules/@allyhub-next/scenery/dist/report.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/screen-focus.d.ts +55 -0
- package/node_modules/@allyhub-next/scenery/dist/screen-focus.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/screen.d.ts +71 -0
- package/node_modules/@allyhub-next/scenery/dist/screen.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/solve.d.ts +82 -0
- package/node_modules/@allyhub-next/scenery/dist/solve.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/timing.d.ts +26 -0
- package/node_modules/@allyhub-next/scenery/dist/timing.js +2 -0
- package/node_modules/@allyhub-next/scenery/dist/vec.d.ts +19 -0
- package/node_modules/@allyhub-next/scenery/dist/vec.js +2 -0
- package/node_modules/@allyhub-next/scenery/package.json +13 -0
- package/node_modules/@allyhub-next/video-core/LICENSE +241 -0
- package/node_modules/@allyhub-next/video-core/dist/anchors.d.ts +164 -0
- package/node_modules/@allyhub-next/video-core/dist/anchors.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/audio-types.d.ts +148 -0
- package/node_modules/@allyhub-next/video-core/dist/audio-types.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/backdrop.d.ts +87 -0
- package/node_modules/@allyhub-next/video-core/dist/backdrop.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/captions.d.ts +122 -0
- package/node_modules/@allyhub-next/video-core/dist/captions.js +11 -0
- package/node_modules/@allyhub-next/video-core/dist/console.d.ts +91 -0
- package/node_modules/@allyhub-next/video-core/dist/console.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/contrast.d.ts +98 -0
- package/node_modules/@allyhub-next/video-core/dist/contrast.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/cut-report.d.ts +77 -0
- package/node_modules/@allyhub-next/video-core/dist/cut-report.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/edit.d.ts +77 -0
- package/node_modules/@allyhub-next/video-core/dist/edit.js +13 -0
- package/node_modules/@allyhub-next/video-core/dist/edits.d.ts +163 -0
- package/node_modules/@allyhub-next/video-core/dist/edits.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/export.d.ts +96 -0
- package/node_modules/@allyhub-next/video-core/dist/export.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/fact.d.ts +965 -0
- package/node_modules/@allyhub-next/video-core/dist/fact.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/footage-motion.d.ts +168 -0
- package/node_modules/@allyhub-next/video-core/dist/footage-motion.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/formats.d.ts +240 -0
- package/node_modules/@allyhub-next/video-core/dist/formats.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/gen.d.ts +37 -0
- package/node_modules/@allyhub-next/video-core/dist/gen.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/index.d.ts +40 -0
- package/node_modules/@allyhub-next/video-core/dist/index.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/look.d.ts +66 -0
- package/node_modules/@allyhub-next/video-core/dist/look.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/marks.d.ts +34 -0
- package/node_modules/@allyhub-next/video-core/dist/marks.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/matrix.d.ts +289 -0
- package/node_modules/@allyhub-next/video-core/dist/matrix.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/measure.d.ts +465 -0
- package/node_modules/@allyhub-next/video-core/dist/measure.js +5 -0
- package/node_modules/@allyhub-next/video-core/dist/media.d.ts +226 -0
- package/node_modules/@allyhub-next/video-core/dist/media.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/messages.d.ts +88 -0
- package/node_modules/@allyhub-next/video-core/dist/messages.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/motion.d.ts +56 -0
- package/node_modules/@allyhub-next/video-core/dist/motion.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/music.d.ts +110 -0
- package/node_modules/@allyhub-next/video-core/dist/music.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/piece.d.ts +1146 -0
- package/node_modules/@allyhub-next/video-core/dist/piece.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/placement.d.ts +37 -0
- package/node_modules/@allyhub-next/video-core/dist/placement.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/problem.d.ts +262 -0
- package/node_modules/@allyhub-next/video-core/dist/problem.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/render-types.d.ts +49 -0
- package/node_modules/@allyhub-next/video-core/dist/render-types.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/schema.d.ts +352 -0
- package/node_modules/@allyhub-next/video-core/dist/schema.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/script-edit.d.ts +176 -0
- package/node_modules/@allyhub-next/video-core/dist/script-edit.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/script.d.ts +67 -0
- package/node_modules/@allyhub-next/video-core/dist/script.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/seams.d.ts +214 -0
- package/node_modules/@allyhub-next/video-core/dist/seams.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/slides.d.ts +37 -0
- package/node_modules/@allyhub-next/video-core/dist/slides.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/sound-under.d.ts +72 -0
- package/node_modules/@allyhub-next/video-core/dist/sound-under.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/speech.d.ts +83 -0
- package/node_modules/@allyhub-next/video-core/dist/speech.js +5 -0
- package/node_modules/@allyhub-next/video-core/dist/timeline.d.ts +616 -0
- package/node_modules/@allyhub-next/video-core/dist/timeline.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/timing.d.ts +88 -0
- package/node_modules/@allyhub-next/video-core/dist/timing.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/transcript.d.ts +288 -0
- package/node_modules/@allyhub-next/video-core/dist/transcript.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/transition.d.ts +289 -0
- package/node_modules/@allyhub-next/video-core/dist/transition.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/voice.d.ts +175 -0
- package/node_modules/@allyhub-next/video-core/dist/voice.js +2 -0
- package/node_modules/@allyhub-next/video-core/dist/words.d.ts +128 -0
- package/node_modules/@allyhub-next/video-core/dist/words.js +2 -0
- package/node_modules/@allyhub-next/video-core/package.json +14 -0
- package/package.json +52 -41
- package/README.md +0 -17
- package/dist/anim.d.ts.map +0 -1
- package/dist/anim.js.map +0 -1
- package/dist/define.d.ts.map +0 -1
- package/dist/define.js.map +0 -1
- package/dist/dom.d.ts.map +0 -1
- package/dist/dom.js.map +0 -1
- package/dist/fit.d.ts.map +0 -1
- package/dist/fit.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/media.d.ts.map +0 -1
- package/dist/media.js.map +0 -1
- package/dist/messages.d.ts.map +0 -1
- package/dist/messages.js.map +0 -1
- package/dist/noise.d.ts.map +0 -1
- package/dist/noise.js.map +0 -1
- package/dist/parts.d.ts.map +0 -1
- package/dist/parts.js.map +0 -1
- package/dist/paths.d.ts.map +0 -1
- package/dist/paths.js.map +0 -1
- package/dist/piece.d.ts.map +0 -1
- package/dist/piece.js.map +0 -1
- package/dist/props.d.ts.map +0 -1
- package/dist/props.js.map +0 -1
- package/dist/text.d.ts.map +0 -1
- package/dist/text.js.map +0 -1
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
AllyHub Software License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 AllyHub, Inc. ("AllyHub"). All rights reserved.
|
|
4
|
+
|
|
5
|
+
This software (the AllyHub command-line tool, its SDK, runtime and the
|
|
6
|
+
packages they depend on) is proprietary. It is not open source.
|
|
7
|
+
|
|
8
|
+
1. Permitted use. You may install and run the software, unmodified, to make,
|
|
9
|
+
check, preview and render videos and decks, including for commercial
|
|
10
|
+
purposes. What you make with it is yours.
|
|
11
|
+
|
|
12
|
+
2. Restrictions. Except as this license permits or applicable law requires,
|
|
13
|
+
you may not copy, modify, adapt, translate, sublicense, sell, rent, lease,
|
|
14
|
+
publish or otherwise distribute the software, create derivative works of
|
|
15
|
+
it, or reverse engineer, decompile or disassemble it.
|
|
16
|
+
|
|
17
|
+
3. Cloud services. AllyHub's cloud tools (sign-in, research, images, voice,
|
|
18
|
+
video) are separate services governed by AllyHub's terms of service.
|
|
19
|
+
|
|
20
|
+
4. Trademarks. This license grants no right to use the name "AllyHub" or its
|
|
21
|
+
logos.
|
|
22
|
+
|
|
23
|
+
5. No warranty. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
|
|
24
|
+
KIND, EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY,
|
|
25
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
|
|
26
|
+
ALLYHUB BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY ARISING FROM,
|
|
27
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR ITS USE.
|
|
28
|
+
|
|
29
|
+
6. Third-party code. Parts of the software are adapted from HyperFrames,
|
|
30
|
+
licensed under the Apache License, Version 2.0 (see NOTICE). Those parts
|
|
31
|
+
remain under that license, reproduced below, and nothing in this license
|
|
32
|
+
limits your rights under it.
|
|
33
|
+
|
|
34
|
+
7. Starter components. The starter components in the "components" folder,
|
|
35
|
+
which "allyhub add" copies into your workspace, are licensed under the MIT
|
|
36
|
+
License (see components/LICENSE): once copied, you may change, use and
|
|
37
|
+
share them freely.
|
|
38
|
+
|
|
39
|
+
--------------------------------------------------------------------------------
|
|
40
|
+
|
|
41
|
+
Apache License
|
|
42
|
+
Version 2.0, January 2004
|
|
43
|
+
http://www.apache.org/licenses/
|
|
44
|
+
|
|
45
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
46
|
+
|
|
47
|
+
1. Definitions.
|
|
48
|
+
|
|
49
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
50
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
51
|
+
|
|
52
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
53
|
+
the copyright owner that is granting the License.
|
|
54
|
+
|
|
55
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
56
|
+
other entities that control, are controlled by, or are under common
|
|
57
|
+
control with that entity. For the purposes of this definition,
|
|
58
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
59
|
+
direction or management of such entity, whether by contract or
|
|
60
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
61
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
62
|
+
|
|
63
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
64
|
+
exercising permissions granted by this License.
|
|
65
|
+
|
|
66
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
67
|
+
including but not limited to software source code, documentation
|
|
68
|
+
source, and configuration files.
|
|
69
|
+
|
|
70
|
+
"Object" form shall mean any form resulting from mechanical
|
|
71
|
+
transformation or translation of a Source form, including but
|
|
72
|
+
not limited to compiled object code, generated documentation,
|
|
73
|
+
and conversions to other media types.
|
|
74
|
+
|
|
75
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
76
|
+
Object form, made available under the License, as indicated by a
|
|
77
|
+
copyright notice that is included in or attached to the work
|
|
78
|
+
(an example is provided in the Appendix below).
|
|
79
|
+
|
|
80
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
81
|
+
form, that is based on (or derived from) the Work and for which the
|
|
82
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
83
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
84
|
+
of this License, Derivative Works shall not include works that remain
|
|
85
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
86
|
+
the Work and Derivative Works thereof.
|
|
87
|
+
|
|
88
|
+
"Contribution" shall mean any work of authorship, including
|
|
89
|
+
the original version of the Work and any modifications or additions
|
|
90
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
91
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
92
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
93
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
94
|
+
means any form of electronic, verbal, or written communication sent
|
|
95
|
+
to the Licensor or its representatives, including but not limited to
|
|
96
|
+
communication on electronic mailing lists, source code control systems,
|
|
97
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
98
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
99
|
+
excluding communication that is conspicuously marked or otherwise
|
|
100
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
101
|
+
|
|
102
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
103
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
104
|
+
subsequently incorporated within the Work.
|
|
105
|
+
|
|
106
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
107
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
108
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
109
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
110
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
111
|
+
Work and such Derivative Works in Source or Object form.
|
|
112
|
+
|
|
113
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
114
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
115
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
116
|
+
(except as stated in this section) patent license to make, have made,
|
|
117
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
118
|
+
where such license applies only to those patent claims licensable
|
|
119
|
+
by such Contributor that are necessarily infringed by their
|
|
120
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
121
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
122
|
+
institute patent litigation against any entity (including a
|
|
123
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
124
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
125
|
+
or contributory patent infringement, then any patent licenses
|
|
126
|
+
granted to You under this License for that Work shall terminate
|
|
127
|
+
as of the date such litigation is filed.
|
|
128
|
+
|
|
129
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
130
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
131
|
+
modifications, and in Source or Object form, provided that You
|
|
132
|
+
meet the following conditions:
|
|
133
|
+
|
|
134
|
+
(a) You must give any other recipients of the Work or
|
|
135
|
+
Derivative Works a copy of this License; and
|
|
136
|
+
|
|
137
|
+
(b) You must cause any modified files to carry prominent notices
|
|
138
|
+
stating that You changed the files; and
|
|
139
|
+
|
|
140
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
141
|
+
that You distribute, all copyright, patent, trademark, and
|
|
142
|
+
attribution notices from the Source form of the Work,
|
|
143
|
+
excluding those notices that do not pertain to any part of
|
|
144
|
+
the Derivative Works; and
|
|
145
|
+
|
|
146
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
147
|
+
distribution, then any Derivative Works that You distribute must
|
|
148
|
+
include a readable copy of the attribution notices contained
|
|
149
|
+
within such NOTICE file, excluding those notices that do not
|
|
150
|
+
pertain to any part of the Derivative Works, in at least one
|
|
151
|
+
of the following places: within a NOTICE text file distributed
|
|
152
|
+
as part of the Derivative Works; within the Source form or
|
|
153
|
+
documentation, if provided along with the Derivative Works; or,
|
|
154
|
+
within a display generated by the Derivative Works, if and
|
|
155
|
+
wherever such third-party notices normally appear. The contents
|
|
156
|
+
of the NOTICE file are for informational purposes only and
|
|
157
|
+
do not modify the License. You may add Your own attribution
|
|
158
|
+
notices within Derivative Works that You distribute, alongside
|
|
159
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
160
|
+
that such additional attribution notices cannot be construed
|
|
161
|
+
as modifying the License.
|
|
162
|
+
|
|
163
|
+
You may add Your own copyright statement to Your modifications and
|
|
164
|
+
may provide additional or different license terms and conditions
|
|
165
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
166
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
167
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
168
|
+
the conditions stated in this License.
|
|
169
|
+
|
|
170
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
171
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
172
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
173
|
+
this License, without any additional terms or conditions.
|
|
174
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
175
|
+
the terms of any separate license agreement you may have executed
|
|
176
|
+
with Licensor regarding such Contributions.
|
|
177
|
+
|
|
178
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
179
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
180
|
+
except as required for reasonable and customary use in describing the
|
|
181
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
182
|
+
|
|
183
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
184
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
185
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
186
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
187
|
+
implied, including, without limitation, any warranties or conditions
|
|
188
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
189
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
190
|
+
appropriateness of using or redistributing the Work and assume any
|
|
191
|
+
risks associated with Your exercise of permissions under this License.
|
|
192
|
+
|
|
193
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
194
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
195
|
+
unless required by applicable law (such as deliberate and grossly
|
|
196
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
197
|
+
liable to You for damages, including any direct, indirect, special,
|
|
198
|
+
incidental, or consequential damages of any character arising as a
|
|
199
|
+
result of this License or out of the use or inability to use the
|
|
200
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
201
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
202
|
+
other commercial damages or losses), even if such Contributor
|
|
203
|
+
has been advised of the possibility of such damages.
|
|
204
|
+
|
|
205
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
206
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
207
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
208
|
+
or other liability obligations and/or rights consistent with this
|
|
209
|
+
License. However, in accepting such obligations, You may act only
|
|
210
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
211
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
212
|
+
defend, and hold each Contributor harmless for any liability
|
|
213
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
214
|
+
of your accepting any such warranty or additional liability.
|
|
215
|
+
|
|
216
|
+
END OF TERMS AND CONDITIONS
|
|
217
|
+
|
|
218
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
219
|
+
|
|
220
|
+
To apply the Apache License to your work, attach the following
|
|
221
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
222
|
+
replaced with your own identifying information. (Don't include
|
|
223
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
224
|
+
comment syntax for the file format. We also recommend that a
|
|
225
|
+
file or class name and description of purpose be included on the
|
|
226
|
+
same "printed page" as the copyright notice for easier
|
|
227
|
+
identification within third-party archives.
|
|
228
|
+
|
|
229
|
+
Copyright [yyyy] [name of copyright owner]
|
|
230
|
+
|
|
231
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
232
|
+
you may not use this file except in compliance with the License.
|
|
233
|
+
You may obtain a copy of the License at
|
|
234
|
+
|
|
235
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
236
|
+
|
|
237
|
+
Unless required by applicable law or agreed to in writing, software
|
|
238
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
239
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
240
|
+
See the License for the specific language governing permissions and
|
|
241
|
+
limitations under the License.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/** Decibels of an amplitude (1 is full scale), rounded to 0.1, at least −120. */
|
|
2
|
+
export declare const db: (x: number) => number;
|
|
3
|
+
/** A stretch in seconds. */
|
|
4
|
+
export interface Band {
|
|
5
|
+
start: number;
|
|
6
|
+
end: number;
|
|
7
|
+
}
|
|
8
|
+
export interface SilenceOptions {
|
|
9
|
+
/** Seconds of the first sample (default 0). */
|
|
10
|
+
t0?: number;
|
|
11
|
+
/** Silence is under this, dBFS (default −40). */
|
|
12
|
+
threshold?: number;
|
|
13
|
+
/** The RMS window, seconds (default 0.01). */
|
|
14
|
+
window?: number;
|
|
15
|
+
/** The shortest band, seconds (default 0.03). */
|
|
16
|
+
minLength?: number;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Stretches where the sound stays under `threshold` dBFS (RMS over
|
|
20
|
+
* `window` seconds) for at least `minLength` seconds.
|
|
21
|
+
*/
|
|
22
|
+
export declare function silenceBands(s: Float32Array, rate: number, o?: SilenceOptions): Band[];
|
|
23
|
+
/** The sound at a cut, in dBFS and dB. */
|
|
24
|
+
export interface CutSound {
|
|
25
|
+
/** RMS over the 10 ms around the cut. */
|
|
26
|
+
levelDb: number;
|
|
27
|
+
/** RMS over 20–150 ms before and after the cut. */
|
|
28
|
+
aroundDb: number;
|
|
29
|
+
/** The highest sample within 5 ms of the cut. */
|
|
30
|
+
peakDb: number;
|
|
31
|
+
/**
|
|
32
|
+
* The largest step between two samples within 2 ms of the cut, against
|
|
33
|
+
* the steps 5–150 ms around it (their 99th percentile, at least −60
|
|
34
|
+
* dBFS): above 0 the cut has a sharper edge than the sound beside it; a
|
|
35
|
+
* click is a large step in quiet sound. At least −60: in silence a step
|
|
36
|
+
* means nothing.
|
|
37
|
+
*/
|
|
38
|
+
jumpDb: number;
|
|
39
|
+
}
|
|
40
|
+
/** The sound at sample `at` of `s`. */
|
|
41
|
+
export declare function soundAtCut(s: Float32Array, rate: number, at: number): CutSound;
|
|
42
|
+
/** Samples as `columns` [min, max] pairs, for drawing a waveform. */
|
|
43
|
+
export declare function waveColumns(s: Float32Array, columns: number): [min: number, max: number][];
|
|
44
|
+
/** The level in dBFS over windows of `window` seconds, each at its middle's time from `t0`. */
|
|
45
|
+
export declare function levelCurve(s: Float32Array, rate: number, o?: {
|
|
46
|
+
t0?: number;
|
|
47
|
+
window?: number;
|
|
48
|
+
}): {
|
|
49
|
+
t: number;
|
|
50
|
+
db: number;
|
|
51
|
+
}[];
|
|
52
|
+
//# sourceMappingURL=at-cut.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
const p=t=>Math.round(t*1e3)/1e3;export const db=t=>t>1e-6?Math.round(20*Math.log10(t)*10)/10:-120;function f(t,l,o){const n=Math.max(0,l),a=Math.min(t.length,o);if(a<=n)return 0;let s=0;for(let h=n;h<a;h++){const u=t[h]??0;s+=u*u}return Math.sqrt(s/(a-n))}export function silenceBands(t,l,o={}){const n=o.t0??0,a=o.threshold??-40,s=Math.max(1,Math.round((o.window??.01)*l)),h=o.minLength??.03,u=[];let c;const i=e=>{c!==void 0&&(e-c)/l>=h-1e-9&&u.push({start:p(n+c/l),end:p(n+e/l)}),c=void 0};for(let e=0;e<t.length;e+=s){const M=db(f(t,e,e+s))<a;M&&c===void 0?c=e:M||i(e)}return i(t.length),u}export function soundAtCut(t,l,o){const n=r=>Math.round(r/1e3*l),a=db(f(t,o-n(5),o+n(5))),s=f(t,o-n(150),o-n(20)),h=f(t,o+n(20),o+n(150)),u=db(Math.sqrt((s*s+h*h)/2));let c=0;for(let r=Math.max(0,o-n(5));r<Math.min(t.length,o+n(5));r++)c=Math.max(c,Math.abs(t[r]??0));const i=r=>Math.abs((t[r]??0)-(t[r-1]??0));let e=0;for(let r=Math.max(1,o-n(2));r<=Math.min(t.length-1,o+n(2));r++)e=Math.max(e,i(r));const M=[];for(const[r,m]of[[o-n(150),o-n(5)],[o+n(5),o+n(150)]])for(let d=Math.max(1,r);d<Math.min(t.length,m);d++)M.push(i(d));M.sort((r,m)=>r-m);const x=M[Math.floor(M.length*.99)]??0,g=10**(-60/20);return{levelDb:a,aroundDb:u,peakDb:db(c),jumpDb:Math.max(-60,Math.round(20*Math.log10(Math.max(e,1e-9)/Math.max(x,g))*10)/10)}}export function waveColumns(t,l){const o=[],n=t.length/l;for(let a=0;a<l;a++){const s=Math.floor(a*n),h=Math.max(s+1,Math.floor((a+1)*n));let u=0,c=0;for(let i=s;i<Math.min(h,t.length);i++){const e=t[i]??0;e<u&&(u=e),e>c&&(c=e)}o.push([u,c])}return o}export function levelCurve(t,l,o={}){const n=Math.max(1,Math.round((o.window??.01)*l)),a=o.t0??0,s=[];for(let h=0;h<t.length;h+=n)s.push({t:a+(h+n/2)/l,db:db(f(t,h,Math.min(t.length,h+n)))});return s}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { MixPlan, SpeechClip, Stereo } from "./plan.js";
|
|
2
|
+
import type { ClipSource } from "./voice.js";
|
|
3
|
+
/** How a file is decoded for the mix: a take's noise reduction and speed, a stem's filter. */
|
|
4
|
+
export interface DecodeAs {
|
|
5
|
+
denoise?: number | undefined;
|
|
6
|
+
speed?: number | undefined;
|
|
7
|
+
filter?: string | undefined;
|
|
8
|
+
}
|
|
9
|
+
/** One file's decoding, as a key: the same file decoded alike is decoded once. */
|
|
10
|
+
export declare const decodeKey: (file: string, how: DecodeAs) => string;
|
|
11
|
+
/**
|
|
12
|
+
* A decoded file as the mix asks for it: its two channels, and what of
|
|
13
|
+
* the asking it was made with (`made.speed`: the take's second s is at s
|
|
14
|
+
* / speed; a speed not made is resampled, its pitch moved). The player
|
|
15
|
+
* may have a file only as recorded until the host has made it.
|
|
16
|
+
*/
|
|
17
|
+
export type SoundOf = (file: string, how: DecodeAs) => {
|
|
18
|
+
src: Stereo;
|
|
19
|
+
made: DecodeAs;
|
|
20
|
+
} | undefined;
|
|
21
|
+
/** The speech's decoding of a clip: its denoise and its speed (pitch kept). */
|
|
22
|
+
export declare const speechHow: (c: SpeechClip) => DecodeAs;
|
|
23
|
+
/** Every decoding a plan asks for, so a host can make them before mixing. */
|
|
24
|
+
export declare function decodings(plan: MixPlan): {
|
|
25
|
+
file: string;
|
|
26
|
+
how: DecodeAs;
|
|
27
|
+
}[];
|
|
28
|
+
/**
|
|
29
|
+
* Each speech clip's source found: as the host made it (sped already,
|
|
30
|
+
* `stretched`), or as recorded, to be resampled.
|
|
31
|
+
*/
|
|
32
|
+
export declare function clipSource(sound: SoundOf): (c: SpeechClip) => ClipSource | undefined;
|
|
33
|
+
//# sourceMappingURL=decode.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
export const decodeKey=(e,i)=>`${e}\0${String(i.denoise??0)}\0${String(i.speed??1)}\0${i.filter??""}`,speechHow=e=>({...e.denoise?{denoise:e.denoise}:{},...e.speed!==void 0&&e.speed!==1?{speed:e.speed}:{}});export function decodings(e){const i=new Map,t=(s,d)=>i.set(decodeKey(s,d),{file:s,how:d});for(const s of e.speech)t(s.file,speechHow(s));for(const s of e.footage)t(s.file,{});e.music&&t(e.music.file,e.music.shape?.filter?{filter:e.music.shape.filter}:{});for(const s of e.sfx)s.file!==void 0&&t(s.file,s.shape?.filter?{filter:s.shape.filter}:{});return[...i.values()]}export function clipSource(e){return i=>{const t=e(i.file,speechHow(i));if(!t)return;const s=i.speed!==void 0&&i.speed!==1?i.speed:void 0;return s!==void 0&&t.made.speed===s?{src:t.src,stretched:s}:{src:t.src}}}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { type MixLevels } from "./levels.js";
|
|
2
|
+
import type { GainPoint, Segment } from "./plan.js";
|
|
3
|
+
/** A stretch of the film, seconds. */
|
|
4
|
+
export interface Span {
|
|
5
|
+
start: number;
|
|
6
|
+
end: number;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Music gain under speech: down by `duck.db` while words are spoken,
|
|
10
|
+
* going down over `attack` before a word and back over `release` after
|
|
11
|
+
* one. Pauses shorter than `hold` stay ducked: under a narration the
|
|
12
|
+
* music is one steady bed, not a swell between every two sentences. It
|
|
13
|
+
* comes back up between paragraphs, and where nobody speaks.
|
|
14
|
+
*/
|
|
15
|
+
export declare function duckEnvelope(spoken: readonly Span[], duck?: MixLevels["duck"]): GainPoint[];
|
|
16
|
+
/**
|
|
17
|
+
* Where speech plays on the film's clock: its segments (room tone
|
|
18
|
+
* included), with gaps shorter than a ramp down and back up joined.
|
|
19
|
+
*/
|
|
20
|
+
export declare function speechSpans(segments: readonly Segment[], duck?: MixLevels["duck"]): Span[];
|
|
21
|
+
/**
|
|
22
|
+
* A level that changes by `depth` dB while speech plays (the spans),
|
|
23
|
+
* ramping over the duck's attack and release: music and footage go to
|
|
24
|
+
* their under-speech level only then.
|
|
25
|
+
*/
|
|
26
|
+
export declare function speechEnvelope(spans: readonly Span[], depth: number, duck?: MixLevels["duck"]): GainPoint[];
|
|
27
|
+
/** The sum of two envelopes, exact at every point of either. */
|
|
28
|
+
export declare function addEnvelopes(a: readonly GainPoint[], b: readonly GainPoint[]): GainPoint[];
|
|
29
|
+
/**
|
|
30
|
+
* The gain of an equal-power fade `x` of the way through (0 to 1): two
|
|
31
|
+
* unrelated sounds cross-faded with it keep their summed power, so room
|
|
32
|
+
* tone goes over into the take's own room without a dip.
|
|
33
|
+
*/
|
|
34
|
+
export declare const equalPower: (x: number) => number;
|
|
35
|
+
/** The envelope's gain at t, in dB: its first value before it, its last after it. */
|
|
36
|
+
export declare function gainAt(points: readonly GainPoint[], t: number): number;
|
|
37
|
+
//# sourceMappingURL=envelope.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
import{MIX_DEFAULTS as s}from"./levels.js";function f(e,t){const n=[];for(const r of[...e].sort((a,o)=>a.start-o.start)){const a=n.at(-1);a&&r.start-a.end<t?a.end=Math.max(a.end,r.end):n.push({start:r.start,end:r.end})}return n}function u(e,t,n,r){const a=[];for(const o of e)a.push({t:Math.max(0,o.start-n),db:0},{t:o.start,db:t},{t:o.end,db:t},{t:o.end+r,db:0});return a}export function duckEnvelope(e,t=s.duck){return t.db>=0||e.length===0?[]:u(f(e,t.hold+t.attack+t.release),t.db,t.attack,t.release)}export function speechSpans(e,t=s.duck){return f(e.filter(n=>n.dur>0).map(n=>({start:n.at,end:n.at+n.dur})),t.attack+t.release)}export function speechEnvelope(e,t,n=s.duck){return t===0||e.length===0?[]:u(e,t,n.attack,n.release)}export function addEnvelopes(e,t){return e.length===0?[...t]:t.length===0?[...e]:[...new Set([...e,...t].map(r=>r.t))].sort((r,a)=>r-a).map(r=>({t:r,db:gainAt(e,r)+gainAt(t,r)}))}export const equalPower=e=>Math.sin(Math.PI/2*Math.min(1,Math.max(0,e)));export function gainAt(e,t){if(e.length===0)return 0;const n=e[0];if(!n||t<=n.t)return n?.db??0;for(let r=1;r<e.length;r++){const a=e[r-1],o=e[r];if(!(!a||!o)&&t<=o.t)return o.t===a.t?o.db:a.db+(o.db-a.db)*(t-a.t)/(o.t-a.t)}return e.at(-1)?.db??0}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export { SAMPLE_RATE, type FootageClip, type GainPoint, type MixPlan, type MusicPlay, type MusicSegment, type PartSpan, type Segment, type SfxPlay, type SpeechClip, type Stereo, type VoicePlan, } from "./plan.js";
|
|
2
|
+
export { addEnvelopes, duckEnvelope, equalPower, gainAt, speechEnvelope, speechSpans, type Span, } from "./envelope.js";
|
|
3
|
+
export { clipSource, decodeKey, decodings, speechHow, type DecodeAs, type SoundOf, } from "./decode.js";
|
|
4
|
+
export { renderMix, playSfx, type RenderOptions } from "./render.js";
|
|
5
|
+
export { playMusic } from "./music.js";
|
|
6
|
+
export { hashSeed, SFX_HIT, synthSfx } from "./sfx.js";
|
|
7
|
+
export { addSpeech, playVoice, sumSpeech, voiceGroups, type ClipSource, type VoiceGroup, } from "./voice.js";
|
|
8
|
+
export { limitPeaks, masterMix, previewMaster } from "./master.js";
|
|
9
|
+
export { drySpeech, recordedSpeech, type SpeechTracks } from "./recorded.js";
|
|
10
|
+
export { db, levelCurve, silenceBands, soundAtCut, waveColumns, type Band, type CutSound, type SilenceOptions, } from "./at-cut.js";
|
|
11
|
+
export { MASTER_DEFAULTS, MASTER_MECHANICS, MIX_DEFAULTS, resolveMaster, resolveMix, type MasterOptions, type MasterTargets, type MixLevels, type MixOptions, } from "./levels.js";
|
|
12
|
+
export { BAND_TYPES, bandAt, COMPRESS_DEFAULTS, shapeProblem, shapes, shapeSound, soundFilterProblem, soundLevel, type BandKey, type BandType, type EqBand, type FixedShape, type ResolvedShape, type SoundCompressor, type SoundMoment, type SoundShape, } from "./shape.js";
|
|
13
|
+
export * from "./recording/index.js";
|
|
14
|
+
export { biquad, biquadGain, BUTTERWORTH_Q, chainGain, fromDb, runBiquads, toDb, type Biquad, type FilterSpec, } from "./recording/filters.js";
|
|
15
|
+
export { convolve, fft, magnitudes, minimumPhase, nextPow2, } from "./recording/fft.js";
|
|
16
|
+
export { agc, compress, deess, gainComputer, type AgcOptions, type CompressorOptions, type DeesserOptions, } from "./recording/dynamics.js";
|
|
17
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
export{SAMPLE_RATE}from"./plan.js";export{addEnvelopes,duckEnvelope,equalPower,gainAt,speechEnvelope,speechSpans}from"./envelope.js";export{clipSource,decodeKey,decodings,speechHow}from"./decode.js";export{renderMix,playSfx}from"./render.js";export{playMusic}from"./music.js";export{hashSeed,SFX_HIT,synthSfx}from"./sfx.js";export{addSpeech,playVoice,sumSpeech,voiceGroups}from"./voice.js";export{limitPeaks,masterMix,previewMaster}from"./master.js";export{drySpeech,recordedSpeech}from"./recorded.js";export{db,levelCurve,silenceBands,soundAtCut,waveColumns}from"./at-cut.js";export{MASTER_DEFAULTS,MASTER_MECHANICS,MIX_DEFAULTS,resolveMaster,resolveMix}from"./levels.js";export{BAND_TYPES,bandAt,COMPRESS_DEFAULTS,shapeProblem,shapes,shapeSound,soundFilterProblem,soundLevel}from"./shape.js";export*from"./recording/index.js";export{biquad,biquadGain,BUTTERWORTH_Q,chainGain,fromDb,runBiquads,toDb}from"./recording/filters.js";export{convolve,fft,magnitudes,minimumPhase,nextPow2}from"./recording/fft.js";export{agc,compress,deess,gainComputer}from"./recording/dynamics.js";
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
/** `video({ mix })`: loudness targets of the stems (LUFS) and the music's ducking and fades. */
|
|
2
|
+
export interface MixOptions {
|
|
3
|
+
/** Each part's speech; default -16. */
|
|
4
|
+
speech?: number;
|
|
5
|
+
/** The music while speech plays; default -20. */
|
|
6
|
+
music?: number;
|
|
7
|
+
/** The music where nobody speaks; default -16. */
|
|
8
|
+
musicAlone?: number;
|
|
9
|
+
/** Sound effects from files; built-in sounds move by the same amount from the default; default -22. */
|
|
10
|
+
sfx?: number;
|
|
11
|
+
/** Footage's own sound where nobody speaks; default -16. */
|
|
12
|
+
footage?: number;
|
|
13
|
+
/** Footage's own sound while speech plays; default -22. */
|
|
14
|
+
footageUnderSpeech?: number;
|
|
15
|
+
/**
|
|
16
|
+
* How the music dips under words: `db` below its level while speech
|
|
17
|
+
* plays (default -8), going down over `attack` seconds before a word
|
|
18
|
+
* (0.3), back up over `release` after one (1), and staying down
|
|
19
|
+
* through pauses shorter than `hold` (2).
|
|
20
|
+
*/
|
|
21
|
+
duck?: {
|
|
22
|
+
db?: number;
|
|
23
|
+
attack?: number;
|
|
24
|
+
release?: number;
|
|
25
|
+
hold?: number;
|
|
26
|
+
};
|
|
27
|
+
/** The music's fade in at the start and out at the end, seconds; defaults 0.3 and 1.5 (at most a quarter of the video). */
|
|
28
|
+
musicFade?: {
|
|
29
|
+
in?: number;
|
|
30
|
+
out?: number;
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
/** The mix's settings with every default filled in. */
|
|
34
|
+
export interface MixLevels {
|
|
35
|
+
speech: number;
|
|
36
|
+
music: number;
|
|
37
|
+
musicAlone: number;
|
|
38
|
+
sfx: number;
|
|
39
|
+
footage: number;
|
|
40
|
+
footageUnderSpeech: number;
|
|
41
|
+
duck: {
|
|
42
|
+
db: number;
|
|
43
|
+
attack: number;
|
|
44
|
+
release: number;
|
|
45
|
+
hold: number;
|
|
46
|
+
};
|
|
47
|
+
musicFade: {
|
|
48
|
+
in: number;
|
|
49
|
+
out: number;
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
export declare const MIX_DEFAULTS: MixLevels;
|
|
53
|
+
/** An output's mix options over the defaults. */
|
|
54
|
+
export declare function resolveMix(o: MixOptions | undefined): MixLevels;
|
|
55
|
+
/** `video({ master })`: what the sum is mastered to. */
|
|
56
|
+
export interface MasterOptions {
|
|
57
|
+
/**
|
|
58
|
+
* Integrated loudness, LUFS (-70 to 0); default the platform profile's,
|
|
59
|
+
* else -14. false keeps the mix's own level (peaks still limited).
|
|
60
|
+
*/
|
|
61
|
+
lufs?: number | false;
|
|
62
|
+
/** True-peak ceiling, dBTP (-9 to 0); default -3 (AAC overshoots up to about 2 dB). */
|
|
63
|
+
truePeak?: number;
|
|
64
|
+
}
|
|
65
|
+
export declare const MASTER_DEFAULTS: {
|
|
66
|
+
readonly lufs: -14;
|
|
67
|
+
readonly truePeak: -3;
|
|
68
|
+
};
|
|
69
|
+
/**
|
|
70
|
+
* How the master reaches its targets, mechanics rather than options: the
|
|
71
|
+
* mix's integrated loudness is measured, one gain brings it to the target,
|
|
72
|
+
* a limiter at `oversample` times the rate holds the true peak under the
|
|
73
|
+
* ceiling (going down over `attack` seconds, back over `release`), and
|
|
74
|
+
* what came out is measured again; the gain is corrected by what the
|
|
75
|
+
* limiter took, at most `rounds` times, until the loudness is within
|
|
76
|
+
* `tolerance` LU of the target. Nothing rides the level over time: the
|
|
77
|
+
* mix keeps its loudness range.
|
|
78
|
+
*/
|
|
79
|
+
export declare const MASTER_MECHANICS: {
|
|
80
|
+
readonly attack: 0.002;
|
|
81
|
+
readonly release: 0.04;
|
|
82
|
+
readonly oversample: 4;
|
|
83
|
+
readonly rounds: 4;
|
|
84
|
+
readonly tolerance: 0.1;
|
|
85
|
+
};
|
|
86
|
+
/** The master's targets, or false to keep the mix's level (its peaks still limited to `truePeak`). */
|
|
87
|
+
export interface MasterTargets {
|
|
88
|
+
lufs: number | false;
|
|
89
|
+
truePeak: number;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* An output's `master` resolved: a number is the loudness, false keeps
|
|
93
|
+
* the mix's level, an object sets either; `profileLufs` is the platform
|
|
94
|
+
* profile's loudness, the default when the output names none.
|
|
95
|
+
*/
|
|
96
|
+
export declare function resolveMaster(master: number | false | MasterOptions | undefined, profileLufs?: number): MasterTargets;
|
|
97
|
+
//# sourceMappingURL=levels.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
export const MIX_DEFAULTS={speech:-16,music:-20,musicAlone:-16,sfx:-22,footage:-16,footageUnderSpeech:-22,duck:{db:-8,attack:.3,release:1,hold:2},musicFade:{in:.3,out:1.5}};export function resolveMix(e){const u=MIX_DEFAULTS;return{speech:e?.speech??u.speech,music:e?.music??u.music,musicAlone:e?.musicAlone??u.musicAlone,sfx:e?.sfx??u.sfx,footage:e?.footage??u.footage,footageUnderSpeech:e?.footageUnderSpeech??u.footageUnderSpeech,duck:{...u.duck,...e?.duck},musicFade:{...u.musicFade,...e?.musicFade}}}export const MASTER_DEFAULTS={lufs:-14,truePeak:-3},MASTER_MECHANICS={attack:.002,release:.04,oversample:4,rounds:4,tolerance:.1};export function resolveMaster(e,u){const s=u??MASTER_DEFAULTS.lufs;return e===!1?{lufs:!1,truePeak:MASTER_DEFAULTS.truePeak}:typeof e=="number"?{lufs:e,truePeak:MASTER_DEFAULTS.truePeak}:{lufs:e?.lufs??s,truePeak:e?.truePeak??MASTER_DEFAULTS.truePeak}}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { type MasterTargets } from "./levels.js";
|
|
2
|
+
import type { Stereo } from "./plan.js";
|
|
3
|
+
/**
|
|
4
|
+
* Holds the samples' peaks at `ceiling` (linear) in place: a gain that
|
|
5
|
+
* looks `attack` seconds ahead, comes down to what the loudest sample in
|
|
6
|
+
* that window allows, averaged over the window so it never jumps, and
|
|
7
|
+
* comes back up over `release`. The preview's limiter: it holds the
|
|
8
|
+
* samples, not the peaks between them, which the export's limiter holds
|
|
9
|
+
* at four times the rate.
|
|
10
|
+
*/
|
|
11
|
+
export declare function limitPeaks(bus: Stereo, ceiling: number, rate: number, attack?: number, release?: number): void;
|
|
12
|
+
/**
|
|
13
|
+
* The preview's master, in place: the export's measured gain to the
|
|
14
|
+
* target loudness and a limiter at the ceiling, the gain corrected by
|
|
15
|
+
* what the limiter took (MASTER_MECHANICS). Its limiter holds samples,
|
|
16
|
+
* not true peaks, so the preview's peaks and loudness can differ from the
|
|
17
|
+
* export's by a fraction of a dB where the mix is limited hard.
|
|
18
|
+
*/
|
|
19
|
+
export declare function masterMix(bus: Stereo, rate: number, targets: MasterTargets): {
|
|
20
|
+
gainDb: number;
|
|
21
|
+
integrated?: number;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* A plan's mix as the player plays it: rendered (render.ts), then
|
|
25
|
+
* mastered in place as the export is. Undefined where it is silent:
|
|
26
|
+
* nothing to master or to play.
|
|
27
|
+
*/
|
|
28
|
+
export declare function previewMaster(bus: Stereo, rate: number, targets: MasterTargets): Stereo | undefined;
|
|
29
|
+
//# sourceMappingURL=master.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
import{integratedLoudness as w}from"./recording/loudness.js";import{MASTER_MECHANICS as M}from"./levels.js";export function limitPeaks(e,s,i,m=M.attack,c=M.release){const n=e[0].length,o=Math.max(1,Math.round(m*i)),a=new Float32Array(n);for(let t=0;t<n;t++){const d=Math.max(Math.abs(e[0][t]??0),Math.abs(e[1][t]??0));a[t]=d>s?s/d:1}const r=new Float32Array(n),l=[];let f=0;for(let t=n-1;t>=0;t--){const d=a[t]??1;for(;l.length>f&&(a[l[l.length-1]??0]??1)>=d;)l.pop();for(l.push(t);(l[f]??0)>t+o;)f++;r[t]=a[l[f]??t]??1}const u=Math.exp(-1/(Math.max(c,1e-4)*i));let h=1;for(let t=0;t<n;t++)h=Math.min(r[t]??1,1-(1-h)*u),r[t]=h;let p=0;const x=new Float32Array(n);for(let t=0;t<n;t++)p+=r[t]??1,t>=o&&(p-=r[t-o]??1),x[t]=p/Math.min(o,t+1);for(let t=0;t<n;t++){const d=Math.min(x[t]??1,a[t]??1);e[0][t]=(e[0][t]??0)*d,e[1][t]=(e[1][t]??0)*d}}export function masterMix(e,s,i){const m=10**(i.truePeak/20),c=w(e,s),n=l=>{const f=10**(l/20),u=[Float32Array.from(e[0],h=>h*f),Float32Array.from(e[1],h=>h*f)];return limitPeaks(u,m,s),u};let o=i.lufs===!1||c===void 0?0:i.lufs-c,a=n(o),r=w(a,s);if(i.lufs!==!1&&c!==void 0)for(let l=1;l<M.rounds&&r!==void 0;l++){const f=i.lufs-r;if(Math.abs(f)<=M.tolerance)break;o+=f,a=n(o),r=w(a,s)}return e[0].set(a[0]),e[1].set(a[1]),{gainDb:o,...r===void 0?{}:{integrated:r}}}export function previewMaster(e,s,i){const[m,c]=e;let n=!1;for(let o=0;o<m.length&&!n;o++)n=m[o]!==0||c[o]!==0;if(n)return masterMix(e,s,i),e}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { MusicPlay, Stereo } from "./plan.js";
|
|
2
|
+
/**
|
|
3
|
+
* The music as the film plays it, at `rate`: its segments with their
|
|
4
|
+
* seams' equal-power fades, shaped by its bands and compressor, levelled
|
|
5
|
+
* (a shaped stem by its loudness as shaped, to the mix's musicAlone),
|
|
6
|
+
* then its gain over time (its dip under speech and its own points) and
|
|
7
|
+
* its fades, ending at `until` or the film's end. What the render's mix
|
|
8
|
+
* and the player add.
|
|
9
|
+
*/
|
|
10
|
+
export declare function playMusic(m: MusicPlay, src: Stereo, duration: number, rate: number): Stereo;
|
|
11
|
+
//# sourceMappingURL=music.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
import{equalPower as b,gainAt as D}from"./envelope.js";import{shapes as F,shapeSound as I,soundLevel as O}from"./shape.js";export function playMusic(f,c,M,t){const i=Math.round(M*t),o=[new Float32Array(i),new Float32Array(i)],g=c[0].length;if(g===0)return o;for(const n of f.segments){const e=Math.round(n.at*t),k=Math.round(n.from*t),r=Math.round(n.dur*t),l=Math.round(n.fadeIn*t),p=Math.round(n.fadeOut*t);for(let s=0;s<r;s++){const u=e+s,a=k+s;if(u<0||u>=i||a<0||a>=g)continue;let d=1;l>0&&s<l&&(d*=b(s/l)),p>0&&r-1-s<p&&(d*=b((r-1-s)/p)),o[0][u]=(o[0][u]??0)+(c[0][a]??0)*d,o[1][u]=(o[1][u]??0)+(c[1][a]??0)*d}}let w=f.gainDb;if(f.shape&&(F(f.shape)||f.shape.filter!==void 0)){I(o,f.shape,t,0);const n=O(o,t);n&&(w=f.alone-n.lufs)}const y=Math.round(f.fadeIn*t),A=Math.round(f.fadeOut*t),h=Math.min(i,Math.round((f.until??M)*t));for(let n=0;n<i;n++){if(n>=h){o[0][n]=0,o[1][n]=0;continue}let e=10**((w+D(f.duck,n/t))/20);n<y&&(e*=n/y),h-n<A&&(e*=(h-n)/A),o[0][n]=(o[0][n]??0)*e,o[1][n]=(o[1][n]??0)*e}return o}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type DecodeAs, type SoundOf } from "../decode.js";
|
|
2
|
+
import { type MixPlan } from "../plan.js";
|
|
3
|
+
import { type FfmpegOptions } from "./ffmpeg.js";
|
|
4
|
+
/**
|
|
5
|
+
* Speech clean-up: ffmpeg's FFT denoiser (afftdn) reducing the noise by
|
|
6
|
+
* `db`, tracking the noise floor as it changes.
|
|
7
|
+
*/
|
|
8
|
+
export declare function denoiseFilter(db: number): string;
|
|
9
|
+
/**
|
|
10
|
+
* The filters that play a file's sound as the mix does: a stem's own
|
|
11
|
+
* filter chain, the denoiser, then ffmpeg's atempo (a time stretch that
|
|
12
|
+
* keeps the pitch; one filter covers 0.5 to 2). None for a file played
|
|
13
|
+
* as recorded.
|
|
14
|
+
*/
|
|
15
|
+
export declare function speechFilters(o: DecodeAs): string[];
|
|
16
|
+
/**
|
|
17
|
+
* A file's sound denoised, sped or filtered as the mix plays it (the
|
|
18
|
+
* same filters, stereo at 48 kHz), written to `out` as FLAC: what the
|
|
19
|
+
* preview plays for a take with denoise() or speed(), or a stem with a
|
|
20
|
+
* filter.
|
|
21
|
+
*/
|
|
22
|
+
export declare function speechFile(path: string, out: string, how: DecodeAs, o?: FfmpegOptions): Promise<void>;
|
|
23
|
+
/**
|
|
24
|
+
* A sound or video file's sound as two channels at 48 kHz (a mono file
|
|
25
|
+
* given twice), through the filters `how` asks for.
|
|
26
|
+
*/
|
|
27
|
+
export declare function decodeStereo(path: string, how?: DecodeAs, o?: FfmpegOptions): Promise<[Float32Array, Float32Array]>;
|
|
28
|
+
/** A file's sound as one channel at `rate` (its channels mixed down), as ffmpeg resamples it. */
|
|
29
|
+
export declare function decodeMono(path: string, rate: number, o?: FfmpegOptions): Promise<Float32Array>;
|
|
30
|
+
/** Where the plan's files are: its name for a file (a repository path) to a path on this computer. */
|
|
31
|
+
export interface MixSources {
|
|
32
|
+
file(name: string): string | undefined;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Every file the plan plays decoded as it asks (a take denoised and sped,
|
|
36
|
+
* a stem filtered), each once; a file that cannot be decoded is left out.
|
|
37
|
+
*/
|
|
38
|
+
export declare function decodePlan(plan: MixPlan, sources: MixSources, o?: FfmpegOptions): Promise<SoundOf>;
|
|
39
|
+
//# sourceMappingURL=decode.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
import{decodeKey as p,decodings as g}from"../decode.js";import{SAMPLE_RATE as w}from"../plan.js";import{ffmpegOf as d,floats as u,runFfmpeg as l}from"./ffmpeg.js";const m=w;export function denoiseFilter(t){return`afftdn=nr=${Math.min(Math.max(t,.01),97).toFixed(2)}:nf=-50:tn=1`}export function speechFilters(t){return[...t.filter?[t.filter]:[],...t.denoise?[denoiseFilter(t.denoise)]:[],...t.speed!==void 0&&t.speed!==1?[`atempo=${t.speed.toFixed(6)}`]:[]]}export async function speechFile(t,n,i,r={}){const c=speechFilters(i);await l(await d(r),["-v","error","-y","-i",t,"-vn",...c.length>0?["-af",c.join(",")]:[],"-ac","2","-ar",String(m),"-c:a","flac","-f","flac",n])}export async function decodeStereo(t,n={},i={}){const r=speechFilters(n),{out:c}=await l(await d(i),["-v","error","-i",t,...r.length>0?["-af",r.join(",")]:[],"-f","f32le","-ac","2","-ar",String(m),"-"],!0),o=u(c),e=Math.floor(o.length/2),a=new Float32Array(e),s=new Float32Array(e);for(let f=0;f<e;f++)a[f]=o[f*2]??0,s[f]=o[f*2+1]??0;return[a,s]}export async function decodeMono(t,n,i={}){const{out:r}=await l(await d(i),["-v","error","-i",t,"-map","0:a:0","-ac","1","-ar",String(n),"-f","f32le","-"],!0);return u(r)}export async function decodePlan(t,n,i={}){const r=await d(i),c=new Map;for(const{file:o,how:e}of g(t)){const a=n.file(o);if(!a)continue;const s=await decodeStereo(a,e,{ffmpeg:r}).catch(()=>{});s&&c.set(p(o,e),s)}return(o,e)=>{const a=c.get(p(o,e));return a?{src:a,made:e}:void 0}}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/** One ebur128 measurement, every 100 ms. */
|
|
2
|
+
export interface LoudnessFrame {
|
|
3
|
+
/** End of the measured window, seconds. */
|
|
4
|
+
t: number;
|
|
5
|
+
/** Momentary loudness (400 ms window), LUFS. */
|
|
6
|
+
momentary: number;
|
|
7
|
+
/** Short-term loudness (3 s window), LUFS. */
|
|
8
|
+
shortTerm: number;
|
|
9
|
+
}
|
|
10
|
+
/** The summary: integrated loudness (LUFS), its range (LU) and true peak (dBTP). */
|
|
11
|
+
export interface LoudnessSummary {
|
|
12
|
+
/** Absent when everything is gated out: ebur128 says −70 LUFS then, nothing to hear. */
|
|
13
|
+
integrated?: number;
|
|
14
|
+
range?: number;
|
|
15
|
+
truePeak?: number;
|
|
16
|
+
}
|
|
17
|
+
/** A finite number in a match, or undefined (`-inf`, missing). */
|
|
18
|
+
export declare function num(s: string | undefined): number | undefined;
|
|
19
|
+
/** ebur128's summary, the last one in the log. */
|
|
20
|
+
export declare function ebur128Summary(log: string): LoudnessSummary;
|
|
21
|
+
/** ebur128's per-frame log (framelog=info) and its summary. */
|
|
22
|
+
export declare function parseEbur128(log: string): LoudnessSummary & {
|
|
23
|
+
frames: LoudnessFrame[];
|
|
24
|
+
};
|
|
25
|
+
//# sourceMappingURL=ebur128.d.ts.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! AllyHub. Copyright (c) 2026 AllyHub, Inc. All rights reserved. Use is subject to LICENSE.md. */
|
|
2
|
+
export function num(e){if(e===void 0)return;const n=Number(e);return Number.isFinite(n)?n:void 0}export function ebur128Summary(e){const n=e.slice(e.lastIndexOf("Summary:")),t=num(/Integrated loudness:\s*\n\s*I:\s*(-?[\d.]+|-inf) LUFS/.exec(n)?.[1]),s=num(/Loudness range:\s*\n\s*LRA:\s*(-?[\d.]+)/.exec(n)?.[1]),r=num(/True peak:\s*\n\s*Peak:\s*(-?[\d.]+|-inf)/.exec(n)?.[1]);return{...t!==void 0&&t>-70?{integrated:t}:{},...s===void 0?{}:{range:s},...r===void 0?{}:{truePeak:r}}}export function parseEbur128(e){const n=[],t=/\bt:\s*(-?[\d.]+)\s+TARGET:.*?\bM:\s*(-?[\d.]+|-inf)\s+S:\s*(-?[\d.]+|-inf)/g;for(const s of e.matchAll(t)){const r=num(s[1]);r!==void 0&&n.push({t:r,momentary:num(s[2])??-120,shortTerm:num(s[3])??-120})}return{frames:n,...ebur128Summary(e)}}
|