libbitsub 1.11.0 → 1.12.0
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/README.md +113 -16
- package/dist/index.d.ts +3 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/integrations/react.d.ts.map +1 -1
- package/dist/integrations/react.js +7 -1
- package/dist/integrations/react.js.map +1 -1
- package/dist/integrations/shared.d.ts +2 -2
- package/dist/integrations/shared.d.ts.map +1 -1
- package/dist/integrations/shared.js.map +1 -1
- package/dist/ts/capabilities.d.ts +8 -0
- package/dist/ts/capabilities.d.ts.map +1 -0
- package/dist/ts/capabilities.js +105 -0
- package/dist/ts/capabilities.js.map +1 -0
- package/dist/ts/parsers.d.ts +39 -2
- package/dist/ts/parsers.d.ts.map +1 -1
- package/dist/ts/parsers.js +229 -1
- package/dist/ts/parsers.js.map +1 -1
- package/dist/ts/renderers.d.ts +128 -10
- package/dist/ts/renderers.d.ts.map +1 -1
- package/dist/ts/renderers.js +1341 -138
- package/dist/ts/renderers.js.map +1 -1
- package/dist/ts/types.d.ts +159 -6
- package/dist/ts/types.d.ts.map +1 -1
- package/dist/ts/utils.d.ts.map +1 -1
- package/dist/ts/utils.js +98 -2
- package/dist/ts/utils.js.map +1 -1
- package/dist/ts/video-frame-scheduler.d.ts +35 -0
- package/dist/ts/video-frame-scheduler.d.ts.map +1 -0
- package/dist/ts/video-frame-scheduler.js +98 -0
- package/dist/ts/video-frame-scheduler.js.map +1 -0
- package/dist/ts/worker.d.ts.map +1 -1
- package/dist/ts/worker.js +394 -0
- package/dist/ts/worker.js.map +1 -1
- package/dist/wrapper.d.ts +4 -3
- package/dist/wrapper.d.ts.map +1 -1
- package/dist/wrapper.js +3 -2
- package/dist/wrapper.js.map +1 -1
- package/package.json +3 -2
- package/pkg/README.md +113 -16
- package/pkg/libbitsub.d.ts +51 -1
- package/pkg/libbitsub.js +178 -3
- package/pkg/libbitsub_bg.wasm +0 -0
- package/pkg/libbitsub_bg.wasm.d.ts +21 -0
- package/pkg/package.json +4 -4
- package/src/integrations/react.tsx +7 -1
- package/src/integrations/shared.ts +2 -1
- package/src/wrapper.ts +22 -2
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# libbit(map)sub
|
|
2
2
|
|
|
3
|
-
High-performance WASM renderer for graphical subtitles (PGS, VobSub, and MKS-embedded VobSub), written in Rust.
|
|
3
|
+
High-performance WASM renderer for graphical subtitles (PGS, VobSub, DVB-SUB, and MKS-embedded VobSub), written in Rust.
|
|
4
4
|
|
|
5
5
|
Started as a fork of Arcus92's [libpgs-js](https://github.com/Arcus92/libpgs-js), this project was reworked for higher performance and broader format support. It keeps the familiar high-level PGS-oriented API while adding a lower-level parser surface, VobSub support, GPU backends, and worker-backed rendering.
|
|
6
6
|
|
|
@@ -8,6 +8,7 @@ Started as a fork of Arcus92's [libpgs-js](https://github.com/Arcus92/libpgs-js)
|
|
|
8
8
|
|
|
9
9
|
- PGS (Blu-ray) subtitle parsing and rendering
|
|
10
10
|
- VobSub (DVD) subtitle parsing and rendering
|
|
11
|
+
- DVB-SUB (ETSI EN 300 743) parsing and rendering via PES/ES and `"DV"` PTS-framed dumps
|
|
11
12
|
- Matroska `.mks` extraction for embedded `S_VOBSUB` tracks
|
|
12
13
|
- WebGPU, WebGL2, and Canvas2D rendering with automatic fallback
|
|
13
14
|
- Worker-backed parsing/rendering for large subtitle files
|
|
@@ -256,6 +257,7 @@ const renderer = new PgsRenderer({
|
|
|
256
257
|
},
|
|
257
258
|
cacheLimit: 32,
|
|
258
259
|
prefetchWindow: { before: 1, after: 2 },
|
|
260
|
+
frameAwareSync: true,
|
|
259
261
|
onWarning: (warning) => {
|
|
260
262
|
console.warn(warning.code, warning.message, warning.details)
|
|
261
263
|
},
|
|
@@ -269,6 +271,33 @@ const renderer = new PgsRenderer({
|
|
|
269
271
|
renderer.dispose()
|
|
270
272
|
```
|
|
271
273
|
|
|
274
|
+
Mount into a fullscreen shell or Shadow DOM root, reuse a player-owned canvas,
|
|
275
|
+
cap high-DPI backing-store cost, or bypass automatic backend selection:
|
|
276
|
+
|
|
277
|
+
```ts
|
|
278
|
+
const renderer = new PgsRenderer({
|
|
279
|
+
video: videoElement,
|
|
280
|
+
subUrl: '/subtitles/movie.sup',
|
|
281
|
+
container: shadowRoot, // HTMLElement or ShadowRoot; defaults to video.parentElement
|
|
282
|
+
canvas: playerOverlayCanvas, // optional; remains mounted after dispose()
|
|
283
|
+
devicePixelRatioCap: 2,
|
|
284
|
+
backend: 'webgl2' // 'auto' | 'webgpu' | 'webgl2' | 'worker-offscreen' | 'canvas2d'
|
|
285
|
+
})
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
An explicitly requested GPU or worker backend falls back to Canvas2D if it cannot
|
|
289
|
+
initialize. A supplied `container` takes precedence over the canvas's current parent;
|
|
290
|
+
without one, an already-mounted caller canvas stays in its existing host. Automatic
|
|
291
|
+
selection does not transfer a caller-owned canvas to a worker; request
|
|
292
|
+
`backend: 'worker-offscreen'` explicitly to allow that ownership transfer.
|
|
293
|
+
|
|
294
|
+
Frame-aware synchronization is enabled by default. On browsers with
|
|
295
|
+
`requestVideoFrameCallback()`, cue lookup uses the `mediaTime` of the frame sent
|
|
296
|
+
to the compositor instead of polling `video.currentTime`. Older browsers fall
|
|
297
|
+
back to `requestAnimationFrame()` automatically; set `frameAwareSync: false` to
|
|
298
|
+
force that compatibility path. The active path is available as
|
|
299
|
+
`renderer.getSynchronizationMode()` and as `getStats().syncMode`.
|
|
300
|
+
|
|
272
301
|
### VobSub renderer
|
|
273
302
|
|
|
274
303
|
```ts
|
|
@@ -290,6 +319,45 @@ renderer.setDebandThreshold(64)
|
|
|
290
319
|
renderer.setDebandRange(15)
|
|
291
320
|
```
|
|
292
321
|
|
|
322
|
+
### DVB renderer
|
|
323
|
+
|
|
324
|
+
```ts
|
|
325
|
+
import { DvbRenderer } from 'libbitsub'
|
|
326
|
+
|
|
327
|
+
const renderer = new DvbRenderer({
|
|
328
|
+
video: videoElement,
|
|
329
|
+
subUrl: '/subtitles/track.dvb'
|
|
330
|
+
})
|
|
331
|
+
```
|
|
332
|
+
|
|
333
|
+
DVB dumps use libbitsub framing:
|
|
334
|
+
|
|
335
|
+
```
|
|
336
|
+
"DV" | pts_90k_be_u32 | payload_len_be_u32 | payload…
|
|
337
|
+
```
|
|
338
|
+
|
|
339
|
+
`payload` is a PES data field (`0x20 0x00 …`) or raw segments (`sync_byte 0x0F`). Concatenated MPEG PES packets (`00 00 01 BD`) with PTS are also accepted.
|
|
340
|
+
|
|
341
|
+
The DVB decoder renders bitmap object coding method 0. Character-string and reserved object coding methods are ignored.
|
|
342
|
+
|
|
343
|
+
### Live / push streams
|
|
344
|
+
|
|
345
|
+
PGS and DVB renderers can start without a URL or in-memory subtitle file. Push transport or demuxer chunks as they arrive; calls are processed in order even when they are made before renderer initialization completes.
|
|
346
|
+
|
|
347
|
+
```ts
|
|
348
|
+
import { DvbRenderer } from 'libbitsub'
|
|
349
|
+
|
|
350
|
+
const renderer = new DvbRenderer({ video: videoElement })
|
|
351
|
+
|
|
352
|
+
const added = await renderer.append(dvbPesChunk) // newly indexed cues
|
|
353
|
+
const total = await renderer.flush() // finalize trailing input; total indexed cues
|
|
354
|
+
|
|
355
|
+
await renderer.reset() // clear cues/caches/display, then reuse the same renderer
|
|
356
|
+
await renderer.append(nextChannelChunk)
|
|
357
|
+
```
|
|
358
|
+
|
|
359
|
+
`append()` accepts `Uint8Array` or `ArrayBuffer` without detaching the caller's buffer. `flush()` discards incomplete trailing bytes; later appends are still accepted. `reset()` keeps the canvas, worker session, render loop, and configuration alive while clearing the stream state. VobSub does not expose the push API because it depends on its `.idx`/container index.
|
|
360
|
+
|
|
293
361
|
### Automatic format detection
|
|
294
362
|
|
|
295
363
|
```ts
|
|
@@ -302,7 +370,7 @@ const renderer = createAutoSubtitleRenderer({
|
|
|
302
370
|
})
|
|
303
371
|
```
|
|
304
372
|
|
|
305
|
-
Automatic detection uses file hints when available and otherwise inspects the binary payload. `.mks` sources are treated as VobSub only when they contain an embedded `S_VOBSUB` track. If the format cannot be identified confidently, it throws instead of silently forcing a parser.
|
|
373
|
+
Automatic detection uses file hints when available and otherwise inspects the binary payload. `.idx` / `idxContent` still means VobSub. Bare `.sub` is content-probed for DVB before VobSub. `.mks` sources are treated as VobSub only when they contain an embedded `S_VOBSUB` track. If the format cannot be identified confidently, it throws instead of silently forcing a parser.
|
|
306
374
|
|
|
307
375
|
## Layout controls
|
|
308
376
|
|
|
@@ -608,7 +676,7 @@ Emitted events:
|
|
|
608
676
|
| `loaded` | subtitle format and parser metadata |
|
|
609
677
|
| `error` | subtitle format and `SubtitleDiagnosticErrorLike` |
|
|
610
678
|
| `warning` | `SubtitleDiagnosticWarning` |
|
|
611
|
-
| `renderer-change` | active backend: `webgpu`, `webgl2`, or `canvas2d`
|
|
679
|
+
| `renderer-change` | active backend: `webgpu`, `webgl2`, `worker-offscreen`, or `canvas2d` |
|
|
612
680
|
| `worker-state` | whether worker mode is enabled, ready, fallback status, and the active session ID |
|
|
613
681
|
| `cache-change` | cached frame count, pending renders, and configured cache limit |
|
|
614
682
|
| `cue-change` | current cue metadata or `null` when nothing is displayed |
|
|
@@ -634,6 +702,7 @@ const stats = renderer.getStats()
|
|
|
634
702
|
- `pendingRenders`
|
|
635
703
|
- `totalEntries`
|
|
636
704
|
- `currentIndex`
|
|
705
|
+
- `syncMode`
|
|
637
706
|
|
|
638
707
|
`getCacheStats()` adds worker/session state for the current renderer cache, while `getLastRenderInfo()` exposes the most recent render outcome with a status of `rendered`, `cleared`, `pending`, `empty`, or `failed`.
|
|
639
708
|
|
|
@@ -683,23 +752,31 @@ const parser = new UnifiedSubtitleParser({
|
|
|
683
752
|
parser.loadAuto({ data: subtitleBytes, fileName: 'track.sup' })
|
|
684
753
|
```
|
|
685
754
|
|
|
686
|
-
## GPU backends
|
|
755
|
+
## GPU / present backends
|
|
687
756
|
|
|
688
757
|
libbitsub prefers:
|
|
689
758
|
|
|
690
|
-
1. WebGPU
|
|
691
|
-
2. WebGL2
|
|
692
|
-
3. Canvas2D
|
|
759
|
+
1. WebGPU (main-thread present)
|
|
760
|
+
2. WebGL2 (main-thread present)
|
|
761
|
+
3. Worker OffscreenCanvas (decode + Canvas2D present off the UI thread)
|
|
762
|
+
4. Canvas2D (main-thread fallback for older TVs)
|
|
693
763
|
|
|
694
764
|
```ts
|
|
695
|
-
import { isWebGPUSupported } from 'libbitsub'
|
|
765
|
+
import { getRuntimeCapabilities, isWebGPUSupported } from 'libbitsub'
|
|
696
766
|
|
|
697
767
|
console.log({
|
|
698
|
-
webgpu: isWebGPUSupported()
|
|
768
|
+
webgpu: isWebGPUSupported(),
|
|
769
|
+
capabilities: getRuntimeCapabilities()
|
|
699
770
|
})
|
|
700
771
|
```
|
|
701
772
|
|
|
702
|
-
|
|
773
|
+
When Worker OffscreenCanvas is selected, composition/present moves into the shared worker —
|
|
774
|
+
not only parsing — which reduces UI stalls during subtitle track switches on constrained devices.
|
|
775
|
+
The existing transferable RGBA path remains for main-thread GPU/Canvas2D present.
|
|
776
|
+
|
|
777
|
+
Use `onWebGPUFallback`, `onWebGL2Fallback`, `onEvent`, `onWarning`, or `getRuntimeCapabilities()`
|
|
778
|
+
to observe or explain the active backend path. Set `offscreenRender: false` to force main-thread
|
|
779
|
+
Canvas2D on the software tier.
|
|
703
780
|
|
|
704
781
|
## Compatibility & visual regression
|
|
705
782
|
|
|
@@ -736,8 +813,8 @@ Browser/device support matrix (including webOS TV): [docs/COMPATIBILITY.md](./do
|
|
|
736
813
|
- `warmup(): Promise<void>` / `ready(): Promise<void>` pre-initialize the shared subtitle worker (including in-worker WASM). Safe to call multiple times; concurrent callers share one init promise. Prefer these in TV/player apps before the first track switch.
|
|
737
814
|
- `isWorkerAvailable(): boolean` / `isWorkerReady(): boolean` report worker support and whether the shared worker has finished initializing.
|
|
738
815
|
- `isWebGPUSupported(): boolean` checks WebGPU support.
|
|
739
|
-
- `detectSubtitleFormat(source: AutoSubtitleSource): 'pgs' | 'vobsub' | null` detects the bitmap subtitle format from file hints or binary data.
|
|
740
|
-
- `createAutoSubtitleRenderer(options: AutoVideoSubtitleOptions): PgsRenderer | VobSubRenderer` creates a high-level renderer after format detection.
|
|
816
|
+
- `detectSubtitleFormat(source: AutoSubtitleSource): 'pgs' | 'vobsub' | 'dvb' | null` detects the bitmap subtitle format from file hints or binary data.
|
|
817
|
+
- `createAutoSubtitleRenderer(options: AutoVideoSubtitleOptions): PgsRenderer | VobSubRenderer | DvbRenderer` creates a high-level renderer after format detection.
|
|
741
818
|
- `openSubtitles(source, options?): Promise<OpenedSubtitles>` initializes WASM, auto-detects the low-level format, and returns a normalized parser handle.
|
|
742
819
|
- `probeRangeSupport(url, options?)` / `fetchSubtitleAsset(url, options?, onChunk?)` / `fetchSubtitleText(url, options?)` perform Range-aware progressive asset downloads for custom loaders.
|
|
743
820
|
- `renderFrameData(frame, options?): SubtitleRenderedFrameData | null` composes a `SubtitleData` frame into exportable pixels.
|
|
@@ -768,16 +845,23 @@ Browser/device support matrix (including webOS TV): [docs/COMPATIBILITY.md](./do
|
|
|
768
845
|
- `clearFrameCache(): void` clears the renderer-side and parser-side frame cache.
|
|
769
846
|
- `prefetchRange(startIndex: number, endIndex: number): Promise<void>` prefetches decoded frames for a cue range.
|
|
770
847
|
- `prefetchAroundTime(time: number, before?: number, after?: number): Promise<void>` prefetches around a playback time in seconds.
|
|
848
|
+
- `append(data: Uint8Array | ArrayBuffer): Promise<number>` pushes live bytes and returns newly indexed cues.
|
|
849
|
+
- `flush(): Promise<number>` finalizes trailing input and returns the total cue count.
|
|
850
|
+
- `reset(): Promise<void>` clears live parser, cue, cache, and presentation state for reuse.
|
|
771
851
|
- `dispose(): void` releases DOM, parser, and worker resources.
|
|
772
852
|
|
|
773
853
|
#### `VobSubRenderer`
|
|
774
854
|
|
|
775
|
-
- Supports
|
|
855
|
+
- Supports the common `PgsRenderer` methods above, except `append()`, `flush()`, and `reset()`.
|
|
776
856
|
- `setDebandEnabled(enabled: boolean): void` enables or disables debanding.
|
|
777
857
|
- `setDebandThreshold(threshold: number): void` updates the deband threshold.
|
|
778
858
|
- `setDebandRange(range: number): void` updates the deband sample range.
|
|
779
859
|
- `debandEnabled: boolean` reports whether debanding is enabled.
|
|
780
860
|
|
|
861
|
+
#### `DvbRenderer`
|
|
862
|
+
|
|
863
|
+
- Supports all `PgsRenderer` methods above, including the live push API (no debanding).
|
|
864
|
+
|
|
781
865
|
### Low-level parsers
|
|
782
866
|
|
|
783
867
|
#### `PgsParser`
|
|
@@ -795,6 +879,12 @@ Browser/device support matrix (including webOS TV): [docs/COMPATIBILITY.md](./do
|
|
|
795
879
|
- `clearCache(): void` clears parser-side caches.
|
|
796
880
|
- `dispose(): void` frees parser resources.
|
|
797
881
|
|
|
882
|
+
#### `DvbParser`
|
|
883
|
+
|
|
884
|
+
- Same progressive surface as `PgsParser` for `"DV"`-framed dumps and MPEG PES streams.
|
|
885
|
+
- `load(data: Uint8Array): number` / `feed` / `finishFeed` / `renderAtIndex` / `renderAtTimestamp` / `getMetadata` / `getCueMetadata` / `dispose`.
|
|
886
|
+
- `getEndTimestamps(): Float64Array` returns the page-timeout-aware cue end timestamps in milliseconds.
|
|
887
|
+
|
|
798
888
|
#### `VobSubParserLowLevel`
|
|
799
889
|
|
|
800
890
|
- `loadFromData(idxContent: string, subData: Uint8Array): void` loads IDX and SUB data (simple in-memory path).
|
|
@@ -810,8 +900,9 @@ Browser/device support matrix (including webOS TV): [docs/COMPATIBILITY.md](./do
|
|
|
810
900
|
- `loadPgs(data: Uint8Array): number` loads PGS data.
|
|
811
901
|
- `loadVobSub(idxContent: string, subData: Uint8Array): void` loads VobSub from IDX and SUB.
|
|
812
902
|
- `loadVobSubOnly(subData: Uint8Array): void` loads SUB-only VobSub data.
|
|
903
|
+
- `loadDvb(data: Uint8Array): number` loads DVB data.
|
|
813
904
|
- `loadAuto(source: AutoSubtitleSource): SubtitleFormatName` detects and loads a supported bitmap subtitle format.
|
|
814
|
-
- `format: 'pgs' | 'vobsub' | null` returns the active format.
|
|
905
|
+
- `format: 'pgs' | 'vobsub' | 'dvb' | null` returns the active format.
|
|
815
906
|
- `getTimestamps()`, `count`, `findIndexAtTimestamp()`, `renderAtIndex()`, `renderAtTimestamp()`, `getMetadata()`, `getCueMetadata()`, `clearCache()`, and `dispose()` are available as on the format-specific parsers.
|
|
816
907
|
|
|
817
908
|
### Core option and data types
|
|
@@ -821,6 +912,10 @@ Browser/device support matrix (including webOS TV): [docs/COMPATIBILITY.md](./do
|
|
|
821
912
|
```ts
|
|
822
913
|
interface VideoSubtitleOptions {
|
|
823
914
|
video: HTMLVideoElement
|
|
915
|
+
container?: HTMLElement | ShadowRoot
|
|
916
|
+
canvas?: HTMLCanvasElement
|
|
917
|
+
devicePixelRatioCap?: number
|
|
918
|
+
backend?: 'auto' | 'webgpu' | 'webgl2' | 'worker-offscreen' | 'canvas2d'
|
|
824
919
|
subUrl?: string
|
|
825
920
|
subContent?: ArrayBuffer
|
|
826
921
|
workerUrl?: string
|
|
@@ -829,6 +924,8 @@ interface VideoSubtitleOptions {
|
|
|
829
924
|
onError?: (error: Error) => void
|
|
830
925
|
onWebGPUFallback?: () => void
|
|
831
926
|
onWebGL2Fallback?: () => void
|
|
927
|
+
offscreenRender?: boolean // default true — Worker OffscreenCanvas on Canvas2D tier
|
|
928
|
+
frameAwareSync?: boolean // default true — sync to presented-frame mediaTime when available
|
|
832
929
|
displaySettings?: Partial<SubtitleDisplaySettings>
|
|
833
930
|
cacheLimit?: number
|
|
834
931
|
prefetchWindow?: {
|
|
@@ -883,7 +980,7 @@ type SubtitleRendererEvent =
|
|
|
883
980
|
| { type: 'loaded'; format: SubtitleFormatName; metadata: SubtitleParserMetadata }
|
|
884
981
|
| { type: 'error'; format: SubtitleFormatName; error: SubtitleDiagnosticErrorLike }
|
|
885
982
|
| { type: 'warning'; warning: SubtitleDiagnosticWarning }
|
|
886
|
-
| { type: 'renderer-change'; renderer: 'webgpu' | 'webgl2' | 'canvas2d' }
|
|
983
|
+
| { type: 'renderer-change'; renderer: 'webgpu' | 'webgl2' | 'worker-offscreen' | 'canvas2d' }
|
|
887
984
|
| { type: 'worker-state'; enabled: boolean; ready: boolean; sessionId: string | null; fallback?: boolean }
|
|
888
985
|
| { type: 'cache-change'; cachedFrames: number; pendingRenders: number; cacheLimit: number }
|
|
889
986
|
| { type: 'cue-change'; cue: SubtitleCueMetadata | null }
|
|
@@ -916,7 +1013,7 @@ Related diagnostics shapes:
|
|
|
916
1013
|
|
|
917
1014
|
```ts
|
|
918
1015
|
interface SubtitleParserMetadata {
|
|
919
|
-
format: 'pgs' | 'vobsub'
|
|
1016
|
+
format: 'pgs' | 'vobsub' | 'dvb'
|
|
920
1017
|
cueCount: number
|
|
921
1018
|
screenWidth: number
|
|
922
1019
|
screenHeight: number
|
package/dist/index.d.ts
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
-
export { PgsRenderer, VobSubRenderer, createAutoSubtitleRenderer, type VideoSubtitleOptions, type VideoVobSubOptions, type SubtitleRendererStats } from './wrapper';
|
|
7
|
-
export { PgsParser, VobSubParserLowLevel, UnifiedSubtitleParser, openSubtitles } from './wrapper';
|
|
8
|
-
export { initWasm, isWasmInitialized, isWebGPUSupported, isWorkerAvailable, isWorkerReady, warmup, ready, detectSubtitleFormat, fetchSubtitleAsset, fetchSubtitleText, probeRangeSupport, renderFrameData, toBlob, toCanvas, toImageBitmap, createSubtitleDiagnosticError, normalizeSubtitleError, SubtitleDiagnosticError, type AssetFetchOptions, type AssetFetchProgress, type AssetFetchStrategy, type AutoSubtitleSource, type AutoVideoSubtitleOptions, type OpenedSubtitles, type RangeProbeResult, type SubtitleAspectMode, type SubtitleCacheStats, type SubtitleCueBounds, type SubtitleCueMetadata, type SubtitleData, type SubtitleDiagnosticDetailValue, type SubtitleDiagnosticErrorCode, type SubtitleDiagnosticErrorLike, type SubtitleDiagnosticsOptions, type SubtitleDiagnosticWarning, type SubtitleDiagnosticWarningCode, type SubtitleCompositionData, type SubtitleDisplaySettings, type SubtitleFrameCanvasOptions, type SubtitleFrameCanvasTarget, type SubtitleFrameCropMode, type SubtitleFrameRenderOptions, type SubtitleRenderedFrameData, type SubtitleFormatName, type SubtitleHorizontalAlign, type SubtitleLastRenderInfo, type SubtitleParserMetadata, type SubtitleRendererBackend, type SubtitleRendererEvent, type SubtitleRendererStatsSnapshot } from './wrapper';
|
|
6
|
+
export { PgsRenderer, DvbRenderer, VobSubRenderer, createAutoSubtitleRenderer, type VideoSubtitleOptions, type VideoVobSubOptions, type SubtitleRendererStats } from './wrapper';
|
|
7
|
+
export { PgsParser, DvbParser, VobSubParserLowLevel, UnifiedSubtitleParser, openSubtitles } from './wrapper';
|
|
8
|
+
export { initWasm, isWasmInitialized, isWebGPUSupported, isWorkerAvailable, isWorkerReady, warmup, ready, getRuntimeCapabilities, canUseWorkerOffscreenRender, isOffscreenCanvasSupported, isOffscreenCanvas2DSupported, isTransferControlToOffscreenSupported, isCanvas2DSupported, detectSubtitleFormat, fetchSubtitleAsset, fetchSubtitleText, probeRangeSupport, renderFrameData, toBlob, toCanvas, toImageBitmap, createSubtitleDiagnosticError, normalizeSubtitleError, SubtitleDiagnosticError, type AssetFetchOptions, type AssetFetchProgress, type AssetFetchStrategy, type AutoSubtitleSource, type AutoVideoSubtitleOptions, type LiveSubtitleRenderer, type OpenedSubtitles, type RangeProbeResult, type RuntimeCapabilities, type SubtitleAspectMode, type SubtitleCacheStats, type SubtitleCueBounds, type SubtitleCueMetadata, type SubtitleData, type SubtitleDiagnosticDetailValue, type SubtitleDiagnosticErrorCode, type SubtitleDiagnosticErrorLike, type SubtitleDiagnosticsOptions, type SubtitleDiagnosticWarning, type SubtitleDiagnosticWarningCode, type SubtitleCompositionData, type SubtitleDisplaySettings, type SubtitleFrameCanvasOptions, type SubtitleFrameCanvasTarget, type SubtitleFrameCropMode, type SubtitleFrameRenderOptions, type SubtitleRenderedFrameData, type SubtitleFormatName, type SubtitleHorizontalAlign, type SubtitleLastRenderInfo, type SubtitleParserMetadata, type SubtitlePresentPath, type SubtitleRendererBackend, type SubtitleRendererEvent, type SubtitleRendererStatsSnapshot, type SubtitleStreamChunk, type SubtitleSynchronizationMode } from './wrapper';
|
|
9
9
|
export type { RenderResult, SubtitleFrame, VobSubFrame } from './wrapper';
|
|
10
10
|
export { PGSRenderer, VobsubRenderer, UnifiedSubtitleRenderer } from './wrapper';
|
|
11
11
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EACL,WAAW,EACX,cAAc,EACd,0BAA0B,EAC1B,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,EACvB,KAAK,qBAAqB,EAC3B,MAAM,WAAW,CAAA;AAGlB,OAAO,EAAE,SAAS,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,EACL,WAAW,EACX,WAAW,EACX,cAAc,EACd,0BAA0B,EAC1B,KAAK,oBAAoB,EACzB,KAAK,kBAAkB,EACvB,KAAK,qBAAqB,EAC3B,MAAM,WAAW,CAAA;AAGlB,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;AAG5G,OAAO,EACL,QAAQ,EACR,iBAAiB,EACjB,iBAAiB,EACjB,iBAAiB,EACjB,aAAa,EACb,MAAM,EACN,KAAK,EACL,sBAAsB,EACtB,2BAA2B,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|
*/
|
|
6
6
|
// High-level video-integrated renderers (compatible with old libpgs-js API)
|
|
7
|
-
export { PgsRenderer, VobSubRenderer, createAutoSubtitleRenderer } from './wrapper';
|
|
7
|
+
export { PgsRenderer, DvbRenderer, VobSubRenderer, createAutoSubtitleRenderer } from './wrapper';
|
|
8
8
|
// Low-level parsers for programmatic use
|
|
9
|
-
export { PgsParser, VobSubParserLowLevel, UnifiedSubtitleParser, openSubtitles } from './wrapper';
|
|
9
|
+
export { PgsParser, DvbParser, VobSubParserLowLevel, UnifiedSubtitleParser, openSubtitles } from './wrapper';
|
|
10
10
|
// Utility exports
|
|
11
|
-
export { initWasm, isWasmInitialized, isWebGPUSupported, isWorkerAvailable, isWorkerReady, warmup, ready, detectSubtitleFormat, fetchSubtitleAsset, fetchSubtitleText, probeRangeSupport, renderFrameData, toBlob, toCanvas, toImageBitmap, createSubtitleDiagnosticError, normalizeSubtitleError, SubtitleDiagnosticError } from './wrapper';
|
|
11
|
+
export { initWasm, isWasmInitialized, isWebGPUSupported, isWorkerAvailable, isWorkerReady, warmup, ready, getRuntimeCapabilities, canUseWorkerOffscreenRender, isOffscreenCanvasSupported, isOffscreenCanvas2DSupported, isTransferControlToOffscreenSupported, isCanvas2DSupported, detectSubtitleFormat, fetchSubtitleAsset, fetchSubtitleText, probeRangeSupport, renderFrameData, toBlob, toCanvas, toImageBitmap, createSubtitleDiagnosticError, normalizeSubtitleError, SubtitleDiagnosticError } from './wrapper';
|
|
12
12
|
// Legacy aliases
|
|
13
13
|
export { PGSRenderer, VobsubRenderer, UnifiedSubtitleRenderer } from './wrapper';
|
|
14
14
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,4EAA4E;AAC5E,OAAO,EACL,WAAW,EACX,cAAc,EACd,0BAA0B,EAI3B,MAAM,WAAW,CAAA;AAElB,yCAAyC;AACzC,OAAO,EAAE,SAAS,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,4EAA4E;AAC5E,OAAO,EACL,WAAW,EACX,WAAW,EACX,cAAc,EACd,0BAA0B,EAI3B,MAAM,WAAW,CAAA;AAElB,yCAAyC;AACzC,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;AAE5G,kBAAkB;AAClB,OAAO,EACL,QAAQ,EACR,iBAAiB,EACjB,iBAAiB,EACjB,iBAAiB,EACjB,aAAa,EACb,MAAM,EACN,KAAK,EACL,sBAAsB,EACtB,2BAA2B,EAC3B,0BAA0B,EAC1B,4BAA4B,EAC5B,qCAAqC,EACrC,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,iBAAiB,EACjB,iBAAiB,EACjB,eAAe,EACf,MAAM,EACN,QAAQ,EACR,aAAa,EACb,6BAA6B,EAC7B,sBAAsB,EACtB,uBAAuB,EAsCxB,MAAM,WAAW,CAAA;AAKlB,iBAAiB;AACjB,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,WAAW,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"react.d.ts","sourceRoot":"","sources":["../../src/integrations/react.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAA+B,KAAK,aAAa,EAAE,KAAK,YAAY,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAC1G,OAAO,EAA0C,KAAK,gBAAgB,EAAE,KAAK,mBAAmB,EAAE,MAAM,UAAU,CAAA;AAClH,OAAO,KAAK,EAAE,uBAAuB,EAAoD,MAAM,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a,CAAA;CACtB;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,kBAAkB,GAAG,YAAY,GAAG,IAAI,CAM5E;AAED,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAC1G,OAAO,EAAE,YAAY,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAC7D,YAAY,EAAE,uBAAuB,EAAE,CAAA"}
|
|
@@ -35,6 +35,10 @@ function sourceKey(source) {
|
|
|
35
35
|
hasIdxContent: Boolean(source.idxContent),
|
|
36
36
|
cacheLimit: source.cacheLimit ?? null,
|
|
37
37
|
timeOffset: source.timeOffset ?? null,
|
|
38
|
+
frameAwareSync: source.frameAwareSync ?? null,
|
|
39
|
+
backend: source.backend ?? null,
|
|
40
|
+
devicePixelRatioCap: source.devicePixelRatioCap ?? null,
|
|
41
|
+
offscreenRender: source.offscreenRender ?? null,
|
|
38
42
|
streamingLoad: source.streamingLoad ?? null,
|
|
39
43
|
rangeRequests: source.rangeRequests ?? null,
|
|
40
44
|
debug: source.debug ?? null,
|
|
@@ -63,6 +67,8 @@ export function useBitSub(videoRef, options) {
|
|
|
63
67
|
const enabled = options?.enabled !== false;
|
|
64
68
|
const key = sourceKey(options);
|
|
65
69
|
const displaySettings = options?.displaySettings;
|
|
70
|
+
const container = options?.container;
|
|
71
|
+
const canvas = options?.canvas;
|
|
66
72
|
useEffect(() => {
|
|
67
73
|
setError(null);
|
|
68
74
|
const video = videoRef.current;
|
|
@@ -104,7 +110,7 @@ export function useBitSub(videoRef, options) {
|
|
|
104
110
|
setController(null);
|
|
105
111
|
}
|
|
106
112
|
// key captures source identity; callback props stay fresh via refs
|
|
107
|
-
}, [videoRef, key, enabled]);
|
|
113
|
+
}, [videoRef, key, enabled, container, canvas]);
|
|
108
114
|
useEffect(() => {
|
|
109
115
|
if (displaySettings) {
|
|
110
116
|
controllerRef.current?.setDisplaySettings(displaySettings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E,GAAG,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,CAAC,CAAA;IAE/C,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,eAAe,EAAE,CAAC;YACpB,aAAa,CAAC,OAAO,EAAE,kBAAkB,CAAC,eAAe,CAAC,CAAA;QAC5D,CAAC;IACH,CAAC,EAAE,CAAC,eAAe,CAAC,CAAC,CAAA;IAErB,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,CAAA;AAC9B,CAAC;AASD;;;GAGG;AACH,MAAM,UAAU,aAAa,CAAC,KAAyB;IACrD,MAAM,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,GAAG,KAAK,CAAA;IACxD,SAAS,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAA;IAE5B,IAAI,CAAC,SAAS,IAAI,CAAC,KAAK;QAAE,OAAO,IAAI,CAAA;IACrC,OAAO,eAAM,SAAS,EAAE,SAAS,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,KAAK,EAAE,iBAAc,MAAM,GAAG,CAAA;AAChG,CAAC;AAGD,OAAO,EAAE,YAAY,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA"}
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
* Shared player-integration helpers for libbitsub.
|
|
3
3
|
* Optional adapters build on this surface so the core package stays dependency-free.
|
|
4
4
|
*/
|
|
5
|
-
import { type AutoVideoSubtitleOptions, type PgsRenderer, type SubtitleDisplaySettings, type SubtitleRendererStats, type VobSubRenderer } from '../wrapper';
|
|
5
|
+
import { type AutoVideoSubtitleOptions, type DvbRenderer, type PgsRenderer, type SubtitleDisplaySettings, type SubtitleRendererStats, type VobSubRenderer } from '../wrapper';
|
|
6
6
|
/** High-level renderer produced by integrations. */
|
|
7
|
-
export type BitSubRenderer = PgsRenderer | VobSubRenderer;
|
|
7
|
+
export type BitSubRenderer = PgsRenderer | VobSubRenderer | DvbRenderer;
|
|
8
8
|
/** Subtitle source + renderer options without a bound video element. */
|
|
9
9
|
export type BitSubSourceOptions = Omit<AutoVideoSubtitleOptions, 'video'>;
|
|
10
10
|
export interface BitSubController {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/integrations/shared.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAEL,KAAK,wBAAwB,EAC7B,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,cAAc,EACpB,MAAM,YAAY,CAAA;AAEnB,oDAAoD;AACpD,MAAM,MAAM,cAAc,GAAG,WAAW,GAAG,cAAc,CAAA;
|
|
1
|
+
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/integrations/shared.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAEL,KAAK,wBAAwB,EAC7B,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,cAAc,EACpB,MAAM,YAAY,CAAA;AAEnB,oDAAoD;AACpD,MAAM,MAAM,cAAc,GAAG,WAAW,GAAG,cAAc,GAAG,WAAW,CAAA;AAEvE,wEAAwE;AACxE,MAAM,MAAM,mBAAmB,GAAG,IAAI,CAAC,wBAAwB,EAAE,OAAO,CAAC,CAAA;AAEzE,MAAM,WAAW,gBAAgB;IAC/B,wDAAwD;IACxD,QAAQ,CAAC,QAAQ,EAAE,cAAc,GAAG,IAAI,CAAA;IACxC,qCAAqC;IACrC,QAAQ,CAAC,KAAK,EAAE,gBAAgB,GAAG,IAAI,CAAA;IACvC,iDAAiD;IACjD,IAAI,CAAC,MAAM,EAAE,mBAAmB,GAAG,cAAc,CAAA;IACjD,gEAAgE;IAChE,KAAK,IAAI,IAAI,CAAA;IACb,yDAAyD;IACzD,OAAO,IAAI,IAAI,CAAA;IACf,uDAAuD;IACvD,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAA;IAC1B,kBAAkB,IAAI,uBAAuB,GAAG,IAAI,CAAA;IACpD,kBAAkB,CAAC,QAAQ,EAAE,OAAO,CAAC,uBAAuB,CAAC,GAAG,IAAI,CAAA;IACpE,oBAAoB,IAAI,IAAI,CAAA;IAC5B,QAAQ,IAAI,qBAAqB,GAAG,IAAI,CAAA;IACxC,6EAA6E;IAC7E,QAAQ,CAAC,KAAK,EAAE,gBAAgB,GAAG,IAAI,GAAG,IAAI,CAAA;CAC/C;AAED,MAAM,WAAW,mBAAoB,SAAQ,mBAAmB;IAC9D,yFAAyF;IACzF,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAcD;;;GAGG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,gBAAgB,EAAE,OAAO,GAAE,mBAAwB,GAAG,gBAAgB,CAmGzG;AAED,gEAAgE;AAChE,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,gBAAgB,EAAE,MAAM,EAAE,mBAAmB,GAAG,cAAc,CAKzG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../src/integrations/shared.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACL,0BAA0B,
|
|
1
|
+
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../src/integrations/shared.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACL,0BAA0B,EAO3B,MAAM,YAAY,CAAA;AAkCnB,SAAS,iBAAiB,CAAC,MAAuC;IAChE,IAAI,CAAC,MAAM;QAAE,OAAO,KAAK,CAAA;IACzB,OAAO,OAAO,CAAC,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,UAAU,IAAI,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,UAAU,IAAI,MAAM,CAAC,QAAQ,CAAC,CAAA;AAC7G,CAAC;AAED,SAAS,WAAW,CAAC,KAA0C;IAC7D,IAAI,CAAC,KAAK,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,cAAc,CAAA;gBAC3B,QAAQ,GAAG,0BAA0B,CAAC;oBACpC,GAAG,cAAc;oBACjB,KAAK,EAAE,SAAS;iBACjB,CAAC,CAAA;YACJ,CAAC;QACH,CAAC;KACF,CAAA;IAED,IAAI,QAAQ,IAAI,UAAU,EAAE,CAAC;QAC3B,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,CAAA;IAC7B,CAAC;IAED,OAAO,UAAU,CAAA;AACnB,CAAC;AAED,gEAAgE;AAChE,MAAM,UAAU,oBAAoB,CAAC,KAAuB,EAAE,MAA2B;IACvF,OAAO,0BAA0B,CAAC;QAChC,GAAG,MAAM;QACT,KAAK,EAAE,WAAW,CAAC,KAAK,CAAC;KAC1B,CAAC,CAAA;AACJ,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { RuntimeCapabilities } from './types';
|
|
2
|
+
export declare function isOffscreenCanvasSupported(): boolean;
|
|
3
|
+
export declare function isTransferControlToOffscreenSupported(): boolean;
|
|
4
|
+
export declare function isOffscreenCanvas2DSupported(): boolean;
|
|
5
|
+
export declare function isCanvas2DSupported(offscreenCanvas2d?: boolean): boolean;
|
|
6
|
+
export declare function canUseWorkerOffscreenRender(): boolean;
|
|
7
|
+
export declare function getRuntimeCapabilities(): RuntimeCapabilities;
|
|
8
|
+
//# sourceMappingURL=capabilities.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"capabilities.d.ts","sourceRoot":"","sources":["../../src/ts/capabilities.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAuB,MAAM,SAAS,CAAA;AAEvE,wBAAgB,0BAA0B,IAAI,OAAO,CAEpD;AAED,wBAAgB,qCAAqC,IAAI,OAAO,CAU/D;AAED,wBAAgB,4BAA4B,IAAI,OAAO,CAWtD;AAED,wBAAgB,mBAAmB,CAAC,iBAAiB,GAAE,OAAwC,GAAG,OAAO,CASxG;AAED,wBAAgB,2BAA2B,IAAI,OAAO,CAOrD;AAuDD,wBAAgB,sBAAsB,IAAI,mBAAmB,CAyB5D"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { isWorkerAvailable } from './worker';
|
|
2
|
+
import { isWebGPUSupported } from './webgpu-renderer';
|
|
3
|
+
import { isWebGL2Supported } from './webgl2-renderer';
|
|
4
|
+
export function isOffscreenCanvasSupported() {
|
|
5
|
+
return typeof OffscreenCanvas !== 'undefined';
|
|
6
|
+
}
|
|
7
|
+
export function isTransferControlToOffscreenSupported() {
|
|
8
|
+
return (typeof HTMLCanvasElement !== 'undefined' &&
|
|
9
|
+
typeof HTMLCanvasElement.prototype === 'object' &&
|
|
10
|
+
typeof HTMLCanvasElement.prototype.transferControlToOffscreen === 'function');
|
|
11
|
+
}
|
|
12
|
+
export function isOffscreenCanvas2DSupported() {
|
|
13
|
+
if (typeof OffscreenCanvas !== 'undefined') {
|
|
14
|
+
try {
|
|
15
|
+
const canvas = new OffscreenCanvas(1, 1);
|
|
16
|
+
return !!canvas.getContext('2d');
|
|
17
|
+
}
|
|
18
|
+
catch {
|
|
19
|
+
return false;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
export function isCanvas2DSupported(offscreenCanvas2d = isOffscreenCanvas2DSupported()) {
|
|
25
|
+
if (offscreenCanvas2d)
|
|
26
|
+
return true;
|
|
27
|
+
if (typeof document === 'undefined')
|
|
28
|
+
return false;
|
|
29
|
+
try {
|
|
30
|
+
return !!document.createElement('canvas').getContext('2d');
|
|
31
|
+
}
|
|
32
|
+
catch {
|
|
33
|
+
return false;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
export function canUseWorkerOffscreenRender() {
|
|
37
|
+
return (isWorkerAvailable() &&
|
|
38
|
+
isOffscreenCanvasSupported() &&
|
|
39
|
+
isTransferControlToOffscreenSupported() &&
|
|
40
|
+
isOffscreenCanvas2DSupported());
|
|
41
|
+
}
|
|
42
|
+
function resolvePreferredPresentPath(capabilities) {
|
|
43
|
+
const reasons = [];
|
|
44
|
+
if (capabilities.webgpu) {
|
|
45
|
+
return { preferredPresentPath: 'main-webgpu', reasons };
|
|
46
|
+
}
|
|
47
|
+
reasons.push('WebGPU unavailable.');
|
|
48
|
+
if (capabilities.webgl2) {
|
|
49
|
+
return { preferredPresentPath: 'main-webgl2', reasons };
|
|
50
|
+
}
|
|
51
|
+
reasons.push('WebGL2 unavailable.');
|
|
52
|
+
if (capabilities.workerOffscreenRender) {
|
|
53
|
+
return { preferredPresentPath: 'worker-offscreen', reasons };
|
|
54
|
+
}
|
|
55
|
+
if (!capabilities.worker) {
|
|
56
|
+
reasons.push('Worker unavailable; parse/decode stays on the main thread when possible.');
|
|
57
|
+
}
|
|
58
|
+
if (!capabilities.offscreenCanvas) {
|
|
59
|
+
reasons.push('OffscreenCanvas unavailable.');
|
|
60
|
+
}
|
|
61
|
+
if (!capabilities.transferControlToOffscreen) {
|
|
62
|
+
reasons.push('transferControlToOffscreen unavailable; cannot move canvas present into a Worker.');
|
|
63
|
+
}
|
|
64
|
+
if (capabilities.worker &&
|
|
65
|
+
capabilities.offscreenCanvas &&
|
|
66
|
+
capabilities.transferControlToOffscreen &&
|
|
67
|
+
!capabilities.offscreenCanvas2d) {
|
|
68
|
+
reasons.push('OffscreenCanvas 2D context unavailable; Worker presentation requires Canvas2D in the Worker.');
|
|
69
|
+
}
|
|
70
|
+
reasons.push('Worker OffscreenCanvas present path unavailable; composition uses the transfer or main-thread Canvas2D path.');
|
|
71
|
+
if (capabilities.canvas2d) {
|
|
72
|
+
return { preferredPresentPath: 'main-canvas2d', reasons };
|
|
73
|
+
}
|
|
74
|
+
reasons.push('Canvas2D unavailable.');
|
|
75
|
+
if (!capabilities.createImageBitmap) {
|
|
76
|
+
reasons.push('createImageBitmap unavailable (export helpers may be limited).');
|
|
77
|
+
}
|
|
78
|
+
reasons.push('No canvas present backend detected.');
|
|
79
|
+
return { preferredPresentPath: 'main-thread', reasons };
|
|
80
|
+
}
|
|
81
|
+
export function getRuntimeCapabilities() {
|
|
82
|
+
const worker = isWorkerAvailable();
|
|
83
|
+
const offscreenCanvas = isOffscreenCanvasSupported();
|
|
84
|
+
const transferControlToOffscreen = isTransferControlToOffscreenSupported();
|
|
85
|
+
const offscreenCanvas2d = isOffscreenCanvas2DSupported();
|
|
86
|
+
const webgpu = isWebGPUSupported();
|
|
87
|
+
const webgl2 = isWebGL2Supported();
|
|
88
|
+
const canvas2d = isCanvas2DSupported(offscreenCanvas2d);
|
|
89
|
+
const createImageBitmap = typeof globalThis.createImageBitmap === 'function';
|
|
90
|
+
const workerOffscreenRender = worker && offscreenCanvas && transferControlToOffscreen && offscreenCanvas2d;
|
|
91
|
+
const base = {
|
|
92
|
+
worker,
|
|
93
|
+
offscreenCanvas,
|
|
94
|
+
transferControlToOffscreen,
|
|
95
|
+
offscreenCanvas2d,
|
|
96
|
+
workerOffscreenRender,
|
|
97
|
+
webgpu,
|
|
98
|
+
webgl2,
|
|
99
|
+
canvas2d,
|
|
100
|
+
createImageBitmap
|
|
101
|
+
};
|
|
102
|
+
const { preferredPresentPath, reasons } = resolvePreferredPresentPath(base);
|
|
103
|
+
return { ...base, preferredPresentPath, reasons };
|
|
104
|
+
}
|
|
105
|
+
//# sourceMappingURL=capabilities.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"capabilities.js","sourceRoot":"","sources":["../../src/ts/capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAA;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AACrD,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAGrD,MAAM,UAAU,0BAA0B;IACxC,OAAO,OAAO,eAAe,KAAK,WAAW,CAAA;AAC/C,CAAC;AAED,MAAM,UAAU,qCAAqC;IACnD,OAAO,CACL,OAAO,iBAAiB,KAAK,WAAW;QACxC,OAA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C;AAED,MAAM,UAAU,sBAAsB;IACpC,MAAM,MAAM,GAAG,iBAAiB,EAAE,CAAA;IAClC,MAAM,eAAe,GAAG,0BAA0B,EAAE,CAAA;IACpD,MAAM,0BAA0B,GAAG,qCAAqC,EAAE,CAAA;IAC1E,MAAM,iBAAiB,GAAG,4BAA4B,EAAE,CAAA;IACxD,MAAM,MAAM,GAAG,iBAAiB,EAAE,CAAA;IAClC,MAAM,MAAM,GAAG,iBAAiB,EAAE,CAAA;IAClC,MAAM,QAAQ,GAAG,mBAAmB,CAAC,iBAAiB,CAAC,CAAA;IACvD,MAAM,iBAAiB,GAAG,OAAO,UAAU,CAAC,iBAAiB,KAAK,UAAU,CAAA;IAC5E,MAAM,qBAAqB,GAAG,MAAM,IAAI,eAAe,IAAI,0BAA0B,IAAI,iBAAiB,CAAA;IAE1G,MAAM,IAAI,GAAG;QACX,MAAM;QACN,eAAe;QACf,0BAA0B;QAC1B,iBAAiB;QACjB,qBAAqB;QACrB,MAAM;QACN,MAAM;QACN,QAAQ;QACR,iBAAiB;KAClB,CAAA;IAED,MAAM,EAAE,oBAAoB,EAAE,OAAO,EAAE,GAAG,2BAA2B,CAAC,IAAI,CAAC,CAAA;IAC3E,OAAO,EAAE,GAAG,IAAI,EAAE,oBAAoB,EAAE,OAAO,EAAE,CAAA;AACnD,CAAC"}
|
package/dist/ts/parsers.d.ts
CHANGED
|
@@ -66,6 +66,39 @@ export declare class PgsParser {
|
|
|
66
66
|
dispose(): void;
|
|
67
67
|
private emitWarning;
|
|
68
68
|
}
|
|
69
|
+
/**
|
|
70
|
+
* Low-level DVB subtitle parser using WASM.
|
|
71
|
+
* Use this for programmatic access to DVB data without video integration.
|
|
72
|
+
*/
|
|
73
|
+
export declare class DvbParser {
|
|
74
|
+
private parser;
|
|
75
|
+
private timestamps;
|
|
76
|
+
private endTimestamps;
|
|
77
|
+
private cueMetadataCache;
|
|
78
|
+
private readonly debug;
|
|
79
|
+
private readonly onWarning?;
|
|
80
|
+
constructor(options?: SubtitleDiagnosticsOptions);
|
|
81
|
+
load(data: Uint8Array): number;
|
|
82
|
+
reset(): void;
|
|
83
|
+
feed(data: Uint8Array): number;
|
|
84
|
+
finishFeed(): number;
|
|
85
|
+
get pendingLen(): number;
|
|
86
|
+
getTimestamps(): Float64Array;
|
|
87
|
+
getEndTimestamps(): Float64Array;
|
|
88
|
+
get count(): number;
|
|
89
|
+
findIndexAtTimestamp(timeSeconds: number): number;
|
|
90
|
+
renderAtIndex(index: number): SubtitleData | undefined;
|
|
91
|
+
getLastRenderIssue(): string | null;
|
|
92
|
+
getMetadata(): SubtitleParserMetadata;
|
|
93
|
+
getCueMetadata(index: number): SubtitleCueMetadata | null;
|
|
94
|
+
renderAtTimestamp(timeSeconds: number): SubtitleData | undefined;
|
|
95
|
+
renderFrameDataAtIndex(index: number, options?: SubtitleFrameRenderOptions): SubtitleRenderedFrameData | undefined;
|
|
96
|
+
renderFrameDataAtTimestamp(timeSeconds: number, options?: SubtitleFrameRenderOptions): SubtitleRenderedFrameData | undefined;
|
|
97
|
+
private convertFrame;
|
|
98
|
+
clearCache(): void;
|
|
99
|
+
dispose(): void;
|
|
100
|
+
private emitWarning;
|
|
101
|
+
}
|
|
69
102
|
/**
|
|
70
103
|
* Low-level VobSub subtitle parser using WASM.
|
|
71
104
|
* Use this for programmatic access to VobSub data without video integration.
|
|
@@ -153,7 +186,7 @@ export declare class VobSubParserLowLevel {
|
|
|
153
186
|
private emitWarning;
|
|
154
187
|
}
|
|
155
188
|
/**
|
|
156
|
-
* Unified subtitle parser that handles
|
|
189
|
+
* Unified subtitle parser that handles PGS, VobSub, and DVB formats.
|
|
157
190
|
*/
|
|
158
191
|
export declare class UnifiedSubtitleParser {
|
|
159
192
|
private renderer;
|
|
@@ -166,6 +199,10 @@ export declare class UnifiedSubtitleParser {
|
|
|
166
199
|
* Load PGS subtitle data.
|
|
167
200
|
*/
|
|
168
201
|
loadPgs(data: Uint8Array): number;
|
|
202
|
+
/**
|
|
203
|
+
* Load DVB subtitle data (`"DV"` framed and/or MPEG PES).
|
|
204
|
+
*/
|
|
205
|
+
loadDvb(data: Uint8Array): number;
|
|
169
206
|
/**
|
|
170
207
|
* Load VobSub from IDX and SUB data.
|
|
171
208
|
*/
|
|
@@ -183,7 +220,7 @@ export declare class UnifiedSubtitleParser {
|
|
|
183
220
|
/**
|
|
184
221
|
* Get the current subtitle format.
|
|
185
222
|
*/
|
|
186
|
-
get format():
|
|
223
|
+
get format(): SubtitleFormatName | null;
|
|
187
224
|
/**
|
|
188
225
|
* Get all timestamps in milliseconds.
|
|
189
226
|
*/
|
package/dist/ts/parsers.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parsers.d.ts","sourceRoot":"","sources":["../../src/ts/parsers.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EACV,kBAAkB,EAClB,eAAe,EACf,0BAA0B,EAC1B,YAAY,EAEZ,mBAAmB,EAEnB,0BAA0B,EAC1B,yBAAyB,EACzB,sBAAsB,EAEtB,kBAAkB,
|
|
1
|
+
{"version":3,"file":"parsers.d.ts","sourceRoot":"","sources":["../../src/ts/parsers.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EACV,kBAAkB,EAClB,eAAe,EACf,0BAA0B,EAC1B,YAAY,EAEZ,mBAAmB,EAEnB,0BAA0B,EAC1B,yBAAyB,EACzB,sBAAsB,EAEtB,kBAAkB,EAOnB,MAAM,SAAS,CAAA;AA0ChB;;;GAGG;AACH,qBAAa,SAAS;IACpB,OAAO,CAAC,MAAM,CAAqC;IACnD,OAAO,CAAC,UAAU,CAAoC;IACtD,OAAO,CAAC,gBAAgB,CAAgD;IACxE,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAC,CAA8C;IAEzE,YAAY,OAAO,GAAE,0BAA+B,EAKnD;IAED,IAAI,CAAC,IAAI,EAAE,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