diff --git a/desmume/src/GPU.cpp b/desmume/src/GPU.cpp index 2beecd5fa..35212f4b7 100644 --- a/desmume/src/GPU.cpp +++ b/desmume/src/GPU.cpp @@ -953,7 +953,7 @@ INLINE void renderline_textBG(const GPU * gpu, u8 num, u8 * dst, u32 Y, u16 XBG, // BACKGROUND RENDERING -ROTOSCALE- /*****************************************************************************/ -FORCEINLINE static void rot_tiled_8bit_entry(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { +FORCEINLINE void rot_tiled_8bit_entry(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { u8 palette_entry; u16 tileindex, x, y, color; @@ -966,7 +966,7 @@ FORCEINLINE static void rot_tiled_8bit_entry(GPU * gpu, int num, s32 auxX, s32 a gpu->setFinalColorBck(gpu,0,num,dst, color,auxX,auxY); } -FORCEINLINE static void rot_tiled_16bit_entry(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { +FORCEINLINE void rot_tiled_16bit_entry(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { u8 palette_entry; u16 x, y, color; TILEENTRY tileentry; @@ -982,7 +982,7 @@ FORCEINLINE static void rot_tiled_16bit_entry(GPU * gpu, int num, s32 auxX, s32 gpu->setFinalColorBck(gpu,0,num,dst, color, i, H); } -FORCEINLINE static void rot_256_map(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { +FORCEINLINE void rot_256_map(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { u8 palette_entry; u16 color; @@ -995,7 +995,7 @@ FORCEINLINE static void rot_256_map(GPU * gpu, int num, s32 auxX, s32 auxY, int } -FORCEINLINE static void rot_BMP_map(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { +FORCEINLINE void rot_BMP_map(GPU * gpu, int num, s32 auxX, s32 auxY, int lg, u8 * dst, u8 * map, u8 * tile, u8 * pal, int i, u16 H) { u16 color; // return; diff --git a/desmume/src/MMU.cpp b/desmume/src/MMU.cpp index b36bcdc55..2051b5a42 100644 --- a/desmume/src/MMU.cpp +++ b/desmume/src/MMU.cpp @@ -87,26 +87,6 @@ void _MMU_write32(int PROCNUM, u32 addr, u32 val) { else _MMU_ARM7_write32(addr,val); } - - -template -u8 _MMU_read08(u32 addr) { return _MMU_read08(PROCNUM, addr); } - -template -u16 _MMU_read16(u32 addr) { return _MMU_read16(PROCNUM, addr); } - -template -u32 _MMU_read32(u32 addr) { return _MMU_read32(PROCNUM, addr); } - -template -void _MMU_write08(u32 addr, u8 val) { _MMU_write08(PROCNUM, addr, val); } - -template -void _MMU_write16(u32 addr, u16 val) { _MMU_write16(PROCNUM, addr, val); } - -template -void _MMU_write32(u32 addr, u32 val) { _MMU_write32(PROCNUM, addr, val); } - //http://home.utah.edu/~nahaj/factoring/isqrt.c.html static u64 isqrt (u64 x) { u64 squaredbit, remainder, root; diff --git a/desmume/src/MMU.h b/desmume/src/MMU.h index 31c124f78..fd8835c54 100644 --- a/desmume/src/MMU.h +++ b/desmume/src/MMU.h @@ -224,4 +224,22 @@ void _MMU_write32(int PROCNUM, u32 addr, u32 val); #define WRITE8(a,b,c) _MMU_write08(b, c) #endif +template +u8 _MMU_read08(u32 addr) { return _MMU_read08(PROCNUM, addr); } + +template +u16 _MMU_read16(u32 addr) { return _MMU_read16(PROCNUM, addr); } + +template +u32 _MMU_read32(u32 addr) { return _MMU_read32(PROCNUM, addr); } + +template +void _MMU_write08(u32 addr, u8 val) { _MMU_write08(PROCNUM, addr, val); } + +template +void _MMU_write16(u32 addr, u16 val) { _MMU_write16(PROCNUM, addr, val); } + +template +void _MMU_write32(u32 addr, u32 val) { _MMU_write32(PROCNUM, addr, val); } + #endif