mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-28 23:11:58 +00:00
- fixed compile errors in POSIX platform code.
This commit is contained in:
parent
12e69adec3
commit
4da2351671
18 changed files with 45 additions and 20 deletions
|
@ -605,6 +605,7 @@ file( GLOB HEADER_FILES
|
||||||
common/console/*.h
|
common/console/*.h
|
||||||
common/utility/*.h
|
common/utility/*.h
|
||||||
common/engine/*.h
|
common/engine/*.h
|
||||||
|
common/menu/*.h
|
||||||
common/fonts/*.h
|
common/fonts/*.h
|
||||||
common/objects/*.h
|
common/objects/*.h
|
||||||
common/filesystem/*.h
|
common/filesystem/*.h
|
||||||
|
@ -1251,6 +1252,7 @@ include_directories( .
|
||||||
common/utility
|
common/utility
|
||||||
common/console
|
common/console
|
||||||
common/engine
|
common/engine
|
||||||
|
common/menu
|
||||||
common/fonts
|
common/fonts
|
||||||
common/objects
|
common/objects
|
||||||
common/rendering
|
common/rendering
|
||||||
|
@ -1457,6 +1459,7 @@ source_group("Common\\Utility" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/
|
||||||
source_group("Common\\Engine" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/engine/.+")
|
source_group("Common\\Engine" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/engine/.+")
|
||||||
source_group("Common\\2D" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/2d/.+")
|
source_group("Common\\2D" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/2d/.+")
|
||||||
source_group("Common\\Objects" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/objects/.+")
|
source_group("Common\\Objects" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/objects/.+")
|
||||||
|
source_group("Common\\Menu" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/menu/.+")
|
||||||
source_group("Common\\Fonts" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/fonts/.+")
|
source_group("Common\\Fonts" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/fonts/.+")
|
||||||
source_group("Common\\File System" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/filesystem/.+")
|
source_group("Common\\File System" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/filesystem/.+")
|
||||||
source_group("Common\\Scripting" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/scripting/.+")
|
source_group("Common\\Scripting" REGULAR_EXPRESSION "^${CMAKE_CURRENT_SOURCE_DIR}/common/scripting/.+")
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include "zstring.h"
|
||||||
|
|
||||||
struct SystemCallbacks
|
struct SystemCallbacks
|
||||||
{
|
{
|
||||||
|
@ -13,3 +14,11 @@ struct SystemCallbacks
|
||||||
};
|
};
|
||||||
|
|
||||||
extern SystemCallbacks *sysCallbacks;
|
extern SystemCallbacks *sysCallbacks;
|
||||||
|
|
||||||
|
struct WadStuff
|
||||||
|
{
|
||||||
|
FString Path;
|
||||||
|
FString Name;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include <stdint.h>
|
||||||
|
#include "zstring.h"
|
||||||
|
|
||||||
struct FStartupInfo
|
struct FStartupInfo
|
||||||
{
|
{
|
||||||
FString Name;
|
FString Name;
|
||||||
|
|
10
src/common/menu/menustate.h
Normal file
10
src/common/menu/menustate.h
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
enum EMenuState : int
|
||||||
|
{
|
||||||
|
MENU_Off, // Menu is closed
|
||||||
|
MENU_On, // Menu is opened
|
||||||
|
MENU_WaitKey, // Menu is opened and waiting for a key in the controls menu
|
||||||
|
MENU_OnNoPause, // Menu is opened but does not pause the game
|
||||||
|
};
|
||||||
|
extern EMenuState menuactive; // Menu overlayed?
|
|
@ -47,6 +47,7 @@
|
||||||
#include "engineerrors.h"
|
#include "engineerrors.h"
|
||||||
#include "v_text.h"
|
#include "v_text.h"
|
||||||
#include "findfile.h"
|
#include "findfile.h"
|
||||||
|
#include "i_interface.h"
|
||||||
|
|
||||||
CVAR (Bool, queryiwad, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
CVAR (Bool, queryiwad, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
||||||
CVAR (String, defaultiwad, "", CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
CVAR (String, defaultiwad, "", CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
||||||
|
|
|
@ -2685,7 +2685,7 @@ void System_CrashInfo(char* buffer, size_t bufflen, const char *lfstr)
|
||||||
buffer += mysnprintf(buffer, buffend - buffer, "%s%sviewx = %f", lfstr, lfstr, vp.Pos.X);
|
buffer += mysnprintf(buffer, buffend - buffer, "%s%sviewx = %f", lfstr, lfstr, vp.Pos.X);
|
||||||
buffer += mysnprintf(buffer, buffend - buffer, "%sviewy = %f", lfstr, vp.Pos.Y);
|
buffer += mysnprintf(buffer, buffend - buffer, "%sviewy = %f", lfstr, vp.Pos.Y);
|
||||||
buffer += mysnprintf(buffer, buffend - buffer, "%sviewz = %f", lfstr, vp.Pos.Z);
|
buffer += mysnprintf(buffer, buffend - buffer, "%sviewz = %f", lfstr, vp.Pos.Z);
|
||||||
buffer += mysnprintf(buffer, buffend - buffer, "%sviewangle = %f", lfstr, vp.Angles.Yaw);
|
buffer += mysnprintf(buffer, buffend - buffer, "%sviewangle = %f", lfstr, vp.Angles.Yaw.Degrees);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
buffer += mysnprintf(buffer, buffend - buffer, "%s", lfstr);
|
buffer += mysnprintf(buffer, buffend - buffer, "%s", lfstr);
|
||||||
|
|
|
@ -66,12 +66,6 @@ extern const char *D_DrawIcon;
|
||||||
extern uint32_t r_renderercaps;
|
extern uint32_t r_renderercaps;
|
||||||
|
|
||||||
|
|
||||||
struct WadStuff
|
|
||||||
{
|
|
||||||
FString Path;
|
|
||||||
FString Name;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct FIWADInfo
|
struct FIWADInfo
|
||||||
{
|
{
|
||||||
FString Name; // Title banner text for this IWAD
|
FString Name; // Title banner text for this IWAD
|
||||||
|
|
|
@ -105,16 +105,9 @@ EXTERN_CVAR (Float, snd_musicvolume) // maximum volume for music
|
||||||
// Status flags for refresh.
|
// Status flags for refresh.
|
||||||
//
|
//
|
||||||
|
|
||||||
enum EMenuState : int
|
#include "menustate.h"
|
||||||
{
|
|
||||||
MENU_Off, // Menu is closed
|
|
||||||
MENU_On, // Menu is opened
|
|
||||||
MENU_WaitKey, // Menu is opened and waiting for a key in the controls menu
|
|
||||||
MENU_OnNoPause, // Menu is opened but does not pause the game
|
|
||||||
};
|
|
||||||
|
|
||||||
extern bool automapactive; // In AutoMap mode?
|
extern bool automapactive; // In AutoMap mode?
|
||||||
extern EMenuState menuactive; // Menu overlayed?
|
|
||||||
extern int paused; // Game Pause?
|
extern int paused; // Game Pause?
|
||||||
extern bool pauseext;
|
extern bool pauseext;
|
||||||
|
|
||||||
|
|
|
@ -44,6 +44,8 @@
|
||||||
#include "dikeys.h"
|
#include "dikeys.h"
|
||||||
#include "v_video.h"
|
#include "v_video.h"
|
||||||
#include "i_interface.h"
|
#include "i_interface.h"
|
||||||
|
#include "menustate.h"
|
||||||
|
#include "engineerrors.h"
|
||||||
|
|
||||||
|
|
||||||
EXTERN_CVAR(Int, m_use_mouse)
|
EXTERN_CVAR(Int, m_use_mouse)
|
||||||
|
@ -77,7 +79,7 @@ void CheckGUICapture()
|
||||||
if (wantCapt != GUICapture)
|
if (wantCapt != GUICapture)
|
||||||
{
|
{
|
||||||
GUICapture = wantCapt;
|
GUICapture = wantCapt;
|
||||||
if (wantCapt && Keyboard != NULL)
|
if (wantCapt)
|
||||||
{
|
{
|
||||||
buttonMap.ResetButtonStates();
|
buttonMap.ResetButtonStates();
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,6 +45,7 @@
|
||||||
#include "version.h"
|
#include "version.h"
|
||||||
#include "printf.h"
|
#include "printf.h"
|
||||||
#include "s_music.h"
|
#include "s_music.h"
|
||||||
|
#include "engineerrors.h"
|
||||||
|
|
||||||
|
|
||||||
#define ZD_UNUSED(VARIABLE) ((void)(VARIABLE))
|
#define ZD_UNUSED(VARIABLE) ((void)(VARIABLE))
|
||||||
|
|
|
@ -346,7 +346,7 @@ void FConsoleWindow::SetTitleText()
|
||||||
}
|
}
|
||||||
|
|
||||||
NSTextField* titleText = [[NSTextField alloc] initWithFrame:titleTextRect];
|
NSTextField* titleText = [[NSTextField alloc] initWithFrame:titleTextRect];
|
||||||
[titleText setStringValue:[NSString stringWithCString:GameStartupInfo.Name
|
[titleText setStringValue:[NSString stringWithCString:GameStartupInfo.Name.GetChars()
|
||||||
encoding:NSISOLatin1StringEncoding]];
|
encoding:NSISOLatin1StringEncoding]];
|
||||||
[titleText setAlignment:NSCenterTextAlignment];
|
[titleText setAlignment:NSCenterTextAlignment];
|
||||||
[titleText setTextColor:RGB(GameStartupInfo.FgColor)];
|
[titleText setTextColor:RGB(GameStartupInfo.FgColor)];
|
||||||
|
|
|
@ -39,6 +39,7 @@
|
||||||
#include "m_argv.h"
|
#include "m_argv.h"
|
||||||
#include "gameconfigfile.h"
|
#include "gameconfigfile.h"
|
||||||
#include "engineerrors.h"
|
#include "engineerrors.h"
|
||||||
|
#include "i_interface.h"
|
||||||
|
|
||||||
#include <Cocoa/Cocoa.h>
|
#include <Cocoa/Cocoa.h>
|
||||||
#include <wordexp.h>
|
#include <wordexp.h>
|
||||||
|
|
|
@ -43,6 +43,8 @@
|
||||||
#include "utf8.h"
|
#include "utf8.h"
|
||||||
#include "keydef.h"
|
#include "keydef.h"
|
||||||
#include "i_interface.h"
|
#include "i_interface.h"
|
||||||
|
#include "engineerrors.h"
|
||||||
|
#include "i_interface.h"
|
||||||
|
|
||||||
|
|
||||||
static void I_CheckGUICapture ();
|
static void I_CheckGUICapture ();
|
||||||
|
@ -170,7 +172,7 @@ static void I_CheckGUICapture ()
|
||||||
if (wantCapt != GUICapture)
|
if (wantCapt != GUICapture)
|
||||||
{
|
{
|
||||||
GUICapture = wantCapt;
|
GUICapture = wantCapt;
|
||||||
if (wantCapt && Keyboard != NULL)
|
if (wantCapt)
|
||||||
{
|
{
|
||||||
buttonMap.ResetButtonStates();
|
buttonMap.ResetButtonStates();
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,6 +48,7 @@
|
||||||
#include "cmdlib.h"
|
#include "cmdlib.h"
|
||||||
#include "engineerrors.h"
|
#include "engineerrors.h"
|
||||||
#include "i_system.h"
|
#include "i_system.h"
|
||||||
|
#include "i_interface.h"
|
||||||
|
|
||||||
// MACROS ------------------------------------------------------------------
|
// MACROS ------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
@ -60,6 +60,7 @@ typedef enum
|
||||||
#include "version.h"
|
#include "version.h"
|
||||||
#include "startupinfo.h"
|
#include "startupinfo.h"
|
||||||
#include "cmdlib.h"
|
#include "cmdlib.h"
|
||||||
|
#include "i_interface.h"
|
||||||
|
|
||||||
EXTERN_CVAR (Bool, queryiwad);
|
EXTERN_CVAR (Bool, queryiwad);
|
||||||
|
|
||||||
|
|
|
@ -460,7 +460,9 @@ void HWWall::PutWall(HWDrawInfo *di, bool translucent)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (di->isFullbrightScene() || (Colormap.LightColor.isWhite() && lightlevel == 255))
|
if (di->isFullbrightScene() || (Colormap.LightColor.isWhite() && lightlevel == 255))
|
||||||
|
{
|
||||||
flags &= ~HWF_GLOW;
|
flags &= ~HWF_GLOW;
|
||||||
|
}
|
||||||
|
|
||||||
if (!screen->BuffersArePersistent())
|
if (!screen->BuffersArePersistent())
|
||||||
{
|
{
|
||||||
|
|
|
@ -188,6 +188,7 @@ void Draw2D(F2DDrawer *drawer, FRenderState &state)
|
||||||
|
|
||||||
switch (cmd.mType)
|
switch (cmd.mType)
|
||||||
{
|
{
|
||||||
|
default:
|
||||||
case F2DDrawer::DrawTypeTriangles:
|
case F2DDrawer::DrawTypeTriangles:
|
||||||
state.DrawIndexed(DT_Triangles, cmd.mIndexIndex, cmd.mIndexCount);
|
state.DrawIndexed(DT_Triangles, cmd.mIndexIndex, cmd.mIndexCount);
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -84,6 +84,7 @@
|
||||||
#include "i_system.h"
|
#include "i_system.h"
|
||||||
#include "bitmap.h"
|
#include "bitmap.h"
|
||||||
#include "cmdlib.h"
|
#include "cmdlib.h"
|
||||||
|
#include "i_interface.h"
|
||||||
|
|
||||||
// MACROS ------------------------------------------------------------------
|
// MACROS ------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue