Add SetEntries() to set color palette

Signed-off-by: Laurent Vivier <Laurent@lvivier.info>
This commit is contained in:
Laurent Vivier 2008-09-14 23:59:22 +02:00
parent 894efdd1db
commit 34dc6d518c
2 changed files with 11 additions and 1 deletions

View File

@ -9,7 +9,6 @@
#include <macos/types.h>
#include <macos/traps.h>
struct BitMap {
void* baseAddr;
int16_t rowBytes;
@ -143,5 +142,15 @@ static inline void InitGraf(void * port)
" addq.l #4, %%sp"
:: "g" (port) : "%%d0", UNPRESERVED_REGS);
}
static inline void SetEntries(short start, short count, CSpecArray aTable)
{
asm("move.l %0, %%d0\n"
"move.l %1, %%d1\n"
"move.l %2, %%a0\n"
Trap(_SetEntries)
:: "g" (start), "g" (count), "g" (aTable) :
UNPRESERVED_REGS);
}
#endif /* __mc68000__ */
#endif /* __MACOS_QUICKDRAW_H__ */

View File

@ -29,6 +29,7 @@
#define _HWPriv 0xA098
#define _SCSIDispatch 0xA815
#define _SysError 0xA9C9
#define _SetEntries 0xAA3F
/*
* Inside Macintosh Volume I, I-94: Register Saving Conventions */