Cesare su ArsTechnica: la “belle epoque” dello sviluppo su Amiga

Un articolo di Jeremy Reimer comparso ieri su ArsTechnica rievoca – con il contributo di molti sviluppatori dell’epoca – i bei tempi dello sviluppo su piattaforma Amiga, ricordando le gesta degli intrepidi coder della prima ora e rievocando il clima di grande entusiasmo che, alla metà degli anni ’80, ruotava attorno alla creatura di Jay Miner.

Con le potenzialità hardware di Amiga ancora ignote ai più, la sperimentazione era all’ordine del giorno e, come sottolinea l’articolo, la probabilità che due sviluppatori risolvessero lo stesso problema nello stesso modo era piuttosto bassa: per nulla esisteva una via maestra e per uno sviluppatore di talento la questione era semplicemente quella di spingere in avanti lo stato dell’arte.

Il caso del nostro Cesare Di Mauro, ripreso da Ars rende bene l’idea:

Consider the task of Cesare Di Mauro, developer of USA Racing. He wanted a target of 50 frames per second to retain a smooth experience, but this, combined with RAM constraints, meant that it was impossible to use double-buffering (a technique where a second screen with the next frame of action is stored behind the scenes in memory). Using a single screen saved execution time and memory, but made the task of scrolling the background and updating the BOBs (blitter objects, similar to sprites) much more difficult.

His solution consisted of a 352 x 272 virtual screen, with only 320 x 240 pixels viewable at any time. The area was divided into two vertical slices, combined to show a single view. The background consisted of 32 x 32 pixel tiles, arranged in a large map of 4096 x 65536 pixels (coders everywhere will recognize those numbers).

Juggling the number of tiles, the BOBs displayed on top, the music and sound effects, and collision detection with walls and other cars was a huge challenge. Cesare ended up writing a tool in assembly language that handled all of these at 50 frames per second, sorting drawable objects into a display list to maximize performance. The program would first display all BOBs in-order on the list, then update hidden areas to handle scrolling (horizontal scrolling was handled by the graphics chipset by setting a scroll register value, while vertical scrolling was similar but more complicated), then waited for the monitor’s display beam to reach the bottom position of each BOB to restore the background they had “stained.” He wrote custom routines for sound and even disk access to maximize speed and minimize RAM usage.

This sort of careful balancing was typical of game programmers who wanted to push the envelope. Many of the concepts they came up with would be recreated as part of industry standard libraries much later—display lists, for example, are a crucial element of Direct3D.

[…]

Concludo questa pillola con una domanda: dopo che il nostro esperto di coding ha avuto l’onore della citazione su ArsTechnica, sarà il caso che lo “spremiamo” un po’ di più sui temi dello sviluppo Amiga anche in AD? :-)

Press ESC to close