Commit Graph
42 Commits
Author SHA1 Message Date
wiiiii123 62323ee3ee revert: undo PRs 625 and 626 2026-05-30 01:20:36 +07:00
wiiiii123 80a513b7c4 fix: preserve mac audio sidecar tracks 2026-05-29 23:30:39 +07:00
Alan Trebugeais 2f1d3f38cd audio encoder code rabbits 2026-05-10 21:20:32 +02:00
Alan Trebugeais 4c1a63178a fix: audio pitch 2026-05-10 20:48:13 +02:00
Alan Trebugeais d25aaa0901 audio encoder fix 2026-05-09 21:10:16 +02:00
Alan Trebugeais 28a8a2217a add normalized gain variable 2026-05-09 20:45:14 +02:00
Alan Trebugeais 0c4771ae67 fix: videoexports with audio (system/mic/mixed/user)... everything should work 2026-05-09 20:18:22 +02:00
Alan Trebugeais 5e5dd7166e fix audio exporting with microphone and system sound etc 2026-05-09 19:43:54 +02:00
Alan Trebugeais 4d5a7ceb6d fix all audios issues it seems finally. with WebAudio API instead of html audio. 2026-05-09 19:14:28 +02:00
Alan Trebugeais d4fe5d72a1 audio encoding works with exporting. 2026-05-09 18:51:44 +02:00
webadderall 25cd1f2f75 Speed up Lightning export and relax local media reads 2026-05-08 11:32:04 +10:00
webadderall 62f2a52860 Fix companion audio sync for trimmed and long exports 2026-04-24 12:04:21 +10:00
webadderall 05a6d3f1b6 Fix embedded audio fallback handling and audio diagnostics (#309)
* Fix embedded audio fallback handling and audio diagnostics

* Add recording fallback diagnostics toasts

* Fix Windows audio fallback cleanup and path matching

* Format rebased recording fallback changes

* Fix embedded audio preview and export fallback handling
2026-04-24 11:30:10 +10:00
webadderall 681bc70c13 fix: clear video src on timeout path in getMediaDurationSec 2026-04-18 22:04:40 +10:00
webadderall a0668696bc fix: address CodeRabbit review — fallback, i18n, return type cleanup
- Change ?? 99 fallback to ?? 100 in finalizing progress label
- Add editor.export.processingAudioEdits i18n key to all 5 locales
- Tighten sourceTimeToOutputTime return type to number (was number|null)
- Remove now-unused totalOutputDurationMs param from scheduleRegionForChunk
- Remove ?? fallbacks at call sites (function always returns a number)
2026-04-18 21:38:05 +10:00
webadderall ebe2bc5c16 fix: audio regions on silent video, interleaved >2ch stride, coderabbit config
- Fall back to video container duration when mainBuffer is null but
  audioRegions are present (prevents empty output)
- Use data.numberOfChannels as deinterleave stride instead of capped
  dataChannels (fixes garbled audio for 5.1+ sources)
- Fix .coderabbit.yaml: '*' is not valid regex, use '.*'
2026-04-18 20:45:46 +10:00
webadderall 028fd91ffd fix: address CodeRabbit review — muxing error guard, dead code removal, i18n
- Add encoderError check after awaiting pendingMuxing to prevent
  finalization of corrupt exports (both exporters)
- Remove unreachable synchronous fast-path in getMediaDurationSec
- Set preload='metadata' before src for correct browser behavior
- Localize audio processing status text with t()
2026-04-18 20:43:48 +10:00
webadderall cbe0b9feac fix: replace real-time audio export with streaming decode + chunked offline rendering
Major rewrite of the audio export pipeline for stability and memory efficiency:

## Streaming Decode
- Primary decode path uses WebDemuxer + AudioDecoder (WebCodecs streaming)
- Falls back to bulk decodeAudioData if streaming fails
- Avoids holding full compressed file + decoded PCM simultaneously

## Chunked Offline Rendering
- Processes timeline in 30-second OfflineAudioContext chunks
- Memory bounded to ~30s of PCM per chunk regardless of recording length

## Chunked WAV Writing
- Writes PCM in ~256KB chunks instead of single massive ArrayBuffer
- Eliminates OOM for long recordings on the native/FFmpeg export path

## Chunked Encoding
- Single AudioEncoder kept alive across all chunks (clean AAC stream)
- Proper backpressure and error propagation per chunk

## scheduleBufferThroughTimeline chunk windowing
- Clips source nodes to chunk boundaries for correct cross-chunk audio
- Backwards compatible defaults when no chunk params provided

## Other export fixes
- Progress cap: 99% -> 100% in both exporters and UI
- Muxing errors: propagated instead of silently swallowed
- Mac recording: enhanced warning when no audio files for muxing
- Export timeout: eliminated by removing real-time rendering
2026-04-18 20:29:14 +10:00
webadderall 8f3a62d811 fix: check both realpath and resolve forms in media URL handler, extract sync constants
- IPC get-local-media-url now checks both fs.realpath and path.resolve forms
  against approvedLocalReadPaths, so symlinks approved via approveUserPath work
- Extract duplicated sync correction parameters into shared constants in
  audioEncoder.ts (SYNC_SEEK_THRESHOLD_SEC, SYNC_PLAYBACK_RATE_OPTIONS)
2026-04-18 19:11:01 +10:00
webadderall f024c89890 fix: always apply aresample sync filter and tighten audio sync tolerances
- Always route audio through aresample=async=1:first_pts=0 filter during
  muxing on both macOS and Windows, even when duration delta is small.
  Previously skipped when delta ≤50ms, which left progressive clock drift
  (from CPU load) completely uncorrected.
- Lower sync detection threshold from 50ms to 20ms so tempo correction
  kicks in earlier.
- Use explicit 48kHz AudioContext sample rate in both browser recording
  and export rendering to prevent sample rate mismatch drift.
- Reduce MediaRecorder timeslice from 1000ms to 250ms to reduce chunk
  loss under CPU pressure.
- Tighten export audio sync: seek threshold 300ms→150ms, tolerance
  15ms→8ms, correction window 2s→0.5s, max adjustment ±8%→±12%.
- Lower companion audio start delay threshold from 50ms to 25ms.
2026-04-18 19:03:36 +10:00
webadderall aa27e7cbd1 fix: address remaining export pipeline review feedback 2026-04-17 00:17:54 +10:00
webadderall f81a740614 fix: address export pipeline review feedback 2026-04-16 18:49:01 +10:00
webadderall 8abceaa914 feat: add H.264 stream-copy export, overhaul exporter pipeline, rename native binaries
- IPC: new inputMode 'h264-stream' — browser VideoEncoder output stream-copied
  into MP4 via ffmpeg rather than piping raw RGBA frames, cuts memory usage
- Security: replace flat approvedLocalReadPaths with userApprovedPaths fed from
  dialog pickers and project load; isAllowedLocalReadPath uses it alongside
  dir prefix / existsSync checks
- nativeVideoExport: add buildNativeH264StreamExportArgs for stream-copy path
- frameRenderer / modernFrameRenderer: cursor-follow camera integration,
  annotation blur post-processing, shadow profile, squircle geometry
- audioEncoder / streamingDecoder / gifExporter / muxer: full pipeline
  hardening — drift correction, backpressure, proper teardown
- Rename native helpers openscreen-* → recordly-* on darwin-arm64 and
  darwin-x64; update helpers-manifest.json for win32-x64
- electron/main, windows, updater, rendererServer: startup and window
  lifecycle improvements
- preload: expose inputMode and new IPC surface to renderer
2026-04-16 17:51:41 +10:00
Wing900 654ed79ba8 Fix silent MP4 exports with FFmpeg audio fallback 2026-04-12 20:55:34 +08:00
webadderall 5fc78fd90b feat(export): add extension render hooks to export pipeline
- Integrate extension render hooks into frameRenderer and modernFrameRenderer
- Add modernFrameRenderer for compositing extensions during export
- Wire extension audio processing in audioEncoder
- Support extension hooks in gif and video export paths
2026-04-12 01:38:36 +10:00
webadderall c85fb7a05a feat: show real-time audio rendering progress during export finalization
Instead of freezing at 'Finalizing 99%' while audio renders in real-time,
the export UI now shows 'Rendering audio XX%' with a live progress bar and
an explanatory note about why real-time playback is required.

Progress is reported every 250ms from the RAF tick loop in AudioProcessor
and piped through VideoExporter to the UI via the existing onProgress callback.
2026-04-09 18:25:25 +10:00
webadderall e670956e42 fix(export): audio encoder reliability and gif exporter compat 2026-04-08 22:00:23 +10:00
webadderall 5fd49fbf0f fix(audio): reduce recording and export drift 2026-04-04 21:53:25 +11:00
webadderall c29673b9fc add audio passthrough export path 2026-04-04 13:07:34 +11:00
webadderall 8690393a80 fix: stale variable references in audioEncoder cleanup 2026-04-01 16:03:40 +11:00
webadderall db8718cf66 Add sidecar audio fallback for silent recordings 2026-04-01 15:40:40 +11:00
webadderall 719fa78e9f Revert "feat: Advanced Video Editor Implementation, Native WGC Integration, and AI Auto-Captions" 2026-03-28 14:12:25 +11:00
Mahdy Arief d5ab86ea44 fix(export, native, ui): resolve critical data integrity and resource management bugs in PR #122
- Implement comprehensive solo/mute export pipeline in audioEncoder.ts
- Fix duplicate caption IDs by adding chunk-specific indices in handlers.ts
- Prioritize native monitor selection by bounds in monitor_utils.cpp
- Fix alignment for blur annotations extending beyond canvas boundaries
- Resolve timeline selection desync and sidebar visibility for blur annotations
- Fix memory leaks in audio waveform generation with AudioContext cleanup
2026-03-28 06:09:50 +07:00
Mahdy Arief 74dfa0d5fa feat: Implement initial video editor with timeline, effects, audio waveforms, and export capabilities. 2026-03-28 01:25:40 +07:00
webadderall ffad684d54 fix(export): encode MP4 audio as AAC 2026-03-27 23:34:39 +11:00
webadderall b131bf8e0d fix(export): stream audio encoding for long exports 2026-03-23 18:00:00 +11:00
webadderall 24927e9b0b Fix TypeScript cleanup regressions 2026-03-18 18:36:25 +11:00
webadderall 0836b9e1e8 Read export local media via IPC 2026-03-18 16:18:53 +11:00
4rjunc ff8d75b074 fix: audio in export, add audioRegion 2026-03-15 18:55:26 +05:30
webadderall 7404301bee fix(export): merge upstream audio timing and cross-platform path normalization 2026-03-15 12:01:45 +11:00
webadderall 9435910e99 History reorganized for upstream alignment. 2026-03-13 21:36:30 +11:00
webadderall c3c5d1ed63 Initial release of Recordly 2026-03-13 21:14:05 +11:00