New terrain renderer - improvements:

Gaming / Game Engines / OpenMW - scrawl [baseoftrash.de] - 19 August 2013 13:34 UTC

- Consistent triangle alignment, fixes a noticable crack near the census and excise office. Note that alignment is still not the same as vanilla. Vanilla uses a weird diagonal pattern. I hope there aren't more trouble spots that will force us to replicate vanilla, but at least we can do that now.- Fixes several blending issues and cell border seams- Fix map render to use the terrain bounding box instead of an arbitrary height- Different LODs are now properly connected instead of using skirts- Support self shadowing- Normals and colors are stored in the vertices instead of a texture, this enables per-vertex lighting which should improve performance, fix compatibility issues due to the PS getting too large and mimic vanilla better- Support a fixed function fallback (though the splatting shader usually performs better)- Designed for distant land support - test: https://www.youtube.com/watch?v=2wnd9EuPJIY - we can't really enable this yet due to depth precision issues when using a large view distance

e27437f New terrain renderer - improvements:
apps/openmw/CMakeLists.txt | 3 +-
apps/openmw/engine.cpp | 6 +-
apps/openmw/mwrender/globalmap.cpp | 11 +-
apps/openmw/mwrender/localmap.cpp | 8 +-
apps/openmw/mwrender/localmap.hpp | 10 +-
apps/openmw/mwrender/renderingmanager.cpp | 37 +-
apps/openmw/mwrender/renderingmanager.hpp | 8 +-
apps/openmw/mwrender/shadows.cpp | 1 -
apps/openmw/mwrender/terrain.cpp | 531 -----------------------------
apps/openmw/mwrender/terrain.hpp | 128 -------
apps/openmw/mwrender/terrainmaterial.cpp | 246 -------------
apps/openmw/mwrender/terrainmaterial.hpp | 88 -----
apps/openmw/mwrender/terrainstorage.cpp | 56 +++
apps/openmw/mwrender/terrainstorage.hpp | 22 ++
apps/openmw/mwrender/water.cpp | 5 +-
apps/openmw/mwworld/scene.cpp | 4 +-
apps/openmw/mwworld/worldimp.cpp | 6 +-
components/CMakeLists.txt | 4 +
components/esm/loadland.hpp | 2 +-
components/terrain/chunk.cpp | 171 ++++++++++
components/terrain/chunk.hpp | 63 ++++
components/terrain/material.cpp | 291 ++++++++++++++++
components/terrain/material.hpp | 54 +++
components/terrain/quadtreenode.cpp | 387 +++++++++++++++++++++
components/terrain/quadtreenode.hpp | 141 ++++++++
components/terrain/storage.cpp | 318 +++++++++++++++++
components/terrain/storage.hpp | 76 +++++
components/terrain/terrain.cpp | 359 +++++++++++++++++++
components/terrain/terrain.hpp | 121 +++++++
files/materials/objects.shader | 1 -
files/materials/terrain.shader | 162 +++++----
libs/openengine/ogre/imagerotate.cpp | 4 +-
32 files changed, 2203 insertions(+), 1121 deletions(-)

Upstream: github.com


  • Share