feat: ATL keeps xpan/ypan/xtile/ytile, 3D rotations, zpos, blend, fit and friends instead of dropping them

These properties were treated as GPU hints and silently discarded. The converter now carries xpan, ypan,
xtile, ytile, xrotate, yrotate, zrotate, zpos, zzoom, blend, additive, transform_anchor, rotate_pad,
matrixanchor, matrixtransform, fit, maxsize and crop_relative into the timelines.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
mrleo1nidandClaude Sonnet 5.5 committed 2026-10-27 01:45:01 +03:00
1 parent 11d769f466
commit 91b1d808ce
2 files changed
+4 -3

No files matched your search

+1 -2
View File
@@ -43,8 +43,7 @@ LEADING_ZERO = re.compile(r"(?<![\w.])0+(\d)(?![\d.]*[\w.])")
SPLIT_SIGN = re.compile(r"^([a-z_]+)(-[\d.]+)$")
IGNORED = {"subpixel", "animation", "around", "alignaround", "rotate_pad"} # no visible effect in the browser
# Purely graphical GPU hints; dropping them changes how a picture is drawn, never what happens
COSMETIC = ("xpan", "ypan", "matrixtransform", "matrixanchor", "transform_anchor", "shader", "mesh", "gl_", "u_", "blend", "additive", "perspective", "point_to", "xrotate", "yrotate",
"zrotate", "zpos", "zzoom", "delay", "events", "fit", "nearest", "fps", "show_cancels_hide")
COSMETIC = ("shader", "mesh", "gl_", "u_", "perspective", "point_to", "delay", "events", "nearest", "fps", "show_cancels_hide")
NAMED_POSITIONS = {
"left": {"xpos": 0.0, "xanchor": 0.0}, "right": {"xpos": 1.0, "xanchor": 1.0},
"center": {"xpos": 0.5, "xanchor": 0.5}, "truecenter": {"xpos": 0.5, "xanchor": 0.5, "ypos": 0.5, "yanchor": 0.5},
+3 -1
View File
@@ -12,7 +12,9 @@ Node = dict[str, Any]
POSITION_PROPS = {"xpos", "ypos", "xanchor", "yanchor", "xalign", "yalign", "xcenter",
"ycenter", "zoom", "xzoom", "yzoom", "alpha", "rotate", "xoffset", "yoffset",
"align", "pos", "anchor", "xysize", "size", "blur", "matrixcolor", "xycenter",
"xsize", "ysize", "crop"}
"xsize", "ysize", "crop", "xpan", "ypan", "xtile", "ytile", "xrotate", "yrotate", "zrotate", "zpos",
"zzoom", "blend", "additive", "transform_anchor", "rotate_pad", "matrixanchor", "matrixtransform",
"fit", "maxsize", "crop_relative"}
_SHOW_KEYWORDS = {"at", "as", "behind", "onlayer", "with", "zorder"}