23 months agoRemove the CONFIG_CD macro, and enable faketracks unconditionally.
divverent [Fri, 19 Oct 2018 06:40:49 +0000 (06:40 +0000)]
Remove the CONFIG_CD macro, and enable faketracks unconditionally.

All support for playing back CD-DA has been removed by leaving only the
SDL2 clients, and it is rather unlikely for CD-DA support to come back.
However while doing so, the CONFIG_CD macro was disabled in the makefile
but not the MSVC project, which broke faketracks (i.e. background music
via track003.ogg files) on Linux.

This change removes all #ifdefs for CONFIG_CD as well as its enablement
in the MSVC project, which is basically equivalent to having the feature
always being enabled.

Fixes background music in Quake with ripped music, Nexuiz, Xonotic, and
probably many other DP-based games. Also fixes Xonotic log spam about

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12466 d7cf8633-e32d-0410-b094-e92efae38249

23 months agoRemove GLX build from the travis build script.
divverent [Wed, 17 Oct 2018 16:26:52 +0000 (16:26 +0000)]
Remove GLX build from the travis build script.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12465 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove a duplicate definition of GLDEBUGPROCARB.
havoc [Sun, 9 Sep 2018 01:55:59 +0000 (01:55 +0000)]
Remove a duplicate definition of GLDEBUGPROCARB.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12464 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove a duplicate definition of qglGetPointerv.
havoc [Sun, 9 Sep 2018 01:50:51 +0000 (01:50 +0000)]
Remove a duplicate definition of qglGetPointerv.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12463 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdd CONFIG_CAPTURE_VIDEO in VS projects, this was somehow missed by the author of...
havoc [Sun, 9 Sep 2018 01:41:47 +0000 (01:41 +0000)]
Add CONFIG_CAPTURE_VIDEO in VS projects, this was somehow missed by the author of that define.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12462 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdded vid_conwidthauto cvar which updates vid_conwidth based on vid_conheight and...
havoc [Sun, 9 Sep 2018 01:39:08 +0000 (01:39 +0000)]
Added vid_conwidthauto cvar which updates vid_conwidth based on vid_conheight and aspect ratio (honoring vid_pixelheight), this defaults on for better usability.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12461 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdd GL_ExtensionSupported in vid_null.c because vid_shared.c relies on
havoc [Sun, 9 Sep 2018 00:51:33 +0000 (00:51 +0000)]
Add GL_ExtensionSupported in vid_null.c because vid_shared.c relies on

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12460 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoGo back to defining GL enums ourselves rather than relying on SDL_opengl.h on desktop.
havoc [Sun, 9 Sep 2018 00:38:26 +0000 (00:38 +0000)]
Go back to defining GL enums ourselves rather than relying on SDL_opengl.h on desktop.

Relying on SDL_opengl.h broke the dedicated server build which does not rely on SDL - having better code isolation of the OpenGL code would make this hack unnecessary.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12459 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoDon't apply r_showtris and such to the HUD and other UI elements, now that they are...
havoc [Sat, 8 Sep 2018 20:21:44 +0000 (20:21 +0000)]
Don't apply r_showtris and such to the HUD and other UI elements, now that they are rendered as a model this was happening.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12458 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoUse GL3.2 Core Profile context.
havoc [Sun, 12 Aug 2018 22:11:32 +0000 (22:11 +0000)]
Use GL3.2 Core Profile context.

Create and bind a vertex array object at start, since Core Profile requires it, but gains no benefit in performance from using multiple.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12457 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoA bit more cleanup.
havoc [Sun, 12 Aug 2018 21:35:57 +0000 (21:35 +0000)]
A bit more cleanup.

Add back some GLES2 support - it probably doesn't work but it will eventually.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12456 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRefactored VID_CheckExtensions and GL_Init to GL_Setup.
havoc [Sun, 12 Aug 2018 21:19:01 +0000 (21:19 +0000)]
Refactored VID_CheckExtensions and GL_Init to GL_Setup.

GL_Setup now fetches all GL functions at the start and then verifies extensions after that, and it uses SDL_GL_ExtensionSupported as it should.

Removed a bunch of commandline flags like -noshadow that no longer do anything since we assume GL3.2 features.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12455 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoUse SDL_opengl.h and SDL_opengl_ext.h headers instead of doing our own defines -...
havoc [Sun, 12 Aug 2018 21:02:05 +0000 (21:02 +0000)]
Use SDL_opengl.h and SDL_opengl_ext.h headers instead of doing our own defines - still have to have the qgl function pointers though.

