Commits
Commits on
e3392c8daecb9842008bcbe01512f645f78036d7Filtered to crates/engine/src/project.rsClear filter2026-08-19
🧹 fix(engine): the inverse admits its hole, the scale law lives onceAhmet Kaan Gümüş · 47c08dd
🧹 fix(engine): the inverse admits its hole, the scale law lives once invert fabricated an answer for the frames a shift-right piece never produces -- the hole between the identity run and the piece's own image -- against its own doc. It answers None there now, and a test walks the hole asserting so. The caption scale law lived twice, one copy clamped and one not, the exact duplication that drifted a frame before: scaled_caption_frame is now the single fn both write_speed and speeded_playhead call. The successor guard saturates instead of overflowing at the clamp ceiling, and the ungrouped-layer arm of whole_take is pinned by its own test again -- a layer is lifted, never rippled.
🐛 fix(engine): a merged group stays one placement per laneAhmet Kaan Gümüş · b1724e2
🐛 fix(engine): a merged group stays one placement per lane group_all folded pre-existing links into the new id transitively with no check on what the merge produced: two captions on one sub lane, each grouped with a different picked clip, both took the id -- a state links_are_consistent only debug_asserts against, where group_of sees the first and delete_members orphans the second. The merge is now counted per lane before anything mutates and refused by name when a lane would carry two, the same refusal remove_lane speaks.
🐛 fix(engine): the captions of a re-rate go through the map itselfAhmet Kaan Gümüş · 675eb6f
🐛 fix(engine): the captions of a re-rate go through the map itself write_speed re-timed a group's captions with its own ratio formula, round(frames * new/old) -- one frame adrift from the TimelineMap that speeded_playhead answers with (92 divergent cells over a length x rate grid; a 90f clip at 2x landed its caption's last frame on 48 while the playhead was sent to 47). The write now builds the same per-caption map and takes start and end from apply(), one source of truth. Two coverage holes closed: the caption arm of speeded_playhead (a playhead in a caption's overhang past its clip) had never been exercised; the write-vs-playhead agreement is now pinned over the grid, exact for compression, containment for expansion where apply() answers the start of a frame's new block by construction.
2026-08-16
🧹 fix(engine): the map's law is real, its inverse honest, its docs trueAhmet Kaan Gümüş · d2ac4e7
🧹 fix(engine): the map's law is real, its inverse honest, its docs true The sweep's survivor-continuity cell built its TimelineMap out of the playhead's own answer and then discarded it -- a law claimed and never asked. The map now comes from the member's own old geometry (old span, source length over the new rate) and the law is the clip's landed span against the map's ends, non-circular. invert() walked into a shifted piece's lerp from the wrong end below its first knot -- frames under min(old lo, new lo) are identity outright, and the shifted-piece test pins the whole run both ways. And the delete docs and one old test name still told the caption-lift story the ripple replaced; they tell the one-law story now.
✅ test(engine): the re-timing sweep, every op against the lawAhmet Kaan Gümüş · 5832d81
✅ test(engine): the re-timing sweep, every op against the law A table-driven property suite over every mutating op (delete from each anchor kind, speed at 2x and half, split, regroup, move, trim, paste) against four project shapes (ungrouped, grouped clips, aligned group with caption, the offset group) under the universal laws: links consistent, every lane sorted and disjoint on both its lists, the playhead's scene within the frame a rate can hold, and the undo round-trip byte-identical at one snapshot per op. Two harness findings on the way in, both of the harness and not the engine: a two-op cell must capture its pre-state between the ops, and a stretch the neighbours refuse is a valid cell -- the refusal names its wall and changed nothing. Paste is the named exception the suite pins directly: media lanes ripple, the words never move. TimelineMap's invert and the total shift answer the laws today and are gated test-only until the delete/paste migrations consume them in a build path.
🐛 fix(timeline): a caption deleted with its group closes its laneAhmet Kaan Gümüş · ac71b75
🐛 fix(timeline): a caption deleted with its group closes its lane The offset rewrite made a grouped delete ripple each media member's span out of its own lane but still LIFT the caption members -- so the sub lane kept the hole while every other lane closed, and the captions after the deleted one never slid up with the rest. One law now, from whichever member the delete was clicked on: a caption deleted WITH its group goes by the same span-out-of-its-own-lane ripple its clip siblings take, and a caption deleted alone keeps the lift that leaves a gap, exactly as before. ripple() is the one mechanism -- the same law the scoped cuts already apply to sub lanes.
🐛 fix(playback): the playhead follows the re-rate through the same mapAhmet Kaan Gümüş · 6d8f3a1
🐛 fix(playback): the playhead follows the re-rate through the same map A speed change left the playhead at its own timeline position while write_speed re-timed the group under it, so the scene changed with the rate -- at 2x from the middle of a clip the cursor jumped a clip's worth of content. Both the commit and every live sample of the bar now map the playhead through a TimelineMap built from the group's own old geometry: each clip member by its old rate against the new one about its own head, each caption member by the held clip's proportion about the held clip's head, and a playhead outside every member unmoved -- nothing ripples, so the difference is the gap's to absorb. TimelineMap (engine/src/map.rs) is the one piecewise-affine answer the re-timing ops will share; this is its read-side consumer, with the laws pinned (monotone, exact on the ends, invertible on the image) and the playhead its first user. The delete and paste migrations land next; until they do, invert and the total shift answer the laws tests alone.
2026-08-15
✨ feat(engine): a speeded clip keeps its pitchAhmet Kaan Gümüş · 475f10c
✨ feat(engine): a speeded clip keeps its pitch The tape effect is gone: a speeded clip's audio was resampled at its speed, so its pitch moved with its rate. The resample is now only what it always should have been -- the rate conversion, reading a source written at another sample rate at the ratio of the two rates, pitch- true by construction -- and the time the Speed asks for is taken by a WSOLA stretch behind it: windows overlap-added at a different hop, each placed where it best continues the one before it, so the timeline compresses or stretches while every period of the signal keeps its own length. The beep stays a 1 kHz beep at 2x, the words stay spoken. Hand-rolled, no new dependencies: N=1024 Hann windows, 512-frame synthesis hop, ±512 search on the first channel by normalized cross- correlation against the natural continuation, one offset for every channel so a stereo pair stays coherent. A silent continuation is placed nominally -- nothing to match -- and a segment too short to prime a window passes through as the decoder read it. Both halves of the chain pace the timeline's promise to the frame, which is the A/V sync invariant the speed suite pins. Measured, not felt: the stretch's own tests put a 440 Hz sine through 2x and 0.5x and read 440 back by Goertzel with the octave gone; the sync fixture's 1 kHz beep plays at 1 kHz at 2x and 0.5x through the real open path (the tape effect's ladder peak read 1350 Hz there), and a 2x WAV export carries the same 1 kHz back out.
🐛 fix(timeline): an arriving clip never touches the captionsAhmet Kaan Gümüş · a3dc07c
🐛 fix(timeline): an arriving clip never touches the captions The rippling paste -- the door a video arriving on the timeline goes through, and the clipboard's own -- opened room on the subtitle lanes too, splitting a caption the landing fell inside and sliding the rest behind the new clips. On a timeline of words alone, adding a video cut the caption in half and pushed its tail to the video's end, which no hand asked for. A paste inserts media; the words keep their own clock. A caption that should travel with a clip is what a group is for, and a group moves as one. The razor still cuts captions with the picture, and a cut region still removes the words over it -- those are cuts, and this was an add.
✨ feat(timeline): captions keep their own clock through a re-rateAhmet Kaan Gümüş · f8f5c46
✨ feat(timeline): captions keep their own clock through a re-rate A placement's cues crossed the timeline one window-microsecond to one timeline-microsecond, which is only the truth at unity: a group's re-rate compresses the frames and leaves the window alone, so the plate and the lane export drew the words falling behind their box, cue by cue, and the tail past the end. The map now goes by the placement's own proportion -- at unity every cue lands exactly where it always did, to the microsecond, and at 2x the words cross in half the time. A caption's box wears the rate its window plays at, derived off the placement itself (so the badge survives the group coming apart), gated past placement rounding; and the grade and the fit resolve a caption in hand to the picture it was pinned to, saying so out loud when there is none -- the speed, silence and equalizer cards' own rule.
🐛 fix(timeline): a region's caption pieces re-time by boundaries, forced apartAhmet Kaan Gümüş · 3a0448f
🐛 fix(timeline): a region's caption pieces re-time by boundaries, forced apart Rounding each in-region caption piece's start and length independently could land two pieces on the same frame (two one-frame cues of a thirty-frame region at 2x both want frame 15) and let the region's last cue run past where its first follower lands -- a debug-assert panic, and in release a silent overlap the lane invariant forbids. The pieces now re-time by their mapped boundaries walked in order: each piece at least one frame, none past the region's own new end, and the first caption behind the region lands exactly on it. A rounding artifact is clamped rather than refused -- nothing about the words asked for an overlap.
✨ feat(timeline): tempo ops carry the captions of a groupAhmet Kaan Gümüş · b801cf5
✨ feat(timeline): tempo ops carry the captions of a group A group's caption now travels with everything that re-times it. A rate set on any member re-times the caption members by the ratio the held clip's own frames take -- the span on the timeline compresses about the held clip's head while the words keep their own window -- and a stretch that would run a caption into its neighbour is refused in the clip arm's words. The silence scan's speed-up shrinks the caption pieces inside its regions and slides the rest up with the clips; its Take scope carries the caption's lane so the cut does too; and the scope law names a caption half left outside a scoped cut, in the words it always used for a clip's. The cards stop dead-ending on a caption in hand: speed and silence resolve a caption anchor to the media half of its group (the picture and the sound respectively) and say so out loud -- with the how-to -- when there is no media behind the words; the equalizer takes the group's sound the same way. Colour and Fit are untouched: a caption anchor retargets to the playhead's picture exactly as an audio anchor always has.
🐛 fix(timeline): grouped caption edits reseek, and the link counter clears caption idsAhmet Kaan Gümüş · 25855e8
🐛 fix(timeline): grouped caption edits reseek, and the link counter clears caption ids A grouped caption's drag and trim move the group's clips with it -- a timeline->source change -- so PlaybackSession::move_sub and trim_sub now invalidate Dirty::Both when the caption is grouped with clips (the check delete_sub already made, now shared as caption_grouped_with_clips), and the app pays the reset_after_reseek a clip's drag and trim pay on the same paths. The link counter a load seeds now sits past every id the file names: from_parts chains the subs a lane already holds, and with_subs -- the door a load's placements actually come through, after from_parts -- raises the counter past the ids its captions carry. A hand-grouped caption holding the file's highest id could have had it re-issued to the next group that asked, silently grouping it with clips it never met. A palette drop onto a subtitle lane renumbers that lane alone; the picks it held now follow the discipline of every other renumbering edit -- kept off the lane, re-read for the marked caption, other lanes' picks untouched. Also folds in the v16 caption-group round-trip test that had been left out of the previous commit.
✨ feat(engine): offset-preserving groups over clips and captionsAhmet Kaan Gümüş · 48cacb6
✨ feat(engine): offset-preserving groups over clips and captions The engine half of manual clip grouping: SubClip gains a link id, the group invariant becomes one-placement-per-lane (span equality dropped), group_all builds a hand group over clips and captions with mates riding along, splits keep the left group and share one fresh id on the right (captions included), deletes ripple each media member's own span on its own lane and lift caption members, grouped caption drags and group trims move every member by one delta clamped to each member's own walls, and the save format grows an optional 6th sub field as v16. App half (Selection refactor, ctrl+click, ctrl+A, oracle/menu, marks) follows.
2026-08-14
✨ feat(engine): the words a timeline places are the tracks its file carriesAhmet Kaan Gümüş · 0f135a8
✨ feat(engine): the words a timeline places are the tracks its file carries An export of a project with subtitle placements writes one track per subtitle lane, in lane order, from the lane's own cues (`Project::sub_lane_cues`) -- language and title from the palette row its first placement plays. The pick list stays in charge of a project with nothing placed anywhere, which is every project the app can make today; the card's line goes lane by lane the same way. A caption hanging past the last picture holds the timeline open but has nothing under it to write, so an export now ends with the last picture or sound (`Project::media_frames`): a cue straddling the end keeps the half inside, a lane wholly past it writes no track, and the plan line says so before the button is pressed -- and the sound is no longer padded with silence out to the caption. A lane of pictures is refused in words and written nowhere: both muxers write text and neither has a bitmap path. Past `MAX_SUB_TRACKS` lanes the card refuses by name, and the muxer refuses again.
✨ feat(engine): the words a project places are in the file it savesAhmet Kaan Gümüş · df4020f
✨ feat(engine): the words a project places are in the file it saves The `.edith` grows a `sub` line -- `sub <lane> <start> <frames> <track> <in> <out>` -- and a bare `sub <lane>` for a subtitle lane holding nothing, written in the lane's own place among the video and audio ones so the display order a load rebuilds is the one that was saved. Both of a caption's clocks are on the line: the placement in timeline frames like everything else, the window in the microseconds its cues are timed in. MAGIC is `edith 15`. `Project::without_orphan_sources` stops filtering the subtitle lanes out of its `Parts` and `Project::lane_gains` stops filtering them out of its gains -- the two are zipped by `edith::emit`, so they were only ever allowed to filter in step, and now neither does. What is *on* those lanes travels beside them in the new `Project::lane_subs`, one list per lane exactly as the gains are, and comes back through `Project::with_subs`, which is `from_parts` for words: it refuses a caption on a lane that is not a subtitle lane, an empty span or window, a track the palette does not have, a span past the last frame there is, and a lane that overlaps itself. The parser refuses the same file by line number. A v14 project is one that named subtitle files and could place none of them: it loads with its palette whole and no subtitle lane at all, which is what it always meant, and re-saves as v15 having invented neither. Also fixes a version-bump straggler in tests/silence.rs, which asserted `edith 13` against a `edith 14` writer and was red before this change.
🐛 fix(engine): a palette row that goes takes the placements' indexes with itAhmet Kaan Gümüş · 03073e6
🐛 fix(engine): a palette row that goes takes the placements' indexes with it A `SubClip` names its subtitle track by index into the project's palette, exactly as a `Clip` names its source -- so `remove_subtitles` owed `remove_source`'s rule and did not have it: a row removed above a placement left every clip past it playing the *next* track's words. The probe that found it: three rows, the middle one placed, remove the first -- the caption on the lane silently became another language. Now it follows that rule whole. Refused, naming the lane and the frame up to three of them, while anything on a subtitle lane plays *this* row; allowed otherwise, walking every placement past it down one; and the undo history is cleared, because its snapshots hold the indexes as they were before the walk. The refusal reaches a person already -- the x on a subtitle row shows the engine's words verbatim. Five smaller things the same read turned up, each its own hunk: - a drag that changes nothing is `Ok` and no step, not a refusal: a caption picked up and put back, and an edge pulled past a wall it already stands against, are both a hand that did nothing wrong, and a front-end shows every `Err` as a notice. - `remove_lane` names the captions it still holds and the way out -- three names, a count, "or drag them to another track" -- instead of "1 subtitle(s), the first at frame 0". - its "only track" sentence gets its own arm for a subtitle lane, so the word stays true if the guard that makes it unreachable is relaxed. - `place_sub` says in words that `at` is where it lands and `sub.start` is ignored, which is `place`'s own contract for a clip. - `track_name` is the one place a refusal turns an index into the name a panel shows.
✨ feat(engine): subtitles become a third lane kind, placed like everything elseAhmet Kaan Gümüş · ec66e07
✨ feat(engine): subtitles become a third lane kind, placed like everything else `LaneKind::Subtitle` joins the lane list, holding `SubClip`s -- a `[in_us, out_us)` window of one of the project's subtitle tracks (the flat `subtitles` list stays the palette) placed at a timeline frame. A caption is therefore added, ordered, labelled `S1`, snapshotted, rippled, razored and undone by the machinery every clip already goes through: an undo step is the lane list, so subtitles joined the history without one of their own. It carries no `Clip` at all, and that is what keeps the media paths free of it: `Project::lane` hands back an empty slice, so trim/set_eq/set_color/set_fit/ set_speed/lift/delete_in refuse it by the bounds check they already had, the composite and the mix never look at it, and the three doors that could still put a picture on one -- `from_parts`, `place`, `append_clip` -- say so by name. Ops: `place_sub` (refuses an overlap rather than overwriting -- words that lost are simply gone), `move_sub`, `trim_sub`/`trim_sub_room` (clamped like a media trim; the window follows the edge), `lift_sub`, and `sub_lane_cues`, which maps a lane to cues clipped to each window and shifted onto the timeline -- the twin of `export::timeline_cues` for a track that is placed rather than carried. Ripple, paste-room, split and regroup cut the windows by *proportion*, so none of that arithmetic needs a frame rate; only a trim and the mapping take one. Not here, on purpose: persistence (`Parts` has no line for a `SubClip`, so a save leaves the lanes out -- named at the filter) and any UI.
2026-08-13
✨ feat(timeline): a track is carried to its place in the stackAhmet Kaan Gümüş · 9ddffc8
✨ feat(timeline): a track is carried to its place in the stack A header is a handle now: drag V1 or A1 onto another header and the whole track takes its slot -- clips, gain and kind travelling with it, a ghost under the pointer and a line along the edge it comes in at, one undo step. Order lives in one place, the lane list, so the stack the preview composites, the stack an export composites and the order a save writes are the same list read three times. Display order is that stack: moving a video track past another changes which picture wins, in the preview and in an export alike, while audio is summed and does not care -- which is what makes an audio track above a video one a rearrangement of the screen alone. A label stays a position among the tracks of its kind, so a track that crosses one of its own kind swaps names with it, and everything holding a (lane, idx) is dropped exactly then.
🐛 fix(timeline): a layer takes the sound down with itAhmet Kaan Gümüş · cd0df09
🐛 fix(timeline): a layer takes the sound down with it A file with audio let go over a further video track landed silent: the placement door put the picture on that lane alone, although its own words said 'its picture on V2, its sound on A2'. Both halves go down now, on the same frames and in one group, with the audio row added when the + V button left the project without one -- one snapshot, so one undo takes the pair and the row back together.
chore: rename ponytail: comment marker to corner-cut:Ahmet Kaan Gümüş · 9ba8e0a
chore: rename ponytail: comment marker to corner-cut: Marker convention renamed after uninstalling the ponytail plugin; semantics unchanged (deliberate corner-cut, known ceiling + upgrade path). Token-only rename, 81 comment lines, no code change.
⏪ revert(subtitles): the removal bin goes, the way back is the file's own doorAhmet Kaan Gümüş · bbe4e40
⏪ revert(subtitles): the removal bin goes, the way back is the file's own door The recovery bin was the wrong answer to the right complaint. What a person wants after removing a row is not that row back out of a session cupboard -- it is a way to put *any* file's subtitles on a timeline without importing the file, which is the door the next commit is about and which brings the removed one back as a side effect. So `Project` keeps no bin: a removal removes, as it did before, and the row's × and the notice now name the add-subtitles stroke as the way back rather than "import the file again". That old sentence does not come back: the file itself never has to be imported for its subtitles. The engine and app halves both go (b13bd53 here, and the app half that rode into 4420513 while two lanes shared one worktree).
✨ feat(subtitles): a removed track is one click from being backAhmet Kaan Gümüş · f41b4c6
✨ feat(subtitles): a removed track is one click from being back Removing a subtitle row dropped the whole track -- cues and all -- and the only way back was importing the file again, which on a big remux is a walk of the whole container for something the session had in hand a second ago. "Bringing back the removed subtitle needs reimport is very nonsense", and it is: a removal is the one edit here whose inverse cost more than the edit. The removal is now non-destructive at the model. `Project` keeps what it took off in a bin beside the list (`removed_subtitles`), and `restore_subtitles` puts one back with the cues it left with -- no file is read, so a row comes back even when its file has gone missing since. The bin is the session's, not the project's: a `.edith` still writes what the timeline has, exactly as it did. The door is the row the removal leaves behind, under the list and dimmed, with a `+` where the × was: the way off the timeline and the way back on are one shape in one place. The list is drawn while either half of it has rows, so removing the last track is exactly when the way back is on screen rather than the moment the section disappears. The audio side of the same class was already reversible: a lane removal is a history snapshot and z restores it. A library row is not, by the decision recorded in `Project::remove_source`, and is left alone. The app half of this slice (`Player::restore_subtitle_track`, the notice and its test) is in 4420513: the theme work committed the whole tree while both were in flight.
2026-08-12
✨ feat(subtitles): as many tracks as you want, embedded in the exportAhmet Kaan Gümüş · 28e2853
✨ feat(subtitles): as many tracks as you want, embedded in the export Subtitle tracks now work the way audio and video tracks do: add as many as you like, remove any of them, and every track with cues on the timeline is written into the exported file. Add and remove - "+ S" beside "+ V"/"+ A" imports every subtitle track in a picked file; each row carries its own "x". Pointer and keyboard doors share one implementation and refuse identically, before any chooser opens. - Project::remove_subtitles / PlaybackSession::remove_subtitles, with the index fixup in one place so a removal cannot repoint the overlay. Embedded in the output - ExportSettings.subtitles is a list; the Matroska muxer writes N tracks from number 3 up, ceiling derived from the encoding (0x7F - SUB_TRACK_FIRST) because track 127 is the all-ones VINT our own reader maps to "unknown" and would silently lose. - mp4 carries them too, as real tx3g timed text. The old "an mp4 carries none" was a false refusal: mp4 0.14 has MediaConfig::TtxtConfig all along. Samples are built from cue boundaries, so gaps are empty samples and the track spans the film. - of_mp4 reads them back, so edith re-imports its own output. Verified against a file ffmpeg muxed, which writes mdhd in microseconds where we write milliseconds. - The export set is derived from timeline_cues per call, so it cannot desync; the card names a track it leaves off, and counts past the width budget rather than eating the card. Language and title - SubtitleTrack carries language and name apart; the guess-them-back heuristic is gone. LanguageBCP47 is read and mapped to a 3-letter code (ffmpeg reads no BCP-47 at all, so writing it would have made the language invisible). A 17-track subtitle library file and a dual-language one no longer read "und". Media bitrate in properties - engine::probe_bitrate opens no decoder; all three numbers share the container's duration, so total >= video + audio holds by construction. Within 0.004% of ffprobe across the library. - Both properties cards show it; a dual-audio file says which of how many. The line picks one unit off its smallest stated component, so a real value never renders as 0.00. Off the render thread - The subtitle walk moved to the background executor at every door: 1324ms -> 0.1ms on a 3.1GB film, 234ms -> 5.0ms on a 25.4GB/35-track one. (The media walk is still on the render thread; separate slice.) False refusals removed - .mks and .mka were refused while the compiled-in Matroska reader parses them; is_matroska now takes the standard's closed set. - The audio-only "sound alone" sentence was unreachable when every pick was a bitmap track. Subtitle-free exports stay byte-identical: 294a8b0c (hevc mkv), 8c16b8b1 (default mp4).
2026-08-11
🐛 fix(project): the undo stack stops at 100 steps and an export clones the timeline, not the sessionAhmet Kaan Gümüş · 2504de7
🐛 fix(project): the undo stack stops at 100 steps and an export clones the timeline, not the session snapshot() drops the oldest step at the cap: one gesture is one step, so 100 is past any chain walked back by hand, and a 1394-clip jumpcut timeline's history is a bounded ~10 MB instead of one that grows for as long as the session lasts. export_to_with hands export::start a Project::export_snapshot() -- lanes and sources with the history left behind. The clone is taken on the UI thread and an export never walks the history back; the written bytes are unchanged.
✨ feat(tonemap): the HDR rendition is a row you pick, not a constant someone chose for youAhmet Kaan Gümüş · 09671f7
✨ feat(tonemap): the HDR rendition is a row you pick, not a constant someone chose for you BT.2446 Method A's assumed mastering peak was a constant in the module: 400 cd/m^2, one exposure decided for everybody. It is a matter of taste, not of correctness -- a reference rendition and a vivid one are both honest pictures of the same film -- so it becomes a project setting with three renditions through the very same curve, which is what keeps the hues right whichever is picked: Reference 1000 nits, chroma 1.0 the published conversion (diffuse white 166) Standard 400 nits, chroma 1.0 display-referred, as bright as a player Vivid 250 nits, chroma 1.10 brightest, and a tenth more colour The chroma gain is a scale about 128 in the SDR codes, after the map and clamped to the legal range: a grey stays exactly grey at any gain, and at 1.0 it is a clamp the maths cannot reach, so the other two presets are byte for byte what Method A produced. HLG's OOTF gain is guarded at black -- below a 1000 cd/m^2 peak the system gamma is under 1, and the 0 * inf that follows byte-cast to 0 and put a hole where black belongs. The preset lives on the Project beside the limiter (a setting, not an undo step), reaches the decode workers and the export through the same value, and is saved as a `tonemap` line in edith 11 -- left out when it is the default, so a project holding no HDR media is the bytes it was, and a v10 file loads as the reference rendition, which is the only one it ever had. Picking one rebuilds the picture under the playhead the way a resize does; an SDR project is unmoved. The panel names it beside the resolution and the rate -- the third thing that is the project's rather than the media's -- and a click opens the three renditions with the one in force marked. No stroke: this is a list to look at.
🐛 fix(timeline): a dropped row lands where the hand let it go, not after the last clipAhmet Kaan Gümüş · 0d1c2c1
🐛 fix(timeline): a dropped row lands where the hand let it go, not after the last clip
A library row dragged onto the open bed past the last clip was appended to
the end of the timeline wherever it was released: the ghost promised one
frame and the release committed another.
`Project::paste` clamped the frame it was asked for to `timeline_frames()`
-- the clipboard's rule ("put it here", never "here with black in front"),
imposed on every caller of the primitive. A drop names a place on the bed
and means it, and `Project::place` (the audio/further-lane half of the same
drop) already honoured one, so V1 was the odd lane out.
The clamp moves to the clipboard's own door, `PlaybackSession::paste_at`,
and the grouped branch of `place_stream_at` goes to `Project::paste`
directly with the frame the pointer named. Nothing else changes: a paste at
the playhead cannot be past the end anyway.
Pinned by `a_row_dropped_on_the_open_bed_lands_under_the_pointer`, which
walks the release's own chain -- `landing` as `place_frame` composes it,
the frame back through the rate as `insert_source` hands it over, and the
one engine door a row goes through -- and lands frame 300 where it used to
land 150.Merge remote-tracking branch 'origin/main' into worktree-agent-a70e2dff6f1316489Ahmet Kaan Gümüş · 288629aBrowse files
✨ feat(export): the subtitles leave with the fileAhmet Kaan Gümüş · df92458
✨ feat(export): the subtitles leave with the file A Matroska export now carries the picked subtitle track as S_TEXT/UTF8: a TrackEntry beside the picture and the sound, and one BlockGroup per cue — Block plus BlockDuration, because a SimpleBlock has nowhere to say when a line goes away. Interleaved into the clusters as the AAC packets are, so a player has the cue by the time it needs it. The cues are put on the exported timeline first. A track that came out of a media file is timed against that file, so it is carried through the spans that still play it: a cue over a stretch that was cut out is gone, one straddling the cut keeps the half that is still there, and everything after a rippled delete moves back with the picture it belongs to. A standalone .srt has no clip to hang on and no offset to shift by, so it stays on the timeline's own clock — the one the overlay drew it at — clipped to the exported length. A cue nothing clipped keeps its own microseconds, so an untouched timeline exports the times the source states, to the millisecond the file is written in. An mp4 says so instead of pretending: tx3g is a different beast and nothing here writes one, so the export card carries a Subtitles row that reads "test_subs.srt → embedded", "mkv only — an mp4 carries none" or "none" before the button is pressed. Exports without a picked track are the files they always were: the track entry and the blocks are written only when there is one.
✨ feat(rate): the project frame rate is a list to pick fromAhmet Kaan Gümüş · d2e25cc
✨ feat(rate): the project frame rate is a list to pick from The panel could only ever read the rate out. Now it opens the rates the way the resolution button opens the sizes -- 23.976 through 60 with the media's own cycled in and the one in force marked -- and picking one conforms the whole timeline to it. PlaybackSession::set_frame_rate maps every frame number on every lane through one Rate (Project::retime), so a take keeps its seconds, its footage and its sync while being counted on the new grid; every source is re-read through a Rate against it and an export comes out at it. The v9 fps line now governs a video-scaffolded project too, so a project cut at 24 reopens at 24 instead of at the media's 30 with every clip number still counted in 24ths.
✨ feat(engine): subtitles come in with the film or beside itAhmet Kaan Gümüş · f4b5fd8
✨ feat(engine): subtitles come in with the film or beside it A subtitle track was a track this engine walked past: the Matroska track walk kept video and audio and dropped type 0x11, and a `.srt` next to the media was a file with no door. Now both arrive as the same thing -- a list of timed cues -- and a project keeps them. `subtitle`: the cue model plus the two ways in. Standalone `.srt`, `.vtt` and `.ass`/`.ssa` go through `oxideav-subtitle` and `oxideav-ass` rather than through a fresh parser here; an embedded track carries its timing on the block and its text in it, so each codec is put back into the shape its own parser reads -- which is what makes an embedded track and the file it was muxed from come back as the same cues. What cannot be read is refused by name and still listed: the four PGS tracks of a BluRay remux are four rows saying they are pictures, not an empty list and not a file that would not open. A `.srt` that has gone missing since the save is the same story, and a re-save keeps its row. `.edith` 10 writes `subtitle <track> <path>` -- the reference only, the cues stay in the file they came from. v9 and every older dialect load as the projects with no subtitles that they are.
✨ feat(mix): every track has its own volume and the mix has a ceilingAhmet Kaan Gümüş · dc7d07d
✨ feat(mix): every track has its own volume and the mix has a ceiling A fader per audio track and one master limiter over the sum of them, both applied where the lanes are added and nowhere else -- so what an export writes is what the room heard, by construction rather than by two call sites agreeing. A track's fader moves everything on it, every frequency: it is not the equalizer (one take, one band) and not the panel's volume (this machine's monitoring, which no file carries). The limiter is lookahead, soft-knee and per sample: the peak of an exported file is a measurement, not a hope, and the hard clamp stays behind it as the backstop. Flat settings are still the bit-exact passthrough: one lane at unity with the limiter off never opens a mixer thread, and an mp4 of such a timeline is still a packet copy. A mixed one re-encodes, and the card says so before the export starts. Both belong to the project, so `.edith` is v9: `fps`, `limiter` and `gain` lines, every older dialect still loading flat. The rate line pays an old debt with it -- a timeline of nothing but stills and songs now comes back at the rate it was cut at instead of the one its scaffold implied. UI: the mix card (f, or an audio track's own header), rows with steppers and hold-to-run arrows, and the track's level on its header.
✨ feat(timeline): a clip goes where you drop it, along its track or across themAhmet Kaan Gümüş · cdb0c4b
✨ feat(timeline): a clip goes where you drop it, along its track or across them A clip dragged along its own lane now lands on the frame the pointer let it go on, and a library row dropped on a lane goes in under the pointer instead of at the playhead. Project::move_to_lane becomes Project::move_clip(from, idx, to, start): the whole group travels the same distance, each half on its own lane, and start is clamped to the gap every member lands in -- a clip butts up against the take next door instead of overwriting it, and the tightest member's wall wins. A drop that changes neither lane nor frame is a click and costs no undo step. The front-end reads the frame under the pointer through the same View the boxes are drawn through, so it lands where it was let go at any zoom, less the offset the hand grabbed the box at, and snaps to a neighbour edge or the playhead within a few pixels.
🔀 merge(T3): mixed frame rates meet mkv HEVC, zero-source survival and the zoomAhmet Kaan Gümüş · 6b5fa2e
🔀 merge(T3): mixed frame rates meet mkv HEVC, zero-source survival and the zoom `main`'s `open_project` now walks every source with the scaffold in its own slot (T6), so the per-source `rates` table is built there frame by frame beside `counts` -- one table in two vectors, grown and shortened together. The codec gate T1 leans on stays; the frame-rate gate is still gone, and a Matroska file shot at another rate imports through the very same door an mp4 does, its rate read off the demuxer's `default_duration`. Grafted from the losing branch, which had the better arithmetic: * `Rate::from_fps` is exact. Built on `mux::frame_timing` -- the pair the muxer already counts an export's frames in -- divided by that pair and reduced, so 24000/1001 over 30 is `800/1001` and stays it however far the timeline runs. The milli-fps rounding it replaces was a frame off after seven hours; that ponytail is gone rather than documented. * A rate no timescale can *name* is an `Err` in `frame_timing`'s own words rather than a silent 1:1, and `matches_timeline` is where a file carrying one is refused -- it hands back the `Rate` it accepted the file at, so the number the refusal was decided on is the number the file plays by. * `file_frames` and `file_rate` ask one `source_of`, so a path that names a length names a rate too. * Five more tests in `tests/mixed_fps.rs`, in timeline frames: the exactness of the NTSC ratio, a trim of an off-rate clip to the room it was dragged to, the neighbouring 30 fps clip still read frame for frame, the linked sound placed at its picture's length, and the exported pictures measured against the file's own frames rather than merely counted. ...and the note the next builder needs in `copy_audio`: a lane holding a clip at another rate stays a packet copy on purpose. A clip counts the *timeline's* frames, so the window the copy trims a source's sound to is whole timeline seconds and the packets are already in sync; re-encoding it would buy nothing and cost a generation of loss. A speed is different, and still refused there.
2026-08-10
✨ feat(timeline): a clip shot at another rate plays at the speed it was shot atAhmet Kaan Gümüş · 26af1e4
✨ feat(timeline): a clip shot at another rate plays at the speed it was shot at A frame rate of its own is no longer a refusal at import. Every frame number in the edit list counts the *timeline's* frames -- a clip's in/out included -- and a file shot at another rate is converted once, at the decoder's door: `Rate` (milli-fps rational, `Speed`'s floor/ceil pair) says which frame of the file a timeline-rate frame is. Playback opens its worker through it and stamps the pictures coming back through its inverse; the export walks its span through it after the speed, so a 2x 24 fps clip on a 30 fps timeline is exactly both. Nothing in `project.rs` changed: placement, trim, split, paste and speed are the same arithmetic on one clock, and a single-rate project takes the identity map everywhere it used to take nothing. A library row now names the *file's* rate rather than the timeline's, which was true only while every source shared it.
🔀 merge(T6): the last media leaves, and nothing assumes source 0 stayedAhmet Kaan Gümüş · 7e4ead7
🔀 merge(T6): the last media leaves, and nothing assumes source 0 stayed Both sides kept: the library-removal slice (a project may name no file, the audio reference is never a still, the clipboard follows its file down the list, a silence edit drops the selection) and main's EQ audio export, image left-trim, track removal, volume slider, hold-repeat and EQ spectrum. The one textual conflict was the test import list; close_session now also drops the gestures and caches those slices added.
🐛 fix(library): the last media leaves and nothing assumes it stayedAhmet Kaan Gümüş · 96c9fbeBrowse files
🐛 fix(timeline): a still stretches out from its left edge like its rightAhmet Kaan Gümüş · bbc3499Browse files
✨ feat(timeline): a jumpcut reaches as far as you tell it toAhmet Kaan Gümüş · 88fbed0
✨ feat(timeline): a jumpcut reaches as far as you tell it to A ripple used to be the whole timeline's business. It is a choice now: the card's first row says whether an apply reaches this take (its picture and its sound), this track alone, or every track -- and a track nobody named does not move, which is how a podcast track loses its silences while the music under it stays where it was. The engine takes an arbitrary set of lanes, not a kind or a range, so what "selected" means stays the front-end's business. It refuses, by name, a scope that would take one half of a take with it rather than quietly widening to the other half: widening would edit a track the user did not name, which is the surprise scoping exists to end. Naming the take is a row, and detaching is the other answer -- the refusal says both. The notice names what it reached: "5 SILENCES CUT on A1 — other tracks untouched".
🐛 fix(timeline): a silence refusal names the file and the frame it meansAhmet Kaan Gümüş · 564ba30
🐛 fix(timeline): a silence refusal names the file and the frame it means
A still handed to the silence card answered in the mp4 demuxer's words
("a box with a larger size than it"), which is true of a container and
useless to a person: a picture has no sound for the same reason a silent
video has none, so it is refused in the same sentence, by name.
And a rate that cannot be cut at the *end* of a silence said the start
instead -- a frame the cut would have been fine at, and the wrong place to
send anyone looking.✨ feat(timeline): silences are cut out or played fast in one pressAhmet Kaan Gümüş · d4ac3fc
✨ feat(timeline): silences are cut out or played fast in one press A scan of the selected clip's own sound (RMS dBFS over 20 ms windows, off the decode path the waveform already takes) marks every silence on the lane before anything moves; `enter` cuts them all out with a ripple, `f` plays them at 4x with the room they no longer need closed behind them. Either way it is one edit and one undo press, however many it found. Four numbers, all keyboard-driven from the card: the threshold, the quiet short enough to forgive, the padding kept either side of speech, and the kept sliver short enough to swallow -- the last of which is what stops a breath between two silences surviving as one-frame confetti. `set_speed` does not ripple, so speed mode closes the gaps itself; a clip on another lane lapping over a silence is refused by name, because the lanes would shrink by different amounts. A source with no audio track at all is refused by name too rather than read as one long silence. Output is ordinary clips: `.edith` stays v8.
🐛 fix(timeline): a hole punched into a slow clip leaves no overlapAhmet Kaan Gümüş · c892972
🐛 fix(timeline): a hole punched into a slow clip leaves no overlap `place` punches a hole with `clear`, and `clear` handed the remainder whatever source range rounding produced. At a quarter speed one source frame *is* four timeline frames, so a punch three frames into such a clip left a head that reached past the hole and overlapped what was placed -- the lane invariant, broken by the one edit that is allowed to overwrite. `Speed::fit` now answers `None` for a room nothing fits in and both remainders go through it: no fit, no remainder. The sweep that found it found a second of the same shape. `set_speed` put one rate on a whole linked group without asking whether the group still covered one span: two halves of *different source lengths* can occupy the same frames at 4x (rounding collapses neighbouring lengths onto one footprint) and re-rating them pulls the halves apart, which is a project that will not load again. Refused by name now, like the collision is. The trim walls move with it: one frame of clip always survives, and at a rate below real time one frame of clip is several frames of timeline (`Speed::room`). A trim that cannot fit refuses before it snapshots rather than writing a range wider than its room. Both fuzz sweeps go to 2000 seeds -- 200 walked straight past this, and a sweep this cheap has no business being the narrow one -- and place now lands speeded clips over speeded clips on purpose. Falsified: with the guard removed, `place`'s own `sorted_disjoint` assert fires. Grafted from the rival build of this feature, which the judge preferred on these three points: - floor/ceil pairing on `Speed`: `source_at` (floor) is what an export encodes, `timeline_at` (ceil) is the stamp playback puts on a decoded frame, and the pair makes the frame the pump is holding *exactly* the frame the export writes, at every rate (`speed_maps_both_ways`, 3751 speeds). The floor/floor this had put the preview a whole held frame off the export at slow rates. - the picture now **honours** a rate: the export walk takes the source frame each timeline frame shows and encodes a held one again rather than decoding it twice. `Span::source_len` reads the last shown frame's own source frame and not one more. - the refusal narrows to the mp4's *copied audio lane* only. AV1 has no audio to copy and honours a speeded take whole; WAV and FLAC always did. EVIDENCE: a mixed-rate mp4 (2x then 1x on one lane) reopens as 135 frames at 30 fps and its bright frames are exactly [15, 16, 75, 76, 77, 78] -- the fixture's four-frame flash halved inside the fast clip, whole inside the slow one -- read back both by the engine's own decoder and by ffmpeg.
✨ feat(timeline): clips play at a speed of their ownAhmet Kaan Gümüş · f8effe8
✨ feat(timeline): clips play at a speed of their own A clip gains a rate (`Speed`, thousandths of real time, 0.25x to 4x) and every speed question is answered at the mapping seams that were already there: `Clip::frames` is the source range divided by the rate, `end` is built on it, and `map`/`span_at`/`composite_span_at` walk the offset through `Speed::source_at`. `in_frame`/`out_frame` stay *source* frames, so a trim and a split still address the file. The picture needs no new decoder: the span says how many source frames it reads, and `try_frame` brings the decoder's numbers back through the same rate -- at 2x two decoded frames land on one timeline frame and the display's drop-when-behind policy takes it from there. The sound is resampled per segment inside the worker playback and the audio export already share (linear interpolation, carried across packet seams), so the pitch moves with the rate: tape, not pitch-preserve, and the card says so. Each segment is told how much timeline it owes and pads or trims to it, which is what keeps a run of speeded cuts from drifting. Rounding is where a rate could break the lane, so it does not: `Speed::fit` never hands a trim more source than its room holds, and `Speed::split_at` refuses a cut a slow clip's rate cannot address rather than leaving two halves that no longer add up. The fuzz sweeps set_speed in with the rest. - card in the eq/colour pattern, on `j` and in the clip menu; a drag is one undo step for the whole linked group, 1.00x reachable by hand and by `r` - clip boxes carry a "2.00x" mark, and their width, waveform and details row are the timeline length - WAV/FLAC honour it; mp4 and AV1 *refuse* by name -- that path copies AAC packets and a resample is not a copy (ponytail names the upgrade path) - .edith v8 carries the rate; v7 and older load at 1.00x - `assets/test_speed_sync.mp4`: one flash, one beep, same instant. At 2x they still land together, to the frame.
🐛 fix(timeline): a pasted still never lands on the audio laneAhmet Kaan Gümüş · b586b85
🐛 fix(timeline): a pasted still never lands on the audio lane `Project::paste` routed by `is_audio` alone, so a *copied* still clip -- the one door that does not go through `place_stream_at` -- was pasted as a grouped take across `V1` and `A1`. The A1 half is a PNG the audio worker demuxes: "file contains a box with a larger size than it", which silences the whole session rather than that clip, and the save it writes is one `open_project` then refuses by name. An `is_image` arm mirrors the audio-only one. Same-shape sweep of every clip-level door that routes by source kind: - `Project::paste` (project.rs) -- this defect, fixed. - `PlaybackSession::place_stream_at` -- already routed, image arm returns on the video lane before the audio fork. - `PlaybackSession::open`/`open_project` -- both directions refused by name at load. - `Project::move_to_lane` -- refuses a move across kinds, so no clip can cross by drag. Clean. - `Project::place`, `split`, `regroup`, `lift`, `delete_in`, `trim` -- the caller names the lane or the lane never changes. Clean, and the loader is the backstop for a hand-written file either way. - `Player::insert_source` (app) -- guarded both ways already. Falsification: with the `(_, true) => &[LaneKind::Video]` arm removed the new test fails at the lane count (A1 1 -> 2), and with that assertion lifted it fails on the WAV export with the demux error above -- the two consequences the test names, both reachable. Two doc corrections found with it: `Still::open` now says alpha is dropped by `to_rgb8` (a transparent PNG lands opaque, with the blend as the ponytail), and `first_audio_of` no longer implies an image-first timeline accepts a later audio import -- it widens which source is asked, not what "the timeline is silent" means. tests: images 7/7 (new `pasting_a_copied_still_never_reaches_the_audio_lane` asserts no A1 clip, no audio clip from a picture, the WAV export still carries the sound, and the save reopens), engine lib 155, saveload 12, audio_files 16, lanes 5 (serial), bin 56.
🔀 merge(main): library row menu meets the edge-trim source lengthsAhmet Kaan Gümüş · 5f60e19
🔀 merge(main): library row menu meets the edge-trim source lengths Both sides appended a test at the same place in the app suite; both kept. Seam: `PlaybackSession::counts` (the per-source frame lengths a trim is walled by) is indexed exactly as `sources` is, and `remove_source` is the one thing that shortens that list -- so it takes the matching count out too. Left behind, the gone file's length walled the survivor and the next import landed its count one index late, tripping `note_frames`'s alignment assert.
🔀 merge(main): detach and group beside the colour drag and the edge trimAhmet Kaan Gümüş · 7cce619
🔀 merge(main): detach and group beside the colour drag and the edge trim The one conflict is the test module's import list: both sides added names to it, so the resolution is the union of the two.
🔀 merge(main): edge trim beside the colour drag on the root carriersAhmet Kaan Gümüş · dcd2d0f
🔀 merge(main): edge trim beside the colour drag on the root carriers Both features hang a drag off the root's mouse-move and mouse-up, which is where they collided. Kept both, in press-target order: equalizer, trim, colour, scrub. They cannot overlap -- a gesture belongs to whatever was pressed, and no two of those hitboxes are the same element.