@hyperframes/producer 0.8.178 → 0.8.179
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/distributed.js +2189 -2107
- package/dist/index.js +3450 -3368
- package/dist/public-server.js +11 -0
- package/dist/services/distributed/chunkAudio.d.ts +11 -0
- package/dist/services/distributed/mp4Stitch.d.ts +1 -0
- package/dist/services/distributed/plan.d.ts +2 -0
- package/package.json +7 -7
package/dist/public-server.js
CHANGED
|
@@ -13851,6 +13851,17 @@ var DISTRIBUTED_RENDER_CAPABILITIES = Object.freeze({
|
|
|
13851
13851
|
// src/services/render/stages/planHash.ts
|
|
13852
13852
|
var FIELD_DELIMITER = Buffer.from([0]);
|
|
13853
13853
|
|
|
13854
|
+
// src/services/distributed/chunkAudio.ts
|
|
13855
|
+
import { appendRenderProvenanceArgs, describeFfmpegFailure as describeFfmpegFailure2, runFfmpeg as runFfmpeg5 } from "@hyperframes/engine";
|
|
13856
|
+
|
|
13857
|
+
// src/services/distributed/mp4Stitch.ts
|
|
13858
|
+
var SCAN_BYTES = 64 * 1024;
|
|
13859
|
+
|
|
13860
|
+
// src/services/distributed/chunkAudio.ts
|
|
13861
|
+
var SLICE_DIR = "audio-chunks";
|
|
13862
|
+
var SLICE_FRAME = `${SLICE_DIR}/frame.m4a`;
|
|
13863
|
+
var SLICE_LAYOUT = `${SLICE_DIR}/layout.json`;
|
|
13864
|
+
|
|
13854
13865
|
// src/services/distributed/planSize.ts
|
|
13855
13866
|
var PLAN_ROOT_CATEGORY = {
|
|
13856
13867
|
compiled: "compiled",
|
|
@@ -15,6 +15,17 @@ interface AudioCut {
|
|
|
15
15
|
packetCount: number;
|
|
16
16
|
}
|
|
17
17
|
export declare function audioCutForChunk(grid: AacPacketGrid, chunks: readonly ChunkSliceJson[], index: number, fps: Fps): AudioCut | null;
|
|
18
|
+
export declare function chunkAudioSlicePath(index: number): string;
|
|
19
|
+
/** Which chunks need a sliced-audio file: `"all"`, one index, or `null` if it is not one. */
|
|
20
|
+
export declare function chunkAudioSliceTarget(path: string): "all" | number | null;
|
|
21
|
+
export declare function writeChunkAudioSlices(input: {
|
|
22
|
+
audioPath: string;
|
|
23
|
+
planDir: string;
|
|
24
|
+
chunks: readonly ChunkSliceJson[];
|
|
25
|
+
fps: Fps;
|
|
26
|
+
}): Promise<void>;
|
|
27
|
+
/** The plan audio for a chunk: the whole file, or one rebuilt at `scratchPath` from its slice. */
|
|
28
|
+
export declare function chunkAudioSource(planDir: string, chunkIndex: number, scratchPath: string): string | null;
|
|
18
29
|
interface MuxInput {
|
|
19
30
|
videoPath: string;
|
|
20
31
|
audioPath: string | null;
|
|
@@ -32,6 +32,7 @@ export interface TrackTable {
|
|
|
32
32
|
/** Each track's sample tables, expanded to one entry per sample (and per chunk). */
|
|
33
33
|
export declare function readTracks(moov: Buffer): TrackTable[];
|
|
34
34
|
export declare function buildStitchedHeader(layouts: readonly Mp4Layout[]): Buffer;
|
|
35
|
+
export declare function fileRange(path: string): ReadRange;
|
|
35
36
|
/** Local join: the stitched header, then each chunk's mdat payload in order. Like the ffmpeg
|
|
36
37
|
* join, it writes in a work folder beside `outputPath` and renames only a finished file there. */
|
|
37
38
|
export declare function writeStitchedMp4(chunkPaths: readonly string[], outputPath: string): Promise<void>;
|
|
@@ -209,6 +209,8 @@ export interface BuildLocalExecutionPlanOptions {
|
|
|
209
209
|
readonly whileAudioMixes?: () => Promise<void>;
|
|
210
210
|
/** mp4 chunks carry their plan-audio slice unless cfr re-encodes. */
|
|
211
211
|
readonly chunksCarryAudio?: boolean;
|
|
212
|
+
/** With `chunksCarryAudio`, also write each chunk's audio packets to their own file. Plan v2 only. */
|
|
213
|
+
readonly sliceChunkAudio?: boolean;
|
|
212
214
|
}
|
|
213
215
|
export interface RemoteProjectFile {
|
|
214
216
|
readonly url: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hyperframes/producer",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.179",
|
|
4
4
|
"description": "HTML-to-video rendering engine using Chrome's BeginFrame API",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -35,11 +35,11 @@
|
|
|
35
35
|
"postcss": "^8.4.0",
|
|
36
36
|
"puppeteer": "^25.2.1",
|
|
37
37
|
"puppeteer-core": "^25.2.1",
|
|
38
|
-
"@hyperframes/core": "0.8.
|
|
39
|
-
"@hyperframes/engine": "0.8.
|
|
40
|
-
"@hyperframes/lint": "0.8.
|
|
41
|
-
"@hyperframes/
|
|
42
|
-
"@hyperframes/
|
|
38
|
+
"@hyperframes/core": "0.8.179",
|
|
39
|
+
"@hyperframes/engine": "0.8.179",
|
|
40
|
+
"@hyperframes/lint": "0.8.179",
|
|
41
|
+
"@hyperframes/studio-server": "0.8.179",
|
|
42
|
+
"@hyperframes/parsers": "0.8.179"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"@types/node": "^25.0.10",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"tsx": "^4.21.0",
|
|
49
49
|
"typescript": "^5.7.2",
|
|
50
50
|
"vitest": "^4.1.11",
|
|
51
|
-
"@hyperframes/aws-lambda": "0.8.
|
|
51
|
+
"@hyperframes/aws-lambda": "0.8.179"
|
|
52
52
|
},
|
|
53
53
|
"engines": {
|
|
54
54
|
"node": ">=22"
|