Files
effectcraft/crates/lottie/tests/fixtures/precomp-matte-text.json
Brandon ThomasandClaude Opus 5.5 c4100bcf80 M11.4: Lottie export/import
New crate effectcraft-lottie (L3): export a comp to Lottie JSON / dotLottie
(precomp and base64 image assets; shape, solid, null, precomp, image and text
layers or glyph shapes; transforms with parenting, separated position,
anchor; keyframes with speed/influence converted to normalised i/o tangents,
hold keys, spatial ti/to; all shape items incl. gradients, dashes, trim,
repeater and path operators; masks, track mattes, blend modes, time remap,
timing, markers, optional expressions, a few Lottie effects) with a warnings
list for what Lottie cannot express, and the inverse import. Commands
file.exportLottie / file.importLottie with File > Export / Import entries.
Round-trip tests (values and rendered frames) and hand-written fixtures.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 08:56:03 -04:00

98 lines
2.7 KiB
JSON

{
"v": "5.12.0",
"nm": "Precomp Matte Text",
"fr": 30,
"ip": 0,
"op": 30,
"w": 240,
"h": 160,
"fonts": { "list": [{ "fName": "Inter-Regular", "fFamily": "Inter", "fStyle": "Regular", "ascent": 75 }] },
"assets": [
{
"id": "comp_bg",
"nm": "Background",
"w": 240,
"h": 160,
"layers": [
{
"ind": 1,
"ty": 1,
"nm": "Teal",
"sc": "#1a8c8c",
"sw": 240,
"sh": 160,
"ip": 0,
"op": 30,
"st": 0,
"sr": 1,
"ks": { "a": { "a": 0, "k": [120, 80, 0] }, "p": { "a": 0, "k": [120, 80, 0] }, "s": { "a": 0, "k": [100, 100, 100] }, "r": { "a": 0, "k": 0 }, "o": { "a": 0, "k": 100 } }
}
]
}
],
"layers": [
{
"ind": 1,
"ty": 4,
"nm": "Matte",
"td": 1,
"ip": 0,
"op": 30,
"st": 0,
"sr": 1,
"ks": { "a": { "a": 0, "k": [0, 0] }, "p": { "a": 0, "k": [120, 80] }, "s": { "a": 0, "k": [100, 100] }, "r": { "a": 0, "k": 0 }, "o": { "a": 0, "k": 100 } },
"shapes": [
{ "ty": "el", "nm": "Oval", "p": { "a": 0, "k": [0, 0] }, "s": { "a": 0, "k": [200, 120] } },
{ "ty": "fl", "nm": "Fill", "c": { "a": 0, "k": [1, 1, 1, 1] }, "o": { "a": 0, "k": 100 } }
]
},
{
"ind": 2,
"ty": 0,
"nm": "Background",
"refId": "comp_bg",
"tt": 1,
"w": 240,
"h": 160,
"ip": 0,
"op": 30,
"st": 0,
"sr": 1,
"ks": { "a": { "a": 0, "k": [120, 80, 0] }, "p": { "a": 0, "k": [120, 80, 0] }, "s": { "a": 0, "k": [100, 100, 100] }, "r": { "a": 0, "k": 0 }, "o": { "a": 0, "k": 100 } }
},
{
"ind": 3,
"ty": 5,
"nm": "Title",
"parent": 4,
"ip": 0,
"op": 30,
"st": 0,
"sr": 1,
"ks": { "a": { "a": 0, "k": [0, 0, 0] }, "p": { "a": 0, "k": [0, 0, 0] }, "s": { "a": 0, "k": [100, 100, 100] }, "r": { "a": 0, "k": 0 }, "o": { "a": 0, "k": 100 } },
"t": {
"d": { "k": [{ "t": 0, "s": { "t": "Hello\rLottie", "f": "Inter-Regular", "s": 28, "fc": [1, 1, 1], "j": 2, "tr": 0, "lh": 33.6, "ls": 0 } }] },
"a": [],
"m": { "g": 1, "a": { "a": 0, "k": [0, 0] } },
"p": {}
}
},
{
"ind": 4,
"ty": 3,
"nm": "Controller",
"ip": 0,
"op": 30,
"st": 0,
"sr": 1,
"ks": {
"a": { "a": 0, "k": [0, 0, 0] },
"p": { "a": 1, "k": [{ "t": 0, "s": [120, 60, 0], "o": { "x": 0.5, "y": 0 }, "i": { "x": 0.5, "y": 1 } }, { "t": 29, "s": [120, 100, 0] }] },
"s": { "a": 0, "k": [100, 100, 100] },
"r": { "a": 0, "k": 0 },
"o": { "a": 0, "k": 100 }
}
}
]
}