no message
This was SVN commit r275.
This commit is contained in:
parent
51375831f1
commit
9aacf9b4bf
@ -21,6 +21,8 @@
|
||||
#include "lib.h"
|
||||
#include "res.h"
|
||||
|
||||
// provision for removing all ZLib code (all inflate calls will fail).
|
||||
// used for checking DLL dependency; might also simulate corrupt Zip files.
|
||||
//#define NO_ZLIB
|
||||
|
||||
#ifndef NO_ZLIB
|
||||
|
@ -131,10 +131,6 @@ static void at_exit(void)
|
||||
{
|
||||
for(int i = 0; i < NUM_CS; i++)
|
||||
DeleteCriticalSection(&cs[i]);
|
||||
|
||||
// redirected to stdout.txt in pre_main_init;
|
||||
// close to avoid BoundsChecker warning.
|
||||
fclose(stdout);
|
||||
}
|
||||
|
||||
|
||||
|
@ -376,6 +376,8 @@ int SDL_Init(Uint32 flags)
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* set video mode wxh:bpp if necessary.
|
||||
* w = h = bpp = 0 => no change.
|
||||
@ -466,7 +468,7 @@ inline void SDL_GL_SwapBuffers()
|
||||
}
|
||||
|
||||
|
||||
static int calc_gamma(float gamma, u16* ramp)
|
||||
static int calc_gamma_ramp(float gamma, u16* ramp)
|
||||
{
|
||||
if(gamma <= 0.0f)
|
||||
return ERR_INVALID_PARAM;
|
||||
@ -496,9 +498,9 @@ static int calc_gamma(float gamma, u16* ramp)
|
||||
int SDL_SetGamma(float r, float g, float b)
|
||||
{
|
||||
u16 ramp[3][256];
|
||||
CHECK_ERR(calc_gamma(r, ramp[0]));
|
||||
CHECK_ERR(calc_gamma(g, ramp[1]));
|
||||
CHECK_ERR(calc_gamma(b, ramp[2]));
|
||||
CHECK_ERR(calc_gamma_ramp(r, ramp[0]));
|
||||
CHECK_ERR(calc_gamma_ramp(g, ramp[1]));
|
||||
CHECK_ERR(calc_gamma_ramp(b, ramp[2]));
|
||||
return SetDeviceGammaRamp(hDC, ramp)? 0 : -1;
|
||||
}
|
||||
|
||||
@ -506,6 +508,10 @@ int SDL_SetGamma(float r, float g, float b)
|
||||
|
||||
void SDL_Quit()
|
||||
{
|
||||
// redirected to stdout.txt in SDL_Init;
|
||||
// close to avoid BoundsChecker warning.
|
||||
fclose(stdout);
|
||||
|
||||
if(hDC != INVALID_HANDLE_VALUE)
|
||||
{
|
||||
ReleaseDC(hWnd, hDC);
|
||||
|
@ -71,7 +71,7 @@ static int write_sys_info()
|
||||
struct utsname un;
|
||||
uname(&un);
|
||||
|
||||
FILE* const f = fopen("../system/system_info.txt", "w");
|
||||
FILE* const f = fopen("../logs/system_info.txt", "w");
|
||||
if(!f)
|
||||
return -1;
|
||||
|
||||
@ -410,6 +410,7 @@ int main(int argc, char* argv[])
|
||||
ParseArgs(argc, argv);
|
||||
|
||||
|
||||
|
||||
lib_init();
|
||||
|
||||
// set 24 bit (float) FPU precision for faster divides / sqrts
|
||||
@ -434,6 +435,7 @@ int main(int argc, char* argv[])
|
||||
atexit(SDL_Quit);
|
||||
SDL_EnableUNICODE(1);
|
||||
|
||||
|
||||
// preferred video mode = current desktop settings
|
||||
// (command line params may override these)
|
||||
get_cur_resolution(g_xres, g_yres);
|
||||
@ -469,6 +471,7 @@ int main(int argc, char* argv[])
|
||||
|
||||
new CConfig;
|
||||
|
||||
// vfs_mount("gui", "gui", 0);
|
||||
vfs_mount("", "mods/official/", 0);
|
||||
//// dir_add_watch("mods\\official", false);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user