Commit Graph
209 Commits
Author SHA1 Message Date
wiiiii123 81bfd2dbcc fix(export): harden post-merge file handling 2026-05-08 13:07:25 +07:00
wiiiii123 f2691187b4 fix(export): tighten native cursor and save cleanup 2026-05-08 12:41:00 +07:00
wiiiii123 add11c820a fix(export): harden native release gates 2026-05-08 12:24:04 +07:00
wiiiii123 211d6165f9 merge main into beta/pr410-native-gpu-export-test
# Conflicts:
#	electron/ipc/project/manager.ts
#	electron/ipc/register/export.ts
#	src/lib/exporter/modernVideoExporter.ts
2026-05-08 10:44:13 +07:00
webadderall 2380e56431 Clarify local file read and media allowlist intent 2026-05-08 12:30:26 +10:00
webadderall 25cd1f2f75 Speed up Lightning export and relax local media reads 2026-05-08 11:32:04 +10:00
webadderall ea8e486436 Merge pull request #419 from crbender/fix/local-read-allowlist-and-postinstall-fallback
fix: close local read allowlist bypass and make whisper-runtime postinstall non-fatal
2026-05-08 09:17:25 +10:00
wiiiii123 234a7b537a fix(export): support native cropped layouts 2026-05-08 03:20:28 +07:00
wiiiii123 eab365d115 fix(export): enable native speed timelines 2026-05-08 02:28:35 +07:00
wiiiii123 c77007560b fix(recording): account for mic pause gaps 2026-05-08 01:35:17 +07:00
wiiiii123 254783b15f fix(export): gate native speed timelines 2026-05-08 00:39:14 +07:00
wiiiii123 3455475f38 fix(export): harden native beta pipeline 2026-05-07 22:37:27 +07:00
wiiiii123 7e94355bb0 fix(recording): default windows mic to browser processing 2026-05-07 04:51:30 +07:00
Alan Trebugeais ff2759448a better code in sources/launchwindow/source
add: caching for 1.2s for a better user experience, less refreshing, it's actually instant now.
2026-05-06 23:32:58 +02:00
wiiiii123 7dd827be43 fix(recording): add windows mic diagnostics fallback 2026-05-07 04:00:46 +07:00
wiiiii123 115ecba7c5 fix(recording): reduce native mic noise amplification 2026-05-07 03:29:58 +07:00
Alan Trebugeais 8a3539abef add: LaunchWindow source selector without that much of a jitter. it's still weirdly behaving but it's better 2026-05-06 21:50:07 +02:00
Alan Trebugeais b1a0667a1c edit: LaunchWindow, RecordingControls for seperations of concern
fix: SourceSelection performances
add: seperator.tsx for "divider" component, instead of a non-generic component. can be reused elsewhere!
2026-05-06 19:34:21 +02:00
wiiiii123 65e7bd4fff fix(recording): prefer staged windows capture helper 2026-05-06 23:46:13 +07:00
wiiiii123 eb1ea68f7e fix(export): support native background blur 2026-05-06 20:53:44 +07:00
wiiiii123 ae0378cee4 fix(recording): declip native Windows mic peaks 2026-05-06 19:10:22 +07:00
wiiiii123 b3862bde79 fix(export): allow native cursor overlay routing 2026-05-06 07:04:01 +07:00
wiiiii123 1168e0edcc fix(export): preserve pitch for fallback speed audio 2026-05-06 06:43:40 +07:00
wiiiii123 9ac4c55ccf feat(export): prepare native GPU beta candidate
Add validated native CUDA/D3D11 timeline retime, pause-aware capture timing, webcam source-time sampling, edited-track audio duration padding, packaged helper updates, and focused tests for PR #410 tester branch.
2026-05-06 01:50:12 +07:00
wiiiii123 df8a1a3ed3 Merge remote-tracking branch 'origin/main' into perf/native-chunked-export-fastpath
# Conflicts:
#	electron/ipc/register/recording.ts
#	src/components/video-editor/VideoEditor.tsx
#	src/components/video-editor/VideoPlayback.tsx
#	src/hooks/useScreenRecorder.ts
#	src/lib/exporter/modernFrameRenderer.ts
#	src/lib/exporter/modernVideoExporter.ts
2026-05-05 16:59:32 +07:00
webadderall b773f98ad0 fix: address PR feedback regressions 2026-05-05 16:17:47 +10:00
webadderall 2c0c436267 Reapply "feat: bundle cursor motion and temporal blur updates"
This reverts commit be01bccb7a.
2026-05-05 16:16:56 +10:00
webadderall ad9895a1c4 Merge pull request #413 from webadderallorg/codex/cursor-telemetry-write-api
feat: add writable cursor telemetry API
2026-05-05 14:57:09 +10:00
Recordly Reviewer b0ab0bf184 fix: address PR review feedback - canonicalize via realpath and gate whisper soft-fail
isAllowedLocalReadPath now resolves the candidate via fs.realpathSync and requires both the lexical and canonical paths to satisfy the policy, so a symlink placed under an allowed prefix that points outside the allowlist is rejected. The redundant 'either resolved or realResolved is allowed' check in read-local-file and generate-wallpaper-thumbnail is removed since the function canonicalizes internally. Adds a regression test that creates such a symlink (skipping when Windows refuses to create it without Developer Mode).

