Commit graph

216 commits

Author SHA1 Message Date
Christoph Oelckers
6a9f1e9da1 - removed the old OpenGL interface. 2020-06-12 00:25:52 +02:00
Christoph Oelckers
ba397f5ca1 - always draw floors opaque 2020-06-11 23:55:23 +02:00
Christoph Oelckers
22aad4999c - use the engine backend to render the scene 2020-06-11 22:26:46 +02:00
Christoph Oelckers
17e1e4175e - switched NPOT emulation to the renamed uniforms.
This was the last feature that needed to be mapped to a GZDoom compatible render state
2020-06-08 08:16:50 +02:00
Christoph Oelckers
a6545788a6 - do RR's lightning flash as a postprocessing effect. 2020-06-07 22:06:47 +02:00
Christoph Oelckers
d7225c1965 - backend update from GZDoom 2020-06-07 15:02:54 +02:00
Christoph Oelckers
4c6abe1bb9 - pass the shade through the 2D drawer, so that palette emulation can still use it. 2020-06-07 14:50:12 +02:00
Christoph Oelckers
9fc5f2d2e7 - some shader cleanup.
I think it's now as close to GZDoom's backend interface as it can be without disabling needed features.
2020-06-07 10:15:31 +02:00
Christoph Oelckers
60d7f4f7c2 - got rid of the RF_NPOTEmulation flag.
This can easily be controlled with the 2 main variables alone.
2020-06-07 09:30:55 +02:00
Christoph Oelckers
353e3eb1fa - fixed RRRA E2L1 fog. 2020-06-07 08:24:12 +02:00
Christoph Oelckers
3adfdfcac5 - renamed a few more things in the shader. 2020-06-07 08:16:04 +02:00
Christoph Oelckers
232b0c1bb6 - store the lighting related uniforms in a GZDoom-style LightParms vec4. 2020-06-06 00:44:57 +02:00
Christoph Oelckers
f159496f6e - moved the ShadeDiv array into the lookup table and took the numshades-2 divisor out of the stored value.
The value was changed to allow easier reuse in scenarios where the size of the shade table does not matter anymore.
2020-06-05 23:18:21 +02:00
Christoph Oelckers
0bd460d9e3 - split up the visibility factor into a scene specific and an element specific part.
The main reason here is that the scene specific part contains a projection dependent component which would be a problem when transitioning to GZDoom's code. The global viewpoint data already has a field for such a factor so now that gets used.
This also means a significant simplification of the visibility code in Polymost and the removal of several global variables.
2020-06-05 19:06:31 +02:00
Christoph Oelckers
9dfd3ddd02 - migration of texture tinting to GZDoom's version.
- start of visibility migration - removing unused globvis variable.
2020-06-05 17:02:21 +02:00
Christoph Oelckers
d812c2997c - start renaming uniforms to match GZDoom.
Needed to allow using the same shader with the backend.
2020-06-04 21:34:27 +02:00
Christoph Oelckers
b15cc31a38 - transitioned matrix setup to use the backend's uniform buffer implementation. 2020-06-04 20:14:48 +02:00
Christoph Oelckers
40f085adea - draw fullscreen blends with the 2D drawer.
Removing one special case of render setup. Now all 2D content is done by the same code.
2020-06-04 18:54:10 +02:00
Christoph Oelckers
cf6855904d - took projection and view matrix out of the render state.
This is a preparation to migrate to GZDoom's HWViewpointUniforms buffer.
2020-06-04 18:46:44 +02:00
Christoph Oelckers
7638ead1c8 - simplified the texture sampler setup.
DAMETH_CLAMPED was redundant and only causig problems.
2020-06-02 16:55:02 +02:00
Christoph Oelckers
350acd2ac3 - scale the vertex coordinates that get output to the hardware by 1024.
This is needed to get a coordinate system that is compatible with GZDoom's so that its lighting code can be reused more easily.
2020-06-01 09:55:28 +02:00
Christoph Oelckers
783dff41b6 - fixed clamp mode setup. 2020-05-31 23:08:56 +02:00
Christoph Oelckers
bd0c8acd46 - replaced detail matrix with a two element scale vector because that is all that is needed. 2020-05-31 12:23:35 +02:00
Christoph Oelckers
d752e33909 - removed the unused SurfaceShader class. 2020-05-31 11:47:19 +02:00
Christoph Oelckers
611dad7f69 - added the softpoly and Vulkan backend code fron GZDoom.
Not hooked up yet.
2020-05-31 10:53:11 +02:00
Christoph Oelckers
2841154683 - moved code around, got a few more utilities from GZDoom. 2020-05-31 10:37:19 +02:00
Christoph Oelckers
1d15fe63a6 - another backend update, pulling in the sky renderer. 2020-05-31 10:32:10 +02:00
Christoph Oelckers
1e2a3da5fd - video base code unified.
# Conflicts:
#	source/core/rendering/v_video.cpp
2020-05-31 09:18:43 +02:00
Christoph Oelckers
edb2cb31ee - backend update with GZDoom model code. 2020-05-31 08:55:00 +02:00
Christoph Oelckers
5728241c1c - updated backend from GZDoom. 2020-05-30 23:10:17 +02:00
Christoph Oelckers
88eea8269a - set proper palette for null translation. 2020-05-30 22:35:21 +02:00
Christoph Oelckers
82eb807090 - activate the texture layers if needed. 2020-05-30 22:27:59 +02:00
Christoph Oelckers
58c62e071c - use FMaterial. 2020-05-30 22:20:06 +02:00
Christoph Oelckers
423f758314 - texture code restructuring. 2020-05-30 21:42:35 +02:00
Christoph Oelckers
cdcb25bc1f - use high level textures to render voxels. 2020-05-30 00:30:56 +02:00
Christoph Oelckers
cca4fc609f - texture code cleanup, mainly cppying layer data into the textures at startup to be able to use a real material system. 2020-05-29 23:33:26 +02:00
Christoph Oelckers
2c94b2bb6d - split texture selection from binding. 2020-05-29 21:53:28 +02:00
Christoph Oelckers
1bc744b77b - moved hictinting data into the lookup tables. 2020-05-29 20:15:42 +02:00
Christoph Oelckers
594ec6626c - transitioned to using GZDoom's texture creation code.
Also added support for creating indexed textures directly into CreateTexBuffer, where this functionality can be shared.
As an added plus, brightmaps are working again, this time with less hackery.
2020-05-29 19:21:18 +02:00
Christoph Oelckers
66809ca9f4 - fixed indexed display of 2D content. 2020-05-29 16:46:36 +02:00
Christoph Oelckers
87a87c155d - moved to GZDoom's gl_hwtexture.cpp. 2020-05-29 01:03:01 +02:00
Christoph Oelckers
381e53017d - some hackery to make the camera textures in DN3D work again.
They depend on a deleted texture not writing to the depth buffer, but other parts in the engine like ROR surfaces depend on them writing a proper depth buffer value, so for now there is a global variable that allows to exclude a single tile from ever getting rendered.
2020-05-29 00:44:13 +02:00
Christoph Oelckers
72889540a5 - use GZDoom's gl_samplers.cpp 2020-05-28 23:48:50 +02:00
Christoph Oelckers
362be65060 - removed FHardwareTexture's mSampler member.
This was a mostly unused relic of early development, the few places using it were static sampler settings.
2020-05-28 21:45:33 +02:00
Christoph Oelckers
4ebe67ba3d - never render the null texture.
Blood's ROR effects won't work if this is not done.
2020-05-27 22:54:39 +02:00
Christoph Oelckers
193b940eef - palette code cleanup. 2020-05-27 22:19:02 +02:00
Christoph Oelckers
c4017de12f - updated to GZDoom's new texture management system. 2020-05-25 23:59:07 +02:00
Christoph Oelckers
55a3c62b59 - use GZDoom's 2D drawer.
Console and menu font colors are not ok yet, aside from that it works.
2020-05-25 17:11:32 +02:00
Christoph Oelckers
758e4ad7cb - stripped down the palette manager in the GL backend and let it use the data that's managed elsewhere.
This class is only needed to manage the palette textures used by the indexed render mode, all the rest is available globally.
2020-05-25 00:31:55 +02:00
Christoph Oelckers
4178d48fb6 - re-enabled GPalette and disabled brightmaps.
In order to finish this I need the switchover, but brightmaps need an update of the texture code which requires merging a few more WIP changes before the code can be fixed.
2020-05-25 00:31:55 +02:00