Commit graph

13 commits

Author SHA1 Message Date
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
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
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
09f4071436 Ok, it had to be done: Removed shader support for pre GLSL 1.3/GL 3.0 hardware. The compromises needed to accomodate these are just too bad and would block any attempt at streamlining the code. 2014-05-11 13:27:51 +02:00
Christoph Oelckers
b09405a8bd - changed rendering of glowing walls so that it doesn't require an additional vertex attribute, just pass the floor and ceiling planes as uniforms. 2014-05-10 17:09:43 +02:00
Christoph Oelckers
e00847f64b - GZDoom solution file
- missing GL resources for gzdoom.pk3.
2013-06-23 11:13:01 +02:00