MCPcopy Create free account
hub / github.com/openai/plugins / max_content_size

Function max_content_size

plugins/game-studio/scripts/normalize_sprite_strip.py:81–91  ·  view source on GitHub ↗
(images: Iterable[Image.Image | None])

Source from the content-addressed store, hash-verified

79
80
81def max_content_size(images: Iterable[Image.Image | None]) -> tuple[int, int]:
82 widths: list[int] = []
83 heights: list[int] = []
84 for image in images:
85 if image is None:
86 continue
87 widths.append(image.width)
88 heights.append(image.height)
89 if not widths or not heights:
90 raise SystemExit("No sprite content was detected in the provided strip.")
91 return max(widths), max(heights)
92
93
94def compose_frame(

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected