1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2024-11-25 09:44:02 +00:00

Hopefully fix build against SDL 1.2. Does not yet run!

Also: Recently introduced key names in usersettings.xml will no longer work.
But this should automatically detect key names as they used to be,
and convert automatically. Needs testing.
This commit is contained in:
fgenesis 2017-02-15 04:34:32 +01:00
parent 4095fde219
commit 3dda97d32a
14 changed files with 461 additions and 51 deletions

View file

@ -910,6 +910,7 @@ This build is not yet final, and as such there are a couple things lacking. They
SDL_Init(SDL_INIT_VIDEO); SDL_Init(SDL_INIT_VIDEO);
if (fullscreen && !sdlVideoModeOK(user.video.displayindex, user.video.resx, user.video.resy, user.video.bits)) if (fullscreen && !sdlVideoModeOK(user.video.displayindex, user.video.resx, user.video.resy, user.video.bits))
{ {
#ifdef BBGE_BUILD_SDL2
SDL_DisplayMode mode, closest; SDL_DisplayMode mode, closest;
mode.format = 0; mode.format = 0;
mode.driverdata = 0; mode.driverdata = 0;
@ -923,11 +924,13 @@ This build is not yet final, and as such there are a couple things lacking. They
user.video.hz = closest.refresh_rate; user.video.hz = closest.refresh_rate;
} }
else else
#endif
{ {
// maybe we can force a sane resolution if SetVideoMode is going to fail... // maybe we can force a sane resolution if SetVideoMode is going to fail...
user.video.resx = 800; user.video.resx = 800;
user.video.resy = 600; user.video.resy = 600;
user.video.hz = 60; user.video.hz = 60;
user.video.bits = 32;
user.video.displayindex = 0; user.video.displayindex = 0;
if (!sdlVideoModeOK(0, user.video.resx, user.video.resy, user.video.bits)) if (!sdlVideoModeOK(0, user.video.resx, user.video.resy, user.video.bits))
fullscreen = false; // last chance. fullscreen = false; // last chance.

View file

@ -23,6 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include "ActionMapper.h" #include "ActionMapper.h"
#include "Core.h" #include "Core.h"
#include "SDL.h" #include "SDL.h"
#include "LegacyKeycodes.h"
static std::string inputcode2string(int k) static std::string inputcode2string(int k)
@ -31,17 +32,15 @@ static std::string inputcode2string(int k)
return std::string(); return std::string();
if(k < KEY_MAXARRAY) if(k < KEY_MAXARRAY)
{ {
const char *name; // See parseKey() below
#ifdef BBGE_BUILD_SDL2
name = SDL_GetScancodeName((SDL_Scancode)k);
#else
name = SDL_GetKeyName((SDLKey)k);
#endif
if(name)
return name;
std::stringstream os; std::stringstream os;
os << "K:" << k; os << "K:";
#ifdef BBGE_BUILD_SDL2
int keycode = SDL_GetKeyFromScancode((SDL_Scancode)k);
os << keycode << "," << k;
#else
os << k;
#endif
return os.str(); return os.str();
} }
@ -149,11 +148,37 @@ std::string getInputCodeToUserString(unsigned int k, size_t joystickID)
return inputcode2string(k); return inputcode2string(k);
} }
#ifndef BBGE_BUILD_SDL2 // two comma-separated ints
static bool s_needKeyTabInit = false; // first is the keycode, second the scancode
std::map<std::string, SDLKey> s_keyNameMap; // (Keymap-independent) Scancodes are used when built with SDL2 support and specified
// (Keymap-dependent) Keycode is used otherwise
static int parseKey(const char *ks)
{
int k = 0;
#ifdef BBGE_BUILD_SDL2
if(const char *comma = strchr(ks, ','))
{
k = atoi(comma + 1);
if(k && k < KEY_MAXARRAY)
return k;
}
#endif #endif
// Use the keycode
k = atoi(ks);
if(k < KEY_MAXARRAY)
{
#ifdef BBGE_BUILD_SDL2
// But when we're on SDL2, don't forget to turn they keycode back into a scancode, since we work with scancodes internally
k = SDL_GetScancodeFromKey(k);
#endif
return k;
}
return 0;
}
int getStringToInputCode(const std::string& s) int getStringToInputCode(const std::string& s)
{ {
if(s == "LMB") if(s == "LMB")
@ -163,7 +188,7 @@ int getStringToInputCode(const std::string& s)
if(s == "MMB") if(s == "MMB")
return MOUSE_BUTTON_MIDDLE; return MOUSE_BUTTON_MIDDLE;
if(!strncmp(s.c_str(), "K:", 2)) if(!strncmp(s.c_str(), "K:", 2))
return atoi(s.c_str() + 2); return parseKey(s.c_str() + 2);
if(!strncmp(s.c_str(), "JB:", 3)) if(!strncmp(s.c_str(), "JB:", 3))
return JOY_BUTTON_0 + atoi(s.c_str() + 3); return JOY_BUTTON_0 + atoi(s.c_str() + 3);
if(!strncmp(s.c_str(), "MB:", 3)) if(!strncmp(s.c_str(), "MB:", 3))
@ -181,11 +206,12 @@ int getStringToInputCode(const std::string& s)
if(s == "NONE") if(s == "NONE")
return 0; return 0;
#ifdef BBGE_BUILD_SDL2 // Maybe we're upgrading from an old config?
return SDL_GetScancodeFromName(underscoresToSpaces(s).c_str()); // Note that this returns 0 for "0", which was considered "no key"
#else if(int k = getInputCodeFromLegacyName(s.c_str()))
return SDL_GetKeyFromName(underscoresToSpaces(s).c_str()); return k;
#endif
return 0;
} }

