mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-10 14:12:04 +08:00
engine: initialize default video mode in refState global, as we don't support reloading engine without reinitializing globals anyway
This commit is contained in:
@@ -6,7 +6,13 @@
|
||||
#include "vid_common.h"
|
||||
|
||||
struct ref_state_s ref;
|
||||
ref_globals_t refState;
|
||||
|
||||
ref_globals_t refState =
|
||||
{
|
||||
// just have something valid until video subsystem is finished initializing
|
||||
.width = 640,
|
||||
.height = 480,
|
||||
};
|
||||
|
||||
static const char* r_skyBoxSuffix[SKYBOX_MAX_SIDES] = { "rt", "bk", "lf", "ft", "up", "dn" };
|
||||
|
||||
|
||||
@@ -34,19 +34,6 @@ CVAR_DEFINE( window_ypos, "_window_ypos", "-1", FCVAR_RENDERINFO, "window positi
|
||||
|
||||
glwstate_t glw_state;
|
||||
|
||||
/*
|
||||
=================
|
||||
VID_InitDefaultResolution
|
||||
=================
|
||||
*/
|
||||
void VID_InitDefaultResolution( void )
|
||||
{
|
||||
// we need to have something valid here
|
||||
// until video subsystem initialized
|
||||
refState.width = 640;
|
||||
refState.height = 480;
|
||||
}
|
||||
|
||||
/*
|
||||
=================
|
||||
R_SaveVideoMode
|
||||
|
||||
@@ -824,7 +824,6 @@ uint LZSS_GetActualSize( const byte *source, size_t input_len );
|
||||
byte *LZSS_Compress( byte *pInput, int inputLength, uint *pOutputSize );
|
||||
uint LZSS_Decompress( const byte *pInput, byte *pOutput, size_t input_len, size_t output_len );
|
||||
void GL_FreeImage( const char *name );
|
||||
void VID_InitDefaultResolution( void );
|
||||
void VID_Init( void );
|
||||
void UI_SetActiveMenu( qboolean fActive );
|
||||
void UI_ShowConnectionWarning( void );
|
||||
|
||||
@@ -88,11 +88,6 @@ void Host_InputFrame( void )
|
||||
{
|
||||
}
|
||||
|
||||
void VID_InitDefaultResolution( void )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void Con_Init( void )
|
||||
{
|
||||
|
||||
|
||||
@@ -1074,9 +1074,6 @@ static void Host_InitCommon( int argc, char **argv, const char *progname, qboole
|
||||
// NOTE: this message couldn't be passed into game console but it doesn't matter
|
||||
// Con_Reportf( "Sys_LoadLibrary: Loading xash.dll - ok\n" );
|
||||
|
||||
// get default screen res
|
||||
VID_InitDefaultResolution();
|
||||
|
||||
// init host state machine
|
||||
COM_InitHostState();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user