build-whisper-runtime now only soft-fails when invoked from postinstall, in CI, or with WHISPER_RUNTIME_ALLOW_MISSING=1. Direct 'npm run build*' invocations fail loudly when CMake is missing and no bundled runtime is staged so we don't ship release builds with broken auto-captioning.
2026-05-04 14:31:09 -04:00
Recordly Reviewer dce19d5209 fix: tighten local read allowlist and gracefully skip whisper-runtime build without CMake
isAllowedLocalReadPath previously returned true for any existing path because of an existsSync fast-path, which made the read-local-file IPC handler and the local media URL policy effectively allow reading arbitrary files on disk. Drop the existsSync bypass so only paths under app-managed directories or paths that have been explicitly approved (via dialogs, exports, recording sessions, etc.) are accepted. Adjust the local media path policy tests to cover the new behaviour.

Also make build-whisper-runtime fall back to bundled artifacts when CMake is missing (mirroring build-windows-capture) so npm ci does not fail on machines without a C++ toolchain.
2026-05-04 14:21:49 -04:00
webadderall be01bccb7a Revert "feat: bundle cursor motion and temporal blur updates" 2026-05-04 18:17:04 +10:00
webadderall dedf43720a Merge pull request #414 from webadderallorg/codex/behavior-3-13
feat: bundle cursor motion and temporal blur updates
2026-05-04 18:15:30 +10:00
webadderall 0abc7a3098 feat: bundle cursor motion and temporal blur updates 2026-05-04 18:12:47 +10:00
webadderall 6cc83b31e9 feat: add writable cursor telemetry API 2026-05-04 17:28:10 +10:00
wiiiii123 23f17f2772 Merge main into native GPU export PR 2026-05-04 11:42:27 +07:00
wiiiii123 94bbd0280f Add NVIDIA CUDA export compositor 2026-05-04 09:59:41 +07:00
wiiiii123 9c81006e5c Add native GPU static layout export path 2026-05-03 22:43:23 +07:00
shafeq 01f61dfada fix(export): return temp path from buffer-mode FFmpeg muxer (>2 GiB)
Exports of recordings whose muxed output exceeds 2 GiB failed with
RangeError [ERR_FS_FILE_TOO_LARGE]: Node's fs.readFile rejects files
larger than kIoMaxLength (2 ** 31 - 1). The legacy export pipeline hit
this in muxExportedVideoAudioBuffer, which called
  await fs.readFile(finalized.outputPath)
to ship the muxed bytes back to the renderer.

Mirror the path-based contract that mux-exported-video-audio-from-path
already uses:

- muxExportedVideoAudioBuffer now returns { outputPath, metrics } and
  collects byte size via fs.stat instead of fs.readFile. The unmuxed
  intermediate is still cleaned up; the muxed output is left for the
  IPC handler to register and the renderer to finalize.
- The mux-exported-video-audio IPC handler registers the muxed output
  via registerOwnedExportPath and returns { tempPath, metrics }.
- preload.ts and electron-env.d.ts: tempPath replaces data in the
  renderer-facing return type.
- videoExporter.ts and modernVideoExporter.ts (the
  finalizeExportWithFfmpegAudio fallback paths) now return
  { tempFilePath } so VideoEditor's existing finalize-exported-video
  flow handles the move — the same path the modern stream-mode export
  already takes.

