Pixel-Frame-Analyse und Sprite-Sheet
Liest Pixelframes, wobei jeder Frame ein Block aus Zeilen ist und Frames durch eine Zeile mit drei Bindestrichen getrennt werden; Rastersymbole beschreibt eine Palette „Symbol = #RRGGBB“. Es prüft, dass alle Frames gleich groß sind, zählt nicht leere Pixel, die Begrenzungsbox und die verwendeten Farben, vergleicht benachbarte Frames über die Zahl geänderter Pixel, berechnet die Dauer aus Framezahl und Rate, baut ein Sprite-Sheet-Layout mit der Quadratwurzel-Obergrenze für Spalten und liefert das Sheet als skaliertes PPM P3 samt ASCII-Vorschau jedes Frames.
Parses pixel frames where each frame is a block of rows and frames are separated by a line of three dashes; grid symbols are described by a palette of “symbol = #RRGGBB”. It checks that every frame has the same size, counts non-empty pixels, the bounding box and the colours used, compares neighbouring frames by the number of changed pixels, computes the duration from the frame count and rate, builds a sprite-sheet layout with the square root ceiling for columns and returns the sheet as a scaled PPM P3 together with an ASCII preview of every frame.