davinci-resolve-mcp 2.173.0 → 2.175.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +41 -0
- package/README.md +1 -1
- package/README.zh-CN.md +2 -2
- package/docs/reference/api-limitations.md +1 -1
- package/install.py +1 -1
- package/package.json +1 -1
- package/resolve-advanced/server/author-interchange.mjs +20 -0
- package/resolve-advanced/server/editorial.mjs +63 -6
- package/resolve-advanced/server/tools/editorial.mjs +1 -1
- package/src/granular/common.py +1 -1
- package/src/server.py +2 -2
- package/src/utils/api_truth.py +9 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,47 @@
|
|
|
2
2
|
|
|
3
3
|
Release history for the DaVinci Resolve MCP Server. The latest release is summarized in the root README; older entries live here to keep the README focused.
|
|
4
4
|
|
|
5
|
+
## What's New in v2.175.0 — E121: a flattened XML compound is a named hole, not a refusal
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- **An XML turnover with a compound clip refused to conform.** Resolve's FCP7
|
|
10
|
+
writer flattens a compound to ONE clipitem whose `<file>` carries an
|
|
11
|
+
explicitly empty `<pathurl>` and no inner content (measured on 19.1.3.7);
|
|
12
|
+
read as a source reel, `assemble_from_interchange` refused the whole
|
|
13
|
+
turnover as an unmapped reel. The walker now tags such clipitems
|
|
14
|
+
`compound`, and the bridge drops them with a reason in
|
|
15
|
+
`unresolvedCompounds` (name, track, record span) while the rest of the cut
|
|
16
|
+
conforms — unless the sourceMap maps the compound's name to a flattened
|
|
17
|
+
media file, in which case it authors like any clip. The reason points at
|
|
18
|
+
the OTIO export, where compounds keep their inner content and flatten
|
|
19
|
+
(E120).
|
|
20
|
+
- `timeline.get_items` help notes that `generator` also covers Fusion titles
|
|
21
|
+
(Text+ enumerates with no media and no properties, like a generator).
|
|
22
|
+
|
|
23
|
+
## What's New in v2.174.0 — E120: compound clips in Resolve's OTIO exports flatten instead of vanishing
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
|
|
27
|
+
- **A compound clip in an OTIO turnover was silently dropped.** Resolve's
|
|
28
|
+
OTIO writer nests a compound as a `Stack` inside the track — its
|
|
29
|
+
`source_range` is the trim window into the compound, and nested compounds
|
|
30
|
+
nest Stacks recursively (measured on 19.1.3.7 from a depth-2 timeline).
|
|
31
|
+
`parseOTIO` skipped the Stack, so a 96-frame timeline parsed as 48 with no
|
|
32
|
+
error. Nested Stacks now flatten into the parent's record time through
|
|
33
|
+
their trim window (source frames trimmed at each clip's own play rate,
|
|
34
|
+
inner upper tracks landing on the next lanes), each flattened cut tagged
|
|
35
|
+
`fromCompound`, and the bridge's ledger names them
|
|
36
|
+
(`flattenedCompounds`, `flattenedCompoundEvents`). Render-verified: the
|
|
37
|
+
flattened conform of Resolve's own export is luma-identical to the
|
|
38
|
+
original compound render at every sampled frame (three picture regions
|
|
39
|
+
at 123–125, the 24-frame white insert at 234).
|
|
40
|
+
|
|
41
|
+
### Measured (filed in api-limitations)
|
|
42
|
+
|
|
43
|
+
- `EXPORT_FCP_7_XML` flattens a compound to a single media-less clipitem
|
|
44
|
+
named after it, with no inner content; `EXPORT_OTIO` keeps the nesting.
|
|
45
|
+
|
|
5
46
|
## What's New in v2.173.0 — E118: Resolve's own OTIO exports re-conform
|
|
6
47
|
|
|
7
48
|
### Fixed
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
English | [简体中文](README.zh-CN.md)
|
|
4
4
|
|
|
5
|
-
[](https://github.com/samuelgursky/davinci-resolve-mcp/releases)
|
|
6
6
|
[](https://www.npmjs.com/package/davinci-resolve-mcp)
|
|
7
7
|
[](docs/reference/api-coverage.md)
|
|
8
8
|
[-blue.svg)](#server-modes)
|
package/README.zh-CN.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
[English](README.md) | 简体中文
|
|
4
4
|
|
|
5
|
-
[](https://github.com/samuelgursky/davinci-resolve-mcp/releases)
|
|
6
6
|
[](https://www.npmjs.com/package/davinci-resolve-mcp)
|
|
7
7
|
[](docs/reference/api-coverage.md)
|
|
8
8
|
[-blue.svg)](#服务器模式)
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
[](https://www.python.org/downloads/)
|
|
13
13
|
[](https://opensource.org/licenses/MIT)
|
|
14
14
|
|
|
15
|
-
> 本翻译对应 v2.
|
|
15
|
+
> 本翻译对应 v2.175.0 版 README。如与英文原版有出入,以 [英文原版](README.md) 为准。
|
|
16
16
|
|
|
17
17
|
一个 Model Context Protocol (MCP) 服务器,让 AI 助手通过官方脚本 API 控制 DaVinci Resolve Studio(达芬奇)。它提供完整的 API 覆盖,外加带护栏的工作流助手,涵盖剪辑、媒体池整理、渲染设置、审阅标记、调色、Fusion、Fairlight、项目生命周期任务、扩展开发,以及不碰源媒体的媒体分析。
|
|
18
18
|
|
|
@@ -313,7 +313,7 @@ equivalent, blocking full automation.
|
|
|
313
313
|
|
|
314
314
|
- **Object:** `MediaPool`
|
|
315
315
|
- **Signature:** `(filePath.xml) -> Timeline`
|
|
316
|
-
- **Behavior:** Resolve's FCP7 XML importer HONOURS a generatoritem's `fillcolor` parameter (measured on Studio 19.1.3.7, E110): a Premiere-shaped Color Matte (effectid Color, category Matte) and a Solid Color generatoritem, both with <red>/<green>/<blue>/<alpha> 0..255 values, imported as Solid Color items and rendered Y81 U90 V240 (red) and Y41 U240 V110 (blue) — exact BT.601 limited-range values for a 640x360 timeline. EXPORT_FCP_7_XML writes the fillcolor back (same 0..255 channels). EXPORT_DRT carries the colour as a 55-byte <EffectFiltersBA> on the Sm2TiGenerator: 8-byte header (version 2, length 47), a fixed 20-byte prefix, a flag byte, then big-endian uint16 A R G B (0xffff = full) plus a pad word, then a second, black colour record; only the ARGB words differed between the red and blue captures. The default generator has an EMPTY EffectFiltersBA. The same importer does NOT carry a TRANSITION's parameters: a `Dip to Color Dissolve` transitionitem with a white and with a red `color` parameter imported as `Dip To Color Dissolve` elements whose 37-byte EffectFiltersBA were byte-identical (defaults), and the transition rendered inert (luma flat through its window, the E66 law) — the dip colour stays GUI-only on 19.1.3.7 (measured, E111). The writer emits a Solid Color's colour as the FxPlug parameter `input_1` (effectid FxPlugWrapper:C18E8B62_…), not `fillcolor` — an authored EffectFiltersBA colour came back exactly (white, 128/64/191; E112). The OTIO writer CANNOT: EXPORT_OTIO emits a Solid Color as a Clip.2 named 'Solid Color' with a NULL media_reference, metadata {"Resolve_OTIO": {}} and a parameterless Transform effect — no colour anywhere (measured E117) — so only an XML re-export witnesses a generator colour (editorial.verify_roundtrip exportedFormat → generatorColourNotInExport). Such an OTIO export DOES re-conform through drt.assemble_from_interchange (E118): the media-less generator clips walk as black legs and the clip→generator fade renders 124→16 — black, the colour having been lost by the writer.
|
|
316
|
+
- **Behavior:** Resolve's FCP7 XML importer HONOURS a generatoritem's `fillcolor` parameter (measured on Studio 19.1.3.7, E110): a Premiere-shaped Color Matte (effectid Color, category Matte) and a Solid Color generatoritem, both with <red>/<green>/<blue>/<alpha> 0..255 values, imported as Solid Color items and rendered Y81 U90 V240 (red) and Y41 U240 V110 (blue) — exact BT.601 limited-range values for a 640x360 timeline. EXPORT_FCP_7_XML writes the fillcolor back (same 0..255 channels). EXPORT_DRT carries the colour as a 55-byte <EffectFiltersBA> on the Sm2TiGenerator: 8-byte header (version 2, length 47), a fixed 20-byte prefix, a flag byte, then big-endian uint16 A R G B (0xffff = full) plus a pad word, then a second, black colour record; only the ARGB words differed between the red and blue captures. The default generator has an EMPTY EffectFiltersBA. The same importer does NOT carry a TRANSITION's parameters: a `Dip to Color Dissolve` transitionitem with a white and with a red `color` parameter imported as `Dip To Color Dissolve` elements whose 37-byte EffectFiltersBA were byte-identical (defaults), and the transition rendered inert (luma flat through its window, the E66 law) — the dip colour stays GUI-only on 19.1.3.7 (measured, E111). The writer emits a Solid Color's colour as the FxPlug parameter `input_1` (effectid FxPlugWrapper:C18E8B62_…), not `fillcolor` — an authored EffectFiltersBA colour came back exactly (white, 128/64/191; E112). The OTIO writer CANNOT: EXPORT_OTIO emits a Solid Color as a Clip.2 named 'Solid Color' with a NULL media_reference, metadata {"Resolve_OTIO": {}} and a parameterless Transform effect — no colour anywhere (measured E117) — so only an XML re-export witnesses a generator colour (editorial.verify_roundtrip exportedFormat → generatorColourNotInExport). Such an OTIO export DOES re-conform through drt.assemble_from_interchange (E118): the media-less generator clips walk as black legs and the clip→generator fade renders 124→16 — black, the colour having been lost by the writer. COMPOUND CLIPS: EXPORT_OTIO nests a compound as a Stack.1 inside the track (its source_range = the trim window into the compound; nested compounds nest Stacks recursively — measured E120 on a depth-2 timeline), while EXPORT_FCP_7_XML flattens the compound to a single media-less clipitem named after it (no inner content). editorial.parse_interchange flattens the OTIO Stacks into record time (fromCompound on each cut).
|
|
317
317
|
- **Workaround / current handling:** Author fade-to-white / colour mattes by placing a Solid Color generator with that blob (drp-format placeGenerator `color`, drt.assemble elements[].color) — or carry an XMEML generatoritem fillcolor through editorial.parse_interchange; the bridge authors the coloured leg.
|
|
318
318
|
- **Tags:** xml, import, generator, colour, export, drt
|
|
319
319
|
|
package/install.py
CHANGED
|
@@ -37,7 +37,7 @@ from src.utils.update_check import (
|
|
|
37
37
|
|
|
38
38
|
# ─── Version ──────────────────────────────────────────────────────────────────
|
|
39
39
|
|
|
40
|
-
VERSION = "2.
|
|
40
|
+
VERSION = "2.175.0"
|
|
41
41
|
# Only hard floor: mcp[cli] requires Python 3.10+. There is no upper bound —
|
|
42
42
|
# Resolve's scripting bridge loads into newer interpreters on recent builds
|
|
43
43
|
# (Python 3.14 verified against Resolve Studio 20.3.2). Older Resolve builds
|
package/package.json
CHANGED
|
@@ -281,6 +281,21 @@ export function eventsToAssembleSpec(events, opts = {}) {
|
|
|
281
281
|
// the fade dissolves around it, measured E91); audio BL legs are silence,
|
|
282
282
|
// which an empty track already is.
|
|
283
283
|
const isBL = (srcName) => /^(BL|BLACK)$/i.test(String(srcName || '').trim());
|
|
284
|
+
// FLATTENED COMPOUNDS (E121): an XML clipitem that is a compound carries no
|
|
285
|
+
// inner content, so nothing can be authored for it unless the sourceMap
|
|
286
|
+
// points its name at a flattened media file. Unmapped ones are DROPPED
|
|
287
|
+
// with a reason — a hole in the conform the ledger names — rather than
|
|
288
|
+
// refusing the whole turnover as an unmapped reel.
|
|
289
|
+
const unresolvedCompounds = [];
|
|
290
|
+
for (const list of [vids, auds]) {
|
|
291
|
+
for (let i = list.length - 1; i >= 0; i -= 1) {
|
|
292
|
+
const e = list[i];
|
|
293
|
+
if (e.compound && !sourceMap[e.source]) {
|
|
294
|
+
unresolvedCompounds.push({ name: e.compound, track: e.track, recIn: e.recIn, recOut: e.recOut, reason: 'XML compound clipitem carries no inner content — re-export as OTIO (nested Stacks flatten) or map the compound name to a flattened media file in sourceMap' });
|
|
295
|
+
list.splice(i, 1);
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
}
|
|
284
299
|
const unmapped = [...new Set([...vids, ...auds].map((e) => e.source).filter((srcName) => !isBL(srcName) && !sourceMap[srcName]))];
|
|
285
300
|
if (unmapped.length) {
|
|
286
301
|
throw new Error(
|
|
@@ -708,6 +723,11 @@ export function eventsToAssembleSpec(events, opts = {}) {
|
|
|
708
723
|
audioEventsSkipped: audioSkipped,
|
|
709
724
|
authoredMarkers: markers.length,
|
|
710
725
|
audioChannelLegsMerged,
|
|
726
|
+
// Compound clips flattened out of nested OTIO Stacks (E120): named so
|
|
727
|
+
// the ledger says which compounds became flat cuts.
|
|
728
|
+
flattenedCompounds: [...new Set(events.filter((e) => e.fromCompound).map((e) => e.fromCompound))],
|
|
729
|
+
flattenedCompoundEvents: events.filter((e) => e.fromCompound).length,
|
|
730
|
+
unresolvedCompounds,
|
|
711
731
|
authoredAudioEvents: audioPlacements.length,
|
|
712
732
|
audioRetimesSkipped,
|
|
713
733
|
...(elements.length || audioBlackLegsSkipped ? {
|
|
@@ -52,6 +52,8 @@ function evt(o) {
|
|
|
52
52
|
...(o.name !== undefined ? { name: o.name } : {}),
|
|
53
53
|
...(o.color !== undefined ? { color: o.color } : {}),
|
|
54
54
|
...(o.generatorName !== undefined ? { generatorName: o.generatorName } : {}),
|
|
55
|
+
...(o.fromCompound !== undefined ? { fromCompound: o.fromCompound } : {}),
|
|
56
|
+
...(o.compound !== undefined ? { compound: o.compound } : {}),
|
|
55
57
|
source: o.source || 'UNKNOWN',
|
|
56
58
|
srcIn: o.srcIn ?? null,
|
|
57
59
|
srcOut: o.srcOut ?? null,
|
|
@@ -179,6 +181,10 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
179
181
|
name: mk.name || undefined, color: mk.color || undefined, fps: mrRate,
|
|
180
182
|
}));
|
|
181
183
|
}
|
|
184
|
+
// Walk one track's children into `sink`. Recursive: a nested Stack (a
|
|
185
|
+
// compound clip) walks its inner tracks with a private cursor and is
|
|
186
|
+
// flattened into the parent's record time (E120).
|
|
187
|
+
const walkChildren = (children, kind, sink) => {
|
|
182
188
|
let rec = 0;
|
|
183
189
|
// An OTIO Transition occupies NO record time (like an AAF transition —
|
|
184
190
|
// it overlaps its neighbours); it describes the junction between the
|
|
@@ -193,7 +199,7 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
193
199
|
// empty track renders black anyway, so the growth is render-neutral.
|
|
194
200
|
let atBlack = true;
|
|
195
201
|
const lastRate = () => opts.fps || 24;
|
|
196
|
-
for (const child of
|
|
202
|
+
for (const child of children || []) {
|
|
197
203
|
const schema = child.OTIO_SCHEMA || '';
|
|
198
204
|
const dur = (child.source_range && child.source_range.duration && child.source_range.duration.value) || 0;
|
|
199
205
|
const rate = (child.source_range && child.source_range.duration && child.source_range.duration.rate) || opts.fps || 24;
|
|
@@ -201,7 +207,7 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
201
207
|
if (pendingTransition) {
|
|
202
208
|
// Transition then Gap = fade-out into black: attach it to a
|
|
203
209
|
// synthetic BL leg at the junction (the bridge grows it forward).
|
|
204
|
-
|
|
210
|
+
sink.push(evt({
|
|
205
211
|
index: idx++, track: kind, source: 'BL',
|
|
206
212
|
recIn: rec, recOut: rec, transition: pendingTransition, fps: lastRate(),
|
|
207
213
|
}));
|
|
@@ -213,6 +219,50 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
213
219
|
atBlack = true;
|
|
214
220
|
continue;
|
|
215
221
|
}
|
|
222
|
+
if (schema.startsWith('Stack')) {
|
|
223
|
+
// NESTED STACK = a compound clip (E120, measured against Resolve's
|
|
224
|
+
// OTIO writer: a compound exports as a Stack inside the track with
|
|
225
|
+
// its own source_range = the trim window into the compound, nested
|
|
226
|
+
// recursively). It was silently DROPPED. Flatten it: walk each inner
|
|
227
|
+
// track of this kind with a private cursor, then translate its
|
|
228
|
+
// events into the parent's record time through the trim window,
|
|
229
|
+
// trimming source frames at the clip's own play rate. Inner tracks
|
|
230
|
+
// beyond the first land on the next lanes up (V2, V3 …).
|
|
231
|
+
const sr = child.source_range || {};
|
|
232
|
+
const winStart = (sr.start_time && sr.start_time.value) || 0;
|
|
233
|
+
const winDur = (sr.duration && sr.duration.value) || 0;
|
|
234
|
+
const wantAudio = /^A/.test(kind);
|
|
235
|
+
const innerTracks = (child.children || []).filter((t) => String(t.OTIO_SCHEMA || '').startsWith('Track') && ((t.kind === 'Audio') === wantAudio));
|
|
236
|
+
const baseLetter = kind.replace(/\d+$/, '');
|
|
237
|
+
const baseNum = parseInt(kind.replace(/\D/g, '') || '1', 10);
|
|
238
|
+
let first = true;
|
|
239
|
+
innerTracks.forEach((it, i) => {
|
|
240
|
+
const label = baseNum + i === 1 ? baseLetter : `${baseLetter}${baseNum + i}`;
|
|
241
|
+
const tmp = [];
|
|
242
|
+
walkChildren(it.children || [], label, tmp);
|
|
243
|
+
for (const e of tmp) {
|
|
244
|
+
if (e.track === 'MARKER') continue;
|
|
245
|
+
const a = e.recIn - winStart, b = e.recOut - winStart;
|
|
246
|
+
const a2 = Math.max(0, a), b2 = Math.min(winDur, b);
|
|
247
|
+
if (b2 <= a2) continue;
|
|
248
|
+
const k = ((e.speed ?? 100) / 100) * (e.reverse ? -1 : 1);
|
|
249
|
+
const flat = {
|
|
250
|
+
...e, index: idx++, recIn: rec + a2, recOut: rec + b2,
|
|
251
|
+
srcIn: e.srcIn != null ? e.srcIn + (a2 - a) * k : e.srcIn,
|
|
252
|
+
srcOut: e.srcOut != null ? e.srcOut - (b - b2) * k : e.srcOut,
|
|
253
|
+
fromCompound: child.name || 'compound',
|
|
254
|
+
};
|
|
255
|
+
// A transition pending INTO the compound attaches to its first flattened cut.
|
|
256
|
+
if (first && pendingTransition && !flat.transition) flat.transition = pendingTransition;
|
|
257
|
+
first = false;
|
|
258
|
+
sink.push(flat);
|
|
259
|
+
}
|
|
260
|
+
});
|
|
261
|
+
pendingTransition = null;
|
|
262
|
+
atBlack = false;
|
|
263
|
+
rec += winDur;
|
|
264
|
+
continue;
|
|
265
|
+
}
|
|
216
266
|
if (schema.startsWith('Transition')) {
|
|
217
267
|
const inOff = (child.in_offset && child.in_offset.value) || 0;
|
|
218
268
|
const outOff = (child.out_offset && child.out_offset.value) || 0;
|
|
@@ -225,7 +275,7 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
225
275
|
if (pendingTransition && atBlack) {
|
|
226
276
|
// Gap (or track start) then Transition then Clip = fade-IN from
|
|
227
277
|
// black — the CMX zero-length-BL form, grown by the bridge.
|
|
228
|
-
|
|
278
|
+
sink.push(evt({
|
|
229
279
|
index: idx++, track: kind, source: 'BL',
|
|
230
280
|
recIn: rec, recOut: rec, fps: rate,
|
|
231
281
|
}));
|
|
@@ -276,7 +326,7 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
276
326
|
const mrStart = (mk.marked_range && mk.marked_range.start_time && mk.marked_range.start_time.value) || 0;
|
|
277
327
|
itemMarkers.push({ frame: mrStart - startVal, name: mk.name || undefined, color: mk.color || undefined });
|
|
278
328
|
}
|
|
279
|
-
|
|
329
|
+
sink.push(
|
|
280
330
|
evt({
|
|
281
331
|
index: idx++,
|
|
282
332
|
track: kind,
|
|
@@ -300,11 +350,13 @@ export function parseOTIO(otio, opts = {}) {
|
|
|
300
350
|
}
|
|
301
351
|
if (pendingTransition) {
|
|
302
352
|
// Transition as the LAST child = fade-out to the end of the track.
|
|
303
|
-
|
|
353
|
+
sink.push(evt({
|
|
304
354
|
index: idx++, track: kind, source: 'BL',
|
|
305
355
|
recIn: rec, recOut: rec, transition: pendingTransition, fps: lastRate(),
|
|
306
356
|
}));
|
|
307
357
|
}
|
|
358
|
+
};
|
|
359
|
+
walkChildren(track.children || [], kind, events);
|
|
308
360
|
}
|
|
309
361
|
return events;
|
|
310
362
|
}
|
|
@@ -407,7 +459,12 @@ export function parseXMEMLEvents(xml, opts = {}) {
|
|
|
407
459
|
const itemMarkers = mks
|
|
408
460
|
.filter((mk) => Number.isFinite(Number(mk.in)))
|
|
409
461
|
.map((mk) => ({ frame: Number(mk.in) - inF, name: mk.name != null ? String(mk.name) : undefined, note: mk.comment != null ? String(mk.comment) : undefined }));
|
|
410
|
-
|
|
462
|
+
// Resolve's FCP7 writer flattens a COMPOUND CLIP to one clipitem whose
|
|
463
|
+
// <file> carries an explicitly EMPTY <pathurl> and no inner content
|
|
464
|
+
// (measured E120/E121). Tag it so the bridge can drop it with a
|
|
465
|
+
// reason instead of refusing the whole turnover as an unmapped reel.
|
|
466
|
+
const isCompound = !!(it.file && typeof it.file.pathurl === 'string' && it.file.pathurl.trim() === '' && !it.__genColor && name !== 'BL');
|
|
467
|
+
events.push(evt({ index: idx++, track, source: name, srcIn: Number.isFinite(inF) ? inF + inAdj : inF, srcOut: Number.isFinite(outF) ? outF + inAdj : outF, recIn: start, recOut: end, speed, reverse, itemMarkers: itemMarkers.length ? itemMarkers : undefined, color: it.__genColor || undefined, compound: isCompound ? name : undefined, fps: seqRate }));
|
|
411
468
|
}
|
|
412
469
|
}
|
|
413
470
|
};
|
|
@@ -86,7 +86,7 @@ const markerSchema = z.object({
|
|
|
86
86
|
export const editorialTool = {
|
|
87
87
|
name: 'editorial',
|
|
88
88
|
description:
|
|
89
|
-
'Editorial integrity (Cluster E) — turnover interchange → normalized events → changelist + conform manifest with TIMING silent-lie guards (flattened retime / dropped J/L-cut audio / framerate-pulldown slip / reverse dropped / transition-handle starvation → flag, skip-not-fake). Report-only (gate: review). Actions: parse_interchange (EDL/OTIO/XMEML natively — incl. Resolve-written OTIO generator clips (a Solid Color is a Clip with a NULL media_reference; it walks as a BL leg with generatorName, and an OTIO GeneratorReference carries its colour) so Resolve\'s own OTIO exports re-conform, Resolve-written FCP7 -1 junction edges (paired in record order) + Solid Color / Color Matte generators carrying their `fillcolor` (BL legs with `color` → fade-to-white and colour mattes author, E110), XMEML audio-track transitionitems as audio cross-fades on numbered lanes A/A2/…, and CMX FROM/TO CLIP NAME comments over the generic AX reel — + AAF via pyaaf2 (flat sound/picture slots number A/A2/… and V/V2/… in slot order so separate beds keep their lanes; NestedScope layers keep layer numbering) + PRPROJ via gunzip+XML → normalized events incl. span-explicit transitions, BL fade legs, and freezes as zero-speed events (OTIO FreezeFrame, XMEML timeremap 0, PrProj in==out, AAF 0% motion effects); for AAF/PRPROJ pass the file PATH as content; AAF also returns per-sequence startTimecode/startFrame — build the timeline at THAT start, not the Resolve 01:00:00:00 default — and per-clip `geometry` for Avid transform effects), list_sequences (ONE offline picker entry point across xml/edl/otio/drt/drp/aaf/prproj → [{id,name,eventCount}], plus startTimecode/startFrame for AAF), convert_to_interchange (author OTIO/EDL/DRT Resolve CAN import from events or a parsed source; the EDL target writes CMX transition pairs incl. BL fades — the .prproj→Resolve conform bridge, no Premiere needed; editorial timing/transitions survive and per-clip effects/color do not. SPEED/REVERSE survive on the otio (LinearTimeWarp) and edl (M2) targets ONLY — this FLAT drt target flattens every retime to 100% forward and returns `flattened`/`flattenedCount` naming each event that lost one (`flattened` is always present on `drt`, empty when there were none); for a .drt that AUTHORS retimes/dissolves/multi-track/audio, use drt.assemble_from_interchange), turnover_changelist (diff old vs new → moved/retimed/trimmed/replaced/new/gone PLUS the junction diff: transition_added/transition_dropped/transition_changed with fade in/out or dissolve, outgoing/incoming, span and duration/type/pre-roll deltas — zero-length CMX carrier lines and the BL legs that carry fades fold into the junction diff instead of reading as gone/new sources; events pair by closest record position, consumed once, so a source cut twice at two speeds compares instance to instance; + timing flags incl. transition_dropped and dropped_split_audio on any A-track), conform_manifest (per-event assert: source resolved/handles/retime/reverse/TC-base; BL-aware — black legs need no source, fades no black-side handles, and a fade-out tail requirement lands on the picture source), marker_roundtrip (markers with provenance tags), verify_roundtrip (input events vs re-export events -> pass/mismatches + fitted per-source TC offsets + marker compare w/ markersNotInExport honesty flag; FADE-AWARE: BL/Solid-Color legs merge out as blackSegments and fade-window boundary reshapes are excused into fadeReshapedBoundaries instead of failing; RETIME-AWARE: speed/reverse compare pairwise — EXPORT_OTIO carries an authored Sm2TimeMap back as LinearTimeWarp (measured), so a flattened/lost retime fails as drift geometry alone cannot catch; AUDIO-AWARE: declared audio events compare (a video-only export such as EXPORT_EDL flags audioNotInExport instead of failing) (channel legs deduped, mismatches tagged trackType audio) while the mirrored-A1 export of a video-only turnover stays informational; COLOUR-AWARE: an input generator leg carrying a fillcolor (fade-to-white, colour matte) must come back on the same track over its span with the same colour — Resolve\'s FCP7 writer emits it — else generator-colour fails (generatorColours reports the compare) — pass exportedFormat: an OTIO/EDL re-export cannot carry colour (measured) and reports generatorColourNotInExport instead of failing; the conform QC loop-closer). Offline (AAF needs pyaaf2; live AAF/DRP import is on the Python davinci-resolve MCP).',
|
|
89
|
+
'Editorial integrity (Cluster E) — turnover interchange → normalized events → changelist + conform manifest with TIMING silent-lie guards (flattened retime / dropped J/L-cut audio / framerate-pulldown slip / reverse dropped / transition-handle starvation → flag, skip-not-fake). Report-only (gate: review). Actions: parse_interchange (EDL/OTIO/XMEML natively — incl. Resolve-written OTIO generator clips (a Solid Color is a Clip with a NULL media_reference; it walks as a BL leg with generatorName, and an OTIO GeneratorReference carries its colour) and nested OTIO Stacks (compound clips — Resolve\'s writer nests them with a trim window) FLATTEN into record time with fromCompound on each cut, so Resolve\'s own OTIO exports re-conform (its FCP7 XML writer flattens a compound to ONE media-less clipitem instead — tagged `compound`, which the bridge drops with a reason in unresolvedCompounds unless the sourceMap maps the compound name to a flattened media file), Resolve-written FCP7 -1 junction edges (paired in record order) + Solid Color / Color Matte generators carrying their `fillcolor` (BL legs with `color` → fade-to-white and colour mattes author, E110), XMEML audio-track transitionitems as audio cross-fades on numbered lanes A/A2/…, and CMX FROM/TO CLIP NAME comments over the generic AX reel — + AAF via pyaaf2 (flat sound/picture slots number A/A2/… and V/V2/… in slot order so separate beds keep their lanes; NestedScope layers keep layer numbering) + PRPROJ via gunzip+XML → normalized events incl. span-explicit transitions, BL fade legs, and freezes as zero-speed events (OTIO FreezeFrame, XMEML timeremap 0, PrProj in==out, AAF 0% motion effects); for AAF/PRPROJ pass the file PATH as content; AAF also returns per-sequence startTimecode/startFrame — build the timeline at THAT start, not the Resolve 01:00:00:00 default — and per-clip `geometry` for Avid transform effects), list_sequences (ONE offline picker entry point across xml/edl/otio/drt/drp/aaf/prproj → [{id,name,eventCount}], plus startTimecode/startFrame for AAF), convert_to_interchange (author OTIO/EDL/DRT Resolve CAN import from events or a parsed source; the EDL target writes CMX transition pairs incl. BL fades — the .prproj→Resolve conform bridge, no Premiere needed; editorial timing/transitions survive and per-clip effects/color do not. SPEED/REVERSE survive on the otio (LinearTimeWarp) and edl (M2) targets ONLY — this FLAT drt target flattens every retime to 100% forward and returns `flattened`/`flattenedCount` naming each event that lost one (`flattened` is always present on `drt`, empty when there were none); for a .drt that AUTHORS retimes/dissolves/multi-track/audio, use drt.assemble_from_interchange), turnover_changelist (diff old vs new → moved/retimed/trimmed/replaced/new/gone PLUS the junction diff: transition_added/transition_dropped/transition_changed with fade in/out or dissolve, outgoing/incoming, span and duration/type/pre-roll deltas — zero-length CMX carrier lines and the BL legs that carry fades fold into the junction diff instead of reading as gone/new sources; events pair by closest record position, consumed once, so a source cut twice at two speeds compares instance to instance; + timing flags incl. transition_dropped and dropped_split_audio on any A-track), conform_manifest (per-event assert: source resolved/handles/retime/reverse/TC-base; BL-aware — black legs need no source, fades no black-side handles, and a fade-out tail requirement lands on the picture source), marker_roundtrip (markers with provenance tags), verify_roundtrip (input events vs re-export events -> pass/mismatches + fitted per-source TC offsets + marker compare w/ markersNotInExport honesty flag; FADE-AWARE: BL/Solid-Color legs merge out as blackSegments and fade-window boundary reshapes are excused into fadeReshapedBoundaries instead of failing; RETIME-AWARE: speed/reverse compare pairwise — EXPORT_OTIO carries an authored Sm2TimeMap back as LinearTimeWarp (measured), so a flattened/lost retime fails as drift geometry alone cannot catch; AUDIO-AWARE: declared audio events compare (a video-only export such as EXPORT_EDL flags audioNotInExport instead of failing) (channel legs deduped, mismatches tagged trackType audio) while the mirrored-A1 export of a video-only turnover stays informational; COLOUR-AWARE: an input generator leg carrying a fillcolor (fade-to-white, colour matte) must come back on the same track over its span with the same colour — Resolve\'s FCP7 writer emits it — else generator-colour fails (generatorColours reports the compare) — pass exportedFormat: an OTIO/EDL re-export cannot carry colour (measured) and reports generatorColourNotInExport instead of failing; the conform QC loop-closer). Offline (AAF needs pyaaf2; live AAF/DRP import is on the Python davinci-resolve MCP).',
|
|
90
90
|
async handler({ action, args }) {
|
|
91
91
|
if (action === 'parse_interchange') {
|
|
92
92
|
const p = parseSchema.parse(args);
|
package/src/granular/common.py
CHANGED
|
@@ -87,7 +87,7 @@ if not logging.getLogger().handlers:
|
|
|
87
87
|
handlers=[logging.StreamHandler()],
|
|
88
88
|
)
|
|
89
89
|
|
|
90
|
-
VERSION = "2.
|
|
90
|
+
VERSION = "2.175.0"
|
|
91
91
|
logger = logging.getLogger("davinci-resolve-mcp")
|
|
92
92
|
logger.info(f"Starting DaVinci Resolve MCP Server v{VERSION}")
|
|
93
93
|
logger.info(f"Detected platform: {get_platform()}")
|
package/src/server.py
CHANGED
|
@@ -11,7 +11,7 @@ Usage:
|
|
|
11
11
|
python src/server.py --full # Start the 353-tool granular server instead
|
|
12
12
|
"""
|
|
13
13
|
|
|
14
|
-
VERSION = "2.
|
|
14
|
+
VERSION = "2.175.0"
|
|
15
15
|
|
|
16
16
|
import base64
|
|
17
17
|
import os
|
|
@@ -26250,7 +26250,7 @@ _ACTION_HELP: Dict[str, Dict[str, Dict[str, Any]]] = {
|
|
|
26250
26250
|
},
|
|
26251
26251
|
"timeline": {
|
|
26252
26252
|
"get_items": {
|
|
26253
|
-
"summary": "List items on one track as a summary (name/id/start/end/duration/kind). Transitions ARE items — a video Cross Dissolve by name, an AUDIO cross-fade with an EMPTY name — and generators/subtitles look identical to them by media-pool item and properties (all None), so `kind` (clip | transition | generator | subtitle) is decided by geometry: a transition straddles a cut.",
|
|
26253
|
+
"summary": "List items on one track as a summary (name/id/start/end/duration/kind). Transitions ARE items — a video Cross Dissolve by name, an AUDIO cross-fade with an EMPTY name — and generators/subtitles look identical to them by media-pool item and properties (all None), so `kind` (clip | transition | generator | subtitle) is decided by geometry: a transition straddles a cut; `generator` also covers Fusion titles (Text+), which enumerate the same way.",
|
|
26254
26254
|
"params": "track_type (video|audio|subtitle), index|track_index (1-based)",
|
|
26255
26255
|
"returns": "{items: [{name, id, start, end, duration, kind}]}",
|
|
26256
26256
|
"example": 'timeline(action="get_items", params={"track_type": "video", "index": 1})',
|
package/src/utils/api_truth.py
CHANGED
|
@@ -2851,7 +2851,15 @@ API_TRUTH: List[Dict[str, Any]] = [
|
|
|
2851
2851
|
"re-conform through drt.assemble_from_interchange (E118): the "
|
|
2852
2852
|
"media-less generator clips walk as black legs and the "
|
|
2853
2853
|
"clip→generator fade renders 124→16 — black, the colour "
|
|
2854
|
-
"having been lost by the writer."
|
|
2854
|
+
"having been lost by the writer. COMPOUND CLIPS: EXPORT_OTIO "
|
|
2855
|
+
"nests a compound as a Stack.1 inside the track (its "
|
|
2856
|
+
"source_range = the trim window into the compound; nested "
|
|
2857
|
+
"compounds nest Stacks recursively — measured E120 on a "
|
|
2858
|
+
"depth-2 timeline), while EXPORT_FCP_7_XML flattens the "
|
|
2859
|
+
"compound to a single media-less clipitem named after it "
|
|
2860
|
+
"(no inner content). editorial.parse_interchange flattens "
|
|
2861
|
+
"the OTIO Stacks into record time (fromCompound on each "
|
|
2862
|
+
"cut).",
|
|
2855
2863
|
"recommended": "Author fade-to-white / colour mattes by placing a "
|
|
2856
2864
|
"Solid Color generator with that blob "
|
|
2857
2865
|
"(drp-format placeGenerator `color`, drt.assemble "
|