Timeline: Puppet pin keyframes show in the Timeline (#273)
Moving a puppet pin keys its Position, but the Timeline didn't show those keys where people look for them. U revealed every pin's Position as one more flat "Position" row under the layer, indistinguishable from the layer's own Position and from each other, and the reveal was a snapshot: a pin placed or moved after U (or with the layer twirled open and Effects closed) got keys that no row showed. As in After Effects, revealed properties inside an effect now show under the effect and its groups (Puppet > Mesh 1 > Deform > Puppet Pin 1 > Position), twirled open by the reveal and closable like any group; Transform and mask properties stay as they were. Placing, moving or recording a pin in the viewer keeps its Position in view: on a twirled-open layer its groups open, and a U reveal takes it in. A collapsed layer stays collapsed. The keys select, move and delete like any others. Test: puppet_pin_keys_show_under_their_pins_in_the_timeline, placing_a_pin_opens_its_groups_on_a_twirled_open_layer (ui_viewer). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
fbc4080f53
commit
285297ed93
@@ -1456,10 +1456,16 @@ pub fn show(app: &mut EffectcraftApp, ui: &mut egui::Ui, rect: Rect) {
|
||||
Gesture::PuppetRecord { layer, pin, others, cti, samples, .. } => {
|
||||
let pts: Vec<serde_json::Value> = samples.iter().map(|(t, p)| json!([t, p[0], p[1]])).collect();
|
||||
let q = json!({"layer": layer.0, "pin": pin, "pins": others, "samples": pts, "start": cti.seconds()});
|
||||
if let Err(e) = app.session.execute("puppet.recordPin", q) {
|
||||
app.ui.status = e.to_string();
|
||||
match app.session.execute("puppet.recordPin", q) {
|
||||
Ok(_) => {
|
||||
for p in std::iter::once(pin).chain(others) {
|
||||
super::puppet_tool::reveal_pin(app, layer, p);
|
||||
}
|
||||
}
|
||||
Err(e) => app.ui.status = e.to_string(),
|
||||
}
|
||||
}
|
||||
Gesture::PuppetPin { layer, pin, .. } => super::puppet_tool::reveal_pin(app, layer, pin),
|
||||
Gesture::Create { tool, start } => {
|
||||
let end = map.to_comp(pos);
|
||||
create_shape(app, tool, start, end, mods.shift);
|
||||
@@ -1555,9 +1561,13 @@ pub fn show(app: &mut EffectcraftApp, ui: &mut egui::Ui, rect: Rect) {
|
||||
&& let Some(inv) = l2c(&ectx, l).0.inverse()
|
||||
{
|
||||
let lp = inv.apply(gv2(cpt[0], cpt[1]));
|
||||
let r = app.session.execute("puppet.addPin", json!({"layer": l.id.0, "kind": t.puppet_kind(), "position": [lp.x, lp.y]}));
|
||||
if let Err(e) = r {
|
||||
app.ui.status = e.to_string();
|
||||
match app.session.execute("puppet.addPin", json!({"layer": l.id.0, "kind": t.puppet_kind(), "position": [lp.x, lp.y]})) {
|
||||
Ok(r) => {
|
||||
if let Some(pin) = r["pin"].as_u64() {
|
||||
super::puppet_tool::reveal_pin(app, l.id, pin);
|
||||
}
|
||||
}
|
||||
Err(e) => app.ui.status = e.to_string(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user