Removed some GLES2 debugging stuff.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12454 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove a lot of OpenGL extension checks.
havoc [Sun, 5 Aug 2018 23:17:18 +0000 (23:17 +0000)]
Remove a lot of OpenGL extension checks.

Rename OpenGL extension functions and defines to core names.

Require the functions for all of the OpenGL3.2 Core Profile functionality - we're not asking for a Core Profile context yet, that will be later.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12453 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoChange a comment and a description to remove mentions of GL_ARB_occlusion_query becau...
havoc [Sun, 5 Aug 2018 22:09:56 +0000 (22:09 +0000)]
Change a comment and a description to remove mentions of GL_ARB_occlusion_query because it is standard in GL3.2.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12452 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoUpload the VBOs for Mod_Mesh models (such as the UI) during Mod_Mesh_Finalize.
havoc [Sun, 5 Aug 2018 21:39:11 +0000 (21:39 +0000)]
Upload the VBOs for Mod_Mesh models (such as the UI) during Mod_Mesh_Finalize.

Refactored the vbooffset handling in models to allow different vertex buffers for each array (this would only happen in the dynamic case when a buffer is recycled - so some code makes that assumption about dynamic buffers when freeing these).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12451 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix UI corruption caused by poor handling of missing VBO with firstvertex > 0.
havoc [Sun, 5 Aug 2018 21:29:44 +0000 (21:29 +0000)]
Fix UI corruption caused by poor handling of missing VBO with firstvertex > 0.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12450 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix gl_debug code which was broken as I didn't copy enough of the headers over from...
havoc [Tue, 31 Jul 2018 02:05:57 +0000 (02:05 +0000)]
Fix gl_debug code which was broken as I didn't copy enough of the headers over from another checkout.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12449 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove some unused stuff related to glDrawRangeElements.
havoc [Tue, 31 Jul 2018 01:35:10 +0000 (01:35 +0000)]
Remove some unused stuff related to glDrawRangeElements.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12448 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoMake the VBO handling in RSurf_PrepareVerticesForBatch much more consistent by refact...
havoc [Sun, 29 Jul 2018 23:35:29 +0000 (23:35 +0000)]
Make the VBO handling in RSurf_PrepareVerticesForBatch much more consistent by refactoring it into RSurf_UploadBuffersForBatch.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12447 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a console dprint about shader compilation that was trying to print a 64bit permut...
havoc [Sun, 29 Jul 2018 23:23:36 +0000 (23:23 +0000)]
Fix a console dprint about shader compilation that was trying to print a 64bit permutation number as 32bit.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12446 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoDisable the code path that compiles geometry shaders - we don't currently use any...
havoc [Sun, 29 Jul 2018 23:22:01 +0000 (23:22 +0000)]
Disable the code path that compiles geometry shaders - we don't currently use any of these and the code path is broken.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12445 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove some old fixed-function state tracking that wasn't needed.
havoc [Sun, 29 Jul 2018 23:20:37 +0000 (23:20 +0000)]
Remove some old fixed-function state tracking that wasn't needed.

Add gl_debug implementation which was forgotten in previous change.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12444 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAssume that GL_EXT_blend_subtract is supported.
havoc [Sun, 29 Jul 2018 23:18:44 +0000 (23:18 +0000)]
Assume that GL_EXT_blend_subtract is supported.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12443 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAssume that GL_ARB_texture_compression is supported.
havoc [Sun, 29 Jul 2018 23:15:59 +0000 (23:15 +0000)]
Assume that GL_ARB_texture_compression is supported.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12442 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdd gl_debug cvar, if enabled the GL context will have GL_ARB_debug_output enabled...
havoc [Sun, 29 Jul 2018 23:12:41 +0000 (23:12 +0000)]
Add gl_debug cvar, if enabled the GL context will have GL_ARB_debug_output enabled, which will print in the console.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12441 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove gl_dither cvar, it isn't supported in GL3.2 Core Profile.
havoc [Sun, 29 Jul 2018 23:04:41 +0000 (23:04 +0000)]
Remove gl_dither cvar, it isn't supported in GL3.2 Core Profile.

Remove unused gl_fbo cvar.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12440 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoOne last edit for the UI rendering with materials change.
havoc [Sun, 1 Jul 2018 08:45:55 +0000 (08:45 +0000)]
One last edit for the UI rendering with materials change.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12439 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoUse the model renderer on the UI - this means q3shaders and other material features...
havoc [Sun, 1 Jul 2018 08:22:40 +0000 (08:22 +0000)]
Use the model renderer on the UI - this means q3shaders and other material features now work.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12438 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoChange MAX_TEXTUREUNITS from 16 to 32 - this fixes a memory corruption that was causi...
havoc [Sat, 30 Jun 2018 21:59:21 +0000 (21:59 +0000)]
Change MAX_TEXTUREUNITS from 16 to 32 - this fixes a memory corruption that was causing all kinds of problems (e.g. cachepic issues).

