Commit Graph
37 Commits
Author SHA1 Message Date
Vanilagy 6d9a65a2aa Address transcode forced by trimming in docs (closes #464) 2026-08-17 11:25:52 +02:00
Vanilagy ae66f01566 Clarify Conversion API codec field default 2026-08-14 11:54:43 +02:00
c3df2a24e5 Add custom quality factors and quantizer bitrate mode (#448)
* Add custom quality factors and quantizer bitrate mode (closes #327)

* Fix quantizer mode fallback and per-frame quantizer edge cases

* Clean up quantizer mode tests

* Quantizer implementation

* Add quality tests

* Improve conversion codec error message, make test more lenient

* Add quantizer support blog post

---------

Co-authored-by: Vanilagy <[email protected]>
2026-07-30 17:24:59 +02:00
Vanilagy ae5a5838d6 Add ability to pause conversions or step them deliberately 2026-07-22 15:30:37 +02:00
f41eef0937 Add composable conversions
* Add non-owning conversions via ConversionOptions.ownsOutput

A conversion with ownsOutput: false only adds tracks to the output and
drives their media data; starting, finalizing, and metadata tags remain
the caller's responsibility. This lets multiple conversions and
directly-added user tracks compose on a single Output (see upstream
issue #436).

- ownsOutput: false allows a pre-populated output (state must still be
  'pending') and seeds track-capacity accounting from existing tracks
- execute() requires the output to be started and never finalizes it
- cancel() closes only the conversion's own sources, releasing internal
  synchronizer waiters, and leaves the output usable
- tags cannot be combined with ownsOutput: false
- isValid requires at least one contributed track instead of the
  format's minimum track counts

Prototype for API discussion; default (owning) behavior is unchanged.

Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01AJdfnbY9AFh9i9dKgtrj6E

* Add external-audio example using a non-owning conversion

Demonstrates composing a user-owned audio track (synthesized voiceover
via OfflineAudioContext + AudioBufferSource) onto a picked video with
Conversion.init({ ownsOutput: false }), including progress reporting
and playback/download of the result.

Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01AJdfnbY9AFh9i9dKgtrj6E

* Release synchronizer waiters when canceling during output finalization

A non-owning conversion's cancel() previously no-oped entirely when the
output (owned by someone else) was already finalizing or finalized,
leaving pump loops parked in the track synchronizer and hanging
execute() forever. Now it still marks the conversion canceled and
releases parked waiters in that state, without force-closing sources
(finalization owns flushing them at that point).

Also adds coverage: non-owning onProgress monotonicity, canceling one
of two sibling conversions, capacity seeding across sequential inits,
exact metadata exclusivity, and cancel-before-execute.

Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01AJdfnbY9AFh9i9dKgtrj6E

* Document non-owning conversions on the converting-media-files guide page

Adds the doc section requested in #436: what ownsOutput: false does, the
required choreography (add tracks -> output.start() before execute() ->
run the conversion concurrently with your own sources -> finalize), the
cancellation split (conversion.cancel() leaves the output alive; cancel
both for a full abort and tear the output down on error paths), isValid
semantics in this mode, and the tags restriction with the
setMetadataTags() alternative. Also cross-links the fresh-output rule to
the new section. VitePress build passes with dead-link checking on.

Co-Authored-By: Claude Opus 4.8 <[email protected]>

* Clean up conversion logic, add Output.tracks and .hasEnoughTracks(), move new conversion tests around, remove external audio example

* non-owning -> composable, and update docs

* Update

---------

Co-authored-by: Claude <[email protected]>
Co-authored-by: Vanilagy <[email protected]>
2026-07-22 08:42:19 +00:00
Vanilagy 1680bd02ad Holistic technical website cleanup 2026-05-03 19:47:39 +02:00
Vanilagy f3dec587fd Make FLAC encoder bit depth depend on input sample format, add sampleFormat audio transformation option, fix incorrect bitrate validation for FLAC (closes #357) 2026-04-29 16:27:20 +02:00
Vanilagy 0f6c374750 Ensure extensions work with huge timestamps, fix AC3 and AAC extension's behavior with huge timestamps 2026-04-27 20:58:05 +02:00
Vanilagy b85ecd3109 Code review fixes 2026-04-16 17:43:12 +02:00
Vanilagy 7080b79a2a Update docs a bunch, fix some typos 2026-04-15 14:36:53 +02:00
Vanilagy 051578c2ca Remove input track descriptors, add async getters on tracks for everything, deprecate old sync getters 2026-04-10 16:23:17 +02:00
Vanilagy b06e407d65 Add HLS live mode 2026-03-31 14:13:00 +02:00
Vanilagy 4fae45ec40 Allow negative trim ranges for conversion, add OutputFormat.supportsTimestampedMediaData 2026-02-11 15:56:51 +01:00
Vanilagy e20f779ede Add InputTrack.number 2026-01-22 09:18:43 +01:00
Vanilagy 277290abe3 Fix tests and elaborate on point in docs 2026-01-19 14:11:02 +01:00
Vanilagy 24af125415 Make Conversion.cancel() cause execute() to throw (closes #271) 2026-01-12 15:13:00 +01:00
4dd747a0a6 Conversion.init(hardwareAcceleration) option (#254)
* Support Conversion.init(hardwareAcceleration) option passed down to the VideoEncodingConfig.

fix #253

* Few changes

---------

Co-authored-by: Raphaël Droz <[email protected]>
Co-authored-by: Vanilagy <[email protected]>
2025-12-17 10:28:29 +00:00
Vanilagy cc649ba192 Add allowRotationMetadata video conversion option (see #247) 2025-12-11 14:41:00 +01:00
Vanilagy e880f54553 Add custom processing to Conversion API 2025-10-17 14:52:13 +02:00
Vanilagy 7accface7b A few cleanups 2025-10-01 22:23:05 +02:00
AJ Funk dcd1f242b4 add keyFrameInterval to ConversionVideoOptions 2025-10-01 09:28:06 -07:00
Vanilagy be151d3494 Add isValid field to Conversion if output track counts haven't been reached, improve error messages to be more clear (closes #148) 2025-09-26 13:11:35 +02:00
Vanilagy 1b8e4f9f4b Add alpha option to Conversion API 2025-09-26 11:12:48 +02:00
Vanilagy fcec67645a Allow object for tags field in conversion 2025-09-16 15:10:16 +02:00
Vanilagy d313a85053 Document cropping in more places 2025-09-12 17:30:31 +02:00
Vanilagy c9433771e9 Fix description in docs 2025-09-12 16:49:46 +02:00
Vanilagy eba1f360d5 Clean up cropping logic 2025-09-12 16:48:35 +02:00
Vanilagy 4aca172d14 Merge branch 'main' into fork-branch 2025-09-12 15:46:12 +02:00
Vanilagy dcd99f8930 Add metadata tag support to Conversion API 2025-09-05 23:34:24 +02:00
Pablo Cúbico 904fd8f95e feat: add video crop option 2025-09-05 07:07:43 -03:00
Vanilagy 5ca5fc4633 Document onwrite in conversion docs 2025-09-02 17:48:33 +02:00
Vanilagy 63b8190185 Add logic for encoding video frames that change size over time (#63) 2025-08-24 16:37:03 +02:00
Vanilagy 11c15c2392 Add track-specific conversion options, fix esbuild race condition 2025-08-11 00:00:04 +02:00
Vanilagy 1fe115ac83 Implement frame rate adjustment logic for Conversion API, fix source not being closed 2025-08-08 18:39:08 +02:00
Vanilagy 99f813c938 Mediakit -> Mediabunny 2025-06-16 15:46:44 +02:00
Vanilagy fa3f4b0052 Document conversion API 2025-06-08 22:42:23 +02:00
Vanilagy e37af1bdad Create conversion doc page, small fixes 2025-06-08 20:40:01 +02:00