From 4dd0294a7a11d6dd8cb2890df9e66fcc17bc7937 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 8 Aug 2016 04:17:09 +0200 Subject: Remove ZeroMemory --- src/ppu_.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'src/ppu_.c') diff --git a/src/ppu_.c b/src/ppu_.c index 8fcfc4c..fea833a 100644 --- a/src/ppu_.c +++ b/src/ppu_.c @@ -2237,7 +2237,7 @@ void S9xResetPPU() PPU.OBJNameBase = 0; PPU.OBJAddition = FALSE; PPU.OAMReadFlip = 0; - ZeroMemory(PPU.OAMData, 512 + 32); + memset(PPU.OAMData, 0, 512 + 32); PPU.VTimerEnabled = FALSE; PPU.HTimerEnabled = FALSE; @@ -2270,9 +2270,9 @@ void S9xResetPPU() IPPU.DisplayedRenderedFrameCount = 0; IPPU.SkippedFrames = 0; IPPU.FrameSkip = 0; - ZeroMemory(IPPU.TileCached [TILE_2BIT], MAX_2BIT_TILES); - ZeroMemory(IPPU.TileCached [TILE_4BIT], MAX_4BIT_TILES); - ZeroMemory(IPPU.TileCached [TILE_8BIT], MAX_8BIT_TILES); + memset(IPPU.TileCached [TILE_2BIT], 0, MAX_2BIT_TILES); + memset(IPPU.TileCached [TILE_4BIT], 0, MAX_4BIT_TILES); + memset(IPPU.TileCached [TILE_8BIT], 0, MAX_8BIT_TILES); IPPU.FirstVRAMRead = FALSE; IPPU.LatchedInterlace = FALSE; IPPU.DoubleWidthPixels = FALSE; @@ -2307,11 +2307,11 @@ void S9xResetPPU() for (c = 0; c < 0x8000; c += 0x100) memset(&Memory.FillRAM [c], c >> 8, 0x100); - ZeroMemory(&Memory.FillRAM [0x2100], 0x100); - ZeroMemory(&Memory.FillRAM [0x4200], 0x100); - ZeroMemory(&Memory.FillRAM [0x4000], 0x100); + memset(&Memory.FillRAM [0x2100], 0, 0x100); + memset(&Memory.FillRAM [0x4200], 0, 0x100); + memset(&Memory.FillRAM [0x4000], 0, 0x100); // For BS Suttehakkun 2... - ZeroMemory(&Memory.FillRAM [0x1000], 0x1000); + memset(&Memory.FillRAM [0x1000], 0, 0x1000); } void S9xProcessMouse(int which1) -- cgit v1.2.3