in reply to OT: Tile maps

I would assign a number to each tile image (01021.jpg) Then just use an A0A to store it. If the maps are big might be able to use a PDL to gain some efficency or even just store each map row as a packed string. The later would certainly take less memory then an AOA of numbers. You could do the map storing, munging in XS as well and gain much speed and lower your mem consumption. Hope this helps.

-Lee

"To be civilized is to deny one's nature."

Replies are listed 'Best First'.
Re^2: Tile maps
by etj (Priest) on Jun 26, 2022 at 15:10 UTC
    To avoid running out of memory, current PDL has PDL::IO::FastRaw for easy memory-mapping of disk files as ndarrays.