#ifndef __BLITTER_H__ #define __BLITTER_H__ #define BLTSIZE(w, h) (w + (h << 6)) #define BLTCON0( \ minterm, aChan, bChan, cChan, dChan, shift \ ) (minterm + (aChan << 11) + (bChan << 10) + (cChan << 9) + (dChan << 8) + (shift << 12)) #define BLTCON1(descending, shift) ((descending << 1) + (shift << 12)) #define BLITTER_ASCENDING (0) #define BLITTER_DESCENDING (1) /* struct BlitAreaDetails { unsigned char *target; uint16_t drawAreaWidth; uint16_t nextBitplaneAdvance; uint8_t contiguousBitplanes; }; struct BlitDrawLineSetup { uint16_t linePattern; unsigned char *target; int dx, dy, sx; int sud, sul, aul, accumulator, sign; }; void blit_fillAreaDetailsFromScreenSetup( struct ScreenSetup *screenSetup, struct BlitAreaDetails *blitAreaDetails ); void blit_calculateLineBlit( struct BlitDrawLineSetup *setup, uint16_t sx, uint16_t sy, uint16_t ex, uint16_t ey ); void blit_drawLine( struct BlitAreaDetails *blitAreaDetails, struct BlitDrawLineSetup *setup, uint16_t sx, uint16_t sy, uint16_t ex, uint16_t ey, uint8_t color ); void blit_copyOneToOne( struct BlitAreaDetails *source, struct BlitAreaDetails *target, uint16_t sx, uint16_t sy, uint16_t ex, uint16_t ey, uint16_t tx, uint16_t ty ); void blit_howDoesFWMandLWMWork( struct BlitAreaDetails *source, struct BlitAreaDetails *target ); struct BlitGenericData { int8_t shift, leftShift; uint16_t width, height; uint16_t heightStart, targetHeightStart; uint16_t wordSource, wordTarget; uint16_t firstWordMask, lastWordMask; }; void blit_marquee( struct BlitAreaDetails *source, struct BlitGenericData *data, uint16_t splitPoint, uint16_t ex, uint16_t ey, uint16_t ty ); */ #endif