Commit Graph
385 Commits
Author SHA1 Message Date
FredAppsandFredrik Hallin 143a8357da Keep layer property targets when duplicating compositions (#4229)
* Preserve layer-valued properties when duplicating a composition

* Keep explicit no-layer values while remapping duplicate targets

---------

Co-authored-by: Fredrik Hallin <fredrik.hallin@guidelinegeo.com>
2026-11-28 10:10:16 +01:00
ebc1d0076b Preserve frozen Object Matte data on project import (#4126)
* Preserve frozen Object Matte data on project import

* Discard frozen mattes when import changes a nested source

* Verify frozen matte media and layer inputs on import

---------

Co-authored-by: ViktorBystrov72 <18964918+ViktorBystrov72@users.noreply.github.com>
Co-authored-by: Fredrik Hallin <fredrik.hallin@guidelinegeo.com>
2026-11-28 09:18:25 +01:00
Anubhav-Rai ffc0ad89da Reduce Project and Remove Unused Footage keep the media an Essential Graphics override shows (#4129) (#4164) 2026-11-28 07:55:33 +01:00
FredApps 995039c7aa Merge branch 'main' into feat/import-photocraft 2026-11-26 17:17:26 +01:00
FredApps 6969ca541d Merge branch 'main' into issue-1963 2026-11-26 16:42:30 +01:00
FredApps 52b1d18833 Merge branch 'main' into camera-tools-2586 2026-11-26 16:07:34 +01:00
FredApps c1758a2667 Merge branch 'main' into export-log-phases-3713 2026-11-26 15:30:33 +01:00
FredApps ac45c3fe9e Merge branch 'main' into paste-text-style-3901 2026-11-26 15:03:43 +01:00
FredApps d56f2d058f Merge branch 'main' into fix/issue-3808-interpret-footage-target 2026-11-26 13:18:53 +01:00
FredApps 8d9aaf1055 Reconcile PhotoCraft import with current EffectCraft dependencies 2026-11-26 08:54:52 +01:00
dotCooCoo 99c7e172b0 Import: show PhotoCraft composition notes as a notice, not an error
The notes about a PhotoCraft composition that was already added now go
to the window as one non-error notice. With several compositions the
notice leads with the first note and a count of the rest, and the
finished import's toast repeats the notes. Both command results keep
the warnings as before.
2026-11-24 09:12:14 -08:00
dotCooCoo 681b2c7468 Import: report PhotoCraft composition notes as warnings
A PhotoCraft document that imports as a composition now returns its
notes in the result's `warnings` instead of `errors`, so a successful
import no longer reports a failure. With `background`, the notes are
shown and returned when the job starts, since the composition stays in
the project when the footage job is canceled.
2026-11-24 00:29:17 -08:00
Valentin KleinandFredApps 29d116c6f7 Convert To Bezier Path works on a selected shape layer or group, for example right after drawing a rectangle (#3220)
* #3057: Convert To Bezier Path converts a selected shape layer's or group's parametric paths

Right after drawing with the Rectangle, Ellipse or Polygon tool only the layer is selected,
and Convert To Bezier Path fell through to the mask branch and reported "no masks". It only
converted when the parametric path row itself (Rectangle Path 1) was selected.

- A selected shape group converts the parametric paths inside it, nested groups included.
- With only layers selected, a shape layer converts its parametric paths, as a selected
  layer's masks are targeted. Locked layers are skipped; animated parametric paths are left
  alone and reported (skippedAnimated), and selecting the path still converts it.
- Masks win only when targeted (mask param, selected mask, mask vertices) or when one uses
  RotoBezier: plain masks no longer turn the command into a silent no-op.
- An explicit layer/layers limits selected shape items to those layers; an unmatched mask
  param is an error instead of converting every path.
- Errors say what to select instead of asking for masks.

A PSD shape layer importing as a layer with a mask matches After Effects; no change there.

Fixes #3057

* #3057: Convert To Bezier Path converts a layer named twice once

A layer given twice in `layers` (by id and by name) was widened twice: its parametric paths were queued twice, and the second replacement found no such item, so the whole command failed. The layer list is deduplicated before the widening, which also keeps skippedAnimated from counting a path twice.

* #3057: Convert To Bezier Path leaves locked layers and a group's animated paths alone

Shape items given as `items` or selected on a locked layer converted anyway (only the layer-wide conversion checked locks); they now go through unlocked(), an error when every one is locked. A selected group skips its keyframed or expression-driven parametric paths and reports them in skippedAnimated, as converting a whole layer does; a path selected itself still converts at the current time.

* Doc comments for the functions this PR touches

* #3057: Convert To Bezier Path gives an explicit mask priority over shape items

With a `mask` given, a selected parametric path (or `items`) was converted instead of the mask, an unmatched `mask` converted the shape rather than reporting the miss, and a locked shape-item layer could reject the call before the mask was looked at. Shape items are now ignored when `mask` is present.

* #3057: Convert To Bezier Path converts a selected mask with the selected shape paths

With a mask and a parametric path both selected, only the path converted and the mask kept its RotoBezier tangents. Masks the selection targets (a selected mask or its property, mask vertices, on unlocked layers in scope) now convert in the same undo step, the result reports them as masks, and they stay selected with the new paths. An explicit `mask` keeps its priority.

* #3057: Convert To Bezier Path keeps mask conversion to an explicit layer

With `{"layer": A}` and a RotoBezier mask selected on layer B, the mask branch converted B's mask and left A unchanged. The resolved masks are now scoped to the explicit layer/layers (falling back to those layers' own masks), the priority check only counts selected masks and vertices in scope, and the scoped targets are edited directly instead of being resolved again.

* #3057: Convert To Bezier Path leaves masks on locked layers alone

A scoped or selected RotoBezier mask on a locked layer was converted through the mask branch. Masks on locked layers are now dropped after the scope and its fallback are resolved, so a locked selected mask does not hand the conversion to other masks; when every targeted mask is locked, the command reports the lock, as it does for shape items.

* #3057: Convert To Bezier Path converts in the composition `comp` names

With `comp` naming a composition that is not active, an explicit `mask` was resolved there but filtered against the active composition ("no mask matches"), and explicit `items` were looked up in the active composition. convert_to_bezier now works in the composition comp_id resolves, and selected_shape_items returns the composition layer_p resolved for explicit items (also used by Group and Ungroup Shapes); a selection made in another composition does not apply.

* Convert To Bezier Path: explicit items add no selected masks

With explicit `items`, only those shape paths convert. A RotoBezier mask
selected on the same layer no longer loses its RotoBezier flag as a side
effect. Regression test added.

* Convert To Bezier Path: explicit items without a parametric path convert no mask

* Convert To Bezier Path: items count as given only as a list

---------

Co-authored-by: FredApps <153173854+FredApps@users.noreply.github.com>
2026-11-23 02:31:15 +07:00
Valentin Klein 525dcfc0d8 Browse… buttons in a script's own dialogs and panels open the file dialog instead of doing nothing (#3253)
* Scripts: a ScriptUI Browse… button opens the file dialog

Fixes #2778.
Fixes #2894.

File.openDialog, File.saveDialog, Folder.selectDialog and the instance
openDlg / saveDlg / selectDlg were stubs that returned null, so a script
dialog's or a dockable ScriptUI panel's Browse… button did nothing.

On a script-host thread, in an app that shows them, the script now asks
for the dialog (Session::script_ui.file_dialogs, each with an id), hands
the session back like a modal dialog's show() does and waits for the
answer: a File (an array with multiSelect), a Folder, or null when
cancelled. The script's filter becomes the dialog's (its name, "All Files"
for *.*); without extensions every file shows. Headless runs, the Script
Console, the web and Shutdown scripts get null at once.

The app shows the dialog after the pass's events: blocking on Windows
(Hooks::pick_file_dialog), without blocking on macOS and Linux, one at a
time; a non-blocking dialog that ends without answering counts as
cancelled. scriptui.fileDialogs lists the waiting dialogs and
scriptui.fileDialog answers one (refused while file access is confined,
and refused to scripts). A dialog leaves the list only when its script
has the answer; the script's windows refuse events meanwhile, except
scriptui.close, which cancels the file dialog first. A script host that
ends takes its dialogs with it.

* Scripts: carry a file dialog's prompt, start location and filter to the native dialog (#2778)

serve_file_dialogs collected the script's prompt, start folder and save filter
but dropped them at the host boundary. FileDialog::Script now carries prompt and
start, and new ScriptFolder and ScriptSave requests carry the folder dialog's
prompt/start and the save dialog's prompt and whole filter (label, extensions,
any file) instead of the default name's extension. Both the blocking and the
non-blocking host dialogs apply title, initial directory and filters; Save also
goes through the blocking hook where one is set. Hook-level regression test
asserts all three requests.

* Scripts: a hidden window paints so a script's file dialog is shown (#3253 review)

* Scripts: formatting (#3253)
2026-11-22 12:58:56 -06:00
dotCooCoo f5bbbd2d64 Merge main into feat/import-photocraft 2026-11-19 07:28:11 -08:00
vangel76 98ada1e8ff Watch Folder renders take the host's memory budget; docs and test comment (#3941 review) 2026-11-19 10:37:00 +01:00
vangel76 0d9c69563f Exports, the Render Queue and command-line renders use the memory budget (#3941)
The command-line tool reads the system's memory once at start, so its caches
share the budget of the installed RAM instead of the budget for unknown RAM.
A Render Queue run's two layer caches and a one-off export's own caches take
the session's layer cache budget instead of a fixed 512 MiB; they are in the
memory accountant, which keeps them within the common budget together with the
other caches. In the browser each gets half the layer cache's cap.
2026-11-19 10:29:54 +01:00
vangel76 5d27d1377c #3901: pasted Source Text keyframes keep their style
Pasting a copied Source Text keyframe (keys.paste, Paste Reversed) or a
copied unanimated Source Text value (Edit > Copy / Paste) went through the
value's JSON form, which is the characters only, so the pasted key took the
font, size and colours of the property's current value. A copied text value
now pastes as the whole document; every other kind is pasted as before.
2026-11-18 16:21:47 +01:00
vangel76 3641cb38a8 Merge remote-tracking branch 'upstream/main' into export-log-phases-3713
# Conflicts:
#	crates/export/src/lib.rs
#	crates/export/src/webm.rs
#	crates/export/src/webm_av1.rs
2026-11-18 12:54:29 +01:00
Christopher Linnett 337a6ba677 #3808: Interpret Footage keeps main's results for targets that aren't footage
`file.interpretFootage` resolves its items as before and skips what isn't
footage, so an explicit missing id, composition or solid succeeds and
changes nothing again, and a script setting a solid's
mainSource.conformFrameRate doesn't throw. The dialog still opens on the
first item `interpretation_targets` gives, which is the first footage the
command changes, and opens no dialog when that is none.

Tests pin Main's result for those targets, Proxy's existing error, and
the script setter on a solid.
2026-11-18 00:07:03 +08:00
Christopher Linnett 5af43b67b5 #3808: Interpret Footage: the dialog shows the footage the command will change
Opened with `item`/`items` (an agent's `ui.menu.invoke`), the Interpret
Footage dialog filled its fields from the Project selection while OK ran
the command on the named item, so that item took another footage's
interpretation. The dialog and the commands now share one target
resolution, `commands::interpretation_targets`: `items`, else `item`,
else the selection, keeping footage (for Proxy, items with a proxy). The
dialog shows its first item.

A named item that is missing, not footage or (Proxy) without a proxy
opens no dialog: the command runs and reports that there is nothing to
interpret, as Proxy already did. Interpret Footage used to accept such
ids and change nothing. Use Proxy and the proxy commands' enablement
share the "has a proxy" filter.
2026-11-17 22:36:17 +08:00
vangel76 c205773d92 Caching: memory is counted where it is held, and whole layers stay whole under a viewer region (#3301 review)
- The memory accountant is offered only layer buffers and preview frames nobody
  else holds, so what it counts as freed is freed; the frame cache's recycled
  buffers count and go first.
- A Cryptomatte plane over the matte cache's own limit is kept only where the
  common budget trims it.
- Disk cache entries read back take their buffers fallibly: memory the system
  can't give is a miss.
- The Layer panel, sampleImage and effect inputs read whole footage frames under
  a viewer region of interest.
- A 16K Cryptomatte source at half resolution is box-filtered, not looked up
  nearest-neighbour.
- The System Compatibility Report shows the cache budget in force.
- A Project panel thumbnail render never starts under a key held back from an
  earlier state.
- Convert Expression to Keyframes makes no keys on a property that can't be
  animated.
2026-11-17 11:09:13 +01:00
vangel76 9ff031c5f1 Merge upstream/main into the plane store branch (#3301)
Conflicts: Cargo manifests (craft-libs pins from main, plus memory-stats, exr and
half for effectcraft-media), exr_channels.rs (the plane store's version; main's
craft-exr channel decode is replaced by the plane store until craft-exr reads
from a seekable source), pool.rs (frame_px takes the rows of #3271 and the
forget generation of #2042), session open/forget (main's forget_files plus the
reload counter), Project panel thumbnails (main's Thumb types, keyed by content).
2026-11-16 20:57:45 +01:00
dotCooCoo e1c8fb745e Merge main into feat/import-photocraft 2026-11-16 00:52:37 -08:00
vangel76 f4a8c88349 Merge upstream/main into cache-defaults-3298 2026-11-15 20:28:43 +01:00
Dylan M. Taylor 8fdbbc604c Refresh shared dotLottie cutover and propagate archive errors 2026-11-15 10:24:25 -05:00
dotCooCoo 160c73f16f Merge main into feat/import-photocraft 2026-11-15 06:08:47 -08:00
vangel76 9fe7f5d5b6 Export log shows where the time went: render, encode, write
When an export or Render Queue job ends, the render log (and the
effectcraft_export log target) gets one summary line: wall time, busy time
of rendering, the encoder and writing the file (they overlap, so not a sum),
the compositor and why, the encoder and its settings, and frames per second.
Formats that cannot time a stage apart say so. effectcraft-cli render --json
returns it as timing and timingSummary.

#3713
2026-11-15 13:21:42 +01:00
.CooCoo d6c9ad6643 Cineon Converter: Gamma 1 gives linear output and saved projects keep their render (#2312)
## Behavior

A new Cineon Converter opens with Gamma 1.7. Its Version parameter is 2 by default. A converter saved before Version existed opens as version 1, retaining its Gamma value, keyframes, and expression text and rendering on its original scale. Reset keeps the instance's Version.

In version 2:

- Log to Linear raises the exposure to `1 / gamma` before subtracting the black offset and normalizing: `(E^(1/g) - O^(1/g)) / (1 - O^(1/g))`, with `E = 10^((code - white) * 0.002 / 0.6)` and `O` the exposure at the black point. Gamma 1 gives linear output, and a larger Gamma lightens the midtones. Highlight Rolloff then applies as before, and Linear to Log is the inverse.
- Log to Log returns code values unchanged at Gamma 1 and raises the normalized code value to `1 / gamma` at other values. With custom black or white points, the code values first go through the Gamma 1 conversion.

The CPU and GPU paths match. Version 1 instances render as before, and Interpret Footage ▸ Cineon Settings keeps its existing formula, which agrees with the version 2 Converter at Gamma 1.

The public Cineon Converter documentation (https://helpx.adobe.com/after-effects/using/utility-effects.html) describes Gamma as a midtone control and gives no defaults or formula. The default, the Log to Linear curve and the Log to Log behavior come from running and scripting After Effects 26.5 on my own machine and reading back the rendered pixels. In After Effects, choosing Log to Log also sets Gamma to 1 and Highlight Rolloff to 0; EffectCraft does not do that yet, because no command sets one parameter from another.

Animation preset format 3 records `cineonVersion` for a saved Gamma property and stores effect key times relative to the first key. Presets in formats 1 and 2 without that tag contain version 1 Gamma values; format 2 already has relative effect key times. Applying a whole old Cineon Converter also gives it version 1. Exposed Essential Properties Gamma values convert to the target converter version where their target is unambiguous (the conversion keeps the linear point; other Gamma values follow each version's own curve); enabled expressions on another scale are skipped instead of rewriting their source.

A saved Gamma records the Version its converter has at the current time. Applied to a converter whose Version is keyframed, a Gamma preset keeps those keys: the Gamma is converted to the one version they hold, or skipped when they hold several or an expression sets the Version. A preset that also holds the Version sets it from that property.

The project schema remains 2. `docs/architecture.md` describes the behavior above.

## Validation

Effect tests check version 2 Log to Linear at Gamma 1.7 (codes 95 to 685) and Gamma 2.2 (codes 180 to 620), and Log to Log at Gamma 1 (Rolloff 0 and 20) and Gamma 1.7, against the measured 8-bit values within one or two codes, plus round trips, version 1 rendering and the Interpret Footage agreement at Gamma 1. GPU tests compare the version 2 paths with the CPU. Engine tests cover old projects, Reset, presets, keyframes, and Essential Properties.

Commands run on `74d398c2`:

- `cargo fmt --all -- --check`
- `cargo clippy -p effectcraft-effects -p effectcraft-gpu -p effectcraft-project -p effectcraft-engine --all-targets -- -D warnings`
- `cargo test -p effectcraft-effects`: 546 passed (including `effects_doc_is_current`, so `docs/effects.md` needs no change), 1 ignored, plus 6
- `cargo test -p effectcraft-project`: 47 passed
- `cargo test -p effectcraft-gpu`: 253 passed, 1 ignored
- `cargo test -p effectcraft-engine`: 1,007 passed, 5 ignored, plus 27
2026-11-15 12:11:07 +01:00
.CooCoo 7cbefaf70f Import: VectorCraft documents import through the PDF they carry (#2901)
* Import: VectorCraft documents import through the PDF they carry

File > Import reads a .vectorcraft file through the PDF that VectorCraft
saves in it with Create PDF-Compatible File, one page per artboard, as
footage or as a composition with one layer per PDF layer. The PDF is read
with craft-doc from craft-libs (plain or compressed files, the PDF inline
or after the JSON). A PDF after the JSON may be as large as a PDF file
EffectCraft imports (512 MiB). A document saved without that option gives
an import error that names it.

craft-doc, craft-vectorcraft-format (tests only) and craft-ecproj-format
are pinned to craft-libs fa1a6574; craft-ecproj-format is unchanged
between ca1b5e2e and that commit.

* Import: show file errors returned by the import dialog

* Keep dropped-file import errors alongside local drop errors

* Import: preserve every file error across background jobs and UI notices

* Import: queue pending errors with bounded notification details

* Import: a damaged VectorCraft preview no longer stops the carried PDF

The importer read every rendition with craft_doc::renditions and then
picked the PDF, so a preview whose base64 was invalid or whose data lay
past the end of the file made the whole import fail. It now reads only
the PDF with craft_doc::rendition, from storytold/craft-libs#546, and
never decodes the preview. A document without a PDF still reports
NoCarriedPdf.

* Import: dismissing a picked import's error status acknowledges its details

A picked or menu import queued its error details with the status
report_import_errors set ("first (and 1 more)"), and show_result_errors
then replaced that status with "first; second". The two never matched,
so clicking the status left the details queued and they showed again.
Import commands now move the queued details to the status that replaces
it, also when After Effects project errors lead it. Other commands'
statuses never take over an import's details.
2026-11-15 03:45:56 -05:00
vangel76 3ad49f8f7b Merge upstream/main into cache-defaults-3298
Conflict in crates/render/src/pipeline.rs: kept both the footage-rows
reader of this branch and the frame-mix span reader from main.
Adapted three menus tests to DialogAnswer.paths now being a Result.
2026-11-14 19:53:16 +01:00
vangel76 1b8fefa0b6 Merge upstream/main into camera-tools-2586 2026-11-14 18:14:13 +01:00
FredApps 38cd374bae Merge pull request #3236 from vangel76/number-field-math-3195
Number fields: typed arithmetic (960/2, (3+4)*2) and a leading *, / or + applied to the value
2026-11-14 17:29:47 +01:00
FredApps 829706de6f Merge pull request #3232 from vangel76/project-drag-new-folder-3196
Project panel: items dropped on New Folder go into a new folder, as After Effects
2026-11-14 17:29:26 +01:00
FredApps 00a4903b5f Merge pull request #3230 from vangel76/script-expression-error-3219
Scripting: expressionError reports evaluation errors, as After Effects
2026-11-14 17:29:06 +01:00
FredApps 5c8e66aa1e Merge pull request #3242 from vangel76/prop-get-footage-3231
Expressions: prop.get and Reveal Expression Errors evaluate with the footage source
2026-11-14 17:28:24 +01:00
vangel76 1ee51f5e2c M2586: camera tool pivot respects solo (scene_layers uses Comp::any_solo like the renderer) 2026-11-14 17:10:47 +01:00
dotCooCoo 3cc6ee2ee1 Merge main into feat/import-photocraft 2026-11-13 04:09:06 -08:00
vangel76 4829a83d30 Merge upstream/main into cache-defaults-3298 2026-11-13 12:39:55 +01:00
Tyler JenningsandFredApps a5ddc93257 Animation presets: preserve text animators and selectors when saving and applying (#3168)
* Text animators: fit one animator to a Per-character 3D setting

* Animation presets: save text animators whole and add them to the target layer (#2530)

* Animation presets: a preset that fits no layer is an error, not silence

* Tests: text animators in animation presets (#2530)

* Fix text preset review edge cases

* Keep existing animators consistent when presets turn 3D off

---------

Co-authored-by: FredApps <FredApps@users.noreply.github.com>
2026-11-13 09:13:02 +01:00
dotCooCoo d0a1724beb Merge main into feat/import-photocraft
# Conflicts:
#	crates/engine/src/cmd/file.rs
2026-11-12 05:21:22 -08:00
arnav-hiwarkar 5b3a469181 #2817: read the selection in place and name the Closed tests for what they prove 2026-11-12 18:36:20 +05:30
arnav-hiwarkar 0ccfd669fb #2817: Closed fits short tangent lists like mask.setClosed 2026-11-12 18:24:01 +05:30
arnav-hiwarkar d7011a36b8 #2817: Closed falls back to the layer's paths when the selection names none
Selecting a non-path property (Position) or a stale selection disabled Closed, unlike
RotoBezier and the other Mask and Shape Path commands, which fall back to every mask of
the selected layers. A selected mask property (Feather, Opacity, Expansion) now selects
its mask. A selected locked mask still counts as a match, so it never falls back to its
unlocked siblings.
2026-11-12 18:22:21 +05:30
arnav-hiwarkar 37b0ea1145 Merge upstream main into fix/issue-2817-open-close-path
# Conflicts:
#	crates/engine/src/cmd/mask.rs
2026-11-12 18:14:02 +05:30
vangel76 dcd46af227 Merge upstream/main into cache-defaults-3298 2026-11-12 12:36:34 +01:00
Dylan M. Taylor 4d6036265b Convert Expression to Keyframes: refuse layers of more than 2^18 frames
* fix(engine): refuse to convert an expression on a layer of more than 2^18 frames

* address review: refuse a non-positive frame duration; count a partial last frame; check every selected layer before converting

* Convert Expression to Keyframes: cap at 2^20 frames (a 3-hour 60 fps comp is 648,000)
2026-11-12 06:29:38 -05:00
Dylan M. Taylor 6e1dd08147 Import: a 3D model's left-out textures reach the user as an import warning
* Import: a model's left-out parts reach the user as an import warning (Model::warnings, Importer::probe_noting)

* Import: a model's left-out parts reach the user as an import warning
2026-11-12 06:29:14 -05:00
dotCooCoo 975b7f0599 Merge main into feat/import-photocraft 2026-11-11 16:16:16 -08:00
vangel76 9924ebb1e0 Merge remote-tracking branch 'upstream/main' into cache-defaults-3298 2026-11-12 00:05:19 +01:00