Commit graph

854 commits

Author SHA1 Message Date
Christoph Oelckers
754c96a540 - added default precision settings to shader include because some old ATI drivers complain if they aren't there - even though the spec doesn't require them... 2014-07-27 16:09:47 +02:00
Christoph Oelckers
637aa9d77e - some adjustments to allow testing the different rendering methods. 2014-07-26 18:43:54 +02:00
Christoph Oelckers
0e647e0f2b Merge branch 'master' into Glew_Version_For_Real 2014-07-26 10:37:00 +02:00
Christoph Oelckers
8465a5f5d7 Merge branch 'master' of https://github.com/rheit/zdoom 2014-07-26 10:23:41 +02:00
Christoph Oelckers
a21f01bc5f - added jpalomo's submission to make freelook a 3-state setting, like crouch and jump. This required moving around the flags a bit so demo compatibility had to be bumped. It may also require adjustment for launchers that can set the dmflags. 2014-07-26 10:15:07 +02:00
Christoph Oelckers
f64428dd2a Merge branch 'master' into Glew_Version_For_Real 2014-07-17 09:31:18 +02:00
Christoph Oelckers
b78b566b0a Merge branch 'master' of https://github.com/rheit/zdoom 2014-07-17 09:30:50 +02:00
Christoph Oelckers
eb9d2d9917 - reactivate compatibility profile so that immediate mode drawing can be used on older hardware not supporting persistently mapped buffers.
- reactivate alpha testing per fixed function pipeline
- use the 'modern' way to define clip planes (GL_CLIP_DISTANCE). This is far more portable than the old glClipPlane method and a lot more robust than checking this in the fragment shader.
2014-07-17 02:37:18 +02:00
Braden Obrzut
bd5bf2a40a - Expand environment variables for autoload paths.
- Forgot to save the French translation file for the last commit, so a few more corrections there.
2014-07-15 21:26:26 -04:00
Braden Obrzut
bfbea40415 - Fixed some typos with chex quest obituaries and French translation error. 2014-07-15 21:20:05 -04:00
Christoph Oelckers
b8bcbe819b - removed texture based dynamic lighting. For GL 3.x the shader approach is always better.
- fixed: sky fog was not unset.
2014-07-15 20:49:21 +02:00
Christoph Oelckers
fc0cf4f998 - GZDoom now runs on an OpenGL core profile. :)
It's probably still necessary to replace GLEW with another loader library. GLEW is pretty much broken on core OpenGL without some hacky workarounds...
2014-07-15 02:26:23 +02:00
Christoph Oelckers
6046b11b4f - all shaders now compile in core profile. 2014-07-15 01:05:53 +02:00
Christoph Oelckers
eedc5a69be - replaced builtin position vertex attribute. 2014-07-15 01:02:48 +02:00
Christoph Oelckers
1b7f5a2e6a - replaced builtin texture coordinate vertex attribute. 2014-07-15 00:59:01 +02:00
Christoph Oelckers
5a322742c3 - remove use of builtin and deprecated color vertex attribute. 2014-07-15 00:37:13 +02:00
Christoph Oelckers
5193f6cfef - remove use of builtin deprecated varyings in shaders. 2014-07-15 00:19:41 +02:00
Christoph Oelckers
ed8a21fd86 - replaced deprecated alpha testing with shader code. 2014-07-14 21:14:43 +02:00
Christoph Oelckers
84a49e37ee - handle normals for spheremapped mirror surfaces using non-deprecated features.
- move all WGL references out of global header files so that global wgl header include is no longer necessary
2014-07-14 19:54:07 +02:00
Christoph Oelckers
ce3653f6e1 - remove all uses of builtin matrices. 2014-07-13 23:13:40 +02:00
Christoph Oelckers
dbb05c5f33 - remove use of builtin texture matrices.
- make matrix class single precision.
2014-07-13 20:41:20 +02:00
Christoph Oelckers
00fcf4bc06 - for some reason using world coordinates for clipping in the shader is somewhat imprecise so the clip plane heights have to be adjusted a bit for it. 2014-07-13 13:25:42 +02:00
Christoph Oelckers
60dc2e1122 - some shader fixes. 2014-07-13 13:01:35 +02:00
Christoph Oelckers
d868f60f6c - since the clip planes for plane mirrors did not work anymore I reimplemented them using shader based logic. It still needs to be seen if this affects performance on older hardware. 2014-07-13 12:14:12 +02:00
Christoph Oelckers
a936629cec - use default fragment shader for burn and stencil shader, with the time consuming parts disabled by a #define, to avoid code duplication. 2014-07-10 10:33:07 +02:00
Christoph Oelckers
f710518903 - use a uniform array to store vertex data to render dynamic stuff on GL 3.x hardware without the ARB_buffer_storage extension.
Due to the way the engine works it needs to render a lot of small primitives with frequent state changes.
But due to the performance of buffer uploads it is impossible to upload each primitive's vertices to a buffer separately because buffer uploads nearly always stall the GPU.
On the other hand, in order to reduce the amount of buffer uploads all the necessary state changes would have to be saved in an array until they can finally be used. This method also imposed an unacceptable overhead.
Fortunately, uploading uniform arrays is very fast and doesn't cause GPU stalls, so now the engine puts the vertex data per primitive into a uniform array and uses a static vertex buffer to index the array in the vertex shader.
This method offers the same performance as immediate mode but only uses core profile features.
2014-06-30 18:10:55 +02:00
Christoph Oelckers
1efc2938b7 - implement model vertex buffer and draw MD2 models using it instead of using the GLCommands from the model. 2014-06-29 23:24:16 +02:00
Christoph Oelckers
9d1dbf4eab - fixed: FBufferedUniform1f didn'T work because it used an int as its buffered value. 2014-06-29 14:08:44 +02:00
Christoph Oelckers
ffcb6cb70a - added second vertex coordinate attribute for model interpolation. 2014-06-29 11:00:21 +02:00
Christoph Oelckers
08054ddc34 Merge branch 'master' into Glew_Version_For_Real 2014-06-29 08:53:43 +02:00
Christoph Oelckers
e15f80f640 Merge branch 'master' of https://github.com/rheit/zdoom 2014-06-23 09:27:30 +02:00
Christoph Oelckers
e56e525d0f - A_FireCustomMissile transfer tranlsation flag, code submission by jpalomo 2014-06-22 08:55:21 +02:00
Christoph Oelckers
6457ced53f Merge branch 'master' into Glew_Version_For_Real 2014-06-19 11:57:36 +02:00
Christoph Oelckers
d30bf6768e Merge branch 'master' of https://github.com/rheit/zdoom 2014-06-19 11:20:38 +02:00
Edward Richardson
a3a7ee569f Multi-intermission waits for all players + changes
- Added a segment of code that now makes the intermission wait for all
players before advancing, instead of continuing on any player. A "ready
icon" shows to reflect this.

