Moved some files to the common folder.

This commit is contained in:
bgk 2009-01-01 14:21:18 +00:00
parent 8e2cc38c7c
commit 6c6e4a8b97
28 changed files with 46 additions and 56 deletions

View File

@ -130,12 +130,12 @@ SET(SRC_MAIN
src/Mode3.cpp
src/Mode4.cpp
src/Mode5.cpp
src/Patch.cpp
src/RTC.cpp
src/Sound.cpp
src/Sram.cpp
src/Util.cpp
src/memgzio.c
src/common/Patch.cpp
src/common/memgzio.c
)
SET(SRC_AGB
@ -178,7 +178,7 @@ SET(SRC_SDL
)
SET(SRC_FEX_MINI
src/fex_mini.cpp
src/common/fex_mini.cpp
)
SET(SRC_FILTERS

View File

@ -1,7 +1,7 @@
#include "System.h"
#include "agb/GBA.h"
#include "Globals.h"
#include "Port.h"
#include "common/Port.h"
#include "Util.h"
#include "NLS.h"

View File

@ -5,7 +5,7 @@
#include "agb/GBA.h"
#include "Globals.h"
#include "Util.h"
#include "Port.h"
#include "common/Port.h"
#include "dmg/gb_apu/Gb_Apu.h"
#include "dmg/gb_apu/Multi_Buffer.h"

View File

@ -1,25 +1,10 @@
#ifndef SYSTEM_H
#define SYSTEM_H
#include <stdint.h>
#include "common/Types.h"
#include <zlib.h>
#ifndef NULL
#define NULL 0
#endif
typedef uint8_t u8;
typedef uint16_t u16;
typedef uint32_t u32;
typedef uint64_t u64;
typedef int8_t s8;
typedef int16_t s16;
typedef int32_t s32;
typedef int64_t s64;
class SoundDriver;
struct EmulatedSystem {

View File

@ -16,13 +16,12 @@ extern "C" {
#include "agb/GBA.h"
#include "Globals.h"
#include "RTC.h"
#include "Patch.h"
#include "Port.h"
#include "common/Port.h"
#include "fex.h"
#include "common/fex.h"
extern "C" {
#include "memgzio.h"
#include "common/memgzio.h"
}
#ifndef _MSC_VER
@ -313,11 +312,6 @@ bool utilWriteBMPFile(const char *fileName, int w, int h, u8 *pix)
return true;
}
void utilApplyIPS(const char *ips, u8 **rom, int *size)
{
applyPatch(ips, rom, size);
}
extern bool cpuIsMultiBoot;
bool utilIsGBAImage(const char * file)

View File

@ -17,7 +17,6 @@
#include "../NLS.h"
#include "../elf.h"
#include "../Util.h"
#include "../Port.h"
#include "../System.h"
#include "agbprint.h"
#ifdef PROFILING

View File

@ -17,7 +17,6 @@
#include "../NLS.h"
#include "../elf.h"
#include "../Util.h"
#include "../Port.h"
#include "../System.h"
#include "agbprint.h"
#ifdef PROFILING

View File

@ -17,7 +17,7 @@
#include "../NLS.h"
#include "../elf.h"
#include "../Util.h"
#include "../Port.h"
#include "../common/Port.h"
#include "../System.h"
#include "agbprint.h"
#ifdef PROFILING

View File

@ -4,7 +4,7 @@
#include "GBA.h"
#include "../Globals.h"
#include "../Port.h"
#include "../common/Port.h"
//#define SPRITE_DEBUG

View File

@ -2,7 +2,7 @@
#define GBAINLINE_H
#include "../System.h"
#include "../Port.h"
#include "../common/Port.h"
#include "../RTC.h"
#include "../Sound.h"
#include "agbprint.h"

View File

@ -3,7 +3,7 @@
#include "GBA.h"
#include "../Globals.h"
#include "../Port.h"
#include "../common/Port.h"
#include "../System.h"
#define debuggerWriteHalfWord(addr, value) \

View File

@ -4,7 +4,7 @@
#include <stdio.h>
#include "System.h"
#include "Port.h"
#include "common/Port.h"
#include "agb/GBA.h"
#include "armdis.h"
#include "elf.h"

View File

@ -3,14 +3,8 @@
#include <string.h>
#include <zlib.h>
#include "System.h"
// #include "NLS.h"
// #include "Util.h"
// #include "Flash.h"
// #include "agb/GBA.h"
// #include "Globals.h"
// #include "RTC.h"
// #include "Port.h"
#include "Patch.h"
#ifdef __GNUC__
#if defined(__APPLE__) || defined (BSD)
@ -283,7 +277,7 @@ static int ppfVersion(FILE *f)
}
}
int ppfFileIdLen(FILE *f, int version)
static int ppfFileIdLen(FILE *f, int version)
{
if (version == 2) {
fseeko64(f, -8, SEEK_END);

View File

@ -1,7 +1,7 @@
#ifndef PATCH_H
#define PATCH_H
#include "System.h"
#include "Types.h"
bool applyPatch(const char *patchname, u8 **rom, int *size);

View File

@ -18,6 +18,8 @@
#ifndef __VBA_SOUND_DRIVER_H__
#define __VBA_SOUND_DRIVER_H__
#include "Types.h"
/**
* Sound driver abstract interface for the core to use to output sound.
* Subclass this to implement a new sound driver.

View File

@ -1,9 +1,24 @@
#include <SDL.h>
#include "../System.h"
#include "../Globals.h"
// VisualBoyAdvance - Nintendo Gameboy/GameboyAdvance (TM) emulator.
// Copyright (C) 2008 VBA-M development team
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 2, or(at your option)
// any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include "SoundSDL.h"
#include "../Globals.h"
extern int emulating;
SoundSDL::SoundSDL():

View File

@ -21,6 +21,8 @@
#include "SoundDriver.h"
#include "RingBuffer.h"
#include <SDL.h>
class SoundSDL: public SoundDriver
{
public:

View File

@ -1,5 +1,5 @@
#include "../agb/GBA.h"
#include "../Port.h"
#include "../common/Port.h"
#include "gbGlobals.h"
#include "gbMemory.h"
#include "gb.h"

View File

@ -2,7 +2,7 @@
#include <memory.h>
#include "../System.h"
#include "../Port.h"
#include "../common/Port.h"
#include "../Util.h"
#include "gb.h"
#include "gbGlobals.h"

View File

@ -3,7 +3,7 @@
#include <string.h>
#include "agb/GBA.h"
#include "Port.h"
#include "common/Port.h"
#include "elf.h"
#include "NLS.h"

View File

@ -40,7 +40,7 @@
#include "../agb/GBA.h"
#include "../agb/agbprint.h"
#include "../Flash.h"
#include "../Patch.h"
#include "../common/Patch.h"
#include "../RTC.h"
#include "../Sound.h"
#include "../Util.h"

View File

@ -24,7 +24,7 @@
#include <ctype.h>
#include "../agb/GBA.h"
#include "../Port.h"
#include "../common/Port.h"
#include "../Sound.h"
#include "../armdis.h"
#include "../elf.h"

View File

@ -21,7 +21,7 @@
#include <stdlib.h>
#include "../agb/GBA.h"
#include "../Port.h"
#include "../common/Port.h"
#include "../elf.h"
#include "exprNode.h"