Get rid of vid.texarrayunits, vid.teximageunits, vid.texunits variables as they are meaningless, assume 32 (because that is how many GL enums exist).

Don't clear texture units on reset, we don't know how many texture units really exist and it's largely pointless.

Do a more thorough unbind of textures on deletion, just for good measure.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12437 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a printf bug in Draw_CachePic so it passes path rather than pic
havoc [Sun, 17 Jun 2018 17:32:36 +0000 (17:32 +0000)]
Fix a printf bug in Draw_CachePic so it passes path rather than pic

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12436 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove cl-release and similar targets from makefile as they no longer exist.
havoc [Sat, 16 Jun 2018 17:46:08 +0000 (17:46 +0000)]
Remove cl-release and similar targets from makefile as they no longer exist.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12435 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdd more debugging prints in Draw_CachePic, most of these are for edge cases.
havoc [Tue, 22 May 2018 02:11:13 +0000 (02:11 +0000)]
Add more debugging prints in Draw_CachePic, most of these are for edge cases.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12434 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoClean up GL extensions a bit to only have the stuff the engine actually uses.
havoc [Tue, 22 May 2018 02:09:42 +0000 (02:09 +0000)]
Clean up GL extensions a bit to only have the stuff the engine actually uses.

Remove a few things that offend GL3.2 Core Profile.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12433 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRename RENDERPATH_GL20 to RENDERPATH_GL32.
havoc [Tue, 22 May 2018 01:43:35 +0000 (01:43 +0000)]

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12432 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdd more CHECKGLERROR calls, and clean up a few obsolete code scraps.
havoc [Tue, 22 May 2018 01:40:17 +0000 (01:40 +0000)]
Add more CHECKGLERROR calls, and clean up a few obsolete code scraps.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12431 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove unused gl20_texunit enum since all of the non-GL paths have been removed and...
havoc [Tue, 22 May 2018 01:33:35 +0000 (01:33 +0000)]
Remove unused gl20_texunit enum since all of the non-GL paths have been removed and the GL path allocates texture units according to usage.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12430 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove use of glPolygonStipple - it will need to be reimplemented in the shader using...
havoc [Tue, 22 May 2018 01:31:16 +0000 (01:31 +0000)]
Remove use of glPolygonStipple - it will need to be reimplemented in the shader using discard, or drawn as an overlay over the area.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12429 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoJust assume GL_ARB_texture_non_power_of_two and a number of other extensions are...
havoc [Sun, 20 May 2018 23:59:04 +0000 (23:59 +0000)]
Just assume GL_ARB_texture_non_power_of_two and a number of other extensions are supported, this simplifies a lot of conditions.

Always use GL_ARB_vertex_buffer_object.

Remove use of glDrawRangeElements as it doesn't exist in GL3.2 Core Profile, and is less necessary with GL_ARB_vertex_buffer_object.

Merge a number of extensions into the core opengl functions.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12428 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove unused light attention textures (2D and 3D) since the GL1 path was removed.
havoc [Sun, 20 May 2018 23:44:22 +0000 (23:44 +0000)]
Remove unused light attention textures (2D and 3D) since the GL1 path was removed.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12427 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoBugfix: Don't use OpenGL 3.2 core context just yet - more fixes needed first.
havoc [Sun, 20 May 2018 23:38:27 +0000 (23:38 +0000)]
Bugfix: Don't use OpenGL 3.2 core context just yet - more fixes needed first.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12426 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove support for libSDL1.2 which has been deprecated for years.
havoc [Sun, 20 May 2018 20:57:46 +0000 (20:57 +0000)]
Remove support for libSDL1.2 which has been deprecated for years.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12425 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove some unused parameters on R_SetupShader_Generic.
havoc [Sun, 20 May 2018 20:43:24 +0000 (20:43 +0000)]
Remove some unused parameters on R_SetupShader_Generic.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12424 d7cf8633-e32d-0410-b094-e92efae38249

2 years agovid_bitsperpixel is now locked to 32.
havoc [Sun, 20 May 2018 20:39:22 +0000 (20:39 +0000)]
vid_bitsperpixel is now locked to 32.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12423 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemoved per-platform clients (wgl/glx/agl) - now only SDL2 client
havoc [Sun, 13 May 2018 05:06:07 +0000 (05:06 +0000)]
Removed per-platform clients (wgl/glx/agl) - now only SDL2 client

