From 0d52a5451b3069509cf6e6bb9c0d277e8a8920c1 Mon Sep 17 00:00:00 2001 From: max Date: Tue, 8 Sep 2026 23:33:08 +0200 Subject: [PATCH] feat(config): add canvas dimensions and padding properties for extended animation motions --- catser/config.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/catser/config.py b/catser/config.py index fdf083b..9c7a6f9 100644 --- a/catser/config.py +++ b/catser/config.py @@ -139,7 +139,28 @@ class Config: """Calculates cat height proportionally based on aspect ratio 121.2 / 92.4.""" return int(round(self.cat_width * (CAT_BOX_HEIGHT / CAT_BOX_WIDTH))) + @property + def pad_x(self) -> int: + """Horizontal padding to accommodate tail wags (-15%) and paw extensions (+9%).""" + return int(round(self.cat_width * 0.20)) + + @property + def pad_y(self) -> int: + """Vertical padding to accommodate ears, stretch, and tail height.""" + return int(round(self.cat_height * 0.20)) + + @property + def canvas_width(self) -> int: + """Total width of the transparent overlay canvas (symmetrical padding).""" + return int(round(self.cat_width * 1.40)) + + @property + def canvas_height(self) -> int: + """Total height of the transparent overlay canvas.""" + return int(round(self.cat_height * 1.30)) + @property def coat(self) -> Coat: """Retrieves the active Coat instance.""" return COATS.get(self.coat_name, COATS["ivory"]) +