From 434efc92fc320ccdb33442b4879e40704f5326d6 Mon Sep 17 00:00:00 2001 From: havoc Date: Fri, 2 Jul 2010 09:00:08 +0000 Subject: [PATCH] created new MSVC2008 project files and solution from scratch fixed several warnings in MSVC2008 git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10266 d7cf8633-e32d-0410-b094-e92efae38249 --- cl_particles.c | 7 +- darkplaces-dedicated.vcproj | 5383 +++-------------------------- darkplaces-sdl.vcproj | 6340 +++-------------------------------- darkplaces-wgl.vcproj | 925 +++++ darkplaces.sln | 61 +- darkplaces.vcproj | 2465 -------------- gl_rmain.c | 8 +- gl_textures.c | 4 +- glquake.h | 9 +- model_shared.c | 2 +- prvm_edict.c | 2 + r_shadow.c | 2 +- sys_sdl.c | 2 + 13 files changed, 1844 insertions(+), 13366 deletions(-) create mode 100644 darkplaces-wgl.vcproj delete mode 100755 darkplaces.vcproj diff --git a/cl_particles.c b/cl_particles.c index 2cc4e658..cd169ebb 100644 --- a/cl_particles.c +++ b/cl_particles.c @@ -1687,16 +1687,15 @@ void CL_ParticleExplosion (const vec3_t org) { for (i = 0;i < 512 * cl_particles_quality.value;i++) { - int k; + int k = 0; vec3_t v, v2; - for (k = 0;k < 16;k++) + do { VectorRandom(v2); VectorMA(org, 128, v2, v); trace = CL_TraceLine(org, v, MOVE_NOMONSTERS, NULL, SUPERCONTENTS_SOLID, true, false, NULL, false); - if (trace.fraction >= 0.1) - break; } + while (k < 16 && trace.fraction < 0.1f); VectorSubtract(trace.endpos, org, v2); VectorScale(v2, 2.0f, v2); CL_NewParticle(org, pt_spark, 0x903010, 0xFFD030, tex_particle, 1.0f, 0, lhrandom(0, 255), 512, 0, 0, org[0], org[1], org[2], v2[0], v2[1], v2[2], 0, 0, 0, 0, true, 0, 1, PBLEND_ADD, PARTICLE_SPARK, -1, -1, -1, 1, 1, 0, 0, NULL); diff --git a/darkplaces-dedicated.vcproj b/darkplaces-dedicated.vcproj index da7b3c38..d9aefa6f 100755 --- a/darkplaces-dedicated.vcproj +++ b/darkplaces-dedicated.vcproj @@ -3,204 +3,24 @@ ProjectType="Visual C++" Version="9.00" Name="darkplaces-dedicated" - ProjectGUID="{F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}" - RootNamespace="darkplaces-dedicated" - TargetFrameworkVersion="131072" + ProjectGUID="{389AE334-D907-4069-90B3-F0551B3EFDE9}" + RootNamespace="darkplacesdedicated" + Keyword="Win32Proj" + TargetFrameworkVersion="196613" > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\builddate.c" + > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\cd_null.c" + > + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\cl_input.c" + > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\gl_backend.c" + > + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\host.c" + > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\vid_null.c" + > + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/darkplaces-sdl.vcproj b/darkplaces-sdl.vcproj index 75ff140a..db073727 100755 --- a/darkplaces-sdl.vcproj +++ b/darkplaces-sdl.vcproj @@ -3,208 +3,24 @@ ProjectType="Visual C++" Version="9.00" Name="darkplaces-sdl" - ProjectGUID="{4C61C95C-3753-46B8-B817-4D57E48A9C45}" - RootNamespace="darkplaces-sdl" - TargetFrameworkVersion="131072" + ProjectGUID="{7470C8B3-FCA7-42D3-9909-5F9E735C7C51}" + RootNamespace="darkplacessdl" + Keyword="Win32Proj" + TargetFrameworkVersion="196613" > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\builddate.c" + > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\cd_sdl.c" + > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\gl_backend.c" + > + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\host.c" + > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + RelativePath=".\vid_sdl.c" + > + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/darkplaces-wgl.vcproj b/darkplaces-wgl.vcproj new file mode 100644 index 00000000..3c736357 --- /dev/null +++ b/darkplaces-wgl.vcproj @@ -0,0 +1,925 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/darkplaces.sln b/darkplaces.sln index 572b9880..e2bed35a 100755 --- a/darkplaces.sln +++ b/darkplaces.sln @@ -1,63 +1,32 @@  Microsoft Visual Studio Solution File, Format Version 10.00 # Visual Studio 2008 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "darkplaces", "darkplaces.vcproj", "{2A31FD21-E0DF-462F-BB97-844CCD7B9E19}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "darkplaces-wgl", "darkplaces-wgl.vcproj", "{6E3D4311-BB84-4EB7-8C6C-10AA3D249C28}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "darkplaces-dedicated", "darkplaces-dedicated.vcproj", "{F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "darkplaces-sdl", "darkplaces-sdl.vcproj", "{7470C8B3-FCA7-42D3-9909-5F9E735C7C51}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "darkplaces-sdl", "darkplaces-sdl.vcproj", "{4C61C95C-3753-46B8-B817-4D57E48A9C45}" +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "darkplaces-dedicated", "darkplaces-dedicated.vcproj", "{389AE334-D907-4069-90B3-F0551B3EFDE9}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 - Debug|x64 = Debug|x64 - Profile|Win32 = Profile|Win32 - Profile|x64 = Profile|x64 Release|Win32 = Release|Win32 - Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Debug|Win32.ActiveCfg = Debug|Win32 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Debug|Win32.Build.0 = Debug|Win32 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Debug|x64.ActiveCfg = Debug|x64 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Debug|x64.Build.0 = Debug|x64 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Profile|Win32.ActiveCfg = Profile|Win32 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Profile|Win32.Build.0 = Profile|Win32 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Profile|x64.ActiveCfg = Profile|x64 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Profile|x64.Build.0 = Profile|x64 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Release|Win32.ActiveCfg = Release|Win32 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Release|Win32.Build.0 = Release|Win32 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Release|x64.ActiveCfg = Release|x64 - {2A31FD21-E0DF-462F-BB97-844CCD7B9E19}.Release|x64.Build.0 = Release|x64 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Debug|Win32.ActiveCfg = Debug|Win32 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Debug|Win32.Build.0 = Debug|Win32 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Debug|x64.ActiveCfg = Debug|x64 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Debug|x64.Build.0 = Debug|x64 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Profile|Win32.ActiveCfg = Profile|Win32 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Profile|Win32.Build.0 = Profile|Win32 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Profile|x64.ActiveCfg = Profile|x64 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Profile|x64.Build.0 = Profile|x64 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Release|Win32.ActiveCfg = Release|Win32 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Release|Win32.Build.0 = Release|Win32 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Release|x64.ActiveCfg = Release|x64 - {F8FBA9F0-F4E4-4B22-B6D1-21F7FB9C72F7}.Release|x64.Build.0 = Release|x64 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Debug|Win32.ActiveCfg = Debug|Win32 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Debug|Win32.Build.0 = Debug|Win32 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Debug|x64.ActiveCfg = Debug|x64 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Debug|x64.Build.0 = Debug|x64 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Profile|Win32.ActiveCfg = Profile|Win32 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Profile|Win32.Build.0 = Profile|Win32 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Profile|x64.ActiveCfg = Profile|x64 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Profile|x64.Build.0 = Profile|x64 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Release|Win32.ActiveCfg = Release|Win32 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Release|Win32.Build.0 = Release|Win32 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Release|x64.ActiveCfg = Release|x64 - {4C61C95C-3753-46B8-B817-4D57E48A9C45}.Release|x64.Build.0 = Release|x64 + {6E3D4311-BB84-4EB7-8C6C-10AA3D249C28}.Debug|Win32.ActiveCfg = Debug|Win32 + {6E3D4311-BB84-4EB7-8C6C-10AA3D249C28}.Debug|Win32.Build.0 = Debug|Win32 + {6E3D4311-BB84-4EB7-8C6C-10AA3D249C28}.Release|Win32.ActiveCfg = Release|Win32 + {6E3D4311-BB84-4EB7-8C6C-10AA3D249C28}.Release|Win32.Build.0 = Release|Win32 + {7470C8B3-FCA7-42D3-9909-5F9E735C7C51}.Debug|Win32.ActiveCfg = Debug|Win32 + {7470C8B3-FCA7-42D3-9909-5F9E735C7C51}.Debug|Win32.Build.0 = Debug|Win32 + {7470C8B3-FCA7-42D3-9909-5F9E735C7C51}.Release|Win32.ActiveCfg = Release|Win32 + {7470C8B3-FCA7-42D3-9909-5F9E735C7C51}.Release|Win32.Build.0 = Release|Win32 + {389AE334-D907-4069-90B3-F0551B3EFDE9}.Debug|Win32.ActiveCfg = Debug|Win32 + {389AE334-D907-4069-90B3-F0551B3EFDE9}.Debug|Win32.Build.0 = Debug|Win32 + {389AE334-D907-4069-90B3-F0551B3EFDE9}.Release|Win32.ActiveCfg = Release|Win32 + {389AE334-D907-4069-90B3-F0551B3EFDE9}.Release|Win32.Build.0 = Release|Win32 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - AMDCaProjectFile = C:\Development\Quake\DarkPlaces\CodeAnalyst\darkplaces.caw - EndGlobalSection EndGlobal diff --git a/darkplaces.vcproj b/darkplaces.vcproj deleted file mode 100755 index f882cced..00000000 --- a/darkplaces.vcproj +++ /dev/null @@ -1,2465 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/gl_rmain.c b/gl_rmain.c index 24b6dfd8..6e3e34f1 100644 --- a/gl_rmain.c +++ b/gl_rmain.c @@ -7365,8 +7365,8 @@ void R_ResetViewRendering2D(void) qglEnable(GL_POLYGON_OFFSET_FILL);CHECKGLERROR qglDepthFunc(GL_LEQUAL);CHECKGLERROR qglDisable(GL_STENCIL_TEST);CHECKGLERROR - qglStencilMask(~0);CHECKGLERROR - qglStencilFunc(GL_ALWAYS, 128, ~0);CHECKGLERROR + qglStencilMask(255);CHECKGLERROR + qglStencilFunc(GL_ALWAYS, 128, 255);CHECKGLERROR qglStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);CHECKGLERROR GL_CullFace(GL_FRONT); // quake is backwards, this culls back faces } @@ -7391,8 +7391,8 @@ void R_ResetViewRendering3D(void) qglEnable(GL_POLYGON_OFFSET_FILL);CHECKGLERROR qglDepthFunc(GL_LEQUAL);CHECKGLERROR qglDisable(GL_STENCIL_TEST);CHECKGLERROR - qglStencilMask(~0);CHECKGLERROR - qglStencilFunc(GL_ALWAYS, 128, ~0);CHECKGLERROR + qglStencilMask(255);CHECKGLERROR + qglStencilFunc(GL_ALWAYS, 128, 255);CHECKGLERROR qglStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);CHECKGLERROR GL_CullFace(r_refdef.view.cullface_back); } diff --git a/gl_textures.c b/gl_textures.c index bcf79232..47981b43 100644 --- a/gl_textures.c +++ b/gl_textures.c @@ -749,7 +749,7 @@ static void GL_SetupTextureParameters(int flags, textype_t textype, int texturet static void R_Upload(gltexture_t *glt, const unsigned char *data, int fragx, int fragy, int fragz, int fragwidth, int fragheight, int fragdepth) { int i, mip, width, height, depth; - GLint oldbindtexnum; + GLint oldbindtexnum = 0; const unsigned char *prevbuffer; prevbuffer = data; @@ -1220,7 +1220,7 @@ rtexture_t *R_LoadTextureDDSFile(rtexturepool_t *rtexturepool, const char *filen textypeinfo_t *texinfo; int mip, mipwidth, mipheight, mipsize; unsigned int c; - GLint oldbindtexnum; + GLint oldbindtexnum = 0; const unsigned char *mippixels, *ddspixels; unsigned char *dds; fs_offset_t ddsfilesize; diff --git a/glquake.h b/glquake.h index 4e7ceb8a..cd59c5ae 100644 --- a/glquake.h +++ b/glquake.h @@ -24,8 +24,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // disable data conversion warnings #ifdef _MSC_VER -#pragma warning(disable : 4244) // LordHavoc: MSVC++ 4 x86, double/float -#pragma warning(disable : 4305) // LordHavoc: MSVC++ 6 x86, double/float +//#pragma warning(disable : 4244) // LordHavoc: MSVC++ 4 x86, double/float +//#pragma warning(disable : 4305) // LordHavoc: MSVC++ 6 x86, double/float +//#pragma warning(disable : 4706) // LordHavoc: MSVC++ 2008 x86, assignment within conditional expression +//#pragma warning(disable : 4127) // LordHavoc: MSVC++ 2008 x86, conditional expression is constant +//#pragma warning(disable : 4100) // LordHavoc: MSVC++ 2008 x86, unreferenced formal parameter +//#pragma warning(disable : 4055) // LordHavoc: MSVC++ 2008 x86, 'type cast' from data pointer to function pointer +//#pragma warning(disable : 4054) // LordHavoc: MSVC++ 2008 x86, 'type cast' from function pointer to data pointer #endif diff --git a/model_shared.c b/model_shared.c index eff2960c..0309c7f6 100644 --- a/model_shared.c +++ b/model_shared.c @@ -361,7 +361,7 @@ dp_model_t *Mod_LoadModel(dp_model_t *mod, qboolean crash, qboolean checkdisk) int num; unsigned int crc; void *buf; - fs_offset_t filesize; + fs_offset_t filesize = 0; mod->used = true; diff --git a/prvm_edict.c b/prvm_edict.c index 80803a23..127562f6 100644 --- a/prvm_edict.c +++ b/prvm_edict.c @@ -1893,6 +1893,8 @@ po_t *PRVM_PO_Load(const char *filename, mempool_t *pool) if(!buf) return NULL; + memset(&thisstr, 0, sizeof(thisstr)); // hush compiler warning + po = (po_t *)Mem_Alloc(pool, sizeof(*po)); memset(po, 0, sizeof(*po)); diff --git a/r_shadow.c b/r_shadow.c index d778e789..2155596b 100644 --- a/r_shadow.c +++ b/r_shadow.c @@ -1896,7 +1896,7 @@ void R_Shadow_ValidateCvars(void) Cvar_SetValueQuick(&gl_ext_stenciltwoside, 0); } -static const r_vertexposition_t resetvertexposition[3]; +static const r_vertexposition_t resetvertexposition[3] = {{0, 0, 0}}; void R_Shadow_RenderMode_Begin(void) { diff --git a/sys_sdl.c b/sys_sdl.c index 724eb79d..3c83d793 100644 --- a/sys_sdl.c +++ b/sys_sdl.c @@ -1,6 +1,8 @@ #include "quakedef.h" #ifdef WIN32 +#pragma comment(lib, "sdl.lib") +#pragma comment(lib, "sdlmain.lib") #include #include "conio.h" #else -- 2.39.2