mirror of
https://github.com/X0nk/Bliss-Shader.git
synced 2025-06-20 07:57:55 +08:00
make seasons work on distant horizons LODS
This commit is contained in:
parent
4c081608ba
commit
4e00602b33
@ -45,6 +45,8 @@ vec4 toClipSpace3(vec3 viewSpacePosition) {
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define SEASONS_VSH
|
||||||
|
#include "/lib/climate_settings.glsl"
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
gl_Position = ftransform();
|
gl_Position = ftransform();
|
||||||
@ -86,6 +88,12 @@ void main() {
|
|||||||
normals_and_materials = vec4(normalize(gl_NormalMatrix * gl_Normal), MATERIALS);
|
normals_and_materials = vec4(normalize(gl_NormalMatrix * gl_Normal), MATERIALS);
|
||||||
dh_material_id = dhMaterialId;
|
dh_material_id = dhMaterialId;
|
||||||
|
|
||||||
|
|
||||||
|
#if defined Seasons && defined OVERWORLD_SHADER
|
||||||
|
float blank = 0.0;
|
||||||
|
YearCycleColor(gcolor.rgb, gl_Color.rgb, blank, dhMaterialId == DH_BLOCK_LEAVES);
|
||||||
|
#endif
|
||||||
|
|
||||||
#if DOF_QUALITY == 5
|
#if DOF_QUALITY == 5
|
||||||
vec2 jitter = clamp(jitter_offsets[frameCounter % 64], -1.0, 1.0);
|
vec2 jitter = clamp(jitter_offsets[frameCounter % 64], -1.0, 1.0);
|
||||||
jitter = rotate(radians(float(frameCounter))) * jitter;
|
jitter = rotate(radians(float(frameCounter))) * jitter;
|
||||||
|
@ -356,7 +356,7 @@ if(heldItemId == ITEM_LIGHT_SOURCES || heldItemId2 == ITEM_LIGHT_SOURCES) HELD_I
|
|||||||
|
|
||||||
#if defined Seasons && defined WORLD && !defined ENTITIES && !defined BLOCKENTITIES && !defined HAND
|
#if defined Seasons && defined WORLD && !defined ENTITIES && !defined BLOCKENTITIES && !defined HAND
|
||||||
float blank = 0.0;
|
float blank = 0.0;
|
||||||
YearCycleColor(color.rgb, gl_Color.rgb, blank);
|
YearCycleColor(color.rgb, gl_Color.rgb, blank, mc_Entity.x == BLOCK_AIR_WAVING);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef TAA_UPSCALING
|
#ifdef TAA_UPSCALING
|
||||||
|
@ -17,7 +17,9 @@
|
|||||||
void YearCycleColor (
|
void YearCycleColor (
|
||||||
inout vec3 FinalColor,
|
inout vec3 FinalColor,
|
||||||
vec3 glcolor,
|
vec3 glcolor,
|
||||||
inout float SnowySeason
|
inout float SnowySeason,
|
||||||
|
|
||||||
|
bool isLeaves
|
||||||
){
|
){
|
||||||
// colors for things that arent leaves and using the tint index.
|
// colors for things that arent leaves and using the tint index.
|
||||||
vec3 SummerCol = vec3(Summer_R, Summer_G, Summer_B);
|
vec3 SummerCol = vec3(Summer_R, Summer_G, Summer_B);
|
||||||
@ -32,7 +34,7 @@
|
|||||||
SpringCol *= glcolor;
|
SpringCol *= glcolor;
|
||||||
|
|
||||||
// do leaf colors different because thats cool and i like it
|
// do leaf colors different because thats cool and i like it
|
||||||
if(mc_Entity.x == BLOCK_AIR_WAVING){
|
if(isLeaves){
|
||||||
SummerCol = vec3(Summer_Leaf_R, Summer_Leaf_G, Summer_Leaf_B);
|
SummerCol = vec3(Summer_Leaf_R, Summer_Leaf_G, Summer_Leaf_B);
|
||||||
AutumnCol = vec3(Fall_Leaf_R, Fall_Leaf_G, Fall_Leaf_B);
|
AutumnCol = vec3(Fall_Leaf_R, Fall_Leaf_G, Fall_Leaf_B);
|
||||||
WinterCol = vec3(Winter_Leaf_R, Winter_Leaf_G, Winter_Leaf_B);
|
WinterCol = vec3(Winter_Leaf_R, Winter_Leaf_G, Winter_Leaf_B);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user