The renderer already preferred tempFilePath over blob in
VideoEditor.tsx for MP4 saves (with the explicit comment "avoids ever
allocating a multi-GiB ArrayBuffer in the renderer"), so this just
removes the buffer-mode regression for large legacy exports.

Adds electron/ipc/export/native-video.test.ts asserting the new
contract: muxExportedVideoAudioBuffer returns a path, never calls
fs.readFile, and still records muxedVideoBytes via stat.

Closes #380
2026-05-02 09:48:05 +08:00
webadderall 5570c119ca [codex] Fix cursor sync after recording pause (#399)
* Fix cursor sync after recording pause

* Align recorder and cursor pause boundaries
2026-05-01 17:18:35 +10:00
webadderall 98e4c7cade Improve project autosave and media path handling 2026-04-27 20:07:32 +10:00
webadderall f58cd07250 Merge pull request #237 from Andrii-Vovk/fix/macos-screen-highlight-bounds
fix(highlight): screen highlight clipping on macOS
2026-04-27 14:43:16 +10:00
Wiii 574cefc6bd fix(export): use tempo filters for speed audio
Use FFmpeg atempo filters for native edited-track speed changes, including near-unity speed tolerance coverage.
2026-04-26 22:59:20 +07:00
Andrii-Vovk 69abb0390d fix(highlight): screen highlight clipping on macOS
On macOS, the screen highlight overlay's right and bottom edges were
   running off-screen. macOS clamps window positions below the menu bar,
   so the outward padding only appeared on the left/top while the
   right/bottom extended beyond the visible area.

   Use display workArea instead of full bounds for screen highlights on
   macOS, and keep the border/glow within the overlay window.
2026-04-26 17:31:28 +03:00
Wiii 97ba2a020c fix(recording): normalize native Windows mic loudness

2026-04-25 18:15:51 +07:00
Wiii 46f384d4d0 fix(recording): use native audio start timestamps for Windows sync

2026-04-25 17:47:39 +07:00
大彪 9ac4dbd2e8 fix(export): stream MP4 output to disk to unblock >2 GiB exports
Long recordings (35-minute screencaps were the motivating case) fail at
the 99% "Finalizing" step with a RangeError once the muxed MP4 would
exceed V8's ~2 GiB per-ArrayBuffer limit. Both export paths accumulate
the whole file in renderer memory and round-trip it through IPC, so no
output size past that point can complete:

- Legacy: src/lib/exporter/muxer.ts uses mediabunny's BufferTarget,
  which holds the entire MP4 in a single ArrayBuffer. finalize() → Blob
  → blob.arrayBuffer() → ipcRenderer.invoke('write-exported-video-to-
  path', arrayBuffer, path) — every step wants a ≥2 GiB contiguous
  allocation.
- Lightning: native-video-export-finish did fs.readFile(finalizedPath)
  and shipped the bytes back to the renderer, which re-serialized them
  again. Same ceiling.

This change moves the finished MP4 across the renderer↔main boundary
via a temp file instead of an ArrayBuffer:

- New electron/ipc/export/exportStream.ts manages streaming temp files
  via fh.write(buf, 0, len, position) so out-of-order writes (moov box
  rewrites, etc.) stay safe. Each session lives in a 0700 mkdtemp()
  directory opened with O_CREAT | O_EXCL so a hostile local user on a
  shared tempdir cannot pre-plant a symlink at the predicted path.
- New renderer-facing IPCs: export-stream-open/write/close,
  finalize-exported-video (renames temp to final path, copy+unlink
  fallback on EXDEV/EPERM/ENOTEMPTY with console.warn on leaked bytes),
  mux-exported-video-audio-from-path (FFmpeg audio fallback that takes
  a path instead of an ArrayBuffer), and discard-exported-temp. Every
  handler validates the caller-supplied path against an owned-export-
  paths registry before touching disk, so a compromised renderer cannot
  route arbitrary filesystem paths into main-process deletes/moves.
- The muxer now picks mediabunny's StreamTarget automatically when the
  Electron bridge is available (BufferTarget stays for tests and any
  non-Electron callers). finalize() returns { mode, tempFilePath,
  bytesWritten } or { mode, blob } so the exporter can branch.
- Exporters forward tempFilePath through ExportResult. Lightning's
  finish returns the ffmpeg temp path directly; the FFmpeg audio
  fallback forks on the muxer result type. modernVideoExporter's
  Lightning success branch now accepts tempFilePath (previously it
  checked blob only, which regressed every native export).
- VideoEditor.tsx dispatches on tempFilePath: finalize via the new IPC,
  keep the temp in place when the save dialog is canceled so "Save
  Again" still works without re-rendering, keep the pending-save entry
  alive on non-canceled save failures, and discard the temp on unmount
  or explicit clear. GIF and smoke-test code paths still use the
  legacy Blob path unchanged.
- app.on('before-quit') also reaps any open streaming sessions via
  cleanupAllExportStreams().

Chunk size is 16 MiB — well under Electron/Mojo IPC message limits
while keeping total writes low (~160 for a 2.5 GB export).

Tested locally: exported a 35:13 source (~2.7 GiB H.264 input) at
Original 1920×1080 + Balanced. Previously failed on finalize with a
RangeError; with this patch the Legacy pipeline produced a valid 3.7
GiB MP4 whose ffmpeg -i duration/streams match the source.

Addresses #194.
2026-04-24 16:02:37 +08: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 235a01c561 Merge pull request #314 from soufian3hm/fix/windows-recording-validation
Fix invalid Windows recording finalization
2026-04-22 17:19:56 +10:00
webadderall 12683f4783 Merge pull request #310 from meiiie/fix/native-audio-lead
fix(recording): keep longer audio tracks anchored
2026-04-22 17:18:51 +10:00