[patch] new fog shader

Everything about development and the OpenMW source code.
visvaldas
Posts: 35
Joined: 24 May 2015, 20:31

Re: [patch] new fog shader

Post by visvaldas »

screenshot005.png
screenshot003.png
screenshot002.png
screenshot001.png
User avatar
lysol
Posts: 1513
Joined: 26 Mar 2013, 01:48
Location: Sweden

Re: [patch] new fog shader

Post by lysol »

zomg
User avatar
psi29a
Posts: 5355
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

Re: [patch] new fog shader

Post by psi29a »

Send a PR when ready ;)
User avatar
drummyfish
Posts: 154
Joined: 22 Oct 2017, 10:13
Contact:

Re: [patch] new fog shader

Post by drummyfish »

I wouldn't believe fog can make such a huge difference, Amazing.
User avatar
raevol
Posts: 3093
Joined: 07 Aug 2011, 01:12
Location: Caldera

Re: [patch] new fog shader

Post by raevol »

So excited for this!!
magamo
Posts: 109
Joined: 28 May 2016, 17:28

Re: [patch] new fog shader

Post by magamo »

This is looking really good! It still affects the minimap, but it's usable, unlike with the old version. This is fantastic work!
User avatar
Thunderforge
Posts: 503
Joined: 06 Jun 2017, 05:57

Re: [patch] new fog shader

Post by Thunderforge »

magamo wrote: 12 Jul 2018, 14:07 It still affects the minimap, but it's usable, unlike with the old version.
Fog on the minimap (and overhead map in general) might actually be a cool feature that roleplayers would enjoy. Maybe it's worth considering as an optional setting?
User avatar
Jemolk
Posts: 237
Joined: 20 Mar 2017, 02:12
Location: Sadrith Mora

Re: [patch] new fog shader

Post by Jemolk »

Beautiful! When we can haz new fog shader in or compatible with nightlies???
visvaldas
Posts: 35
Joined: 24 May 2015, 20:31

Re: [patch] new fog shader

Post by visvaldas »

Before this can be mainlined there should to be a way to easily switch between different fog implementations.
This is a bit complicated because the fog shader depends on several components I had to modify to make it work.
Among those are:
  • lighting calculations: lighting.glsl, mwworld/weather.cpp
  • sky rendering: the fog effect has to be applied to the sky too, to avoid artifacts. Therefore extensive changes are needed in mwrender/sky.cpp.
    Maybe the sky manager can be subclassed to allow different implementations.
wolfraider
Posts: 3
Joined: 17 Jul 2018, 14:12

Re: [patch] new fog shader

Post by wolfraider »

Hi, I'm new here!

First off, great work with the shader, it looks real good in the screenshots. I seem to have a problem though.

I my game, the terrain has a blue hue to it, but not objects. Anyone else had the same problem? Here is the screenshot:
https://ibb.co/ezyvUJ

Here is my settings.cfg file, if it will help:

Code: Select all

# This is the OpenMW user 'settings.cfg' file.  This file only contains
# explicitly changed settings.  If you would like to revert a setting
# to its default, simply remove it from this file.  For available
# settings, see the file 'settings-default.cfg' or the documentation at:
#
#   https://openmw.readthedocs.io/en/master/reference/modding/settings/index.html

[Game]
followers attack on sight = true
prevent merchant equipping = true
rebalance soul gem values = true
show effect duration = true
show enchant chance = true
show melee info = true
show owned = 2
show projectile damage = true

best attack = true
[Input]
toggle sneak = true

always run = false
[Video]
antialiasing = 16
resolution x = 1920
resolution y = 1080
vsync = true
fullscreen = true

[Camera]
field of view = 60.8911
near clip = 5
small feature culling = true
viewing distance = 30000.0
small feature culling pixel size = 5.0

[GUI]
subtitles = true

[General]
anisotropy = 16
texture mipmap = linear

[Objects]
num lights = 8
shaders = true
use static geometry = true

[Sound]
music volume = 0.325833

[Water]
reflect actors = true
reflect statics = true
reflect terrain = true
refraction = true
rtt size = 2048
shader = true

[Map]
global = true

[Saves]
character = hn

[Cells]
exterior cell load distance = 1

[Terrain]
distant terrain = True
shader = true

[Shaders]
auto use object normal maps = true
auto use object specular maps = true
force shaders = true

[Viewing distance]
fog end factor = 2.0
fog start factor = 1.0
limit small object distance = true
max viewing distance = 30000
small object distance = 4000
small object size = 10
viewing distance = 30000

Thanks for helping!
Post Reply