- The Deathmatch intermisson couldn't show the ready icon (because it
just used the ingame scoreboard), so a proper intermission was added,
which reflects the same design as the coop scoreboard.

- The colour column wasted more space then it should have needed, so it
was replaced with player colour backgrounds.

- Slight y offset adjustments to make everything fit in 320x200
properly.
2014-06-17 19:46:10 +12:00
Christoph Oelckers
2ad47935ef Merge branch 'master' into Glew_Version_For_Real 2014-06-01 12:43:17 +02:00
Christoph Oelckers
7fedaf9221 Merge branch 'master' of https://github.com/rheit/zdoom 2014-06-01 12:39:13 +02:00
Edward Richardson
e8513a64ed Rebuild nodes for hellfact map04 2014-06-01 15:32:43 +12:00
Christoph Oelckers
3c5d07e9c6 Merge branch 'master' of https://github.com/rheit/zdoom 2014-05-31 11:05:44 +02:00
Christoph Oelckers
8f5683e23d - moved secret found message to string table and removed the CVAR crutch that dates from a time when modifying string table content wasn't as easy as it is now.
- added 'showsecretsector' CVAR to show the sector number with the secret found message.
2014-05-29 17:50:14 +02:00
Christoph Oelckers
39775cc904 - mystery of desaturation shader solved: The old code passed '1-desaturation' to the shader, the new code 'desaturation', so for the 'mix' function to work its arguments must be swapped. 2014-05-21 15:25:25 +02:00
Christoph Oelckers
54425ee2ef - fixed: Desaturation factor was applied incorrectly.
- Also fixed some very strange thing in the shader's desaturate function. For unknown reasons using the 'mix' function there did not work.
- fixed: The fog boundary special shader could not be used.
2014-05-21 13:40:46 +02:00
Christoph Oelckers
6e6be8ed5b Merge branch 'master' into Glew_Version_For_Real 2014-05-18 12:47:48 +02:00
Christoph Oelckers
4e64ad847b Merge branch 'master' of https://github.com/rheit/zdoom 2014-05-15 09:46:47 +02:00
Christoph Oelckers
802a478766 - Heretic doesn't really need dontcrunchcorpses because there was already some alternative handling for that situation. 2014-05-14 14:03:15 +02:00
Christoph Oelckers
51ed68dc72 - forgot to save this... 2014-05-14 13:02:04 +02:00
Christoph Oelckers
388f09f786 - fixed: In Heretic corpses do not get crunched to gibs, they just get their size reduced to 0. Handled by a new gameinfo flag. This also gets set for Chex quest which has the gib sprite replaced by something different. Using a Crush state will override this global flag. 2014-05-14 12:54:03 +02:00
Christoph Oelckers
cf45f2d718 - added missing shader files. 2014-05-12 22:24:26 +02:00
Christoph Oelckers
4d005bdfa0 shader rework
All those special shaders have been merged together.
Mostly working but the non-shader lighting seems a bit broken.
2014-05-12 14:45:41 +02:00
Christoph Oelckers
b9a6fe80a4 Do not use the shader to handle STYLEF_RedIsAlpha.
Turns out that the name doesn't accurately describe what it does.
It is correct for images that come with their own palette or are true color.
But for images using the game palette it doesn't use the red channel to determine translucency but the palette index! Ugh...

This means it cannot be done with a simple operation in the shader because it won't get a proper source image. The only solution is to create a separate texture.
2014-05-11 23:56:53 +02:00