Fog factor changed
This commit is contained in:
parent
53ca2affcb
commit
7327c92ef1
@ -255,7 +255,7 @@ void main() {
|
||||
|
||||
camera_vector = mix(camera_vector, vec3(0, 1, 0), min(1.0, u_fog));
|
||||
|
||||
float fog = 1.0f / (u_fog + 1.0);
|
||||
float fog = 1.0f / (u_fog*0.5 + 1.0);
|
||||
// hide darkness at horizon
|
||||
camera_vector.y = max(0.01, camera_vector.y)*(1.0-u_mie*0.08) + 0.08*u_mie;
|
||||
camera_vector = normalize(camera_vector);
|
||||
|
||||
@ -128,7 +128,7 @@ void WorldRenderer::drawChunks(Chunks* chunks,
|
||||
void WorldRenderer::draw(const GfxContext& pctx, Camera* camera){
|
||||
EngineSettings& settings = engine->getSettings();
|
||||
skybox->refresh(level->world->daytime,
|
||||
fmax(1.0f, 18.0f/settings.chunks.loadDistance), 4);
|
||||
fmax(1.0f, 10.0f/(settings.chunks.loadDistance-2)), 4);
|
||||
|
||||
const Content* content = level->content;
|
||||
const ContentIndices* contentIds = content->indices;
|
||||
@ -156,7 +156,7 @@ void WorldRenderer::draw(const GfxContext& pctx, Camera* camera){
|
||||
ctx.depthTest(true);
|
||||
ctx.cullFace(true);
|
||||
|
||||
float fogFactor = 18.0f / (float)settings.chunks.loadDistance;
|
||||
float fogFactor = 15.0f / ((float)settings.chunks.loadDistance-2);
|
||||
|
||||
// Setting up main shader
|
||||
shader->use();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user