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
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
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
38a6726a07
Fixes shore waves rendering after 29368cf776.
...
Tested By: phosit
Differential Revision: https://code.wildfiregames.com/D4865
This was SVN commit r27375.
2023-01-06 19:11:47 +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
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
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
a17fad722a
Moves framebuffer management to CDeviceCommandContext.
...
Tested By: Langbart, nwtour
Differential Revision: https://code.wildfiregames.com/D4475
This was SVN commit r26302.
2022-02-05 16:59:23 +00:00
vladislavbelov
5adbe4f1a3
Moves blend state management to DeviceCommandContext. Fixes #6420
...
Tested By: Langbart
Comments By: Stan
Differential Revision: https://code.wildfiregames.com/D4441
This was SVN commit r26228.
2022-01-19 17:28:47 +00:00
vladislavbelov
1d9a8b2b0b
Splits water surface and shore drawing functions and fixes their switch.
...
Differential Revision: https://code.wildfiregames.com/D4436
This was SVN commit r26215.
2022-01-14 17:34:58 +00:00
vladislavbelov
0cda752ec3
Uses CVertexBufferManager handle instead of raw VBChunk pointer management.
...
Tested By: Stan
Differential Revision: https://code.wildfiregames.com/D4430
This was SVN commit r26196.
2022-01-10 16:51:43 +00:00
vladislavbelov
60a422b668
Moves water textures and terrain alpha composite map to GL texture class following 57ba7c4a1c.
...
Tested By: Stan
Differential Revision: https://code.wildfiregames.com/D4394
This was SVN commit r26120.
2021-12-27 08:14:47 +00:00
vladislavbelov
fe81a6eec7
Refactors WaterManager to remove duplication of the current texture index calculation. Removes unused m_WaterCurrentTex from f2cae8cb9b.
...
This was SVN commit r26045.
2021-12-09 18:01:28 +00:00
vladislavbelov
c0e0d620eb
Draws fancy water and its shore waves only for GLSL shaders.
...
This was SVN commit r26017.
2021-11-26 21:47:04 +00:00
vladislavbelov
a5c82a4ef6
Removes unused forward declarations of class and struct.
...
This was SVN commit r25903.
2021-09-08 19:43:01 +00:00
vladislavbelov
6282960991
Removes useless option for shadows on water
...
Reviewed By: wraitii
Differential Revision: https://code.wildfiregames.com/D3368
This was SVN commit r24630.
2021-01-15 15:45:39 +00:00
vladislavbelov
9669b5f1a9
Removes additional depth texture copying and reusing existing refraction depth.
...
Tested By: Stan, wraitii
Differential Revision: https://code.wildfiregames.com/D3084
This was SVN commit r24160.
2020-11-11 18:46:52 +00:00
vladislavbelov
92cbf5ead0
Reduces memory usage for fancy water by merging two textures.
...
Two textures were added in 9ce51f4357 .
Reviewed By: wraitii
Tested By: Angen, Freagarach
Differential Revision: https://code.wildfiregames.com/D2983
This was SVN commit r24046.
2020-09-16 18:03:51 +00:00
wraitii
b1de59de66
Fix algorithmic error in 9903fd8a6c (waves computation speedup), and delete unused code.
...
9903fd8a6c introduced a much faster (for a little precision cost)
algorithm to compute distance to shore. However a condition was
incorrectly inverted, which made the algorithm return less-than-sensible
results in many situations.
Further, there was some unused code left behind which is now removed.
Fixes #5580
Reported by: nani (shore bug), elexis (unused code)
Differential Revision: https://code.wildfiregames.com/D2249
This was SVN commit r22862.
2019-09-07 08:50:55 +00:00
vladislavbelov
651cf8b364
Split CColor from Shapes.
...
Reviewed By: wraitii
Tested By: Stan
Differential Revision: https://code.wildfiregames.com/D1515
This was SVN commit r22051.
2019-01-13 15:38:41 +00:00
elexis
04f2209b50
Rename WaterUgly setting to WaterEffects in order to remove the invertedboolean workaround of the options page.
...
Differential Revision: https://code.wildfiregames.com/D815
Refs #3737
Tested By: Stan
This was SVN commit r20010.
2017-08-21 00:09:25 +00:00
elexis
c67d79d9f3
Recompute water graphics when changing the water level and upon deserialization to fix a graphical (non-simulation) OOS on rejoin.
...
Differential Revision: https://code.wildfiregames.com/D638
Refs #4596
Contains a fix mentioned by leper.
This was SVN commit r19862.
2017-07-01 04:15:49 +00:00
elexis
b18f74da44
Remove trailing whitespace and whitespace in empty lines of source/ except source/third_party/.
...
This was SVN commit r18987.
2016-11-23 11:18:37 +00:00
wraitii
ead8436b3d
Improve water rendering, partly based on a patch by aeonios, including:
...
-increase the size of the refraction and reflection texture
-blur the refraction map depending on depth
Fixes #3781
This was SVN commit r18443.
2016-06-26 16:54:58 +00:00
Itms
caf89fa04e
Rename ps/Overlay(.h|.cpp) to ps/Shapes(.h|.cpp), fixes a TODO located in graphics/Overlay.h.
...
The file name did not match the content.
Also little cleanup of some unnecessary includes.
This was SVN commit r16431.
2015-03-15 18:06:32 +00:00
wraitii
2d7d5b446d
Fix Atlas so that changing water type will actually change water type.
...
Fix the water shader so that object reflections are more visible. Looks
better.
This was SVN commit r16388.
2015-02-28 13:50:52 +00:00
wraitii
143e199d45
Add a new function to update the water renderer textures when resizing the renderer window. Patch by pendingchaos.
...
This fixes #2692 though the same issue might appear in some other cases
(possibly Atlas) and those will have to be checked.
This was SVN commit r16315.
2015-02-10 19:41:29 +00:00
historic_bruno
41b98a6f12
Fixes incorrect reuse of a member variable in WaterManager, caused a crash when starting a new map in Atlas after loading a water map. Fixes #2784 .
...
Fixes likely mem leaks from not cleaning up vertex buffer allocations
This was SVN commit r15715.
2014-09-07 23:49:24 +00:00
wraitii
e50147fd96
Metaprogramming 9ce51f4357.
...
Change something on water shaders to see if it works better on ATI
cards.
This was SVN commit r15594.
2014-08-01 10:15:29 +00:00
wraitii
9ce51f4357
Commit coastal waves when activating fancy effects, and incidentally completely change how this effect work. Refs #48 .
...
This was SVN commit r15576.
2014-07-28 10:14:00 +00:00
wraitii
9d4665248b
Check water FBOs creation correctly to detect some errors. Use two depth textures since I have a hunch the issues people encounter are caused by my using only one.
...
This was SVN commit r15488.
2014-07-04 10:14:35 +00:00
wraitii
326290463e
Further WIP water improvements. Add 3 different textures for different looks. Update some oasis maps for that. Streamline water settings (some removed, some added). Update Atlas for those (needs to be tested). Fix an issue with HQ water effects.
...
Please report any issue and/or crash. Those will get fixed in commits to
come. Refs #48 .
This was SVN commit r15484.
2014-07-03 20:07:15 +00:00
wraitii
ab30e0d4fb
Change the water texture to a new, bigger one, created in Blender (thanks to Enrique). Change settings so that they are more logical, yet allow reverting back to an even lower quality setting. Add a WIP high setting (with foam) which isn't finished yet.
...
Change the shader itself so that the effects look nicer and are more
consistent across settings.
Rework the water mesh generation (simpler system). Fix a few issues.
May work oddly with Atlas since I haven't been able to compile yet.
Refs #1875 (maybe fix), Fixes #2077 (I'll assume it does), Fixes #2114
(assumption again), refs #48 .
This was SVN commit r15473.
2014-07-01 16:05:05 +00:00
wraitii
e2f4379e9a
Fix an issue with corruption of water data when the actor editor opened in Atlas.
...
Potential marginal optimizations to the water data creation code.
This was SVN commit r14784.
2014-02-25 06:27:15 +00:00
wraitii
15ec863aec
Substantial speed-up of the foam generation code.
...
Remove waves for now as they were unsatisfactory.
Removes "shininess" as a water parameter as it was basically useless.
Add a button in Atlas to recompute water parameters so you can now see
fog in Atlas.
Fixes #1743 , #1803 (invalid)
Refs #1875 , #2114 , #48 .
This was SVN commit r14514.
2014-01-05 16:15:20 +00:00
wraitii
a4707bcc16
Change the water manager so incremental updates to the water information is possible. Streamline a few things (and removes a not-really-used calculation to speed things up further). Fixes #2063 , refs #1743 .
...
This was SVN commit r13698.
2013-08-18 09:27:11 +00:00
wraitii
4233acfa36
Slight clean up of the water code. Uses vertex data instead of a texture for foam. Should be faster to generate and render. Still no Atlas support.
...
This was SVN commit r13374.
2013-04-27 12:20:42 +00:00
historic_bruno
a4a060cd86
Fixes build warning and cleans up a few things
...
This was SVN commit r12895.
2012-11-26 02:28:35 +00:00
wraitii
76676b1e38
Fix a non-fatal GL error, fix me forgetting to commit a file, remove the "3D" waviness setting as it was mostly redundant with HQ.
...
This was SVN commit r12822.
2012-11-05 12:14:04 +00:00
wraitii
ed7c66eb82
Updates the water settings: features can now be enabled individually for more modularity. Fixes a few bugs. Allows it to be run at an acceptable speed in Atlas.
...
This was SVN commit r12817.
2012-11-04 15:54:36 +00:00
wraitii
fb035d08e3
fixes #1572 and fixes #932
...
Changes the water rendering in game to support higher quality effects
and to look nicer.
This was SVN commit r12802.
2012-10-31 18:42:17 +00:00
Ykkrosh
67a94572ec
# Add new texture loading system with automatic compression.
...
Replace almost all texture uses with calls to the new system.
Add some anistropic filtering to terrain textures.
Let Atlas load terrain texture previews partly-asynchronously by
polling.
Fix inefficient texture colour determination for minimap.
Remove unused global g_TerrainModified.
Change GUI texcoord computation to be less efficient but to cope with
dynamic texture changes.
Fix GUI renderer effects leaving bogus colour state.
This was SVN commit r8099.
2010-09-10 21:02:10 +00:00
Ykkrosh
58e79bfdbe
Force fancywater off if fragment shader extensions are not supported. See #270
...
This was SVN commit r7385.
2010-03-21 14:18:15 +00:00
Ykkrosh
1743645fd3
Simplify the overly-complex CppDoc-breaking file headers
...
This was SVN commit r6832.
2009-04-18 17:51:05 +00:00
Ykkrosh
c9fa7f13d9
Add GPL header
...
This was SVN commit r6830.
2009-04-18 17:00:33 +00:00
janwas
c0ed950657
had to remove uint and ulong from lib/types.h due to conflict with other library.
...
this snowballed into a massive search+destroy of the hodgepodge of
mostly equivalent types we had in use (int, uint, unsigned, unsigned
int, i32, u32, ulong, uintN).
it is more efficient to use 64-bit types in 64-bit mode, so the
preferred default is size_t (for anything remotely resembling a size or
index). tile coordinates are ssize_t to allow more efficient conversion
to/from floating point. flags are int because we almost never need more
than 15 distinct bits, bit test/set is not slower and int is fastest to
type. finally, some data that is pretty much directly passed to OpenGL
is now typed accordingly.
after several hours, the code now requires fewer casts and less
guesswork.
other changes:
- unit and player IDs now have an "invalid id" constant in the
respective class to avoid casting and -1
- fix some endian/64-bit bugs in the map (un)packing. added a
convenience function to write/read a size_t.
- ia32: change CPUID interface to allow passing in ecx (required for
cache topology detection, which I need at work). remove some unneeded
functions from asm, replace with intrinsics where possible.
This was SVN commit r5942.
2008-05-11 18:48:32 +00:00
janwas
b755ddefda
remove all author/modified by tags.
...
make include guards consistent.
This was SVN commit r5040.
2007-05-07 16:33:24 +00:00