Vladislav Belov
18a16aa135
Moves all rendering to material passes
...
Now we should use material passes instead of context and defines to
select a needed shader. It allows us to reduce the number of
shader combinations we use and reduce memory consumption.
2026-05-10 23:57:20 +02:00
Vladislav Belov
75bd640bd8
Removes context of terrain shadows and silhouettes
...
We were unnecessary passing all combinations of our scene shader context
even if we don't need it as for shadows and silhouettes for terrain
rendering. Since we only need to draw a solid color.
2026-05-10 23:56:57 +02:00
Vantha
1d3cdec48d
Move cutscene mode to renderer
...
This patch splits "cutscene mode" (disabling silhouttes, territory
borders and other visual overlays) from the cinema manager component
and moves it to the renderer, since it doesn't influence the simulation
anyway. The mode can now be independently controlled by the GUI. This
is done so it can also be used for other narrative elements like speech
or dialogue in the future. Cutscene mode is still always enabled while
cinema paths are playing, though.
By design, this also fixes the issue that range overlays weren't hidden
during cutscene mode.
2026-03-03 11:25:52 +01:00
Vladislav Belov
0432b86de7
Removes ARB (legacy OpenGL) backend
...
ARB is a legacy backend which uses old assembly shaders. It makes
writing shaders more complex. According to the stats
https://feedback.wildfiregames.com we small amount of players with
ARB.
Fixes #8533
2026-02-20 22:07:38 +01:00
Chrzanof
5daae13525
Pass device command context by reference in DebugRenderer
...
Improve the DebugRenderer API by passing the IDeviceCommandContext
as a reference instead of calling g_Renderer.
Fixes : #6650
2026-01-24 11:54:01 +01:00
Vladislav Belov
3ffb5ec5a0
Removes USE_FOG define and switches to a shader parameter.
...
Refs #8385
2025-10-11 08:11:35 +02:00
Vladislav Belov
199f4cb666
Fixes uninitialized water textures.
...
Fixes #8052
2025-10-05 14:13:49 +02:00
Ralph Sennhauser
f9e1e742bf
Fix includes in source/renderer
...
Make include-what-you-use happy with files in source/renderer and
fix what needs to be fixed.
Ref: #8086
Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
2025-07-27 16:07:14 +02:00
Ralph Sennhauser
47b2733183
Fix some includes in source/renderer
...
Make include-what-you-use happy with some files in source/renderer and
fix what needs to be fixed.
Ref: #8086
Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
2025-07-12 12:19:41 +02:00
Ralph Sennhauser
5e4b49f65f
Fix some includes in source/renderer
...
Make include-what-you-use happy with some files in source/renderer and
fix what needs to be fixed.
Ref: #8086
Signed-off-by: Ralph Sennhauser <ralph.sennhauser@gmail.com>
2025-07-07 17:45:54 +02:00
phosit
891908b801
Remove UNUSED
...
The `UNUSED` macro is used to mark a variable as unused but with a name.
Those usages are replaced with comments so that `UNUSED` can be removed.
https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rf-unused
2025-06-26 17:25:05 +02:00
Vladislav Belov
0b33921c06
Removes GL code from the common GPU profiler.
2025-04-16 22:38:34 +02:00
Vladislav Belov
9c560c36af
Removes ARBShadersShadow IDevice capability.
...
According to our stats `GL_ARB_fragment_program_shadow` is supported
by all our GL users. Also we're going to remove OpenGL ARB in A29. So
I remove ARBShadersShadow completely.
2025-04-12 23:14:28 +02:00
Vladislav Belov
8ee48a164a
Fixes missing SPIR-V shader combinations.
...
We have multiple renderer backends for a while. So we can't rely on
a single CONFIG_GLES2 macro for disabling features.
2025-01-07 02:49:38 +01:00
Vladislav Belov
de1257c8da
Adds GPU skinning support via compute shaders.
...
We use a shader with 64 bones by default to consume less uniform memory.
But if we meet bigger skeletons we batch and handle them afterwards.
In the future we need to sort the input models to have less changes for
bound buffers. Also we might want to skin up to 4 models per a single
dispatch.
2024-12-09 22:47:17 +01:00
Vladislav Belov
9094c3adb0
Batches update and upload passes for model renderers.
2024-11-08 13:57:57 +01:00
Vladislav Belov
5a5d518c28
Cleans up code after renaming HWLightingModelRenderer to CPUSkinnedModelRenderer.
2024-10-19 23:24:40 +02:00
vladislavbelov
ffc4a56b9f
Revert non-ASCII characters from source and configuration files introduced in 157c6af18e.
...
Fixes #6846
Differential Revision: https://code.wildfiregames.com/D5185
This was SVN commit r27965.
2023-12-03 00:30:12 +00:00
vladislavbelov
e2c5a62a19
Moves model flags to ModelAbstract.
...
Differential Revision: https://code.wildfiregames.com/D5146
This was SVN commit r27880.
2023-10-09 18:37:56 +00:00
bb
157c6af18e
Make the space in 0 A.D. non-breaking throughout the codebase.
...
Avoid cases of filenames
Update years in terms and other legal(ish) documents
Don't update years in license headers, since change is not meaningful
Will add linter rule in seperate commit
Happy recompiling everyone!
Original Patch By: Nescio
Comment By: Gallaecio
Differential Revision: D2620
This was SVN commit r27786.
2023-07-27 20:54:46 +00:00
vladislavbelov
8f78ac1ef8
Decouples renderer code from VideoMode to get backend device.
...
Differential Revision: https://code.wildfiregames.com/D5043
This was SVN commit r27693.
2023-06-14 07:06:22 +00:00
vladislavbelov
e5635a9d7f
Fixes shadows cascades iteration.
...
This was SVN commit r27492.
2023-01-26 17:12:11 +00:00
vladislavbelov
7c84c23114
Adds Vulkan backend.
...
Comments By: phosit, Stan
Differential Revision: https://code.wildfiregames.com/D4876
This was SVN commit r27412.
2023-01-10 20:22:20 +00:00
vladislavbelov
90f064ff03
Switches from per draw vertex attribute format to precompiled vertex input layout.
...
Comments By: phosit, Stan
Differential Revision: https://code.wildfiregames.com/D4852
This was SVN commit r27363.
2023-01-06 00:39:25 +00:00
vladislavbelov
4ed41d4a9a
Switches from pipeline state descriptions to pipeline states.
...
Tested By: phosit, Stan
Differential Revision: https://code.wildfiregames.com/D4850
This was SVN commit r27328.
2022-12-31 18:29:44 +00:00
vladislavbelov
c0e888e2af
Removes SetViewport from CRenderer.
...
Differential Revision: https://code.wildfiregames.com/D4849
This was SVN commit r27313.
2022-12-29 06:53:06 +00:00
vladislavbelov
29368cf776
Adds framebuffer attachment load and store operations.
...
Comments By: phosit, Stan
Differential Revision: https://code.wildfiregames.com/D4830
This was SVN commit r27256.
2022-11-26 21:55:17 +00:00
vladislavbelov
8e51dfa91a
Moves post processing out of scene rendering to avoid framebuffer pass duplicate.
...
Comments By: phosit, Stan
Differential Revision: https://code.wildfiregames.com/D4827
This was SVN commit r27232.
2022-11-18 19:59:18 +00:00
vladislavbelov
097725e1e0
Moves particles data uploading out of framebuffer pass.
...
Comments By: phosit
Differential Revision: https://code.wildfiregames.com/D4820
This was SVN commit r27207.
2022-11-06 11:31:05 +00:00
vladislavbelov
2d0cde4e64
Disallows backend buffer uploading inside framebuffer pass.
...
Differential Revision: https://code.wildfiregames.com/D4815
This was SVN commit r27182.
2022-10-29 23:20:04 +00:00
vladislavbelov
968fd50fb0
Moves Backend enum from CVideoMode to backends.
...
Comments By: phosit, Stan
Differential Revision: https://code.wildfiregames.com/D4809
This was SVN commit r27173.
2022-10-25 22:45:54 +00:00
vladislavbelov
d3f0395d2a
Adds BeginFramebufferPass/EndFramebufferPass instead of SetFramebuffer.
...
This was SVN commit r27151.
2022-10-12 21:51:27 +00:00
vladislavbelov
b728c9e97e
Fixes vertex attribute format in minimap and passes dependent textures as parameters.
...
This was SVN commit r27145.
2022-10-11 20:37:27 +00:00
vladislavbelov
b0c29b8676
Removes GL types from regular renderer code after 3ed4eaf247.
...
This was SVN commit r26920.
2022-06-06 07:30:45 +00:00
vladislavbelov
53033ceaa2
Fixes rendering reflections and refractions in case of empty scissors.
...
This was SVN commit r26902.
2022-05-24 19:15:26 +00:00
vladislavbelov
62e589ab76
Adds renderer backend interface and dummy backend.
...
Comments By: phosit, Stan
Tested By: Langbart, phosit
Differential Revision: https://code.wildfiregames.com/D4636
This was SVN commit r26858.
2022-05-08 22:02:46 +00:00
vladislavbelov
3ed4eaf247
Removes ogl_WarnIfError from regular renderer code.
...
This was SVN commit r26850.
2022-05-02 21:52:21 +00:00
vladislavbelov
04bd96cee0
Moves uniform and texture binding to CDeviceCommandContext.
...
Tested By: Langbart
Differential Revision: https://code.wildfiregames.com/D4631
This was SVN commit r26848.
2022-05-02 20:57:22 +00:00
vladislavbelov
4934784266
Adds USE_FP_SHADOW to shader context only for GL ARB.
...
This was SVN commit r26712.
2022-03-26 19:00:28 +00:00
vladislavbelov
2ed2e9de0c
Invalidates CDeviceCommandContext texture bind cache properly.
...
Tested By: Langbart
Differential Revision: https://code.wildfiregames.com/D4553
This was SVN commit r26664.
2022-03-17 18:17:11 +00:00
vladislavbelov
b4253d48cb
Moves CShaderProgram to backend and handling via CDeviceCommandContext.
...
Differential Revision: https://code.wildfiregames.com/D4548
This was SVN commit r26652.
2022-03-14 22:16:14 +00:00
vladislavbelov
518a1421ab
Clears the color attachment of the main framebuffer only if needed.
...
Differential Revision: https://code.wildfiregames.com/D4539
This was SVN commit r26623.
2022-03-11 22:26:49 +00:00
vladislavbelov
5390143b66
Fixes rendering reflections even they are disabled, broken in 9ce51f4357. Fixes #6454
...
Reported By: Langbart
This was SVN commit r26615.
2022-03-10 16:36:16 +00:00
vladislavbelov
1ce999a52d
Creates water backend textures and framebuffers only if needed.
...
Tested By: Stan
Differential Revision: https://code.wildfiregames.com/D4536
This was SVN commit r26613.
2022-03-09 21:40:24 +00:00
vladislavbelov
da4ec670c1
Moves glViewport from CRenderer to CDeviceCommandContext.
...
This was SVN commit r26497.
2022-02-26 23:17:48 +00:00
vladislavbelov
23a023507a
Replaces GL_LINES, GL_QUADS, GL_TRIANGLE_STRIP and GL_TRIANGLE_FAN by GL_TRIANGLES.
...
This was SVN commit r26488.
2022-02-26 00:37:27 +00:00
vladislavbelov
d5d1754991
Moves polygon mode handling to PipelineState and CDeviceCommandContext.
...
This was SVN commit r26486.
2022-02-25 22:05:06 +00:00
vladislavbelov
8a63adc40d
Uses CDeviceCommandContext as an input parameter for CCanvas2D.
...
This was SVN commit r26480.
2022-02-25 08:14:11 +00:00
vladislavbelov
b0826da1bc
Fixes not drawing brushes under water when refractions are enabled.
...
This was SVN commit r26411.
2022-02-19 15:44:32 +00:00
vladislavbelov
b949f19875
Moves GL debug information toggle to run-time to make it easier to test after release.
...
This was SVN commit r26407.
2022-02-18 22:38:45 +00:00