blob: 3c368c17ef281969cf8552b685677612e818ab17 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
#include "native.h"
#include "endianutils.h"
#define MAIN_TYPE DrawSpriteType
#include "macros.h"
UInt32 Screen_drawSprite(void *userData68KP) {
// import variables
SETPTR (UInt8 * ,sprData );
SET16 (UInt16, sprHeight );
SET16 (UInt16, sprWidth );
SET16 (UInt16, sprPitch );
SETPTR (UInt8 * ,dest );
SET16 (UInt16, _scrnSizeX );
// end of import
for (uint16 cnty = 0; cnty < sprHeight; cnty++) {
for (uint16 cntx = 0; cntx < sprWidth; cntx++)
if (sprData[cntx])
dest[cntx] = sprData[cntx];
sprData += sprPitch;
dest += _scrnSizeX;
}
return 0;
}
|