Removed dedicated server from VS2017 projects - it's not really needed.

Removed cd_sdl.c since SDL1.2 support is not maintained, and the SDL2
code path in it is equivalent to cd_null.c as SDL2 does not support
controlling cd audio playback - also removed cd_null.c and the
corresponding code in cd_shared.c, which now only uses faketrack mode.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12422 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove r_vertexgeneric_t, r_vertexmesh_t, vid.interleavedarrays and code related...
havoc [Sun, 6 May 2018 04:39:34 +0000 (04:39 +0000)]
Remove r_vertexgeneric_t, r_vertexmesh_t, vid.interleavedarrays and code related to them.

Refactor r_showsurfaces code to modify the rsurface.batchlightmapcolor4f in place instead of using the R_Mesh_PrepareVertices_Generic_Lock/Unlock functions which have been removed.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12421 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix more Mod_ValidateElements sequencing issues - always generate
havoc [Sat, 5 May 2018 19:20:15 +0000 (19:20 +0000)]
Fix more Mod_ValidateElements sequencing issues - always generate
element3s before calling it, or don't pass element3s at all.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12420 d7cf8633-e32d-0410-b094-e92efae38249

2 years agomake precache_pic not use the fallback image
havoc [Sat, 5 May 2018 18:54:37 +0000 (18:54 +0000)]
make precache_pic not use the fallback image

(reported by terencehill)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12419 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a bug in MD3 model loading that caused warnings from
havoc [Sat, 5 May 2018 08:54:40 +0000 (08:54 +0000)]
Fix a bug in MD3 model loading that caused warnings from

Fix a bug in the output of Mod_ValidateElements which did not show the
mismatching elements correctly.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12418 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoSimplify Mod_ShadowMesh_* functions - removed support for every unused feature of...
havoc [Fri, 4 May 2018 04:37:14 +0000 (04:37 +0000)]
Simplify Mod_ShadowMesh_* functions - removed support for every unused feature of shadowmeshes (e.g. texcoords, and linked list meshes).

Add back Mod_CreateCollisionMesh which was mistakenly removed.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12417 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove Mod_CreateCollisionMesh and reduce the exposed API of Mod_ShadowMesh, it reall...
havoc [Wed, 2 May 2018 07:23:56 +0000 (07:23 +0000)]
Remove Mod_CreateCollisionMesh and reduce the exposed API of Mod_ShadowMesh, it really doesn't need to support most of the things it supports as only compiled shadowmaps use it now.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12416 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove model->surfmesh.shadowmesh which was a vertex-welded version of the regular...
havoc [Wed, 2 May 2018 07:17:13 +0000 (07:17 +0000)]
Remove model->surfmesh.shadowmesh which was a vertex-welded version of the regular surfmesh, we don't need that as we're not computing triangle neighbors as shadow volume support was removed.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12415 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove shadowvolume rendering entirely, now shadowmaps are the only kind of shadow.
havoc [Wed, 2 May 2018 07:00:12 +0000 (07:00 +0000)]
Remove shadowvolume rendering entirely, now shadowmaps are the only kind of shadow.

Also remove R_SetStencilSeparate and corresponding gl bindings since it isn't needed (R_SetStencil could also be removed but it might have uses).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12414 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRefactored and improved Mod_ValidateElements so it also validates element3s and has...
havoc [Tue, 1 May 2018 06:49:00 +0000 (06:49 +0000)]
Refactored and improved Mod_ValidateElements so it also validates element3s and has more useful output.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12413 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a crash on Doombringer duel5.bsp where one of the lights has more than 32768...
havoc [Tue, 1 May 2018 06:48:05 +0000 (06:48 +0000)]
Fix a crash on Doombringer duel5.bsp where one of the lights has more than 32768 triangles - this was using more than one shadowmesh and the sidetotals code was written incorrectly to assume there is a single shadowmesh per light - so now shadowmeshes are preallocated large enough for the entire model, to ensure there is only one.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12412 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoGenerate a pvs for refraction renders just like for reflection renders, this fixes...
havoc [Tue, 1 May 2018 02:48:46 +0000 (02:48 +0000)]
Generate a pvs for refraction renders just like for reflection renders, this fixes a water rendering issue in the Doombringer map duel2.bsp where certain leafs did not include the necessary pvs data (or something was wrong with how the renderer used the existing vis data).

