24 Commits
Author SHA1 Message Date
Alexei Kotov a357dcc1b1 Change the texture asset convention to top-left (#6885)
This is basically a MR description but this commit covers a lot of things so I'll include it so you don't have to look at the MR:

This allows us to use BC6H and BC7 textures as is, provided the used OSG revision and hardware support them
DDS images are unflipped by default, non-DDS bottom-left convention images are flipped (TGA, BMP, PNG, JPG)
3D DDS images always used top-left convention if they were used in post-processing

Numerous things flipped in this commit to guarantee the same visual results are:
- Terrain UV and blend maps
- Water UV, normal map and simple water ripple alignment

- NiTriShapeData and BSTriShape UV (unflipped), NiUVController vertical offset
- NIF particles are NOT flipped, they remain flipped for Morrowind compatibility

- GUI widget texture UV and convention
- Cursor
- Character preview inventory doll and race menu head UV and display
- Loading screen scene image UV
- Local and global map UVs (fog of war, unexplored and explored maps)
- Saved game screenshot UV
- Video widget UV

- Rain particle alignment
- Sun and moon UV

- Tangent space handedness (bitangent direction)
- Parallax vertical offset

Things where this is a breaking change
- Collada geometry UV (Example Suite and anything else affected must adopt the changes)
- Compressed non-S3TC images that should but can't be flipped (this is KTX which we don't technically support yet)
- Any forward pass shader replacements that currently still use the original tangent space handedness and parallax convention
2026-02-05 21:05:35 +03:00
Evil Eye f7292680d6 Fix most conversion warnings in components 2025-09-18 22:00:55 +02:00
clang-format-botandζeh Matt ddb0522bbf Apply clang-format to code base 2022-09-22 21:35:26 +03:00
Bo SvenssonandGitHub 5f1bf89369 improves groundcover view distance (#3219)
This PR aims to solve all issues with `Groundcover` view distance handling in a satisfying way while preserving other optimisations that benefit other features. The main idea here is not to rely on `ViewData` updates for distance culling calculations because we can not accurately determine distance against lazily updated views. Instead, we perform an accurate measurement in a cull callback we can run every frame in `Groundcover` itself. While we do have to add some code to handle this feature, it is quite loosely coupled code that could be useful elsewhere in the future. These changes should address a performance regression @akortunov experienced.
2021-11-08 10:27:42 +01:00
jvoisin cb08f490d7 Sprinkle some const-ref in loop
This was done on the good advices of clang-tidy
2021-09-04 20:50:59 +02:00
AnyOldName3 eb80c997b8 Avoid OSG setting array binding from multiple threads 2021-01-22 19:44:22 +00:00
elsid 40ad87bc4d Replace OpenThreads by std types 2020-06-25 22:16:09 +02:00
scrawl 4fba157d3b Implement releaseGLObjects for cached resources 2017-08-26 19:29:12 +00:00
Kyle Cooley 3b9326d238 Clear terrain cache and reload terrain 2017-08-20 22:34:41 -04:00
scrawl 274690f790 Refactor BufferCache to allow caching buffers of different sizes 2017-03-14 19:27:55 +01:00
Allofich 0f20312012 Fix MSVC warnings 2017-01-28 04:37:47 +09:00
scrawl 4322e76cb6 Fix shadowing warnings 2016-08-29 12:38:24 +02:00
scrawl 7071d286e8 Fix inverted check for 16-bit indices 2016-02-19 14:59:47 +01:00
scrawl 0865cea211 Preload terrain 2016-02-09 21:16:11 +01:00
scrawl fbd4ad9b0c Flip terrain textures 2016-02-05 22:46:15 +01:00
scrawl 98571148b0 Remove custom license for terrain code
Now that it's no longer a stand-alone component, there's not much point in custom licensing it.
2015-06-14 20:44:29 +02:00
scrawl b978153edb Enable VBO sharing for terrain geometry 2015-06-03 02:24:09 +02:00
scrawl cdd0623009 Terrain rendering 2015-06-03 01:35:41 +02:00
scrawl 20af2b67a8 Change the triangle pattern used for terrain (Fixes #2459) 2015-04-17 18:54:14 +02:00
jacmoeandscrawl ee574e08ef MIT License header added to all terrain component files. 2015-02-09 20:16:29 +01:00
scrawl 261da8dd0a Terrain: use 32-bit indices if necessary 2015-01-13 05:37:43 +01:00
scrawl f7bac58b39 Terrain: change index buffer flags to unsigned 2015-01-13 05:37:43 +01:00
slothlife 9ea22324f7 Fix some MSVC warnings.
Several fixes are warnings about truncations on 64-bit, while others are
complaints about mixed signed / unsigned integer operations.
2014-06-23 01:13:30 -05:00
scrawl 97c3efb3ba Terrain: decoupled Chunk from QuadTreeNode. 2014-03-05 21:46:37 +01:00