OpenTTD/src/core
Patric Stout 8e0d48a0f6
Fix: [SDL2] simplify what to redraw to prevent tearing (#8685)
When there are a lot of rects to redraw, of which one of the last
ones is almost the full screen, visual tearing happens over the
vertical axis. This is most visible when scrolling the map.

This can be prevented by using less rects. To simplify the situation,
and as solutions like OpenGL need this anyway, keep a single rect
that shows the biggest size that updates everything correctly.

Although this means it needs a bit more time redrawing where it
is strictly seen not needed, it also means less commands have
to be executed in the backend. In the end, this is a trade-off,
and from experiments it seems the approach of this commit gives
a better result.
2021-02-17 21:19:32 +01:00
..
CMakeLists.txt Add: introduce CMake for project management 2020-06-05 19:36:05 +02:00
alloc_func.cpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
alloc_func.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
alloc_type.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
backup_type.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
bitmath_func.cpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
bitmath_func.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
endian_func.hpp Fix: Globally apply preprocessor directive coding style 2020-07-03 09:08:46 +02:00
endian_type.hpp Fix: Globally apply preprocessor directive coding style 2020-07-03 09:08:46 +02:00
enum_type.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
geometry_func.cpp Fix: [SDL2] simplify what to redraw to prevent tearing (#8685) 2021-02-17 21:19:32 +01:00
geometry_func.hpp Fix: [SDL2] simplify what to redraw to prevent tearing (#8685) 2021-02-17 21:19:32 +01:00
geometry_type.hpp Fix: Globally apply preprocessor directive coding style 2020-07-03 09:08:46 +02:00
kdtree.hpp Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
math_func.cpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
math_func.hpp Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
mem_func.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
multimap.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
overflowsafe_type.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
pool_func.cpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
pool_func.hpp Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
pool_type.hpp Codechange: Replace assert_compile macro with static_assert 2020-12-27 10:55:42 +00:00
random_func.cpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
random_func.hpp Fix: Globally apply preprocessor directive coding style 2020-07-03 09:08:46 +02:00
smallmap_type.hpp Codechange: Make use of the improved C++17 emplace_back function. 2020-12-15 00:29:30 +01:00
smallmatrix_type.hpp Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
smallstack_type.hpp Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
smallvec_type.hpp Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
string_compare_type.hpp Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00