In light of the above, allow r_wateralpha when r_water is used, even if the bsp is not watervised - this works for all non-recursive cases (so the elder hall water pool in start.bsp is still broken).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12411 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a missing newline in system vars mismatch warning.
havoc [Tue, 1 May 2018 02:21:46 +0000 (02:21 +0000)]
Fix a missing newline in system vars mismatch warning.

Fix a typo in r_shadow_culllights_trace_pad which made it not work.

Fix the name used on index buffers for Mod_ShadowMesh geometry - loadmodel->name doesn't make sense given where this is called.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12410 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix lighting origins on CSQC entities.
havoc [Mon, 30 Apr 2018 21:59:24 +0000 (21:59 +0000)]
Fix lighting origins on CSQC entities.

Fix a couple crashes with showtex 1 on level change where prog is not fully initialized.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12409 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix clipping plane bug on r_water - a line had been deleted when removing RENDERPATH_...
havoc [Mon, 30 Apr 2018 19:54:49 +0000 (19:54 +0000)]
Fix clipping plane bug on r_water - a line had been deleted when removing RENDERPATH_SOFT that should have stayed.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12408 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix bugs with unloading of cachepic skinframes in QC menus - the reloading was broken...
havoc [Mon, 30 Apr 2018 06:38:44 +0000 (06:38 +0000)]
Fix bugs with unloading of cachepic skinframes in QC menus - the reloading was broken in some weird way that made it white (it wasn't reusing the skinframe).

Simplify Draw_CachePic behaviors with regards to NewPic and textureflags (mismatch now causes texture reload rather than having multiple with the same name in memory).

Improved reloading of unloaded pics by reusing the existing skinframe, so it can not produce duplicates.

Make Draw_NewPic clear the pic->autoload flag, this is a behavior change in VM_CL_ReadPicture.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12407 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a typo in DrawQ_RotPic which broke it badly.
havoc [Sun, 29 Apr 2018 10:27:38 +0000 (10:27 +0000)]
Fix a typo in DrawQ_RotPic which broke it badly.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12406 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix multiple bugs with ft2 font loading that were caused by the switch to cachepic...
havoc [Sun, 29 Apr 2018 10:16:09 +0000 (10:16 +0000)]
Fix multiple bugs with ft2 font loading that were caused by the switch to cachepic and skinframe.

R_Skinframe_LoadExternal now uses comparecrc = -1 to allow the shader loading to find the skinframe for an ft2 font.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12405 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoDefault vid_desktopfullscreen to 1.
havoc [Sun, 29 Apr 2018 09:34:22 +0000 (09:34 +0000)]
Default vid_desktopfullscreen to 1.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12404 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix the menu for missing data, it needs to use CACHEPICFLAG_FAILONMISSING or the...
havoc [Sun, 29 Apr 2018 09:32:21 +0000 (09:32 +0000)]
Fix the menu for missing data, it needs to use CACHEPICFLAG_FAILONMISSING or the Draw_IsPicLoaded call will never fail.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12403 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix Image_GenerateNoTexture, it was using a wrong stride, resulting in a very bogus...
havoc [Sun, 29 Apr 2018 09:23:09 +0000 (09:23 +0000)]
Fix Image_GenerateNoTexture, it was using a wrong stride, resulting in a very bogus image with the bottom half being black.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12402 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove the last remnants of DPSOFTRAST support in vid_glx.c.
havoc [Fri, 20 Apr 2018 06:06:03 +0000 (06:06 +0000)]
Remove the last remnants of DPSOFTRAST support in vid_glx.c.

Remove some dead files.

Fix some warnings on CL_MeshEntities functions that should have been

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12401 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a prvm_int_t variable that was being passed directly to printf.
havoc [Fri, 20 Apr 2018 05:59:25 +0000 (05:59 +0000)]
Fix a prvm_int_t variable that was being passed directly to printf.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12400 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove all render paths except GL20/GLES2. This means no DPSOFTRAST, no DX9 support...
havoc [Fri, 20 Apr 2018 05:36:20 +0000 (05:36 +0000)]
Remove all render paths except GL20/GLES2.  This means no DPSOFTRAST, no DX9 support, no GL1.1/GL1.3 support.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12399 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoReworked v_isometric code significantly, it now defaults to a proper isometric view...
havoc [Sun, 15 Apr 2018 23:23:11 +0000 (23:23 +0000)]
Reworked v_isometric code significantly, it now defaults to a proper isometric view and some maps are actually playable like this.

Added R_Viewport_InitOrtho3D which more correctly implements the VF_PERSPECTIVE=0 case for CSQC, with correct camera orientation and all that.  This may break existing mods that tried to use that feature but I doubt there are any as it was pretty broken before.

Reworked how R_CanSeeBox (and other vis code) determine if the view is able to use vieworigin based culling or not, this is now a separate property (r_refdef.view.usevieworiginculling) and can be turned on or off for reflection views and such.  This is also exposed as v_isometric_usevieworiginculling for the v_isometric case.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12398 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoChanged how polygonbegin guesses if the geometry is 2D or 3D, it now uses a separate...
havoc [Sun, 15 Apr 2018 23:17:19 +0000 (23:17 +0000)]
Changed how polygonbegin guesses if the geometry is 2D or 3D, it now uses a separate variable rather than relying on r_refdef.draw2dstage.

Reworked DrawQ_* and R_RenderView code to make clear distinctions between 2D and 3D code, this removes a lot of unnecessary calls to DrawQ_FlushUI (including ones that happened in R_RenderView).

Added R_DebugLine which takes a line in world coordinates and adds it as a 2D line in CL_Mesh_UI.

Added r_showparticleedges and r_showspriteedges debugging cvars which make use of R_DebugLine.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12397 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdded v_isometric cvars, this mode is mostly a curiosity but it's useful for testing...
havoc [Sat, 14 Apr 2018 06:54:35 +0000 (06:54 +0000)]
Added v_isometric cvars, this mode is mostly a curiosity but it's useful for testing engine compatibility with non-perspective rendering.

Fixed a few bugs where distance culling was misbehaving with non-perspective rendering.

Make r_refdef.view.ismain more useful - it's now cleared after R_RenderView rather than before, so R_RenderView can make use of it (for r_motionblur ghost texture updates and anything else that wants to happen just on the main view).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12396 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdded r_cullentities_trace_expand and pad cvars, these configure additional ways...
havoc [Sat, 14 Apr 2018 05:20:44 +0000 (05:20 +0000)]
Added r_cullentities_trace_expand and pad cvars, these configure additional ways to expand entity boxes when culling by traceline.

Added r_vis_trace feature which allows you to turn on traceline-based culling of portals, and r_vis_trace_surfaces lets you cull surfaces by traceline (slow and probably pointless, but a curious feature).

Added r_shadow_culllights_trace_expand and pad cvars.

Added sv_cullentities_trace_expand to make SV_CanSeeBox be at feature parity with R_CanSeeBox.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12395 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix two pieces of code that did not compile with PRVM_64.
havoc [Sat, 14 Apr 2018 05:11:44 +0000 (05:11 +0000)]
Fix two pieces of code that did not compile with PRVM_64.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12394 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoEnable PRVM_64 - the QuakeC VM will run as 64bit (using int64/double rather than...
havoc [Sat, 14 Apr 2018 04:34:54 +0000 (04:34 +0000)]
Enable PRVM_64 - the QuakeC VM will run as 64bit (using int64/double rather than int/float).

This means that levels can run for > 10 hours without time precision issues, and float flags values can have flags ranging up to 54 bits rather than 24 bits.

There may be bugs, and physics is still using 32bit floats in a bunch of places so this does not enable huge worlds currently.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12393 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoCheck r_showtris cvar as a float rather than integer - can now use fractional brightness.
havoc [Sat, 14 Apr 2018 04:26:28 +0000 (04:26 +0000)]
Check r_showtris cvar as a float rather than integer - can now use fractional brightness.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12392 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix incorrect layer color values that caused models to be completely black in RENDERP...
havoc [Fri, 13 Apr 2018 05:31:46 +0000 (05:31 +0000)]
Fix incorrect layer color values that caused models to be completely black in RENDERPATH_GL1*.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12391 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoMade RENDERPATH_GL20 require fbo support and always use it.
havoc [Fri, 13 Apr 2018 05:20:44 +0000 (05:20 +0000)]
Made RENDERPATH_GL20 require fbo support and always use it.

Implemented R_RenderTarget system for managing fbo and texture requests dynamically, reusing the same ones across frames - this means that the textures are now allocated much smaller and there is better handling of multiple CSQC viewports.

In the short-term this means that vid_samples antialiasing doesn't do anything, it will need to be reimplemented using fbo.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12390 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix some viewport issues with r_viewfbo and r_bloom by passing view size information...
havoc [Fri, 13 Apr 2018 05:00:22 +0000 (05:00 +0000)]
Fix some viewport issues with r_viewfbo and r_bloom by passing view size information when calling the various rendering subsystems - there are still a bunch of bugs but this is a temporary measure before rendertargets are put in.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12389 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoCSQC polygonbegin functionality now uses the CL_MeshEntities system, this finally...
havoc [Fri, 13 Apr 2018 02:23:34 +0000 (02:23 +0000)]
CSQC polygonbegin functionality now uses the CL_MeshEntities system, this finally makes it possible to use shaders on those polygons.

UI elements (DrawQ_ system) now use the CL_MeshEntities system, but still renders the mesh the old way, shader support is planned.

DrawQ_Line no longer uses GL_LINES, it now produces a polygon in the CL_MeshEntities system, so shownetgraph and r_speeds_graph features now work on D3D9/DPSOFTRAST/GLES2 render paths.

Added MATERIALFLAG_VERTEXCOLOR as a special case for rgbgen vertex shaders that are being used by CL_MeshEntities meshes, currently this is an unlit type of material but lighting support for it is planned.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12388 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoDefault scr_loadingscreen_background to 1, and also a fix for sRGB issues with the...
havoc [Thu, 12 Apr 2018 22:08:34 +0000 (22:08 +0000)]
Default scr_loadingscreen_background to 1, and also a fix for sRGB issues with the loadingscreen background.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12387 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a bug where R_GetTexture could return 0 rather than a white texture.
havoc [Thu, 12 Apr 2018 21:44:41 +0000 (21:44 +0000)]
Fix a bug where R_GetTexture could return 0 rather than a white texture.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12386 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdded Draw_GetPicWidth, Draw_GetPicHeight, Draw_IsPicLoaded functions and moved cache...
havoc [Wed, 11 Apr 2018 05:28:24 +0000 (05:28 +0000)]
Added Draw_GetPicWidth, Draw_GetPicHeight, Draw_IsPicLoaded functions and moved cachepic_t to live in gl_draw.c (no longer visible to other modules).

Changed Draw_CachePic to use the R_SkinFrame_LoadExternal system, and reworked font loading to use Draw_CachePic rather than keeping track of textures itself.  R_SkinFrame_LoadExternal can now load gfx.wad lumps and gfx/*.lmp files, and the embedded images have been moved to image.c as they are now returned as raw images, suitable for R_SkinFrame_LoadExternal to use.

Reworked cl_video code to not need the cl_dyntexture system (which has been removed); it still uses dynamic texture callbacks (which is a feature of rtexture_t).

Changed the parameters to Mod_LoadCustomMaterial and a few other model_shared.c functions to not assume loadmodel is the owner of memory and textures; this was necessary for Draw_CachePic to be able to use R_SkinFrame_LoadExternal.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12385 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove the model parameter from NativeContentsFromSuperContents/SuperContentsFromNati...
havoc [Tue, 10 Apr 2018 06:59:02 +0000 (06:59 +0000)]
Remove the model parameter from NativeContentsFromSuperContents/SuperContentsFromNativeContents functions, none of the current formats need it.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12384 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoEnable GL_OES_framebuffer_object on Android - it was broken in Android 2.1 but that...
havoc [Tue, 10 Apr 2018 05:11:30 +0000 (05:11 +0000)]
Enable GL_OES_framebuffer_object on Android - it was broken in Android 2.1 but that's been irrelevant for years.

Remove prototype for R_Init, it doesn't exist.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12383 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoDon't bother setting anisotropy on textures twice during startup.
havoc [Tue, 10 Apr 2018 05:10:08 +0000 (05:10 +0000)]
Don't bother setting anisotropy on textures twice during startup.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12382 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRemove v_glslgamma cvar (now assumed to be 1) and corresponding code like R_DrawGamma.
havoc [Tue, 10 Apr 2018 05:09:08 +0000 (05:09 +0000)]
Remove v_glslgamma cvar (now assumed to be 1) and corresponding code like R_DrawGamma.

RENDERPATH_GL1* paths no longer support bloom.

Fix a bug in D3D9 renderpath where SHADERPERMUTATION_GAMMARAMPS would crash due to using the wrong variable for the texture unit.

Enable GL_ARB_texture_non_power_of_two on OSX again - the old OSX versions and corresponding hardware that had issues are long gone.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12381 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoImproved r_sky_scissor - scissor box is tighter as it now computes scissor box for...
havoc [Mon, 9 Apr 2018 05:58:15 +0000 (05:58 +0000)]
Improved r_sky_scissor - scissor box is tighter as it now computes scissor box for each surface and combines them.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12380 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoImplemented r_sky_scissor feature (on by default) - this limits rendering of sky...
havoc [Mon, 9 Apr 2018 05:29:12 +0000 (05:29 +0000)]
Implemented r_sky_scissor feature (on by default) - this limits rendering of sky to approximately the area of the surfaces.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12379 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdded R_SkinFrame_PurgeSkinFrame to de-duplicate some repeated code.
havoc [Mon, 9 Apr 2018 05:01:24 +0000 (05:01 +0000)]
Added R_SkinFrame_PurgeSkinFrame to de-duplicate some repeated code.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12378 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoAdd prvm_offsets.h to VS2017 projects, so it can be searched easily.
havoc [Mon, 9 Apr 2018 04:40:24 +0000 (04:40 +0000)]
Add prvm_offsets.h to VS2017 projects, so it can be searched easily.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12377 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoRefactored R_UpdateEntityLighting to CL_UpdateEntityShading, which sets fields like...
havoc [Mon, 9 Apr 2018 04:39:19 +0000 (04:39 +0000)]
Refactored R_UpdateEntityLighting to CL_UpdateEntityShading, which sets fields like ent->render_modellight_ambient.

Added texture->render_modellight_ambient and similar fields which concretely define how the material is to be rendered, so all of the various tweaks and modifiers are no longer buried in R_SetupShader_Surface which has now been refactored heavily.

Removed R_LightPoint as it's really not necessary - this change will make lit particles a little bit slower as R_CompleteLightPoint is a slightly more expensive function.

Refactored R_CompleteLightPoint to have more consistent code, changed the final color math so that it passes q1bsp/q2bsp lighting through unmodified.

Changed shading of tag_entity attachments - they now use the root entity's origin for shading, this fixes r_shadows where the shadows could go in different directions on CSQC entities (r_shadows code already contained a hack to work around this problem for network entities).

Renamed r_refdef.lightmapintensity and ambient to r_refdef.scene.lightmapintensity and ambientintensity.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12376 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoChange default value of r_shadows_shadowmapscale from 1 to 0.25, so that
havoc [Mon, 9 Apr 2018 02:52:08 +0000 (02:52 +0000)]
Change default value of r_shadows_shadowmapscale from 1 to 0.25, so that
shadows cover a larger part of the level around the eye.

Change the way r_shadows 2 size is calculated so that it uses 1/4th of
the texture atlas size (at default this would be 2048 of 8192) rather
than 2*r_shadow_shadowmapping_maxsize (at default that was 2*512 = 1024
of 8192).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12375 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoIncrease shadowmap bordersize from 4 to 5, thanks Vic for debugging this
havoc [Mon, 9 Apr 2018 02:39:42 +0000 (02:39 +0000)]
Increase shadowmap bordersize from 4 to 5, thanks Vic for debugging this
- the shadowmap filters need one more pixel than originally thought.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12374 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a bug with height fog which was revealed by removing
havoc [Sun, 8 Apr 2018 23:59:22 +0000 (23:59 +0000)]
Fix a bug with height fog which was revealed by removing

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12373 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoMissed the cl_particles.c edits to remove RSurf_ActiveWorldEntity. I blame VS2017...
havoc [Sat, 7 Apr 2018 20:46:54 +0000 (20:46 +0000)]
Missed the cl_particles.c edits to remove RSurf_ActiveWorldEntity.  I blame VS2017, just because.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12372 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoUncomment the texture binding check in R_Mesh_TexBind so that the engine makes less...
havoc [Sat, 7 Apr 2018 19:27:07 +0000 (19:27 +0000)]
Uncomment the texture binding check in R_Mesh_TexBind so that the engine makes less calls.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12371 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoDelete unused Debug_PolygonBegin and associated code.
havoc [Sat, 7 Apr 2018 19:25:34 +0000 (19:25 +0000)]
Delete unused Debug_PolygonBegin and associated code.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12370 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoFix a mistake made when merging R_RenderView call in #12367.
havoc [Sat, 7 Apr 2018 19:25:02 +0000 (19:25 +0000)]
Fix a mistake made when merging R_RenderView call in #12367.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12369 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoConfigure all of the CL_MeshEntities* meshes the same, the material flags decide...
havoc [Sat, 7 Apr 2018 19:20:05 +0000 (19:20 +0000)]
Configure all of the CL_MeshEntities* meshes the same, the material flags decide whether each thing should cast a shadow.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12368 d7cf8633-e32d-0410-b094-e92efae38249

2 years agoMake the semantics of CL_VM_UpdateView more clear - if CSQC is loaded, it is required...
havoc [Sat, 7 Apr 2018 19:18:49 +0000 (19:18 +0000)]
Make the semantics of CL_VM_UpdateView more clear - if CSQC is loaded, it is required to provide the CSQC_UpdateView function, and won't render a view if it does not call that, so we don't need to check its return value.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12367 d7cf8633-e32d-0410-b094-e92efae38249