// Stage present. // // stagePresent flips the library-owned stage (back-buffer) to the // display. On chunky platforms (IIgs, DOS) this is a direct copy; on // planar platforms (Amiga, Atari ST) this is a chunky-to-planar // conversion. Drawing primitives mark per-row dirty ranges on the // stage as a side effect, so stagePresent only touches rows that // actually changed since the last present. See docs/DESIGN.md. #ifndef JOEYLIB_PRESENT_H #define JOEYLIB_PRESENT_H #include "platform.h" #include "surface.h" #include "types.h" // Flip the dirty regions of the stage to the display, then clear the // dirty state. Cheap when nothing has changed since the last call. void stagePresent(void); // Flip a specific rectangular region of the stage to the display, // regardless of dirty state. Coordinates are clipped to the surface; // negative or zero dimensions are no-ops. Does not consult or modify // the dirty arrays -- callers mixing stagePresentRect with stagePresent // in the same frame may see redundant work on the next stagePresent. void stagePresentRect(int16_t x, int16_t y, uint16_t w, uint16_t h); #endif