Epic 2.5.1: basis for framing layer
This commit is contained in:
@@ -99,6 +99,14 @@ export function setFrameUniforms(layer, renderer, target, ctx) {
|
||||
else u[name].value = v;
|
||||
}
|
||||
|
||||
// Framing is per shot and wins over the personality's neutral defaults —
|
||||
// it is the operator's hand on a shot that is already set up, not a trait
|
||||
// of the track. See look/framing.js.
|
||||
if (layer.framing) {
|
||||
u.u_sigFrameScale.value = layer.framing.scale;
|
||||
u.u_sigFrameShift.value.set(layer.framing.shift[0], layer.framing.shift[1]);
|
||||
}
|
||||
|
||||
u.u_prev.value = prevTexture || null;
|
||||
u.u_hasPrev.value = prevTexture ? 1 : 0;
|
||||
}
|
||||
@@ -136,6 +144,16 @@ export class Layer {
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* This shot's FRAMING — a per-shot scale/recentre pushed by the arc driver,
|
||||
* applied inside sigCamera. A layer that is never framed renders at the
|
||||
* neutral (full-frame) scale, so nothing predating framing changes.
|
||||
*/
|
||||
setFraming(framing) {
|
||||
this.framing = framing || null;
|
||||
return this;
|
||||
}
|
||||
|
||||
/** Resolve base params + reactive modulation into the values used this frame. */
|
||||
resolveParams(features) {
|
||||
const defs = this.module.params || {};
|
||||
|
||||
Reference in New Issue
Block a user