davinci-resolve-mcp 2.159.0 → 2.160.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 +14 -0
- package/README.md +1 -1
- package/README.zh-CN.md +2 -2
- package/install.py +1 -1
- package/package.json +1 -1
- package/resolve-advanced/server/author-interchange.mjs +23 -4
- package/src/granular/common.py +1 -1
- package/src/server.py +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,20 @@
|
|
|
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.160.0 — write-side span fidelity; the flat DRT target stops lying about black
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- **`eventsToOTIO` forced every transition to centered**, so a start-at-cut
|
|
10
|
+
fade-in re-written to OTIO demanded incoming pre-roll the source never
|
|
11
|
+
needed — and the round-trip dropped the fade as handle starvation. The
|
|
12
|
+
writer now carries the source event's actual alignment (start-at-cut,
|
|
13
|
+
`inOffset`, or derived from `recStart`).
|
|
14
|
+
- **The flat DRT target omitted nothing and authored a bogus `BL` offline
|
|
15
|
+
clip** for black legs. BL legs are now omitted — an empty track region
|
|
16
|
+
renders the same black without the media-offline lie — and the `drt`
|
|
17
|
+
result reports `blackLegsOmitted`.
|
|
18
|
+
|
|
5
19
|
## What's New in v2.159.0 — the EDL writer learns transitions
|
|
6
20
|
|
|
7
21
|
### 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.160.0 版 README。如与英文原版有出入,以 [英文原版](README.md) 为准。
|
|
16
16
|
|
|
17
17
|
一个 Model Context Protocol (MCP) 服务器,让 AI 助手通过官方脚本 API 控制 DaVinci Resolve Studio(达芬奇)。它提供完整的 API 覆盖,外加带护栏的工作流助手,涵盖剪辑、媒体池整理、渲染设置、审阅标记、调色、Fusion、Fairlight、项目生命周期任务、扩展开发,以及不碰源媒体的媒体分析。
|
|
18
18
|
|
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.160.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
|
@@ -156,13 +156,22 @@ export function eventsToOTIO(events, opts = {}) {
|
|
|
156
156
|
clip.effects.push({ OTIO_SCHEMA: 'LinearTimeWarp.1', name: 'Speed', metadata: {}, effect_name: 'LinearTimeWarp', time_scalar: (e.reverse ? -1 : 1) * ((e.speed ?? 100) / 100) });
|
|
157
157
|
}
|
|
158
158
|
if (e.transition) {
|
|
159
|
+
// Span fidelity (E102): carry the source event's actual alignment
|
|
160
|
+
// instead of forcing centered — a centered rewrite of a start-at-cut
|
|
161
|
+
// fade-in demands incoming pre-roll the source never needed, and the
|
|
162
|
+
// conform then drops it as handle starvation.
|
|
163
|
+
const d = e.transition.duration || 0;
|
|
164
|
+
let inOff = Math.ceil(d / 2);
|
|
165
|
+
if (e.transition.alignment === 'start') inOff = 0;
|
|
166
|
+
else if (e.transition.inOffset != null) inOff = Math.max(0, Math.min(d, e.transition.inOffset));
|
|
167
|
+
else if (e.transition.recStart != null && e.recIn != null) inOff = Math.max(0, Math.min(d, e.recIn - e.transition.recStart));
|
|
159
168
|
children.push({
|
|
160
169
|
OTIO_SCHEMA: 'Transition.1',
|
|
161
170
|
metadata: {},
|
|
162
171
|
name: 'Cross Dissolve',
|
|
163
172
|
transition_type: 'SMPTE_Dissolve',
|
|
164
|
-
in_offset: rt(
|
|
165
|
-
out_offset: rt(
|
|
173
|
+
in_offset: rt(inOff, fps),
|
|
174
|
+
out_offset: rt(d - inOff, fps),
|
|
166
175
|
});
|
|
167
176
|
}
|
|
168
177
|
children.push(clip);
|
|
@@ -780,7 +789,13 @@ export function drtFlattenedRetimes(events) {
|
|
|
780
789
|
/** Build a buildDRT spec (Resolve-native .drt) from normalized events. */
|
|
781
790
|
export function eventsToDrtSpec(events, opts = {}) {
|
|
782
791
|
const fps = opts.fps || events.find((e) => e.fps)?.fps || 24;
|
|
783
|
-
|
|
792
|
+
// BL legs are OMITTED on this flat target (E102): a 'BL' mediaFilePath
|
|
793
|
+
// would author a bogus offline clip, while an empty track region renders
|
|
794
|
+
// black anyway — the same picture without the media-offline lie. (The
|
|
795
|
+
// fade transitions themselves flatten on DRT by design; use
|
|
796
|
+
// drt.assemble_from_interchange for a .drt that AUTHORS them.)
|
|
797
|
+
const isBLev = (e) => /^(BL|BLACK)$/i.test(String(e.source || '').trim());
|
|
798
|
+
const groups = byTrack(events.filter((e) => !isBLev(e)));
|
|
784
799
|
const mkTrack = (list) => ({
|
|
785
800
|
clips: list.map((e) => ({ start: e.recIn ?? 0, duration: (e.recOut ?? 0) - (e.recIn ?? 0), in: e.srcIn ?? 0, mediaFilePath: e.source || '' })),
|
|
786
801
|
});
|
|
@@ -817,7 +832,11 @@ export async function authorInterchange(events, target, opts = {}) {
|
|
|
817
832
|
if (t === 'drt') {
|
|
818
833
|
const spec = eventsToDrtSpec(events, opts);
|
|
819
834
|
const buf = await drt().buildDRT(spec);
|
|
820
|
-
|
|
835
|
+
const blackLegsOmitted = events.filter((e) => /^(BL|BLACK)$/i.test(String(e.source || '').trim())).length;
|
|
836
|
+
return {
|
|
837
|
+
target: 'drt', spec, buffer: buf, bytes: buf.length, flattened: drtFlattenedRetimes(events),
|
|
838
|
+
...(blackLegsOmitted ? { blackLegsOmitted } : {}),
|
|
839
|
+
};
|
|
821
840
|
}
|
|
822
841
|
throw new Error(`authorInterchange: unknown target '${target}' (otio|edl|drt)`);
|
|
823
842
|
}
|
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.160.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()}")
|