/** * What do we need * * [ ] screen setup */ #include #include "system/system.h" #include "system/copper.h" #include "screen.h" extern struct Custom far custom; uint16_t custom_color = (uint16_t)offsetof(Custom, color); uint16_t custom_sprite = (uint16_t)offsetof(Custom, sprpt); uint16_t custom_sprite_control = (uint16_t)offsetof(Custom, spr); int main(void) { struct ScreenDefinition screenDefinition; struct ActiveScreenBufferDetails activeScreenBufferDetails; uint16_t *copperlist, *currentCopperlist; void *copperlistBitplanePointers[8][2]; int i; allocateDoubleBufferedScreenMemory( &screenDefinition, &activeScreenBufferDetails, 320, 256, 2 ); copperlist = prepareNewCopperlist(300); currentCopperlist = addDisplayToCopperlist( copperlist, &screenDefinition, &activeScreenBufferDetails, &copperlistBitplanePointers ); COPPERLIST_MOVE(currentCopperlist, custom_color, 0x3a6); COPPERLIST_MOVE(currentCopperlist, custom_color + 2, 0x000); COPPERLIST_MOVE(currentCopperlist, custom_color + 4, 0xfff); endCopperlist(currentCopperlist); takeOverSystem(); setCopperlist(copperlist); setUpDisplay((uint32_t)screenDefinition.bitplanes); for (i = 0; i < 100000; ++i) { } giveBackSystem(); freeCopperlist(copperlist); teardownScreen(&screenDefinition); }