Commit graph

15276 commits

Author SHA1 Message Date
Christoph Oelckers
70f9507f16 - moved RenderPortal, too. 2018-10-28 23:18:19 +01:00
Christoph Oelckers
24d6b23042 - moved RenderScene and RenderTranslucent to hwrenderer. 2018-10-28 22:58:35 +01:00
Christoph Oelckers
9b56f407dd - moved all 'present' functions into FGLRenderer.
This list of functions contained half of the existing references to the global GLRenderer variable.
2018-10-28 22:36:52 +01:00
Christoph Oelckers
9f9d747a6b - moved all methods that would involve command buffer manipulation in Vulkan to FRenderState, because that's the object that would serve as command buffer builder. 2018-10-28 22:20:51 +01:00
Christoph Oelckers
2ee2766812 - moved more code from FDrawInfo to HWDrawInfo.
The entire setup/takedown code did not reference any API specific data. The only thing needed is a global virtual creation function.
2018-10-28 19:39:31 +01:00
Christoph Oelckers
1ca811d4a8 - moved more code out of FDrawInfo. 2018-10-28 19:19:46 +01:00
Christoph Oelckers
cb4ffbf053 - moved the draw lists back to the API independent side.
The original idea was to let Vulkan do this completely differently, but if that comes to pass it should be done without having generic data maintenance code on the API side.
2018-10-28 19:06:29 +01:00
Christoph Oelckers
df15f00a21 - moved more code out of 'gl'. 2018-10-28 18:49:29 +01:00
Christoph Oelckers
e6efee61b1 - moved the last remaining function from gl_shadowmap.cpp elsewhere so that the file can be deleted. 2018-10-28 17:09:22 +01:00
Christoph Oelckers
54f46fdfee - moved most of FShadowMap to IShadowMap, except the main Update function. 2018-10-28 16:11:04 +01:00
Christoph Oelckers
cc058f98a5 - use IDataBuffer for the shadow map generator's buffers. 2018-10-28 15:59:20 +01:00
Christoph Oelckers
926a918e0c - moved the light buffer pointer to globally visible state. 2018-10-28 15:22:48 +01:00
Christoph Oelckers
b2776c9351 - moved lightbuffer files to hwrenderer. 2018-10-28 15:09:33 +01:00
Christoph Oelckers
bd7df13200 - let the light buffer use IDataBuffer as well. 2018-10-28 15:04:57 +01:00
alexey.lysiuk
49c3ec6a87 - fixed compilation warnings reported by GCC and Clang
src/gl/data/gl_viewpointbuffer.cpp:142:12: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare]
src/gl/data/gl_viewpointbuffer.cpp:142:34: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare]
2018-10-28 15:59:28 +02:00
alexey.lysiuk
649857c80d - updated Travis configuration to use Clang 7 2018-10-28 15:58:18 +02:00
Christoph Oelckers
54de0bf59f - changed a bit more stuff that doesn't need to be routed through the OpenGL interface anymore. 2018-10-28 14:25:29 +01:00
Christoph Oelckers
f7c7c8d1c5 - moved some buffer variables out of GLRenderer into common parts of the code so that they can be accessed from hwrenderer as well.
This will allow more code to be moved out of the API dependent parts.
2018-10-28 13:56:24 +01:00
Christoph Oelckers
c5b3b9e107 - moved the viewpoint buffer to hwrenderer. 2018-10-28 13:26:47 +01:00
Christoph Oelckers
b51cc8b115 - base the viewpoint buffer on IDataBuffer. 2018-10-28 13:18:13 +01:00
Christoph Oelckers
3b26e64404 - renamed the 'vertexbuffer' files to 'buffers' because it's now generic for all buffer types. 2018-10-28 12:04:20 +01:00
Christoph Oelckers
a1fb1f60f4 - replaced IUniformBuffer with IDataBuffer, which reuses the code for the other buffer types and is more flexible. 2018-10-28 11:54:26 +01:00
Christoph Oelckers
8abf09afe2 - consolidated buffer implementations.
Since this is nearly identical for different buffer types they should share the same code wherever possible.
2018-10-28 09:45:51 +01:00
Christoph Oelckers
9e109995cd - moved model renderer to hwrenderer after removing the remaining traces of OpenGL. 2018-10-28 00:40:41 +02:00
Christoph Oelckers
51acf3053c - fixed model vertex buffer setup.
Setting the buffer and its attribute bindings must be one step, not twp. With Vulkan this is a single API call.
This removes the now obsolete SetVertexBuffer method from the model renderer's interface.
2018-10-27 23:33:22 +02:00
Christoph Oelckers
a62cd64138 - removed all direct OpenGL dependencies from gl_models.cpp. 2018-10-27 22:55:33 +02:00
Christoph Oelckers
ac37ff422a - removed unneeded Apply call.
This had a problem with being called before some data was going to be deleted so its applied buffer state got lost.
2018-10-27 22:30:50 +02:00
Christoph Oelckers
83e706afe7 - - removed the remains of the old FVertexBuffer class. 2018-10-27 22:04:13 +02:00
Christoph Oelckers
067716cefb - made sky vertex buffer backend independent. 2018-10-27 21:31:27 +02:00
Christoph Oelckers
b92b7ca0a7 - fixed a few more places where unwanted dynamic lights were still active. 2018-10-27 19:25:51 +02:00
Christoph Oelckers
537faa16dc - fixed: Before rendering a portal the dynamic light index must be reset.
Otherwise the portal may 'inherit' some light of the last rendered item.
This is important for non-scene portals which have no dynamic lighting.
2018-10-27 19:16:56 +02:00
Christoph Oelckers
cd8c7a17eb - model vertex buffer converted. 2018-10-27 16:59:13 +02:00
Christoph Oelckers
5201501534 - added lock/unlock methods to the buffer implementations.
These are not interchangeable with Map/Unmap!
Map/Unmap is for mapping a buffer for updating on old hardware, Lock/Unlock are for manually copying some initialization data directly into a static buffer.
2018-10-27 16:04:28 +02:00
Christoph Oelckers
5a4e5a8038 - moved the remaining parts of the main vertex buffer to hwrenderer. 2018-10-27 14:42:24 +02:00
Christoph Oelckers
dad3c50ebd - renamed classes before continuing. 2018-10-27 14:27:43 +02:00
Christoph Oelckers
72bc7693bd - refactored main vertex buffer (but didn't merge with hwrender class yet. 2018-10-27 14:24:47 +02:00
Christoph Oelckers
332ab220ad - hooked low level buffers into render state.
It still needs to support the old interface so the code isn't really clean
2018-10-27 10:55:35 +02:00
Christoph Oelckers
3db26a3a1b - added an abstract index buffer implementation as well. 2018-10-27 10:26:51 +02:00
Christoph Oelckers
bb09f5488f - added an abstract base vertex buffer class. 2018-10-27 09:07:26 +02:00
Christoph Oelckers
5cce310f11 - fixed line portal setups in one-subsector maps. 2018-10-27 00:47:24 +02:00
Christoph Oelckers
fa85717155 - a bit of code reordering. 2018-10-25 22:50:45 +02:00
Christoph Oelckers
4f4bcd2d7d - moved DrawSorted back to HWDrawList. 2018-10-25 22:45:55 +02:00
Christoph Oelckers
21b658d34f Merge branch 'master' into renderstate_abstraction 2018-10-25 22:30:26 +02:00
Christoph Oelckers
c98474d1c7 - portal refactoring complete. 2018-10-25 22:30:03 +02:00
Magnus Norddahl
952ffb289c Merge branch 'master' of https://github.com/coelckers/gzdoom 2018-10-25 12:41:08 +02:00
Magnus Norddahl
2404634d5d - fix softpoly bug where sprites and translucent walls in front of models would disappear 2018-10-25 12:40:56 +02:00
Christoph Oelckers
bc97e585ba - removed some leftover GL2 code. 2018-10-25 01:02:16 +02:00
Christoph Oelckers
cead0194bd - safety commit. To finalize we need a better vertex buffer interface. 2018-10-25 00:49:39 +02:00
Christoph Oelckers
3940f17980 - portals are now completely on the hwrenderer side.
The only thing that still needs to be on the backend side is the one function that manages the rendering.
2018-10-25 00:25:55 +02:00
Christoph Oelckers
e6b5eba469 - moved GLScenePortal to the hardware independent code. 2018-10-24 07:57:32 +02:00