2 * (C) GraÅžvydas "notaz" Ignotas, 2011
4 * This work is licensed under the terms of GNU GPL, version 2 or later.
5 * See the COPYING file in the top-level directory.
12 @ in: r0=dst, r2=pal, r12=0x1e
13 @ trashes r6-r8,lr,flags
14 .macro do_4_pixels rs ibase obase
16 and r6, r12, \rs, lsl #1
18 and r6, r12, \rs, lsr #\ibase-1
20 and r7, r12, \rs, lsr #\ibase+3
21 and r8, r12, \rs, lsr #\ibase+7
22 and lr, r12, \rs, lsr #\ibase+11
28 strneh r6, [r0, #\obase+0]
30 strneh r7, [r0, #\obase+2]
32 strneh r8, [r0, #\obase+4]
34 strneh lr, [r0, #\obase+6]
37 .global draw_spr16_full @ (u16 *d, void *s, u16 *pal, int lines)
40 mov r12, #0x1e @ empty pixel
47 do_4_pixels r5, 16, 24