Skip to content

fix(editor): allow muting split segments independently - #2110

Closed
akash1520 wants to merge 3 commits into
CapSoftware:mainfrom
akash1520:fix/independent-segment-mute
Closed

akash1520 wants to merge 3 commits into
CapSoftware:mainfrom
akash1520:fix/independent-segment-mute

Conversation

@akash1520

@akash1520 akash1520 commented Aug 11, 2026 •

Copy link
Copy Markdown

Summary

Fixes #2109.

After splitting a recording clip, each resulting timeline segment keeps its own persisted mute state. Muting a segment preserves its selected pitch/speed processing mode, and unmuting restores that mode. Existing projects remain compatible, including clips muted using speedAudioMode.

Changes

  • Merge current main and integrate segment muting with the current Solid and GPUI clip menus, volume controls, and cursor settings.
  • Apply audioMuted in preview, normal and retimed rendering, and the streaming export path, including both sides of transitions.
  • Refresh active playback when segment mute changes and reject edited mute state in the preparation path that requires an unchanged timeline.
  • Preserve mute when splitting, merging, and importing Cap projects; regenerate the TypeScript segment binding from the Rust schema.
  • Keep global recording mute and timeline/background audio behavior consistent with the existing editor.

Validation

Passed locally:

  • cargo check -p cap-project --locked
  • cargo test -p cap-project --lib — 140 tests
  • Expanded mute persistence/backward-compatibility test
  • Desktop TypeScript check (tsc --project apps/desktop/tsconfig.json --noEmit)
  • Clip audio and merge Vitest checks — 8 tests
  • Scoped Biome checks, workspace Rust formatting, GPUI Rust formatting, and git diff --check

Added regression coverage for segment isolation, retimed mute, streaming exports with crossfade/fade-through-black, active playback refresh, preparation validation, split/unmute behavior, merge preservation, and import preservation.

Native validation is incomplete locally: cargo test -p cap-editor --lib segment_mute and cargo check -p cap-desktop --all-targets stop in the cidre dependency because this Mac has Command Line Tools but no full Xcode installation. Editor, backend/import, and GPUI native tests still need CI validation. No manual UI/audio playback verification was performed.

Comment thread apps/desktop/src-tauri/src/import.rs Outdated
@akash1520
akash1520 force-pushed the fix/independent-segment-mute branch from bd66fc6 to 7a0de47 Compare August 11, 2026 08:13
@richiemcilroy

Copy link
Copy Markdown
Member

hey! can you please get this to a 5/5?

Persist mute state per timeline segment instead of per clip, so splitting
a segment lets each half be muted independently. Centralizes the mute
check in the audio renderer for normal-speed, retimed, and transition
audio, and threads audioMuted through Cap-project import so it isn't
lost when appending a muted segment into another project.
@akash1520
akash1520 force-pushed the fix/independent-segment-mute branch from 7a0de47 to 71a1a26 Compare August 11, 2026 13:46
@akash1520

Copy link
Copy Markdown
Author

Hey @richiemcilroy, could you re-run Greptile on this? I've fixed the import regression it flagged and added a test covering it, so it should score 5/5 now.

@richiemcilroy

Copy link
Copy Markdown
Member

hey @greptileai please re-review the pr

@superagent-security

Copy link
Copy Markdown

Manage your Superagent protection

Superagent has paused scans for this repository because this unlinked GitHub App installation has used all three included PR scans.

You have 0 of 3 included PR scans remaining.

Create a free account to continue protection, manage scan settings, review security history, and control which repositories are protected.

@akash1520
akash1520 force-pushed the fix/independent-segment-mute branch from 7cb1213 to 0afab1b Compare August 30, 2026 17:02
@akash1520

Copy link
Copy Markdown
Author

Closing this PR as superseded by changes already in main:

  • 727ac5a5f fixed independent split-segment muting in playback and export, with regression coverage.
  • 8b347ebce added the clip settings menu with the Mute clip option.

The original behavior requested in #2109 is already implemented, so this PR's additional audioMuted field is unnecessary for that fix. Thanks for the review!

@akash1520 akash1520 closed this Oct 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

After splitting a track, users should be able to mute each of the resulting tracks individually

2 participants