/***********************************************/
/*           Copyright (c) 2025 Belmu          */
/*             All Rights Reserved             */
/***********************************************/

uniform vec3 sunPosition;
uniform vec3 moonPosition;
uniform vec3 cameraPosition;

uniform float viewWidth;
uniform float viewHeight;
uniform float aspectRatio;
uniform vec2 viewSize;
uniform vec2 texelSize;
uniform ivec2 atlasSize;

uniform int frameCounter;
uniform float frameTime;
uniform float frameTimeCounter;
uniform int worldTime;
uniform int worldDay;
uniform float near;
uniform float far;
uniform int isEyeInWater;
uniform int hideGUI;
uniform float rainStrength;
uniform float wetness;
uniform float sunAngle;

uniform sampler2D normals;
uniform sampler2D specular;
uniform sampler2D colortex0;
uniform sampler2D colortex1;
uniform sampler2D colortex2;
uniform sampler2D colortex3;
uniform sampler2D colortex4;

uniform sampler1D noisetex;

uniform mat4 gbufferModelView;
uniform mat4 gbufferModelViewInverse;
uniform mat4 gbufferProjection;
uniform mat4 gbufferProjectionInverse;

const int noiseTextureResolution = 128;

// Maximum values for x amount of bits (2^x - 1)
const float maxFloat8    = 255.0;
const float maxFloat16   = 65535.0;
const float rcpMaxFloat8 = 1.0 / maxFloat8;