View file

@ -8,6 +8,7 @@ class ActionSet;
const unsigned mouseExtraButtons = 8; const unsigned mouseExtraButtons = 8;
// *_END is non-inclusive!
enum ActionButtonType enum ActionButtonType
{ {
MOUSE_BUTTON_LEFT = KEY_MAXARRAY + 1, MOUSE_BUTTON_LEFT = KEY_MAXARRAY + 1,

View file

@ -126,7 +126,12 @@ void Core::reloadDevice()
void Core::setup_opengl() void Core::setup_opengl()
{ {
#ifdef BBGE_BUILD_SDL2
assert(gGLctx); assert(gGLctx);
#else
assert(gScreen);
#endif
glViewport(0, 0, width, height); glViewport(0, 0, width, height);
@ -150,6 +155,11 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
{ {
assert(lib_graphics); assert(lib_graphics);
const int oldw = width;
const int oldh = height;
bool reloadRes = false;
#ifdef BBGE_BUILD_SDL2
const int oldDisplay = getDisplayIndex(); const int oldDisplay = getDisplayIndex();
assert(oldDisplay >= 0); assert(oldDisplay >= 0);
if(display == -1) if(display == -1)
@ -174,11 +184,12 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
SDL_SetWindowPosition(gScreen, center, center); SDL_SetWindowPosition(gScreen, center, center);
} }
const int oldw = width;
const int oldh = height;
const bool useDesktop = w == 0 || h == 0 || (oldw && w == -1 && oldh && h == -1 && _useDesktopResolution); const bool useDesktop = w == 0 || h == 0 || (oldw && w == -1 && oldh && h == -1 && _useDesktopResolution);
#else
const bool useDesktop = false;
#endif
const bool wasFullscreen = _fullscreen; const bool wasFullscreen = _fullscreen;
if(hz == -1) if(hz == -1)
@ -190,11 +201,13 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
if (vsync == -1) if (vsync == -1)
vsync = _vsync; vsync = _vsync;
#ifdef BBGE_BUILD_SDL2
if(useDesktop) if(useDesktop)
{ {
w = displaymode.w; w = displaymode.w;
h = displaymode.h; h = displaymode.h;
} }
#endif
if (w == -1) if (w == -1)
w = width; w = width;
@ -209,9 +222,10 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
_fullscreen = fullscreen; _fullscreen = fullscreen;
_bpp = bpp; _bpp = bpp;
_refreshRate = hz; _refreshRate = hz;
displaymode.refresh_rate = hz;
#ifdef BBGE_BUILD_SDL2 #ifdef BBGE_BUILD_SDL2
displaymode.refresh_rate = hz;
if(vsync) if(vsync)
{ {
if(SDL_GL_SetSwapInterval(-1) != 0) if(SDL_GL_SetSwapInterval(-1) != 0)
@ -227,7 +241,6 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
SDL_SetWindowFullscreen(gScreen, 0); SDL_SetWindowFullscreen(gScreen, 0);
bool resize = true; bool resize = true;
bool reloadRes = false;
bool maximize = true; bool maximize = true;
if(useDesktop != _useDesktopResolution) if(useDesktop != _useDesktopResolution)
{ {
@ -245,7 +258,7 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
useh = oldh; useh = oldh;
maximize = false; maximize = false;
} }
createWindow(usew, useh, useDesktop, false); createWindow(usew, useh, useDesktop, false, bpp);
reloadRes = true; reloadRes = true;
} }
@ -276,7 +289,7 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
if(resize && !fullscreen && !useDesktop) if(resize && !fullscreen && !useDesktop)
{ {
if(w != oldw|| h != oldh) if(w != oldw || h != oldh)
{ {
SDL_SetWindowSize(gScreen, w, h); SDL_SetWindowSize(gScreen, w, h);
int c = SDL_WINDOWPOS_CENTERED_DISPLAY(display); int c = SDL_WINDOWPOS_CENTERED_DISPLAY(display);
@ -284,17 +297,20 @@ void Core::initGraphics(int w, int h, int fullscreen, int vsync, int bpp, int di
} }
} }
#else if(!resize)
SDL_GetWindowSize(gScreen, &w, &h);
# error FIXME: backport to support SDL 1.2 #else
if(w != oldw || h != oldh)
{
reloadRes = true; // Always reload resources on SDL 1.2, since it loses the GL context!
createWindow(w, h, false, fullscreen, bpp);
}
#endif #endif
_useDesktopResolution = useDesktop; _useDesktopResolution = useDesktop;
if(!resize)
SDL_GetWindowSize(gScreen, &w, &h);
updateWindowDrawSize(w, h); updateWindowDrawSize(w, h);
if(reloadRes) if(reloadRes)
@ -525,8 +541,10 @@ Core::Core(const std::string &filesystem, const std::string& extraDataDir, int n
nestedMains = 0; nestedMains = 0;
afterEffectManager = 0; afterEffectManager = 0;
loopDone = false; loopDone = false;
#ifdef BBGE_BUILD_SDL2
winPosX = SDL_WINDOWPOS_CENTERED; winPosX = SDL_WINDOWPOS_CENTERED;
winPosY = SDL_WINDOWPOS_CENTERED; winPosY = SDL_WINDOWPOS_CENTERED;
#endif
core = this; core = this;
for (int i = 0; i < KEY_MAXARRAY; i++) for (int i = 0; i < KEY_MAXARRAY; i++)
@ -866,20 +884,24 @@ bool Core::initGraphicsLibrary(int width, int height, bool fullscreen, bool vsyn
initIcon(gScreen); initIcon(gScreen);
std::ostringstream os;
os << "setting vsync: " << vsync;
debugLog(os.str());
#ifndef BBGE_BUILD_SDL2
SDL_GL_SetAttribute(SDL_GL_SWAP_CONTROL, vsync);
SDL_GL_SetAttribute(SDL_GL_SHARE_WITH_CURRENT_CONTEXT, 1);
#ifdef _DEBUG
SDL_GL_SetAttribute(SDL_GL_CONTEXT_FLAGS SDL_GL_CONTEXT_DEBUG_FLAG); #ifdef BBGE_BUILD_SDL2
#endif # ifdef _DEBUG
SDL_GL_SetAttribute(SDL_GL_CONTEXT_FLAGS, SDL_GL_CONTEXT_DEBUG_FLAG);
# endif
SDL_GL_SetAttribute(SDL_GL_SHARE_WITH_CURRENT_CONTEXT, 1);
#else
{
std::ostringstream os;
os << "setting vsync: " << vsync;
SDL_GL_SetAttribute(SDL_GL_SWAP_CONTROL, vsync); // SDL 1.2 can't set this on an existing context
debugLog(os.str());
}
#endif #endif
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1); SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);
createWindow(width, height, !width && !height, fullscreen); createWindow(width, height, !width && !height, fullscreen, bpp);
if (SDL_GL_LoadLibrary(NULL) == -1) if (SDL_GL_LoadLibrary(NULL) == -1)
{ {
@ -913,7 +935,7 @@ bool Core::initGraphicsLibrary(int width, int height, bool fullscreen, bool vsyn
return true; return true;
} }
void Core::createWindow(int w, int h, bool resizable, bool fullscreen) void Core::createWindow(int w, int h, bool resizable, bool fullscreen, int bpp)
{ {
#ifdef BBGE_BUILD_SDL2 #ifdef BBGE_BUILD_SDL2
if(gScreen) if(gScreen)
@ -1039,7 +1061,7 @@ void Core::enumerateScreenModes()
{ {
if (modes[i]->w > modes[i]->h) if (modes[i]->w > modes[i]->h)
{ {
screenModes.push_back(ScreenMode(i, modes[i]->w, modes[i]->h, 0)); screenModes.push_back(ScreenMode(i, modes[i]->w, modes[i]->h));
} }
} }
} }

View file

@ -486,7 +486,7 @@ protected:
bool initInputLibrary(); bool initInputLibrary();
void initJoystickLibrary(); void initJoystickLibrary();
bool initGraphicsLibrary(int w, int h, bool fullscreen, bool vsync, int bpp, int display, int hz); bool initGraphicsLibrary(int w, int h, bool fullscreen, bool vsync, int bpp, int display, int hz);
void createWindow(int w, int h, bool resizable, bool fullscreen); void createWindow(int w, int h, bool resizable, bool fullscreen, int bpp);
void shutdownInputLibrary(); void shutdownInputLibrary();
void shutdownJoystickLibrary(); void shutdownJoystickLibrary();
void shutdownGraphicsLibrary(); void shutdownGraphicsLibrary();

View file

@ -122,6 +122,8 @@
#else // BBGE_BUILD_SDL2 #else // BBGE_BUILD_SDL2
// ------------- SDL 1.2 code path -----------------
#include <SDL_keysym.h> #include <SDL_keysym.h>
#define KEY_LSUPER SDLK_LSUPER #define KEY_LSUPER SDLK_LSUPER

111
BBGE/LegacyKeycodes.cpp Normal file
View file

@ -0,0 +1,111 @@
#include "LegacyKeycodes.h"
#include "ActionStatus.h"
#include <map>
#include <sstream>
typedef std::map<std::string, int> InputCodeMap;
InputCodeMap inputCodeMap;
static void initInputCodeMap()
{
#define K(k)inputCodeMap[#k] = k;
K(KEY_A)
K(KEY_B)
K(KEY_C)
K(KEY_D)
K(KEY_E)
K(KEY_F)
K(KEY_G)
K(KEY_H)
K(KEY_I)
K(KEY_J)
K(KEY_K)
K(KEY_L)
K(KEY_M)
K(KEY_N)
K(KEY_O)
K(KEY_P)
K(KEY_Q)
K(KEY_R)
K(KEY_S)
K(KEY_T)
K(KEY_U)
K(KEY_V)
K(KEY_W)
K(KEY_X)
K(KEY_Y)
K(KEY_Z)
K(KEY_1)
K(KEY_2)
K(KEY_3)
K(KEY_4)
K(KEY_5)
K(KEY_6)
K(KEY_7)
K(KEY_8)
K(KEY_9)
K(KEY_0)
K(KEY_NUMPAD1)
K(KEY_NUMPAD2)
K(KEY_NUMPAD3)
K(KEY_NUMPAD4)
K(KEY_NUMPAD5)
K(KEY_NUMPAD6)
K(KEY_NUMPAD7)
K(KEY_NUMPAD8)
K(KEY_NUMPAD9)
K(KEY_NUMPAD0)
K(KEY_F1)
K(KEY_F2)
K(KEY_F3)
K(KEY_F4)
K(KEY_F5)
K(KEY_F6)
K(KEY_F7)
K(KEY_F8)
K(KEY_F9)
K(KEY_F10)
K(KEY_F11)
K(KEY_F12)
K(KEY_LEFT)
K(KEY_RIGHT)
K(KEY_UP)
K(KEY_DOWN)
K(KEY_SPACE)
K(KEY_LCONTROL)
K(KEY_RCONTROL)
K(KEY_LSHIFT)
K(KEY_RSHIFT)
K(KEY_LMETA)
K(KEY_RMETA)
K(KEY_LALT)
K(KEY_RALT)
K(KEY_RETURN)
K(KEY_TAB)
K(KEY_ESCAPE)
K(MOUSE_BUTTON_LEFT)
K(MOUSE_BUTTON_RIGHT)
K(MOUSE_BUTTON_MIDDLE)
#undef K
for (int jb = JOY_BUTTON_0; jb < JOY_BUTTON_END; jb++)
{
std::ostringstream os;
os << "JOY_BUTTON_" << jb - JOY_BUTTON_0;
inputCodeMap[os.str()] = jb;
}
}
int getInputCodeFromLegacyName(const char *name)
{
return inputCodeMap[name];
}
struct LegacyKeymapInitializer
{
LegacyKeymapInitializer() { initInputCodeMap(); }
};
static LegacyKeymapInitializer s_kinit;

6
BBGE/LegacyKeycodes.h Normal file
View file

@ -0,0 +1,6 @@
#ifndef BBGE_LEGACYKEYCODES_H
#define BBGE_LEGACYKEYCODES_H
int getInputCodeFromLegacyName(const char *name);
#endif

View file

@ -66,11 +66,12 @@ void initIcon(void *screen)
#ifdef BBGE_BUILD_SDL2 #ifdef BBGE_BUILD_SDL2
SDL_GetWindowWMInfo((SDL_Window*)screen, &wminfo); SDL_GetWindowWMInfo((SDL_Window*)screen, &wminfo);
HWND hwnd = wminfo.info.win.window;
#else #else
SDL_GetWindowWMInfo((SDL_Surface*)screen, &wminfo); SDL_GetWMInfo(&wminfo);
HWND hwnd = wminfo.window;
#endif #endif
HWND hwnd = wminfo.info.win.window;
::SetClassLongPtr(hwnd, -14, (LONG) icon_windows); // -14 is GCL_HICON (32bit) or GCLP_HICON (64bit) ::SetClassLongPtr(hwnd, -14, (LONG) icon_windows); // -14 is GCL_HICON (32bit) or GCLP_HICON (64bit)
#endif #endif
} }

View file

@ -9,13 +9,18 @@
#include <limits.h> #include <limits.h>
#if defined(_MSC_VER) && _MSC_VER < 1600 #if defined(_MSC_VER) && _MSC_VER < 1600
#include "SDL_version.h"
#if SDL_VERSION_ATLEAST(2, 0, 0) // AQUARIA HACK: Included SDL 1.2 includes define some of these, SDL does not. Avoid conflicts.
typedef signed __int8 int8_t; typedef signed __int8 int8_t;
typedef signed __int16 int16_t;
typedef signed __int32 int32_t;
typedef signed __int64 int64_t;
typedef unsigned __int8 uint8_t; typedef unsigned __int8 uint8_t;
typedef signed __int16 int16_t;
typedef unsigned __int16 uint16_t; typedef unsigned __int16 uint16_t;
typedef signed __int32 int32_t;
typedef unsigned __int32 uint32_t; typedef unsigned __int32 uint32_t;
#else
#include "SDL_config.h"
#endif
typedef signed __int64 int64_t;
typedef unsigned __int64 uint64_t; typedef unsigned __int64 uint64_t;
# ifdef __cplusplus # ifdef __cplusplus
namespace std namespace std

View file

@ -16,19 +16,26 @@ EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32 Debug|Win32 = Debug|Win32
Debug-SDL1.2|Win32 = Debug-SDL1.2|Win32
Release|Win32 = Release|Win32 Release|Win32 = Release|Win32
EndGlobalSection EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution GlobalSection(ProjectConfigurationPlatforms) = postSolution
{4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Debug|Win32.ActiveCfg = Debug|Win32 {4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Debug|Win32.ActiveCfg = Debug|Win32
{4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Debug|Win32.Build.0 = Debug|Win32 {4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Debug|Win32.Build.0 = Debug|Win32
{4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Debug-SDL1.2|Win32.ActiveCfg = Debug-SDL1.2|Win32
{4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Debug-SDL1.2|Win32.Build.0 = Debug-SDL1.2|Win32
{4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Release|Win32.ActiveCfg = Release|Win32 {4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Release|Win32.ActiveCfg = Release|Win32
{4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Release|Win32.Build.0 = Release|Win32 {4DB6D5AA-4EAD-4195-9B54-389B558036D8}.Release|Win32.Build.0 = Release|Win32
{4C2AD812-6776-4728-A4B0-ABA397224152}.Debug|Win32.ActiveCfg = Debug|Win32 {4C2AD812-6776-4728-A4B0-ABA397224152}.Debug|Win32.ActiveCfg = Debug|Win32
{4C2AD812-6776-4728-A4B0-ABA397224152}.Debug|Win32.Build.0 = Debug|Win32 {4C2AD812-6776-4728-A4B0-ABA397224152}.Debug|Win32.Build.0 = Debug|Win32
{4C2AD812-6776-4728-A4B0-ABA397224152}.Debug-SDL1.2|Win32.ActiveCfg = Debug-SDL1.2|Win32
{4C2AD812-6776-4728-A4B0-ABA397224152}.Debug-SDL1.2|Win32.Build.0 = Debug-SDL1.2|Win32
{4C2AD812-6776-4728-A4B0-ABA397224152}.Release|Win32.ActiveCfg = Release|Win32 {4C2AD812-6776-4728-A4B0-ABA397224152}.Release|Win32.ActiveCfg = Release|Win32
{4C2AD812-6776-4728-A4B0-ABA397224152}.Release|Win32.Build.0 = Release|Win32 {4C2AD812-6776-4728-A4B0-ABA397224152}.Release|Win32.Build.0 = Release|Win32
{6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Debug|Win32.ActiveCfg = Debug|Win32 {6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Debug|Win32.ActiveCfg = Debug|Win32
{6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Debug|Win32.Build.0 = Debug|Win32 {6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Debug|Win32.Build.0 = Debug|Win32
{6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Debug-SDL1.2|Win32.ActiveCfg = Debug-SDL1.2|Win32
{6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Debug-SDL1.2|Win32.Build.0 = Debug-SDL1.2|Win32
{6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Release|Win32.ActiveCfg = Release|Win32 {6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Release|Win32.ActiveCfg = Release|Win32
{6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Release|Win32.Build.0 = Release|Win32 {6A2DACD7-DA30-49A1-9214-CCDEB48E6050}.Release|Win32.Build.0 = Release|Win32
EndGlobalSection EndGlobalSection

View file

@ -179,6 +179,83 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug-SDL1.2|Win32"
OutputDirectory="$(SolutionDir)\..\bin"
IntermediateDirectory="$(SolutionDir)\temp\$(ConfigurationName)\$(ProjectName)"
ConfigurationType="1"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
AdditionalOptions="/MP"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include\freetype\config&quot;;&quot;$(SolutionDir)\..\ExternalLibs\gl&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libogg\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libvorbis\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\FTGL\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\SDL12\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\AL\include&quot;;&quot;$(SolutionDir)\..\BBGE&quot;;&quot;$(SolutionDir)\..\ExternalLibs\lua-5.1.4\src&quot;;&quot;$(SolutionDir)\..\ExternalLibs\lvpa\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\lvpa&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs_cfileapi&quot;;&quot;$(SolutionDir)\..\ExternalLibs&quot;;&quot;$(SolutionDir)\..\ExternalLibs\tinyxml2&quot;;&quot;$(SolutionDir)\..\ExternalLibs\glpng&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;GL_GLEXT_LEGACY=1;HAVE_PUTENV=1;_CRT_SECURE_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;BBGE_BUILD_WINDOWS=1;BBGE_BUILD_VFS=1;VFS_ENABLE_C_API=1;BBGE_USE_GLM=1;AQUARIA_INTERNAL_FTGL=1"
MinimalRebuild="false"
BasicRuntimeChecks="0"
RuntimeLibrary="3"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
OutputFile="$(OutDir)\$(ProjectName)d.exe"
LinkIncremental="2"
AdditionalLibraryDirectories=""
IgnoreDefaultLibraryNames="msvcrt.lib"
GenerateDebugInformation="true"
SubSystem="1"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
@ -468,6 +545,10 @@
RelativePath="..\..\Aquaria\SceneEditor.cpp" RelativePath="..\..\Aquaria\SceneEditor.cpp"
> >
</File> </File>
<File
RelativePath="..\..\Aquaria\SceneEditor.h"
>
</File>
<File <File
RelativePath="..\..\Aquaria\SchoolFish.cpp" RelativePath="..\..\Aquaria\SchoolFish.cpp"
> >

View file

@ -160,6 +160,75 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug-SDL1.2|Win32"
OutputDirectory="$(SolutionDir)\temp\$(ConfigurationName)\$(ProjectName)"
IntermediateDirectory="$(SolutionDir)\temp\$(ConfigurationName)\$(ProjectName)"
ConfigurationType="4"
UseOfMFC="0"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
AdditionalOptions="/MP"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include\freetype\config&quot;;&quot;$(SolutionDir)\..\ExternalLibs\glpng&quot;;&quot;$(SolutionDir)\..\BBGE&quot;;&quot;$(SolutionDir)\..\ExternalLibs\zlib&quot;;&quot;$(SolutionDir)\..\ExternalLibs\png&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libogg\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libvorbis\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\FTGL\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\SDL12\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\AL\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\tinyxml2&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs_cfileapi&quot;;&quot;$(SolutionDir)\..\ExternalLibs\lvpa&quot;;&quot;$(SolutionDir)\..\ExternalLibs\lvpa\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;GL_GLEXT_LEGACY=1;HAVE_PUTENV=1;FTGL_LIBRARY_STATIC;_CRT_SECURE_NO_DEPRECATE;_CRT_SECURE_NO_WARNINGS;BBGE_BUILD_WINDOWS=1;VFS_ENABLE_C_API=1;BBGE_USE_GLM=1;AQUARIA_INTERNAL_FTGL=1"
MinimalRebuild="false"
BasicRuntimeChecks="0"
RuntimeLibrary="3"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
AdditionalDependencies="SDL.lib SDLmain.lib OpenAL32.lib"
AdditionalLibraryDirectories="&quot;$(SolutionDir)\..\ExternalLibs\AL\lib\win32&quot;;&quot;$(SolutionDir)\..\ExternalLibs\SDL12\lib\win32&quot;"
IgnoreAllDefaultLibraries="true"
IgnoreDefaultLibraryNames=""
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
@ -321,6 +390,14 @@
RelativePath="..\..\BBGE\Joystick.h" RelativePath="..\..\BBGE\Joystick.h"
> >
</File> </File>
<File
RelativePath="..\..\BBGE\LegacyKeycodes.cpp"
>
</File>
<File
RelativePath="..\..\BBGE\LegacyKeycodes.h"
>
</File>
<File <File
RelativePath="..\..\BBGE\LensFlare.cpp" RelativePath="..\..\BBGE\LensFlare.cpp"
> >

View file

@ -117,7 +117,6 @@
OmitFramePointers="true" OmitFramePointers="true"
EnableFiberSafeOptimizations="true" EnableFiberSafeOptimizations="true"
AdditionalIncludeDirectories="&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include\freetype\config&quot;;&quot;$(SolutionDir)\..\BBGE&quot;;&quot;$(SolutionDir)\..\ExternalLibs\zlib&quot;;&quot;$(SolutionDir)\..\ExternalLibs\png&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libogg\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libvorbis\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\FTGL\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\SDL2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs_cfileapi&quot;;&quot;$(SolutionDir)\..\ExternalLibs\&quot;" AdditionalIncludeDirectories="&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include\freetype\config&quot;;&quot;$(SolutionDir)\..\BBGE&quot;;&quot;$(SolutionDir)\..\ExternalLibs\zlib&quot;;&quot;$(SolutionDir)\..\ExternalLibs\png&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libogg\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libvorbis\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\FTGL\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\SDL2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs_cfileapi&quot;;&quot;$(SolutionDir)\..\ExternalLibs\&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPRECATE;HAVE_FCNTL_H;FT_CONFIG_OPTION_SYSTEM_ZLIB;FTGL_LIBRARY_STATIC;FT2_BUILD_LIBRARY;GL_GLEXT_LEGACY=1;TIXML_USE_STL=1;HAVE_PUTENV=1;_HAS_EXCEPTIONS=0;VFS_ENABLE_C_API=1" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPRECATE;HAVE_FCNTL_H;FT_CONFIG_OPTION_SYSTEM_ZLIB;FTGL_LIBRARY_STATIC;FT2_BUILD_LIBRARY;GL_GLEXT_LEGACY=1;TIXML_USE_STL=1;HAVE_PUTENV=1;_HAS_EXCEPTIONS=0;VFS_ENABLE_C_API=1"
StringPooling="true" StringPooling="true"
ExceptionHandling="0" ExceptionHandling="0"
@ -162,6 +161,75 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug-SDL1.2|Win32"
OutputDirectory="$(SolutionDir)\temp\$(ConfigurationName)\$(ProjectName)"
IntermediateDirectory="$(SolutionDir)\temp\$(ConfigurationName)\$(ProjectName)"
ConfigurationType="4"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
AdditionalOptions="/MP"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include\freetype\config&quot;;&quot;$(SolutionDir)\..\ExternalLibs\gl&quot;;&quot;$(SolutionDir)\..\ExternalLibs\zlib&quot;;&quot;$(SolutionDir)\..\ExternalLibs\png&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libogg\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\libvorbis\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\freetype2\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\FTGL\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\SDL12\include&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs&quot;;&quot;$(SolutionDir)\..\ExternalLibs\ttvfs_cfileapi&quot;;&quot;$(SolutionDir)\..\ExternalLibs\glpng&quot;;&quot;$(SolutionDir)\..\ExternalLibs\&quot;;&quot;$(SolutionDir)\..\ExternalLibs\tinyxml2&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPRECATE;HAVE_FCNTL_H;FT_CONFIG_OPTION_SYSTEM_ZLIB;FTGL_LIBRARY_STATIC;FT2_BUILD_LIBRARY;GL_GLEXT_LEGACY=1;HAVE_PUTENV=1;VFS_ENABLE_C_API=1"
MinimalRebuild="false"
BasicRuntimeChecks="0"
RuntimeLibrary="3"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="4"
DisableSpecificWarnings="4244;4996;4305;4800"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
AdditionalDependencies="ws2_32.lib"
AdditionalLibraryDirectories=""
IgnoreAllDefaultLibraries="true"
IgnoreDefaultLibraryNames=""
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>