Christoph Oelckers
5666e4c805
- made camera textures operational again.
...
Now with proper separation of software rendering logic from the main part of the class.
2018-12-11 00:01:45 +01:00
Christoph Oelckers
2e7bcf9e41
- implemented a proper texture composition cache.
...
This will mostly ensure that each patch used for composition is only loaded once and automatically unloaded once no longer needed.
So far only for paletted rendering, but the same logic can be used for true color as well.
2018-12-10 01:17:39 +01:00
Christoph Oelckers
a7e472b4b3
- moved all exports from class Font to vmthunks.cpp and gave them direct native entrypoints.
...
- changed PARAM_STRING to use the passed string by reference instead of by value. The 3 instances where passing by value was needed now use PARAM_STRING_VAL.
2018-12-01 10:30:50 +01:00
Christoph Oelckers
8e46cb3a21
Merge remote-tracking branch 'remotes/origin/master' into asmjit
2018-11-30 18:49:28 +01:00
Christoph Oelckers
024870ba11
- merged DCanvas and DSimpleCanvas and use a TArray to hold its memory.
2018-11-30 17:02:39 +01:00
Christoph Oelckers
a9ec819557
- moved the type infomation entirely out of VMValue.
...
For the varargs functions that used the Type field to validate their parameters, now a hidden additional argument is passed which contains a byte array with the type info for the current call's arguments. Since this is static per call location it can be better prepared once when the code is being compiled instead of being put in a runtime created array for each invocation. Everything else uses the per-function instance of the same data.
The only thing that still needed the type field with a VMValue is the defaults array, so this uses a different struct type now to store its data.
2018-11-18 19:31:13 +01:00
Christoph Oelckers
cfe51f0c30
- hole filling subsectors must also be explicitly triangulated for the automap because they may be non-convex.
2018-11-10 08:04:03 +01:00
Jonathan Russell
f39a389e99
- changed the way alpha works on DrawLine and DrawThickLine so they're consistent
2018-11-01 00:10:47 +01:00
Christoph Oelckers
893e08df70
- moved DrawScene to GLRenderer and call it through std::function.
...
This was the last remaining virtual override of HWDrawInfo.
With it removed this type is now fully API independent.
2018-10-29 12:54:10 +01:00
Christoph Oelckers
90982285ac
- moved the mSceneClearColor variable to main DFrameBuffer class.
2018-10-29 09:34:30 +01:00
Christoph Oelckers
5528981a77
- CreateScene, too.
2018-10-28 23:32:13 +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
926a918e0c
- moved the light buffer pointer to globally visible state.
2018-10-28 15:22:48 +01:00
Christoph Oelckers
bd7df13200
- let the light buffer use IDataBuffer as well.
2018-10-28 15:04:57 +01: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
b51cc8b115
- base the viewpoint buffer on IDataBuffer.
2018-10-28 13:18:13 +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
067716cefb
- made sky vertex buffer backend independent.
2018-10-27 21:31:27 +02:00
Christoph Oelckers
3db26a3a1b
- added an abstract index buffer implementation as well.
2018-10-27 10:26:51 +02:00
Christoph Oelckers
c98474d1c7
- portal refactoring complete.
2018-10-25 22:30:03 +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
93dac4e4d8
- some reorganization of portal code.
2018-10-23 22:32:00 +02:00
Christoph Oelckers
1768508c80
- first adjustments to decal code.
...
- moved texture mode constants to a global header and consolidated with the variants of the 2D drawer.
2018-10-21 08:14:48 +02:00
Christoph Oelckers
5f838d52b9
- some cleanup on the OpenGL interface and its flags.
...
Most importantly, the separate command line options for switching on the legacy buffer handling have been removed.
There's really no need for them anymore, because unlike in earlier versions many of the implementation differences no longer exist - with the exception of where the light and vertex buffer contents are generated.
For testing this, -glversion 3 is sufficient.
2018-10-20 12:55:25 +02:00
Christoph Oelckers
acb9505606
- fixed cherry-picked commit so that modern OpenGL can still do the light setup in the render pass.
2018-10-20 10:33:26 +02:00
Christoph Oelckers
6e0ed3e930
- crossfade wipe is working again.
...
The other two types still need work.
2018-09-02 12:03:17 +02:00
Christoph Oelckers
29a54c33b2
- temporarily disabled wipe code and removed old function stubs.
...
This still needs work.
# Conflicts:
# src/gl/data/gl_attributebuffer.cpp
2018-09-02 12:02:59 +02:00
Christoph Oelckers
9af01c4667
- Untested wipe refactor
...
# Conflicts:
# src/gl/renderer/gl_renderer.cpp
# src/gl/system/gl_wipe.cpp
# src/hwrenderer/scene/hw_attributebuffer.cpp
2018-09-02 12:02:36 +02:00
Christoph Oelckers
ecf6e3f620
Sanitized the Being/End2D interface so that it can be used to keep the attribute buffer mapped while processing 2D commands.
...
For this to work the 2D mode has to be properly set and unset at the right places so that no double mapping occurs and no render operation can happen while in 2D mode.
# Conflicts:
# src/d_main.cpp
# src/v_video.h
2018-09-02 11:59:01 +02:00
Jonathan Russell
ea81ab4097
- added Screen.DrawThickLine for drawing lines with thickness
2018-08-30 19:21:57 +02:00
Magnus Norddahl
48c83d36b5
- add post processing support to the software renderer and softpoly
2018-08-04 14:58:55 +02:00
Christoph Oelckers
0d8d860c93
- moved the win_* CVARs to a single platform independent location.
2018-07-28 10:27:41 +02:00
Christoph Oelckers
3b53f31da3
- default to fullscreen display.
2018-07-28 10:05:50 +02:00
Christoph Oelckers
156ed5790e
- added vid_setsize CCMD and fixed some issues with window restoration when switching from fullscreen.
...
Windows apparently cannot both undo borderless fullscreen and resize the window at the same time, so this must delay the resizing one frame.
2018-07-21 21:32:02 +02:00
Christoph Oelckers
7a692b1557
- added DTA_LegacyRenderStyle so that STYLE_* constants can be passed directly to the Draw functions.
...
- fixed the optional parameter in Shape2D.Clear.
2018-07-14 22:58:24 +02:00
Christoph Oelckers
33ee0f3c27
Merge branch 'master' into modern
...
# Conflicts:
# src/gl/renderer/gl_renderer.cpp
# src/gl/renderer/gl_renderer.h
# src/gl/renderer/gl_renderstate.h
# src/gl/system/gl_framebuffer.cpp
# src/gl/system/gl_framebuffer.h
2018-07-14 13:18:34 +02:00
Christoph Oelckers
7817e6a7b2
- moved the texture binding code back to the OpenGL specific parts.
...
turns out that this cannot be consolidated with Vulkan because the semantics are far too different here.
2018-07-14 13:05:49 +02:00
Christoph Oelckers
124fe63d00
Merge branch 'master' into modern
2018-07-14 10:24:41 +02:00
Marisa Kirisame
2d0fb4ed2e
Adds 2D shape (triangle array) drawer, usable from ZScript. Handles most drawtexture parameters excluding those related to scaling, at the moment.
2018-07-13 20:24:06 +02:00
Christoph Oelckers
532fba5c26
- moved the Stereo3D EyePose to their own file in hwrenderer/.
2018-06-24 10:47:42 +02:00
Christoph Oelckers
b106f72741
- don't route calls to FMaterial::FlushAll through the framebuffer interface.
2018-06-20 22:18:31 +02:00
Christoph Oelckers
babe55819e
- fullscreen toggle and some cleanup. Not fully working yet.
2018-06-17 22:11:35 +02:00
Christoph Oelckers
b65b83edb3
- removed the hard screen resolution switch that still was present on Windows and cleaned up the entire video backend code from the remaining support code for this.
...
Like Linux and macOS this will only support borderless fullscreen in the active desktop resolution now, which is what modern systems need.
The list of discrete resolutions has been removed as it makes no sense anymore with a fixed video mode - all the other scaling options remain active, though.
2018-06-17 20:08:35 +02:00
Christoph Oelckers
e9e1911fa5
- made the scene scale and offset calculations inline functions of DFrameBuffer.
...
These got repeated quite often.
2018-06-17 12:23:29 +02:00
Christoph Oelckers
4937848123
- refactoring of fixed colormap stuff to have it better organized and to reduce the number of uniforms in the main shader.
...
This removes 3 uniforms, consisting of 9 floats. Those were merged into other values that never get used at the same time.
It also moves the costly setup of the fixed colormap out of the render state into the 2D processing code.
Since 3D forces use of render buffers now, it is no longer necessary to draw the entire scene with the colormap active, meaning it can be handled more efficiently.
2018-06-16 22:40:44 +02:00
Christoph Oelckers
9ff7e5a4ef
- force render buffers to be active.
...
For modern hardware the fallback path really makes no sense and this allows to simplify some things quite a bit.
2018-06-16 09:37:01 +02:00
Christoph Oelckers
8ab68264c1
- removal of all code to handle OpenGL 2. From this commit on the main build of GZDoom will be OpenGL 3.3 or higher.
...
# Conflicts:
# src/gl/renderer/gl_renderer.cpp
# src/gl/shaders/gl_shader.cpp
# src/gl/system/gl_framebuffer.cpp
# src/gl_load/gl_interface.cpp
2018-06-15 21:45:05 +02:00
Christoph Oelckers
3401876476
- use FShaderProgram through an abstract interface and remove all dependencies on the GL renderer from the shader definition source files.
2018-06-13 22:08:55 +02:00
Christoph Oelckers
ce50b0e46b
- read sampler bindings from the shader instead of tagging along a large amount of support data.
...
Works for most shaders, except SSAO.
2018-06-13 17:44:49 +02:00