Export frame - #46
Conversation
Introduce optional exportFrame crop in project.json so the composition canvas can differ from delivery size. Preview shows a dimmed overscan overlay with a draggable frame handle, aspect presets in the monitor, and Fast export crops JPEGs to the frame. Realtime export is disabled while a frame is set.
Move the caption inside the crop, add edge drag strips, and fix handle vertical alignment with 0.8/1/0.9 opacity states for normal, hover, and active drag.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
🚧 Files skipped from review as they are similar to previous changes (3)
📝 WalkthroughWalkthroughAdded optional ChangesExport frame reframing
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant User
participant ProgramMonitor
participant ProjectModel
participant ExportSetup
participant FastExport
User->>ProgramMonitor: Select or drag export frame
ProgramMonitor->>ProjectModel: Update project.exportFrame
ProjectModel->>ExportSetup: Provide active crop
ExportSetup->>FastExport: Update export engine state
FastExport->>FastExport: Encode cropped preview JPEG
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@app.js`:
- Around line 5984-5996: Make manual export-frame repositioning
keyboard-operable by adding keyboard movement handling alongside the pointer
logic in app.js around the export-frame drag setup, updating and persisting
project.exportFrame with accessible, predictable step behavior. In index.html
around the existing export-frame UI, add or expose a focusable framing control
with appropriate accessible labels; apply the requested changes in both app.js
(lines 5984-5996) and index.html (lines 93-100).
- Around line 5713-5718: Update the active export-frame toggle branch around
state.exportFrameView so it only hides the overlay by setting
state.exportFrameView to false. Remove the project.exportFrame = null
assignment, while preserving syncExportFrameSel, updateMonitorRes, and
scheduleSave so the crop remains applied until “Full canvas” is explicitly
selected.
In `@CLAUDE.md`:
- Around line 157-160: Update the documented exportFrame example to use an
in-bounds 9:16 rectangle, such as x=405, y=0, w=405, h=720, within the 1280×720
canvas; keep the surrounding crop and coordinate guidance unchanged.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: a2ae3019-37aa-4a81-908c-6cb177b97096
📒 Files selected for processing (6)
CLAUDE.mdREADME.mdapp.jsindex.htmlmcp-server.jsstyle.css
What does this PR do?
This is a proposal, as rendering is affected (the one called "realtime" - it is disabled while frame is active).
Quite often the footage is, for example, horizontal, but a vertical reel must be produced. Abstracting out the video reframing done externally, for the manual process now one can set a project to 16x9, with a cropping frame 9x16. On ffmpeg export, this will be preserved. While making a composition (by a human), it is quite easy to manualy frame the source horizontal video, as it is visible, but dimmed ouside the frame area.
Type of change
How was it verified?
node --check server.js && node --check app.js && node --check mcp-server.jspassesCLAUDE.md/README.mdif the schema, props, or API changedChecklist
Summary by CodeRabbit