Compare commits
7 commits
cde37a365c
...
944f5b352b
Author | SHA1 | Date | |
---|---|---|---|
|
944f5b352b | ||
|
bb68cfdf48 | ||
|
fa5574b074 | ||
|
39a2ff3bfc | ||
|
b0c74f4825 | ||
|
d5798ecc7d | ||
|
0c4e2c9143 |
1112 changed files with 70173 additions and 0 deletions
BIN
client/1.20.6/core/bobby-5.2.0+mc1.20.6.jar
Normal file
BIN
client/1.20.6/core/bobby-5.2.0+mc1.20.6.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/core/cloth-config-14.0.126-fabric.jar
Normal file
BIN
client/1.20.6/core/cloth-config-14.0.126-fabric.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/core/fabric-api-0.97.8+1.20.6.jar
Normal file
BIN
client/1.20.6/core/fabric-api-0.97.8+1.20.6.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/core/lithium-fabric-mc1.20.6-0.12.3.jar
Normal file
BIN
client/1.20.6/core/lithium-fabric-mc1.20.6-0.12.3.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/core/modmenu-10.0.0-beta.1.jar
Normal file
BIN
client/1.20.6/core/modmenu-10.0.0-beta.1.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/core/sodium-fabric-0.5.8+mc1.20.6.jar
Normal file
BIN
client/1.20.6/core/sodium-fabric-0.5.8+mc1.20.6.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/extra/appleskin-neoforge-mc1.20.5-3.0.0.jar
Normal file
BIN
client/1.20.6/extra/appleskin-neoforge-mc1.20.5-3.0.0.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/extra/freecam-fabric-modrinth-1.2.4+mc1.20.5.jar
Normal file
BIN
client/1.20.6/extra/freecam-fabric-modrinth-1.2.4+mc1.20.5.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/extra/guiclock-1.20.6-4.5.jar
Normal file
BIN
client/1.20.6/extra/guiclock-1.20.6-4.5.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/extra/guicompass-1.20.6-4.6.jar
Normal file
BIN
client/1.20.6/extra/guicompass-1.20.6-4.6.jar
Normal file
Binary file not shown.
BIN
client/1.20.6/fabric-installer-1.0.1.exe
Normal file
BIN
client/1.20.6/fabric-installer-1.0.1.exe
Normal file
Binary file not shown.
46
client/1.20.6/install_jungle.bat
Normal file
46
client/1.20.6/install_jungle.bat
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
@ECHO OFF
|
||||||
|
set installfolder=%cd%
|
||||||
|
ECHO The Monkey will now plant a Jungle in your computer.
|
||||||
|
ECHO Good Luck!
|
||||||
|
ECHO It's CTRL+C to quit this btw.
|
||||||
|
ECHO If you wanna quit, now is the right time, because stopping copying files can be annyoing to clean.
|
||||||
|
PAUSE
|
||||||
|
cd %appdata%\.minecraft
|
||||||
|
MD mods
|
||||||
|
CD mods
|
||||||
|
|
||||||
|
SET /P installfabric=Install Fabric (Y/[N])?
|
||||||
|
IF /I "%installfabric%" NEQ "Y" GOTO SKIPINSTALLFABRIC
|
||||||
|
SET fabriclocation=%installfolder%\fabric-installer-1.0.1.exe
|
||||||
|
START %fabriclocation%
|
||||||
|
ECHO Give this a second to load before moving onto the next step!
|
||||||
|
PAUSE
|
||||||
|
|
||||||
|
:SKIPINSTALLFABRIC
|
||||||
|
|
||||||
|
SET /P installcore=Install Core (Y/[N])?
|
||||||
|
IF /I "%installcore%" NEQ "Y" GOTO SKIPINSTALLCORE
|
||||||
|
COPY %installfolder%\core\*
|
||||||
|
|
||||||
|
:SKIPINSTALLCORE
|
||||||
|
|
||||||
|
SET /P installextra=Install Extras (Y/[N])?
|
||||||
|
IF /I "%installextra%" NEQ "Y" GOTO SKIPINSTALLEXTRA
|
||||||
|
COPY %installfolder%\extra\*
|
||||||
|
|
||||||
|
:SKIPINSTALLEXTRA
|
||||||
|
|
||||||
|
SET /P installshaders=Install Shaders (Y/[N])?
|
||||||
|
IF /I "%installshaders%" NEQ "Y" GOTO SKIPINSTALLSHADERS
|
||||||
|
COPY %installfolder%\shaders\*
|
||||||
|
CD ..
|
||||||
|
MD shaderpacks
|
||||||
|
CD shaderpacks
|
||||||
|
XCOPY %installfolder%\shaderpacks %cd% /s /e
|
||||||
|
|
||||||
|
:SKIPINSTALLSHADERS
|
||||||
|
|
||||||
|
ECHO Everything has installed successfully!
|
||||||
|
ECHO Have fun!
|
||||||
|
|
||||||
|
PAUSE
|
10
client/1.20.6/shaderpacks/Bliss-Shader-main.txt
Normal file
10
client/1.20.6/shaderpacks/Bliss-Shader-main.txt
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
#Tue May 14 22:21:55 WAT 2024
|
||||||
|
BLISS_SHADERS=1
|
||||||
|
BLOOM_STRENGTH=0.0
|
||||||
|
DAMAGE_TAKEN_EFFECT=false
|
||||||
|
EMISSIVE_TYPE=0
|
||||||
|
EXPOSURE_MULTIPLIER=0.7
|
||||||
|
MOTION_AMOUNT=0.0
|
||||||
|
SATURATION=0.4
|
||||||
|
SHARPENING=1.0
|
||||||
|
TONEMAP=Tonemap_Xonk
|
34
client/1.20.6/shaderpacks/Bliss-Shader-main/CREDITS.txt
Normal file
34
client/1.20.6/shaderpacks/Bliss-Shader-main/CREDITS.txt
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
Credit to the creator of the entire shader that Bliss is an edit of:
|
||||||
|
|
||||||
|
Chocapic13 / https://www.curseforge.com/minecraft/customization/chocapic13-shaders
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Credit to the creators of code contributions, various code uses, or code snippets:
|
||||||
|
|
||||||
|
EminGt / https://github.com/EminGT
|
||||||
|
Gri573 / https://github.com/gri573
|
||||||
|
Null / https://github.com/Null-MC
|
||||||
|
Sasha / https://github.com/WoMspace
|
||||||
|
SixthSurge / https://github.com/sixthsurge
|
||||||
|
Zombye / https://github.com/zombye
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Credit to the translators:
|
||||||
|
|
||||||
|
Nord / nordwhy (discord)
|
||||||
|
Ruri / nakiriruri (discord)
|
||||||
|
YurgenS / yurgens (discord)
|
||||||
|
CReepa / _CReepa_ (discord)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Credit to the people who inspired many changes and ideas, that you NEED to know about:
|
||||||
|
|
||||||
|
Ambrosia / https://github.com/ambrosia13
|
||||||
|
Rre36 / https://github.com/rre36
|
||||||
|
SixthSurge / https://github.com/sixthsurge
|
||||||
|
EminGt / https://github.com/EminGT
|
||||||
|
Null / https://github.com/Null-MC
|
||||||
|
L4mbads / l4mbads (discord) | https://www.youtube.com/channel/UC-5tMMYBNrGJfp1SMjuAf2w
|
47
client/1.20.6/shaderpacks/Bliss-Shader-main/LICENSE.md
Normal file
47
client/1.20.6/shaderpacks/Bliss-Shader-main/LICENSE.md
Normal file
|
@ -0,0 +1,47 @@
|
||||||
|
License, as stated by Chocapic13:
|
||||||
|
Sharing a modified version of my shaders:
|
||||||
|
|
||||||
|
You are not allowed to claim any of the code included in "Chocapic13' shaders" as your own
|
||||||
|
|
||||||
|
You can share a modified version of my shaders if you respect the following title scheme : " -Name of the shaderpack- (Chocapic13' Shaders edit) "
|
||||||
|
|
||||||
|
You cannot use any monetizing links (for example adfoc.us ; adf.ly)
|
||||||
|
|
||||||
|
The rules of modification and sharing have to be same as the one here (copy paste all these rules in your post and change depending if you allow modification or not), you cannot make your own rules, you can only choose if you allow redistribution.
|
||||||
|
|
||||||
|
I have to be clearly credited
|
||||||
|
|
||||||
|
You cannot use any version older than "Chocapic13' Shaders V4" as a base, however you can modify older versions for personal use
|
||||||
|
|
||||||
|
Common sense : if you want a feature from another shaderpack or want to use a piece of code found on the web, make sure the code is open source. In doubt ask the creator.
|
||||||
|
|
||||||
|
Common sense #2 : share your modification only if you think it adds something really useful to the shaderpack(not only 2-3 constants changed)
|
||||||
|
Special level of permission; with written permission from Chocapic13, on request if you think your shaderpack is an huge modification from the original:
|
||||||
|
|
||||||
|
Allows to use monetizing links
|
||||||
|
|
||||||
|
Allows to create your own sharing rules
|
||||||
|
|
||||||
|
Shaderpack name can be chosen
|
||||||
|
|
||||||
|
Listed on Chocapic13' shaders official thread
|
||||||
|
|
||||||
|
Chocapic13 still have to be clearly credited
|
||||||
|
|
||||||
|
Using this shaderpack in a video or a picture:
|
||||||
|
|
||||||
|
You are allowed to use this shaderpack for screenshots and videos if you give the shaderpack name in the description/message
|
||||||
|
|
||||||
|
You are allowed to use this shaderpack in monetized videos if you respect the rule above.
|
||||||
|
|
||||||
|
Minecraft websites:
|
||||||
|
|
||||||
|
The download link must redirect to the download link given in the shaderpack's official thread
|
||||||
|
|
||||||
|
There has to be a link to the shaderpack's official thread
|
||||||
|
|
||||||
|
You are not allowed to add any monetizing link to the shaderpack download
|
||||||
|
|
||||||
|
If you are not sure about what you are allowed to do or not, PM Chocapic13 on http://www.minecraftforum.net/.
|
||||||
|
|
||||||
|
Not respecting these rules can and will result in a request of thread/download shutdown to the host/administrator, with or without warning. Intellectual property stealing is punished by law.
|
25
client/1.20.6/shaderpacks/Bliss-Shader-main/README.md
Normal file
25
client/1.20.6/shaderpacks/Bliss-Shader-main/README.md
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
# Bliss
|
||||||
|
<img src="https://github.com/X0nk/Bliss-Shader/assets/122314734/873c788c-5a48-46c0-9fb5-eac57b4ffa27" width="100%" height="100%">
|
||||||
|
I always loved chocapic's shaders, and how customizeable it was. But i wanted MORE.
|
||||||
|
i eventually started tweaking the shader, adding settings, breaking stuff, and after a while wanted to impose my own visual style onto the shader.
|
||||||
|
i wanted to emphasize a varying scene, where the lighting isn't always the same whenever or wherever you are.
|
||||||
|
|
||||||
|
### SPECIAL THANKS:
|
||||||
|
+ Chocapic13, for the whole thing
|
||||||
|
+ WoMspace, for doing a DOF overhaul
|
||||||
|
+ Emin, and Gri573, for teaching me how to stop alot of light leaking
|
||||||
|
+ RRe36 and Sixthsurge, for the great ideas to steal
|
||||||
|
### [Want to support me? donate on my patreon](https://www.patreon.com/Xonkmoney)
|
||||||
|
|
||||||
|
# IN-DEVELOPMENT VERSIONS AND RELEASE VERSIONS
|
||||||
|
`In-development versions` are the very latest versions, and are released regularly to be tested by anyone. **Please report any issues you find.**
|
||||||
|
|
||||||
|
`Release versions` are uploaded when the in-development version is stable enough, and has enough changes to warrant a release. These are the versions uploaded to Modrinth or Curseforge. The release versions are not the very latest version.
|
||||||
|
### Download the latest `in-development` version:
|
||||||
|
- locate the `green "code" button` on this page. this button is NOT in the `releases` page.
|
||||||
|
- click the `green "code" button` and select `"download zip"`.
|
||||||
|
- once the zip file finishes downloading, install it like a normal shader. you do NOT need to unzip/extract/decompress.
|
||||||
|
### Download the latest `release` version:
|
||||||
|
- locate the `"Releases"` tab on the right side of this page.
|
||||||
|
- find the release version you want to download. locate the files attactched to it, and download the file named similar to `"Bliss_(version)_chocapic13_shaders_edit.zip"`
|
||||||
|
- once the zip file finishes downloading, install it like a normal shader. you do NOT need to unzip/extract/decompress.
|
|
@ -0,0 +1,448 @@
|
||||||
|
layer.translucent = minecraft:glass minecraft:glass_pane
|
||||||
|
|
||||||
|
block.8=minecraft:water minecraft:flowing_water
|
||||||
|
|
||||||
|
block.11=bamboo bamboo_sapling
|
||||||
|
|
||||||
|
block.12=minecraft:short_grass minecraft:grass
|
||||||
|
|
||||||
|
block.13=minecraft:tall_grass:half=lower
|
||||||
|
|
||||||
|
block.14=minecraft:tall_grass:half=upper
|
||||||
|
|
||||||
|
block.15=minecraft:oak_sapling minecraft:spruce_sapling minecraft:birch_sapling minecraft:jungle_sapling minecraft:acacia_sapling minecraft:dark_oak_sapling
|
||||||
|
|
||||||
|
block.16=vine
|
||||||
|
|
||||||
|
|
||||||
|
####### ----- waving blocks with SSS ----- #######
|
||||||
|
|
||||||
|
## ground waving
|
||||||
|
## add a newline to organize for modded blocks
|
||||||
|
block.60=minecraft:sunflower:half=upper minecraft:beetroots minecraft:potatoes minecraft:carrots minecraft:wheat minecraft:nether_wart minecraft:kelp minecraft:large_fern:half=upper minecraft:peony:half=upper minecraft:rose_bush:half=upper minecraft:lilac:half=upper minecraft:crimson_roots minecraft:nether_sprouts minecraft:warped_roots minecraft:seagrass minecraft:tall_seagrass:half=upper minecraft:wither_rose minecraft:lily_of_the_valley minecraft:cornflower minecraft:sweet_berry_bush minecraft:oxeye_daisy minecraft:pink_tulip minecraft:white_tulip minecraft:orange_tulip minecraft:red_tulip minecraft:azure_bluet minecraft:allium minecraft:blue_orchid minecraft:poppy minecraft:dandelion minecraft:dead_bush
|
||||||
|
# removed: sapling(s)
|
||||||
|
|
||||||
|
## ground waving vertical models. this exists to brighten up the sides of grass and stuff in shaded places they blend in better with the world.
|
||||||
|
block.61=minecraft:fern conquest:acacia_sapling conquest:alder_tree_sapling conquest:apple_tree_sapling conquest:aspen_tree_sapling conquest:birch_sapling conquest:cherry_tree_sapling conquest:dark_oak_sapling conquest:downy_willow_tree_sapling conquest:gorse_tree_sapling conquest:grape_vine_sapling conquest:horse_chestnut_tree_sapling conquest:jungle_sapling conquest:larch_tree_sapling conquest:mallorn_tree_sapling conquest:oak_sapling conquest:orange_tree_sapling conquest:pear_tree_sapling conquest:pine_tree_sapling conquest:plum_tree_sapling conquest:rowan_tree_sapling conquest:spruce_sapling conquest:willow_tree_sapling conquest:angelica conquest:black_knapweed conquest:buttercups conquest:cornflower conquest:dandelion conquest:elanor conquest:goldenrod conquest:harebell conquest:lily_of_the_valley conquest:lobelia_flowers conquest:marsh_ragwort conquest:meadow_saffron conquest:mediterranean_wild_tulip conquest:moorland_spotted_orchid conquest:niphredil conquest:orange_tulip conquest:orpine conquest:oxeye_daisy conquest:pasque_flower conquest:pink_tulip conquest:poppy conquest:red_tulip conquest:rock_rose conquest:sea_lavender conquest:simbelmyne conquest:white_clematis conquest:white_tulip conquest:wild_dagga conquest:allium conquest:barley conquest:bean_pole conquest:beetroots conquest:cabbage conquest:carrots conquest:common_beans conquest:corn conquest:flax conquest:heirloom_wheat_crops conquest:hemp conquest:lavender conquest:peas conquest:potatoes conquest:rice conquest:thyme conquest:tobacco conquest:turnips conquest:water_mint conquest:wheat conquest:wild_basil conquest:wild_parsley conquest:wild_wheat conquest:common_meadow_grass conquest:cotton_grass conquest:dead_grass conquest:deergrass conquest:grass conquest:kentucky_bluegrass conquest:lush_grass conquest:purple_moor_grass conquest:sea_arrowgrass conquest:seagrass conquest:sweet_grass conquest:timothy_grass conquest:wavy_hair_grass conquest:pine_cones conquest:spruce_cones conquest:beautyberry_bush conquest:bilberry_bush conquest:blackberry_bush conquest:bog_blueberry_bush conquest:broom_bush conquest:dead_bush conquest:hawthorn_bush conquest:lingonberry_bush conquest:raspberry_bush conquest:alpine_sow_thristle conquest:athelas conquest:autumnal_dwarf_birch conquest:birdsfoot_trefoil conquest:bog_asphodel conquest:bottle_sedge conquest:cattails conquest:common_cow_wheat conquest:cow_parsley conquest:cross leaved heath conquest:dead_reeds conquest:dead_shrubs conquest:desert_shrub conquest:dogs_mercury conquest:dooryard_dock conquest:dry_reeds conquest:greater_fen_sedge conquest:greater_wood_rush conquest:green_meadow_fescue conquest:green_spurge conquest:heather conquest:meadow_fescue conquest:melancholy_thristle conquest:nettles conquest:nightshade conquest:papyrus conquest:purple_wolfs_bane conquest:red_common_cow_wheat conquest:rosebay_willowherb conquest:rushes conquest:wild_shrub conquest:sedge conquest:small_fescue conquest:small_scabious conquest:sweet_woodruff conquest:wild_overgrown_nettles conquest:wild_shrub conquest:wood_horsetail conquest:woodland_sedge conquest:wormwood conquest:yellow_wolfs_bane conquest:autumnal_bracken conquest:bracken conquest:dark_autumnal_bracken conquest:dead_bracken conquest:fern conquest:fern_1 conquest:fern_2 conquest:harts_tongue_fern conquest:large_fern_1 conquest:large_fern_2 conquest:large_fern_3 conquest:thick_fern conquest:tall_grass conquest:large_fern conquest:sunflower conquest:tall_lilac conquest:peony conquest:rose_bush conquest:tall_seagrass conquest:cypress conquest:young_tree conquest:young_frozen_tree conquest:cross_leaved_heath conquest:jungle_ground_cover conquest:alpine_sow_thistle conquest:duckweed conquest:red_mushroom conquest:brown_mushroom
|
||||||
|
|
||||||
|
## air waving
|
||||||
|
## add a newline to organize for modded blocks
|
||||||
|
block.62=minecraft:azalea_leaves minecraft:flowering_azalea_leaves minecraft:cherry_leaves minecraft:mangrove_leaves minecraft:vine minecraft:oak_leaves minecraft:spruce_leaves minecraft:birch_leaves minecraft:jungle_leaves minecraft:acacia_leaves minecraft:dark_oak_leaves westerosblocks:vine_jasmine westerosblocks:apple_fruit_leaves westerosblocks:apricot_fruit_leaves westerosblocks:cherry_fruit_leaves westerosblocks:purple_grape_fruit_leaves westerosblocks:lemon_fruit_leaves westerosblocks:lime_fruit_leaves westerosblocks:orange_fruit_leaves westerosblocks:peach_fruit_leaves westerosblocks:plum_fruit_leaves westerosblocks:pomegranate_fruit_leaves westerosblocks:weirwood_leaves westerosblocks:hop_fruit_leaves westerosblocks:olive_fruit_leaves westerosblocks:palm_leaves westerosblocks:white_grape_fruit_leaves conquest:apple_tree_leaves conquest:ash_tree_leaves conquest:aspen_leaves conquest:autumnal_aspen_leaves conquest:dark_deciduous_leaves conquest:autumnal_beech_tree_leaves conquest:autumnal_birch_leaves conquest:autumnal_horse_chestnut_leaves conquest:autumnal_maple_leaves conquest:autumnal_oak_leaves conquest:autumnal_weeping_willow_leaves conquest:banana_tree_leaves conquest:beech_tree_leaves conquest:bright_autumnal_beech_tree_leaves conquest:bright_autumnal_weeping_willow_leaves conquest:bushy_joshua_tree_leaves conquest:caribbean_royal_palm_leaves conquest:caribbean_royal_palm_leaves_corner conquest:cherry_tree_leaves conquest:dark_beech_tree_leaves conquest:date_palm_leaves conquest:diseased_horse_chestnut_leaves conquest:downy_willow_leaves conquest:downy_willow_leaves_tip conquest:faded_autumnal_beech_tree_leaves conquest:dead_norway_spruce_needles conquest:orange_larch_leaf_top conquest:yellow_larch_leaf_top conquest:larch_leaf_top conquest:larch_spruce_leaf_top conquest:larch_leaf_slab conquest:larch_leaf_long_branch conquest:larch_leaf_branch conquest:larch_spruce_leaf_top conquest:yellow_larch_spruce_leaf_top conquest:yellow_larch_leaf_slab conquest:yellow_larch_leaf_long_branch conquest:yellow_larch_leaf_branch conquest:orange_larch_spruce_leaf_top conquest:orange_larch_leaf_slab conquest:oranch_larch_leaf_long_branch conquest:orange_larch_leaf_branch conquest:dead_spruce_leaf_top conquest:dead_spruce_leaf_slab conquest:dead_spruce_leaf_long_branch conquest:dead_spruce_leaf_branch conquest:light_spruce_leaf_top conquest:light_spruce_leaf_slab conquest:light_spruce_leaf_long_branch conquest:light_spruce_leaf_branch conquest:goat_willow_leaves conquest:gorse_leaves conquest:grape_vine_leaves conquest:holly_leaves conquest:horse_chestnut_leaves conquest:joshua_tree_leaves conquest:lemon_tree_leaves conquest:old_caribbean_royal_palm_leaves conquest:old_caribbean_royal_palm_leaves_corner conquest:olive_tree_leaves conquest:orange_tree_leaves conquest:pear_tree_leaves conquest:plum_tree_leaves conquest:rowan_leaves conquest:weeping_willow_leaves conquest:wisteria_leaves conquest:yellow_autumnal_weeping_willow_leaves conquest:dark_spruce_needles conquest:dead_pine_needles conquest:dead_spruce_needles conquest:larch_needles conquest:light_spruce_needles conquest:orange_autumnal_larch_needles conquest:pine_needles conquest:yellow_autumnal_larch_needles conquest:dead_deciduous_branches conquest:mistletoe_garland conquest:lilac conquest:pink_cherry_blossoms conquest:purple_cherry_blossoms conquest:red_cherry_blossoms conquest:white_cherry_blossoms conquest:wisteria_blossoms conquest:hanging_moss conquest:lianas conquest:moss_vines conquest:spruce_leaf_top conquest:spruce_leaf_branch conquest:spruce_leaf_slab conquest:spruce_leaf_long_branch conquest:thick_hanging_ivy conquest:thick_ivy conquest:hanging_roots conquest:acacia_branch_tip conquest:acacia_branch_tip_45 conquest:acacia_branch_tip_2 conquest:acacia_branch_tip_2_45 conquest:beech_branch_tip conquest:beech_branch_tip_45 conquest:beech_branch_tip_2 conquest:beech _branch_tip_2_45 conquest:birch_branch_tip conquest:birch_branch_tip_45 conquest:birch_branch_tip_2 conquest:birch_branch_tip_2_45 conquest:oak_branch_tip conquest:oak_branch_tip_45 conquest:oak_branch_tip_2 conquest:oak_branch_tip_2_45 conquest:spruce_branch_tip conquest:spruce_branch_tip_45 conquest:spruce_branch_tip_2 conquest:spruce_branch_tip_2_45 conquest:orange_pine_branch_tip conquest:orange_pine_branch_tip_45 conquest:orange_pine_branch_tip_2 conquest:orange_pine_branch_tip_2_45
|
||||||
|
|
||||||
|
|
||||||
|
####### ----- blocks with SSS ----- #######
|
||||||
|
|
||||||
|
## strong sss
|
||||||
|
block.80=minecraft:flowering_azalea minecraft:tall_seagrass minecraft:seagrass minecraft:kelp minecraft:large_fern:half=lower minecraft:tall_seagrass minecraft:kelp_plant minecraft:peony minecraft:rose_bush minecraft:lilac minecraft:sunflower:half=lower minecraft:packed_ice minecraft:blue_ice minecraft:melon_stem minecraft:pumpkin_stem minecraft:attached_melon_stem minecraft:attached_pumpkin_stem minecraft:lily_pad westerosblocks:blackberry_bush westerosblocks:blueberry_bush westerosblocks:raspberry_bush westerosblocks:juniper_bush westerosblocks:red_rose_bush westerosblocks:pink_rose_bush westerosblocks:white_rose_bush westerosblocks:yellow_rose_bush westerosblocks:yellow_wildflowers westerosblocks:green_spiny_herb westerosblocks:green_leafy_herb westerosblocks:orange_marigolds westerosblocks:orange_trollius westerosblocks:blue_forgetmenots westerosblocks:pink_wildflowers westerosblocks:yellow_tansy westerosblocks:blue_flax westerosblocks:white_daisies westerosblocks:yellow_daisies westerosblocks:green_scrub_grass westerosblocks:dead_scrub_grass westerosblocks:yellow_bedstraw westerosblocks:orange_bells westerosblocks:blue_bells westerosblocks:blue_swamp_bells westerosblocks:yellow_buttercups westerosblocks:orange_bog_asphodel westerosblocks:yellow_lupine westerosblocks:blue_hyacinth westerosblocks:pink_thistle westerosblocks:yellow_dandelions westerosblocks:yellow_daffodils westerosblocks:yellow_roses westerosblocks:strawberry_bush westerosblocks:white_lilyofthevalley westerosblocks:yellow_bells westerosblocks:yellow_sunflower westerosblocks:white_roses westerosblocks:red_dark_roses westerosblocks:yellow_hellebore westerosblocks:meadow_fescue westerosblocks:red_poppies westerosblocks:red_roses westerosblocks:purple_pansies westerosblocks:purple_roses westerosblocks:orange_sun_star westerosblocks:pink_primrose westerosblocks:red_aster westerosblocks:blue_chicory westerosblocks:red_flowering_spiny_herb westerosblocks:purple_foxglove westerosblocks:pink_allium westerosblocks:purple_violets westerosblocks:white_chamomile westerosblocks:red_tulips westerosblocks:white_peony westerosblocks:purple_alpine_sowthistle westerosblocks:red_carnations westerosblocks:magenta_roses westerosblocks:red_chrysanthemum westerosblocks:blue_orchid westerosblocks:yellow_rudbeckia westerosblocks:pink_tulips westerosblocks:cranberry_bush westerosblocks:purple_lavender westerosblocks:red_sourleaf_bush westerosblocks:pink_sweet_peas westerosblocks:red_sorrel westerosblocks:pink_roses westerosblocks:unshaded_grass westerosblocks:cow_parsely westerosblocks:bracken westerosblocks:lady_fern westerosblocks:nettle westerosblocks:dead_bracken westerosblocks:fireweed westerosblocks:heather westerosblocks:red_fern westerosblocks:dock_leaf westerosblocks:jasmine_vines westerosblocks:dappled_moss westerosblocks:cushion_moss_wall westerosblocks:hemp_short westerosblocks:hemp_tall westerosblocks:hemp_dense westerosblocks:crop_carrots westerosblocks:crop_wheat westerosblocks:crop_turnips westerosblocks:crop_peas westerosblocks:cattails westerosblocks:jungle_tall_fern westerosblocks:jungle_tall_grass westerosblocks:savanna_tall_grass
|
||||||
|
|
||||||
|
## weak sss
|
||||||
|
block.81=minecraft:amethyst_block minecraft:budding_amethyst minecraft:small_amethyst_bud minecraft:pitcher_plant minecraft:small_dripleaf minecraft:grass_block:snowy=true minecraft:snow_block minecraft:snow powder_snow cobweb red_mushroom_block brown_mushroom_block weeping_vines weeping_vines_plant twisting_vines twisting_vines_plant tube_coral tube_coral_block tube_coral_fan tube_coral_wall_fan horn_coral horn_coral_block horn_coral_fan horn_coral_wall_fan fire_coral fire_coral_block fire_coral_fan fire_coral_wall_fan dead_brain_coral dead_brain_coral_block dead_brain_coral_fan dead_brain_coral_wall_fan dead_bubble_coral dead_bubble_coral_block dead_bubble_coral_fan dead_bubble_coral_wall_fan dead_bush dead_fire_coral dead_fire_coral_block dead_fire_coral_fan dead_fire_coral_wall_fan dead_horn_coral dead_horn_coral_block dead_horn_coral_fan dead_horn_coral_wall_fan dead_tube_coral dead_tube_coral_block dead_tube_coral_fan dead_tube_coral_wall_fan bubble_coral bubble_coral_block bubble_coral_fan bubble_coral_wall_fan brain_coral brain_coral_block brain_coral_fan brain_coral_wall_fan minecraft:spore_blossom minecraft:cave_vines:berries=false minecraft:cave_vines_plant:berries=false minecraft:glow_lichen minecraft:melon minecraft:pumpkin minecraft:big_dripleaf minecraft:big_dripleaf_stem minecraft:cactus minecraft:hay_block minecraft:brown_mushroom minecraft:mushroom_stem minecraft:sugar_cane minecraft:crimson_fungus minecraft:warped_fungus minecraft:sea_pickle:waterlogged=false minecraft:honeycomb_block
|
||||||
|
|
||||||
|
## weak sss
|
||||||
|
block.82=minecraft:white_wool minecraft:orange_wool minecraft:magenta_wool minecraft:light_blue_wool minecraft:yellow_wool minecraft:lime_wool minecraft:pink_wool minecraft:gray_wool minecraft:light_gray_wool minecraft:cyan_wool minecraft:purple_wool minecraft:blue_wool minecraft:brown_wool minecraft:green_wool minecraft:red_wool minecraft:black_wool minecraft:orange_carpet minecraft:magenta_carpet minecraft:light_blue_carpet minecraft:yellow_carpet minecraft:lime_carpet minecraft:pink_carpet minecraft:gray_carpet minecraft:light_gray_carpet minecraft:cyan_carpet minecraft:purple_carpet minecraft:blue_carpet minecraft:brown_carpet minecraft:green_carpet minecraft:red_carpet minecraft:black_carpet westerosblocks:clothesline westerosblocks:smoke westerosblocks:brown_mushroom_1 westerosblocks:brown_mushroom_2 westerosblocks:brown_mushroom_3 westerosblocks:brown_mushroom_4 westerosblocks:brown_mushroom_5 westerosblocks:brown_mushroom_6 westerosblocks:brown_mushroom_7 westerosblocks:brown_mushroom_8 westerosblocks:brown_mushroom_9 westerosblocks:brown_mushroom_10 westerosblocks:brown_mushroom_11 westerosblocks:brown_mushroom_12 westerosblocks:brown_mushroom_13 westerosblocks:red_mushroom_1 westerosblocks:red_mushroom_2 westerosblocks:red_mushroom_3 westerosblocks:red_mushroom_4 westerosblocks:red_mushroom_5 westerosblocks:red_mushroom_6 westerosblocks:red_mushroom_7 westerosblocks:red_mushroom_8 westerosblocks:red_mushroom_9 westerosblocks:white_wool_slab westerosblocks:orange_wool_slab westerosblocks:light_brown_wool_slab westerosblocks:light_blue_wool_slab westerosblocks:yellow_wool_slab westerosblocks:dirty_white_wool_slab westerosblocks:pink_wool_slab westerosblocks:grey_wool_slab westerosblocks:light_grey_wool_slab westerosblocks:cyan_wool_slab westerosblocks:purple_wool_slab westerosblocks:blue_wool_slab westerosblocks:brown_wool_slab westerosblocks:green_wool_slab westerosblocks:red_wool_slab westerosblocks:black_wool_slab westerosblocks:white_wool_carpet westerosblocks:orange_wool_carpet westerosblocks:light_brown_wool_carpet westerosblocks:light_blue_wool_carpet westerosblocks:yellow_wool_carpet westerosblocks:dirty_white_wool_carpet westerosblocks:pink_wool_carpet westerosblocks:grey_wool_carpet westerosblocks:light_grey_wool_carpet westerosblocks:cyan_wool_carpet westerosblocks:purple_wool_carpet westerosblocks:blue_wool_carpet westerosblocks:brown_wool_carpet westerosblocks:green_wool_carpet westerosblocks:red_wool_carpet westerosblocks:black_wool_carpet westerosblocks:thatch_light_fur_carpet westerosblocks:thatch_dark_fur_carpet
|
||||||
|
|
||||||
|
## weak sss
|
||||||
|
block.83=minecraft:white_wall_banner minecraft:orange_wall_banner minecraft:magenta_wall_banner minecraft:light_blue_wall_banner minecraft:yellow_wall_banner minecraft:lime_wall_banner minecraft:pink_wall_banner minecraft:gray_wall_banner minecraft:light_gray_wall_banner minecraft:cyan_wall_banner minecraft:purple_wall_banner minecraft:blue_wall_banner minecraft:brown_wall_banner minecraft:green_wall_banner minecraft:red_wall_banner minecraft:black_wall_banner minecraft:white_banner minecraft:orange_banner minecraft:magenta_banner minecraft:light_blue_banner minecraft:yellow_banner minecraft:lime_banner minecraft:pink_banner minecraft:gray_banner minecraft:light_gray_banner minecraft:cyan_banner minecraft:purple_banner minecraft:blue_banner minecraft:brown_banner minecraft:green_banner minecraft:red_banner minecraft:black_banner westerosblocks:renly_banner westerosblocks:redwyne_banner westerosblocks:grafton_banner westerosblocks:grey_banner westerosblocks:red_banner westerosblocks:black_banner westerosblocks:the_faith_of_the_seven_banner westerosblocks:cream_banner westerosblocks:blue_banner westerosblocks:brown_banner westerosblocks:cyan_banner westerosblocks:green_banner westerosblocks:orange_banner westerosblocks:pink_banner westerosblocks:purple_banner westerosblocks:lord_of_light_rhllor_banner westerosblocks:yellow_banner westerosblocks:arryn_banner westerosblocks:baratheon_banner westerosblocks:bolton_banner westerosblocks:dayne_banner westerosblocks:frey_banner westerosblocks:greyjoy_banner westerosblocks:hightower_banner westerosblocks:lannister_banner westerosblocks:manderly_banner westerosblocks:martell_banner westerosblocks:stannis_banner westerosblocks:stark_banner westerosblocks:targaryen_banner westerosblocks:tarly_banner westerosblocks:tully_banner westerosblocks:tyrell_banner
|
||||||
|
|
||||||
|
## weird blocks
|
||||||
|
block.84=minecraft:sand minecraft:red_sand
|
||||||
|
|
||||||
|
## grass uwu
|
||||||
|
block.85=minecraft:grass_block:snowy=false
|
||||||
|
|
||||||
|
|
||||||
|
####### ----- lightsources ----- #######
|
||||||
|
|
||||||
|
block.101=large_amethyst_bud
|
||||||
|
|
||||||
|
block.102=medium_amethyst_bud
|
||||||
|
|
||||||
|
block.103=amethyst_cluster
|
||||||
|
|
||||||
|
block.104=beacon
|
||||||
|
|
||||||
|
block.105=brewing_stand
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef LPV_COLORED_CANDLES
|
||||||
|
block.106=candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.107=candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.108=candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.109=candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.110=black_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.111=black_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.112=black_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.113=black_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.114=blue_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.115=blue_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.116=blue_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.117=blue_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.118=brown_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.119=brown_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.120=brown_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.121=brown_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.122=cyan_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.123=cyan_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.124=cyan_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.125=cyan_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.126=gray_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.127=gray_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.128=gray_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.129=gray_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.130=green_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.131=green_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.132=green_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.133=green_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.134=light_blue_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.135=light_blue_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.136=light_blue_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.137=light_blue_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.138=light_gray_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.139=light_gray_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.140=light_gray_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.141=light_gray_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.142=lime_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.143=lime_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.144=lime_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.145=lime_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.146=magenta_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.147=magenta_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.148=magenta_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.149=magenta_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.150=orange_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.151=orange_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.152=orange_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.153=orange_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.154=pink_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.155=pink_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.156=pink_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.157=pink_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.158=purple_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.159=purple_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.160=purple_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.161=purple_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.162=red_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.163=red_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.164=red_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.165=red_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.166=white_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.167=white_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.168=white_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.169=white_candle:candles=4:lit=true
|
||||||
|
|
||||||
|
block.170=yellow_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.171=yellow_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.172=yellow_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.173=yellow_candle:candles=4:lit=true
|
||||||
|
#else
|
||||||
|
block.174=candle:candles=1:lit=true black_candle:candles=1:lit=true blue_candle:candles=1:lit=true brown_candle:candles=1:lit=true cyan_candle:candles=1:lit=true gray_candle:candles=1:lit=true green_candle:candles=1:lit=true light_blue_candle:candles=1:lit=true light_gray_candle:candles=1:lit=true lime_candle:candles=1:lit=true magenta_candle:candles=1:lit=true orange_candle:candles=1:lit=true pink_candle:candles=1:lit=true purple_candle:candles=1:lit=true red_candle:candles=1:lit=true white_candle:candles=1:lit=true yellow_candle:candles=1:lit=true
|
||||||
|
|
||||||
|
block.175=candle:candles=2:lit=true black_candle:candles=2:lit=true blue_candle:candles=2:lit=true brown_candle:candles=2:lit=true cyan_candle:candles=2:lit=true gray_candle:candles=2:lit=true green_candle:candles=2:lit=true light_blue_candle:candles=2:lit=true light_gray_candle:candles=2:lit=true lime_candle:candles=2:lit=true magenta_candle:candles=2:lit=true orange_candle:candles=2:lit=true pink_candle:candles=2:lit=true purple_candle:candles=2:lit=true red_candle:candles=2:lit=true white_candle:candles=2:lit=true yellow_candle:candles=2:lit=true
|
||||||
|
|
||||||
|
block.176=candle:candles=3:lit=true black_candle:candles=3:lit=true blue_candle:candles=3:lit=true brown_candle:candles=3:lit=true cyan_candle:candles=3:lit=true gray_candle:candles=3:lit=true green_candle:candles=3:lit=true light_blue_candle:candles=3:lit=true light_gray_candle:candles=3:lit=true lime_candle:candles=3:lit=true magenta_candle:candles=3:lit=true orange_candle:candles=3:lit=true pink_candle:candles=3:lit=true purple_candle:candles=3:lit=true red_candle:candles=3:lit=true white_candle:candles=3:lit=true yellow_candle:candles=3:lit=true
|
||||||
|
|
||||||
|
block.177=candle:candles=4:lit=true black_candle:candles=4:lit=true blue_candle:candles=4:lit=true brown_candle:candles=4:lit=true cyan_candle:candles=4:lit=true gray_candle:candles=4:lit=true green_candle:candles=4:lit=true light_blue_candle:candles=4:lit=true light_gray_candle:candles=4:lit=true lime_candle:candles=4:lit=true magenta_candle:candles=4:lit=true orange_candle:candles=4:lit=true pink_candle:candles=4:lit=true purple_candle:candles=4:lit=true red_candle:candles=4:lit=true white_candle:candles=4:lit=true yellow_candle:candles=4:lit=true
|
||||||
|
#endif
|
||||||
|
|
||||||
|
block.178=cave_vines_plant:berries=true cave_vines:berries=true
|
||||||
|
|
||||||
|
block.179=comparator:powered=true
|
||||||
|
|
||||||
|
block.180=copper_bulb:lit=true waxed_copper_bulb:lit=true
|
||||||
|
|
||||||
|
block.181=exposed_copper_bulb:lit=true waxed_exposed_copper_bulb:lit=true
|
||||||
|
|
||||||
|
block.182=oxidized_copper_bulb:lit=true waxed_oxidized_copper_bulb:lit=true
|
||||||
|
|
||||||
|
block.183=weathered_copper_bulb:lit=true waxed_weathered_copper_bulb:lit=true
|
||||||
|
|
||||||
|
block.184=conduit
|
||||||
|
|
||||||
|
block.185=crying_obsidian
|
||||||
|
|
||||||
|
block.186=end_gateway
|
||||||
|
|
||||||
|
block.187=end_rod
|
||||||
|
|
||||||
|
block.188=fire campfire:lit=true
|
||||||
|
|
||||||
|
block.189=ochre_froglight
|
||||||
|
|
||||||
|
block.190=pearlescent_froglight
|
||||||
|
|
||||||
|
block.191=verdant_froglight
|
||||||
|
|
||||||
|
block.192=furnace:lit=true blast_furnace:lit=true smoker:lit=true
|
||||||
|
|
||||||
|
block.193=glow_lichen
|
||||||
|
|
||||||
|
block.194=glowstone
|
||||||
|
|
||||||
|
block.195=jack_o_lantern
|
||||||
|
|
||||||
|
block.196=lantern
|
||||||
|
|
||||||
|
block.197=lava
|
||||||
|
|
||||||
|
block.198=light:level=1
|
||||||
|
|
||||||
|
block.199=light:level=2
|
||||||
|
|
||||||
|
block.200=light:level=3
|
||||||
|
|
||||||
|
block.201=light:level=4
|
||||||
|
|
||||||
|
block.202=light:level=5
|
||||||
|
|
||||||
|
block.203=light:level=6
|
||||||
|
|
||||||
|
block.204=light:level=7
|
||||||
|
|
||||||
|
block.205=light:level=8
|
||||||
|
|
||||||
|
block.206=light:level=9
|
||||||
|
|
||||||
|
block.207=light:level=10
|
||||||
|
|
||||||
|
block.208=light:level=11
|
||||||
|
|
||||||
|
block.209=light:level=12
|
||||||
|
|
||||||
|
block.210=light:level=13
|
||||||
|
|
||||||
|
block.211=light:level=14
|
||||||
|
|
||||||
|
block.212=light:level=15
|
||||||
|
|
||||||
|
block.213=magma_block
|
||||||
|
|
||||||
|
block.214=redstone_lamp:lit=true
|
||||||
|
|
||||||
|
block.215=redstone_torch:lit=true redstone_wall_torch:lit=true
|
||||||
|
|
||||||
|
block.216=redstone_wire:power=1
|
||||||
|
|
||||||
|
block.217=redstone_wire:power=2
|
||||||
|
|
||||||
|
block.218=redstone_wire:power=3
|
||||||
|
|
||||||
|
block.219=redstone_wire:power=4
|
||||||
|
|
||||||
|
block.220=redstone_wire:power=5
|
||||||
|
|
||||||
|
block.221=redstone_wire:power=6
|
||||||
|
|
||||||
|
block.222=redstone_wire:power=7
|
||||||
|
|
||||||
|
block.223=redstone_wire:power=8
|
||||||
|
|
||||||
|
block.224=redstone_wire:power=9
|
||||||
|
|
||||||
|
block.225=redstone_wire:power=10
|
||||||
|
|
||||||
|
block.226=redstone_wire:power=11
|
||||||
|
|
||||||
|
block.227=redstone_wire:power=12
|
||||||
|
|
||||||
|
block.228=redstone_wire:power=13
|
||||||
|
|
||||||
|
block.229=redstone_wire:power=14
|
||||||
|
|
||||||
|
block.230=redstone_wire:power=15
|
||||||
|
|
||||||
|
block.231=repeater:powered=true
|
||||||
|
|
||||||
|
block.232=respawn_anchor:charges=4
|
||||||
|
|
||||||
|
block.233=sculk_sensor:sculk_sensor_phase=active
|
||||||
|
|
||||||
|
block.234=sea_pickle:waterlogged=true:pickles=1
|
||||||
|
|
||||||
|
block.235=sea_pickle:waterlogged=true:pickles=2
|
||||||
|
|
||||||
|
block.236=sea_pickle:waterlogged=true:pickles=3
|
||||||
|
|
||||||
|
block.237=sea_pickle:waterlogged=true:pickles=4
|
||||||
|
|
||||||
|
block.238=sea_lantern
|
||||||
|
|
||||||
|
block.239=shroomlight
|
||||||
|
|
||||||
|
block.240=soul_fire soul_campfire:lit=true
|
||||||
|
|
||||||
|
block.241=soul_lantern
|
||||||
|
|
||||||
|
block.242=soul_torch soul_wall_torch
|
||||||
|
|
||||||
|
block.243=torch wall_torch
|
||||||
|
|
||||||
|
block.244=westerosblocks:safe_fire
|
||||||
|
block.245=conquest:white_paper_lantern conquest:yellow_paper_lantern conquest:small_red_paper_lantern conquest:chinese_palace_lantern conquest:campfire conquest:brazier conquest:hanging_brazier conquest:chandelier conquest:candelabra conquest:cross_chandelier conquest:iron_candelabrum_1 conquest:golden_candelabrum_1 conquest:candle conquest:hanging_candle_holder conquest:candle_in_a_lantern conquest:candles conquest:hand_candle conquest:torch_with_grille conquest:elven_hand_light conquest:ship_lantern conquest:victorian_lantern conquest:small_lantern conquest:big_lantern conquest:hanging_oil_lamp conquest:oil_lamp conquest:terracotta_oil_lamp conquest:invisible_light_low conquest:invisible_light_medium conquest:invisible_light
|
||||||
|
|
||||||
|
|
||||||
|
####### ----- reflective translucents / glass ----- #######
|
||||||
|
|
||||||
|
block.301=glass glass_pane
|
||||||
|
|
||||||
|
block.302=honey_block
|
||||||
|
|
||||||
|
block.303=ice frosted_ice
|
||||||
|
|
||||||
|
block.304=nether_portal
|
||||||
|
|
||||||
|
block.305=slime_block
|
||||||
|
|
||||||
|
block.306=black_stained_glass black_stained_glass_pane
|
||||||
|
|
||||||
|
block.307=blue_stained_glass blue_stained_glass_pane
|
||||||
|
|
||||||
|
block.308=brown_stained_glass brown_stained_glass_pane
|
||||||
|
|
||||||
|
block.309=cyan_stained_glass cyan_stained_glass_pane
|
||||||
|
|
||||||
|
block.310=gray_stained_glass gray_stained_glass_pane
|
||||||
|
|
||||||
|
block.311=green_stained_glass green_stained_glass_pane
|
||||||
|
|
||||||
|
block.312=light_blue_stained_glass light_blue_stained_glass_pane
|
||||||
|
|
||||||
|
block.313=light_gray_stained_glass light_gray_stained_glass_pane
|
||||||
|
|
||||||
|
block.314=lime_stained_glass lime_stained_glass_pane
|
||||||
|
|
||||||
|
block.315=magenta_stained_glass magenta_stained_glass_pane
|
||||||
|
|
||||||
|
block.316=orange_stained_glass orange_stained_glass_pane
|
||||||
|
|
||||||
|
block.317=pink_stained_glass pink_stained_glass_pane
|
||||||
|
|
||||||
|
block.318=purple_stained_glass purple_stained_glass_pane
|
||||||
|
|
||||||
|
block.319=red_stained_glass red_stained_glass_pane
|
||||||
|
|
||||||
|
block.320=white_stained_glass white_stained_glass_pane
|
||||||
|
|
||||||
|
block.321=yellow_stained_glass yellow_stained_glass_pane
|
||||||
|
|
||||||
|
|
||||||
|
####### ----- LPV shapes ----- #######
|
||||||
|
|
||||||
|
block.401=chain ladder lever tripwire tripwire_hook snow:layers=1 candle:lit=false black_candle:lit=false blue_candle:lit=false brown_candle:lit=false cyan_candle:lit=false gray_candle:lit=false green_candle:lit=false light_blue_candle:lit=false light_gray_candle:lit=false lime_candle:lit=false magenta_candle:lit=false orange_candle:lit=false pink_candle:lit=false purple_candle:lit=false red_candle:lit=false white_candle:lit=false yellow_candle:lit=false acacia_button bamboo_button birch_button cherry_button crimson_button dark_oak_button jungle_button mangrove_button oak_button polished_blackstone_button spruce_button stone_button warped_button
|
||||||
|
|
||||||
|
block.402=black_carpet blue_carpet brown_carpet cyan_carpet gray_carpet green_carpet light_blue_carpet light_gray_carpet lime_carpet magenta_carpet moss_carpet orange_carpet pink_carpet purple_carpet red_carpet white_carpet yellow_carpet
|
||||||
|
|
||||||
|
|
||||||
|
block.403=acacia_door:facing=north:open=false bamboo_door:facing=north:open=false birch_door:facing=north:open=false cherry_door:facing=north:open=false crimson_door:facing=north:open=false dark_oak_door:facing=north:open=false iron_door:facing=north:open=false jungle_door:facing=north:open=false mangrove_door:facing=north:open=false oak_door:facing=north:open=false spruce_door:facing=north:open=false warped_door:facing=north:open=false copper_door:facing=north:open=false exposed_copper_door:facing=north:open=false weathered_copper_door:facing=north:open=false oxidized_copper_door:facing=north:open=false waxed_copper_door:facing=north:open=false waxed_exposed_copper_door:facing=north:open=false waxed_weathered_copper_door:facing=north:open=false waxed_oxidized_copper_door:facing=north:open=false acacia_door:facing=west:hinge=left:open=true bamboo_door:facing=west:hinge=left:open=true birch_door:facing=west:hinge=left:open=true cherry_door:facing=west:hinge=left:open=true crimson_door:facing=west:hinge=left:open=true dark_oak_door:facing=west:hinge=left:open=true iron_door:facing=west:hinge=left:open=true jungle_door:facing=west:hinge=left:open=true mangrove_door:facing=west:hinge=left:open=true oak_door:facing=west:hinge=left:open=true spruce_door:facing=west:hinge=left:open=true warped_door:facing=west:hinge=left:open=true copper_door:facing=west:hinge=left:open=true exposed_copper_door:facing=west:hinge=left:open=true weathered_copper_door:facing=west:hinge=left:open=true oxidized_copper_door:facing=west:hinge=left:open=true waxed_copper_door:facing=west:hinge=left:open=true waxed_exposed_copper_door:facing=west:hinge=left:open=true waxed_weathered_copper_door:facing=west:hinge=left:open=true waxed_oxidized_copper_door:facing=west:hinge=left:open=true acacia_door:facing=east:hinge=right:open=true bamboo_door:facing=east:hinge=right:open=true birch_door:facing=east:hinge=right:open=true cherry_door:facing=east:hinge=right:open=true crimson_door:facing=east:hinge=right:open=true dark_oak_door:facing=east:hinge=right:open=true iron_door:facing=east:hinge=right:open=true jungle_door:facing=east:hinge=right:open=true mangrove_door:facing=east:hinge=right:open=true oak_door:facing=east:hinge=right:open=true spruce_door:facing=east:hinge=right:open=true warped_door:facing=east:hinge=right:open=true copper_door:facing=east:hinge=right:open=true exposed_copper_door:facing=east:hinge=right:open=true weathered_copper_door:facing=east:hinge=right:open=true oxidized_copper_door:facing=east:hinge=right:open=true waxed_copper_door:facing=east:hinge=right:open=true waxed_exposed_copper_door:facing=east:hinge=right:open=true waxed_weathered_copper_door:facing=east:hinge=right:open=true waxed_oxidized_copper_door:facing=east:hinge=right:open=true
|
||||||
|
|
||||||
|
block.404=acacia_door:facing=east:open=false bamboo_door:facing=east:open=false birch_door:facing=east:open=false cherry_door:facing=east:open=false crimson_door:facing=east:open=false dark_oak_door:facing=east:open=false iron_door:facing=east:open=false jungle_door:facing=east:open=false mangrove_door:facing=east:open=false oak_door:facing=east:open=false spruce_door:facing=east:open=false warped_door:facing=east:open=false copper_door:facing=east:open=false exposed_copper_door:facing=east:open=false weathered_copper_door:facing=east:open=false oxidized_copper_door:facing=east:open=false waxed_copper_door:facing=east:open=false waxed_exposed_copper_door:facing=east:open=false waxed_weathered_copper_door:facing=east:open=false waxed_oxidized_copper_door:facing=east:open=false acacia_door:facing=north:hinge=left:open=true bamboo_door:facing=north:hinge=left:open=true birch_door:facing=north:hinge=left:open=true cherry_door:facing=north:hinge=left:open=true crimson_door:facing=north:hinge=left:open=true dark_oak_door:facing=north:hinge=left:open=true iron_door:facing=north:hinge=left:open=true jungle_door:facing=north:hinge=left:open=true mangrove_door:facing=north:hinge=left:open=true oak_door:facing=north:hinge=left:open=true spruce_door:facing=north:hinge=left:open=true warped_door:facing=north:hinge=left:open=true copper_door:facing=north:hinge=left:open=true exposed_copper_door:facing=north:hinge=left:open=true weathered_copper_door:facing=north:hinge=left:open=true oxidized_copper_door:facing=north:hinge=left:open=true waxed_copper_door:facing=north:hinge=left:open=true waxed_exposed_copper_door:facing=north:hinge=left:open=true waxed_weathered_copper_door:facing=north:hinge=left:open=true waxed_oxidized_copper_door:facing=north:hinge=left:open=true acacia_door:facing=south:hinge=right:open=true bamboo_door:facing=south:hinge=right:open=true birch_door:facing=south:hinge=right:open=true cherry_door:facing=south:hinge=right:open=true crimson_door:facing=south:hinge=right:open=true dark_oak_door:facing=south:hinge=right:open=true iron_door:facing=south:hinge=right:open=true jungle_door:facing=south:hinge=right:open=true mangrove_door:facing=south:hinge=right:open=true oak_door:facing=south:hinge=right:open=true spruce_door:facing=south:hinge=right:open=true warped_door:facing=south:hinge=right:open=true copper_door:facing=south:hinge=right:open=true exposed_copper_door:facing=south:hinge=right:open=true weathered_copper_door:facing=south:hinge=right:open=true oxidized_copper_door:facing=south:hinge=right:open=true waxed_copper_door:facing=south:hinge=right:open=true waxed_exposed_copper_door:facing=south:hinge=right:open=true waxed_weathered_copper_door:facing=south:hinge=right:open=true waxed_oxidized_copper_door:facing=south:hinge=right:open=true
|
||||||
|
|
||||||
|
block.405=acacia_door:facing=south:open=false bamboo_door:facing=south:open=false birch_door:facing=south:open=false cherry_door:facing=south:open=false crimson_door:facing=south:open=false dark_oak_door:facing=south:open=false iron_door:facing=south:open=false jungle_door:facing=south:open=false mangrove_door:facing=south:open=false oak_door:facing=south:open=false spruce_door:facing=south:open=false warped_door:facing=south:open=false copper_door:facing=south:open=false exposed_copper_door:facing=south:open=false weathered_copper_door:facing=south:open=false oxidized_copper_door:facing=south:open=false waxed_copper_door:facing=south:open=false waxed_exposed_copper_door:facing=south:open=false waxed_weathered_copper_door:facing=south:open=false waxed_oxidized_copper_door:facing=south:open=false acacia_door:facing=east:hinge=left:open=true bamboo_door:facing=east:hinge=left:open=true birch_door:facing=east:hinge=left:open=true cherry_door:facing=east:hinge=left:open=true crimson_door:facing=east:hinge=left:open=true dark_oak_door:facing=east:hinge=left:open=true iron_door:facing=east:hinge=left:open=true jungle_door:facing=east:hinge=left:open=true mangrove_door:facing=east:hinge=left:open=true oak_door:facing=east:hinge=left:open=true spruce_door:facing=east:hinge=left:open=true warped_door:facing=east:hinge=left:open=true copper_door:facing=east:hinge=left:open=true exposed_copper_door:facing=east:hinge=left:open=true weathered_copper_door:facing=east:hinge=left:open=true oxidized_copper_door:facing=east:hinge=left:open=true waxed_copper_door:facing=east:hinge=left:open=true waxed_exposed_copper_door:facing=east:hinge=left:open=true waxed_weathered_copper_door:facing=east:hinge=left:open=true waxed_oxidized_copper_door:facing=east:hinge=left:open=true acacia_door:facing=west:hinge=right:open=true bamboo_door:facing=west:hinge=right:open=true birch_door:facing=west:hinge=right:open=true cherry_door:facing=west:hinge=right:open=true crimson_door:facing=west:hinge=right:open=true dark_oak_door:facing=west:hinge=right:open=true iron_door:facing=west:hinge=right:open=true jungle_door:facing=west:hinge=right:open=true mangrove_door:facing=west:hinge=right:open=true oak_door:facing=west:hinge=right:open=true spruce_door:facing=west:hinge=right:open=true warped_door:facing=west:hinge=right:open=true copper_door:facing=west:hinge=right:open=true exposed_copper_door:facing=west:hinge=right:open=true weathered_copper_door:facing=west:hinge=right:open=true oxidized_copper_door:facing=west:hinge=right:open=true waxed_copper_door:facing=west:hinge=right:open=true waxed_exposed_copper_door:facing=west:hinge=right:open=true waxed_weathered_copper_door:facing=west:hinge=right:open=true waxed_oxidized_copper_door:facing=west:hinge=right:open=true
|
||||||
|
|
||||||
|
block.406=acacia_door:facing=west:open=false bamboo_door:facing=west:open=false birch_door:facing=west:open=false cherry_door:facing=west:open=false crimson_door:facing=west:open=false dark_oak_door:facing=west:open=false iron_door:facing=west:open=false jungle_door:facing=west:open=false mangrove_door:facing=west:open=false oak_door:facing=west:open=false spruce_door:facing=west:open=false warped_door:facing=west:open=false copper_door:facing=west:open=false exposed_copper_door:facing=west:open=false weathered_copper_door:facing=west:open=false oxidized_copper_door:facing=west:open=false waxed_copper_door:facing=west:open=false waxed_exposed_copper_door:facing=west:open=false waxed_weathered_copper_door:facing=west:open=false waxed_oxidized_copper_door:facing=west:open=false acacia_door:facing=south:hinge=left:open=true bamboo_door:facing=south:hinge=left:open=true birch_door:facing=south:hinge=left:open=true cherry_door:facing=south:hinge=left:open=true crimson_door:facing=south:hinge=left:open=true dark_oak_door:facing=south:hinge=left:open=true iron_door:facing=south:hinge=left:open=true jungle_door:facing=south:hinge=left:open=true mangrove_door:facing=south:hinge=left:open=true oak_door:facing=south:hinge=left:open=true spruce_door:facing=south:hinge=left:open=true warped_door:facing=south:hinge=left:open=true copper_door:facing=south:hinge=left:open=true exposed_copper_door:facing=south:hinge=left:open=true weathered_copper_door:facing=south:hinge=left:open=true oxidized_copper_door:facing=south:hinge=left:open=true waxed_copper_door:facing=south:hinge=left:open=true waxed_exposed_copper_door:facing=south:hinge=left:open=true waxed_weathered_copper_door:facing=south:hinge=left:open=true waxed_oxidized_copper_door:facing=south:hinge=left:open=true acacia_door:facing=north:hinge=right:open=true bamboo_door:facing=north:hinge=right:open=true birch_door:facing=north:hinge=right:open=true cherry_door:facing=north:hinge=right:open=true crimson_door:facing=north:hinge=right:open=true dark_oak_door:facing=north:hinge=right:open=true iron_door:facing=north:hinge=right:open=true jungle_door:facing=north:hinge=right:open=true mangrove_door:facing=north:hinge=right:open=true oak_door:facing=north:hinge=right:open=true spruce_door:facing=north:hinge=right:open=true warped_door:facing=north:hinge=right:open=true copper_door:facing=north:hinge=right:open=true exposed_copper_door:facing=north:hinge=right:open=true weathered_copper_door:facing=north:hinge=right:open=true oxidized_copper_door:facing=north:hinge=right:open=true waxed_copper_door:facing=north:hinge=right:open=true waxed_exposed_copper_door:facing=north:hinge=right:open=true waxed_weathered_copper_door:facing=north:hinge=right:open=true waxed_oxidized_copper_door:facing=north:hinge=right:open=true
|
||||||
|
|
||||||
|
block.407=acacia_fence bamboo_fence birch_fence cherry_fence crimson_fence dark_oak_fence jungle_fence mangrove_fence nether_brick_fence oak_fence spruce_fence warped_fence
|
||||||
|
|
||||||
|
block.408=acacia_fence_gate bamboo_fence_gate birch_fence_gate cherry_fence_gate crimson_fence_gate dark_oak_fence_gate jungle_fence_gate mangrove_fence_gate oak_fence_gate spruce_fence_gate warped_fence_gate
|
||||||
|
|
||||||
|
block.409=flower_pot potted_acacia_sapling potted_allium potted_azalea_bush potted_bamboo potted_azure_bluet potted_birch_sapling potted_blue_orchid potted_brown_mushroom potted_cactus potted_cornflower potted_crimson_fungus potted_crimson_roots potted_dandelion potted_dark_oak_sapling potted_dead_bush potted_fern potted_flowering_azalea_bush potted_jungle_sapling potted_lily_of_the_valley potted_mangrove_propagule potted_oak_sapling potted_orange_tulip potted_oxeye_daisy potted_pink_tulip potted_poppy potted_red_mushroom potted_red_tulip potted_spruce_sapling potted_torchflower potted_warped_fungus potted_warped_roots potted_white_tulip potted_wither_rose
|
||||||
|
|
||||||
|
block.410=iron_bars
|
||||||
|
|
||||||
|
block.411=acacia_pressure_plate bamboo_pressure_plate birch_pressure_plate cherry_pressure_plate crimson_pressure_plate dark_oak_pressure_plate heavy_weighted_pressure_plate jungle_pressure_plate light_weighted_pressure_plate mangrove_pressure_plate oak_pressure_plate polished_blackstone_pressure_plate spruce_pressure_plate stone_pressure_plate warped_pressure_plate
|
||||||
|
|
||||||
|
|
||||||
|
block.412=acacia_slab:type=top bamboo_slab:type=top bamboo_mosaic_slab:type=top birch_slab:type=top cherry_slab:type=top crimson_slab:type=top dark_oak_slab:type=top jungle_slab:type=top mangrove_slab:type=top oak_slab:type=top spruce_slab:type=top warped_slab:type=top andesite_slab:type=top blackstone_slab:type=top brick_slab:type=top cobbled_deepslate_slab:type=top cobblestone_slab:type=top cut_copper_slab:type=top cut_red_sandstone_slab:type=top cut_sandstone_slab:type=top dark_prismarine_slab:type=top deepslate_brick_slab:type=top deepslate_tile_slab:type=top diorite_slab:type=top end_stone_brick_slab:type=top exposed_cut_copper_slab:type=top granite_slab:type=top mossy_cobblestone_slab:type=top mossy_stone_brick_slab:type=top mud_brick_slab:type=top nether_brick_slab:type=top oxidized_cut_copper_slab:type=top petrified_oak_slab:type=top polished_andesite_slab:type=top polished_blackstone_brick_slab:type=top polished_blackstone_slab:type=top polished_deepslate_slab:type=top polished_diorite_slab:type=top polished_granite_slab:type=top prismarine_brick_slab:type=top prismarine_slab:type=top purpur_slab:type=top quartz_slab:type=top red_nether_brick_slab:type=top red_sandstone_slab:type=top sandstone_slab:type=top smooth_quartz_slab:type=top smooth_red_sandstone_slab:type=top smooth_sandstone_slab:type=top smooth_stone_slab:type=top stone_brick_slab:type=top stone_slab:type=top waxed_cut_copper_slab:type=top waxed_exposed_cut_copper_slab:type=top waxed_oxidized_cut_copper_slab:type=top waxed_weathered_cut_copper_slab:type=top weathered_cut_copper_slab:type=top
|
||||||
|
|
||||||
|
block.413=acacia_slab:type=bottom bamboo_slab:type=bottom bamboo_mosaic_slab:type=bottom birch_slab:type=bottom cherry_slab:type=bottom crimson_slab:type=bottom dark_oak_slab:type=bottom jungle_slab:type=bottom mangrove_slab:type=bottom oak_slab:type=bottom spruce_slab:type=bottom warped_slab:type=bottom andesite_slab:type=bottom blackstone_slab:type=bottom brick_slab:type=bottom cobbled_deepslate_slab:type=bottom cobblestone_slab:type=bottom cut_copper_slab:type=bottom cut_red_sandstone_slab:type=bottom cut_sandstone_slab:type=bottom dark_prismarine_slab:type=bottom deepslate_brick_slab:type=bottom deepslate_tile_slab:type=bottom diorite_slab:type=bottom end_stone_brick_slab:type=bottom exposed_cut_copper_slab:type=bottom granite_slab:type=bottom mossy_cobblestone_slab:type=bottom mossy_stone_brick_slab:type=bottom mud_brick_slab:type=bottom nether_brick_slab:type=bottom oxidized_cut_copper_slab:type=bottom petrified_oak_slab:type=bottom polished_andesite_slab:type=bottom polished_blackstone_brick_slab:type=bottom polished_blackstone_slab:type=bottom polished_deepslate_slab:type=bottom polished_diorite_slab:type=bottom polished_granite_slab:type=bottom prismarine_brick_slab:type=bottom prismarine_slab:type=bottom purpur_slab:type=bottom quartz_slab:type=bottom red_nether_brick_slab:type=bottom red_sandstone_slab:type=bottom sandstone_slab:type=bottom smooth_quartz_slab:type=bottom smooth_red_sandstone_slab:type=bottom smooth_sandstone_slab:type=bottom smooth_stone_slab:type=bottom stone_brick_slab:type=bottom stone_slab:type=bottom waxed_cut_copper_slab:type=bottom waxed_exposed_cut_copper_slab:type=bottom waxed_oxidized_cut_copper_slab:type=bottom waxed_weathered_cut_copper_slab:type=bottom weathered_cut_copper_slab:type=bottom daylight_detector
|
||||||
|
|
||||||
|
|
||||||
|
block.414=acacia_trapdoor:half=bottom:open=false bamboo_trapdoor:half=bottom:open=false birch_trapdoor:half=bottom:open=false cherry_trapdoor:half=bottom:open=false crimson_trapdoor:half=bottom:open=false dark_oak_trapdoor:half=bottom:open=false iron_trapdoor:half=bottom:open=false jungle_trapdoor:half=bottom:open=false mangrove_trapdoor:half=bottom:open=false oak_trapdoor:half=bottom:open=false spruce_trapdoor:half=bottom:open=false warped_trapdoor:half=bottom:open=false copper_trapdoor:half=bottom:open=false exposed_copper_trapdoor:half=bottom:open=false weathered_copper_trapdoor:half=bottom:open=false oxidized_copper_trapdoor:half=bottom:open=false waxed_copper_trapdoor:half=bottom:open=false waxed_exposed_copper_trapdoor:half=bottom:open=false waxed_weathered_copper_trapdoor:half=bottom:open=false waxed_oxidized_copper_trapdoor:half=bottom:open=false
|
||||||
|
|
||||||
|
block.415=acacia_trapdoor:half=top:open=false bamboo_trapdoor:half=top:open=false birch_trapdoor:half=top:open=false cherry_trapdoor:half=top:open=false crimson_trapdoor:half=top:open=false dark_oak_trapdoor:half=top:open=false iron_trapdoor:half=top:open=false jungle_trapdoor:half=top:open=false mangrove_trapdoor:half=top:open=false oak_trapdoor:half=top:open=false spruce_trapdoor:half=top:open=false warped_trapdoor:half=top:open=false copper_trapdoor:half=top:open=false exposed_copper_trapdoor:half=top:open=false weathered_copper_trapdoor:half=top:open=false oxidized_copper_trapdoor:half=top:open=false waxed_copper_trapdoor:half=top:open=false waxed_exposed_copper_trapdoor:half=top:open=false waxed_weathered_copper_trapdoor:half=top:open=false waxed_oxidized_copper_trapdoor:half=top:open=false
|
||||||
|
|
||||||
|
block.416=acacia_trapdoor:facing=north:open=true bamboo_trapdoor:facing=north:open=true birch_trapdoor:facing=north:open=true cherry_trapdoor:facing=north:open=true crimson_trapdoor:facing=north:open=true dark_oak_trapdoor:facing=north:open=true iron_trapdoor:facing=north:open=true jungle_trapdoor:facing=north:open=true mangrove_trapdoor:facing=north:open=true oak_trapdoor:facing=north:open=true spruce_trapdoor:facing=north:open=true warped_trapdoor:facing=north:open=true copper_trapdoor:facing=north:open=true exposed_copper_trapdoor:facing=north:open=true weathered_copper_trapdoor:facing=north:open=true oxidized_copper_trapdoor:facing=north:open=true waxed_copper_trapdoor:facing=north:open=true waxed_exposed_copper_trapdoor:facing=north:open=true waxed_weathered_copper_trapdoor:facing=north:open=true waxed_oxidized_copper_trapdoor:facing=north:open=true
|
||||||
|
|
||||||
|
block.417=acacia_trapdoor:facing=east:open=true bamboo_trapdoor:facing=east:open=true birch_trapdoor:facing=east:open=true cherry_trapdoor:facing=east:open=true crimson_trapdoor:facing=east:open=true dark_oak_trapdoor:facing=east:open=true iron_trapdoor:facing=east:open=true jungle_trapdoor:facing=east:open=true mangrove_trapdoor:facing=east:open=true oak_trapdoor:facing=east:open=true spruce_trapdoor:facing=east:open=true warped_trapdoor:facing=east:open=true copper_trapdoor:facing=east:open=true exposed_copper_trapdoor:facing=east:open=true weathered_copper_trapdoor:facing=east:open=true oxidized_copper_trapdoor:facing=east:open=true waxed_copper_trapdoor:facing=east:open=true waxed_exposed_copper_trapdoor:facing=east:open=true waxed_weathered_copper_trapdoor:facing=east:open=true waxed_oxidized_copper_trapdoor:facing=east:open=true
|
||||||
|
|
||||||
|
block.418=acacia_trapdoor:facing=south:open=true bamboo_trapdoor:facing=south:open=true birch_trapdoor:facing=south:open=true cherry_trapdoor:facing=south:open=true crimson_trapdoor:facing=south:open=true dark_oak_trapdoor:facing=south:open=true iron_trapdoor:facing=south:open=true jungle_trapdoor:facing=south:open=true mangrove_trapdoor:facing=south:open=true oak_trapdoor:facing=south:open=true spruce_trapdoor:facing=south:open=true warped_trapdoor:facing=south:open=true copper_trapdoor:facing=south:open=true exposed_copper_trapdoor:facing=south:open=true weathered_copper_trapdoor:facing=south:open=true oxidized_copper_trapdoor:facing=south:open=true waxed_copper_trapdoor:facing=south:open=true waxed_exposed_copper_trapdoor:facing=south:open=true waxed_weathered_copper_trapdoor:facing=south:open=true waxed_oxidized_copper_trapdoor:facing=south:open=true
|
||||||
|
|
||||||
|
block.419=acacia_trapdoor:facing=west:open=true bamboo_trapdoor:facing=west:open=true birch_trapdoor:facing=west:open=true cherry_trapdoor:facing=west:open=true crimson_trapdoor:facing=west:open=true dark_oak_trapdoor:facing=west:open=true iron_trapdoor:facing=west:open=true jungle_trapdoor:facing=west:open=true mangrove_trapdoor:facing=west:open=true oak_trapdoor:facing=west:open=true spruce_trapdoor:facing=west:open=true warped_trapdoor:facing=west:open=true copper_trapdoor:facing=west:open=true exposed_copper_trapdoor:facing=west:open=true weathered_copper_trapdoor:facing=west:open=true oxidized_copper_trapdoor:facing=west:open=true waxed_copper_trapdoor:facing=west:open=true waxed_exposed_copper_trapdoor:facing=west:open=true waxed_weathered_copper_trapdoor:facing=west:open=true waxed_oxidized_copper_trapdoor:facing=west:open=true
|
||||||
|
|
||||||
|
|
||||||
|
####### ----- misc ----- #######
|
||||||
|
|
||||||
|
## stuff
|
||||||
|
block.500=minecraft:end_portal
|
||||||
|
|
||||||
|
## all blocks here get exluded from POM.
|
||||||
|
block.501=minecraft:oak_sign minecraft:spruce_sign minecraft:birch_sign minecraft:jungle_sign minecraft:acacia_sign minecraft:dark_oak_sign minecraft:mangrove_sign minecraft:crimson_sign minecraft:warped_sign minecraft:oak_wall_sign minecraft:spruce_wall_sign minecraft:birch_wall_sign minecraft:jungle_wall_sign minecraft:acacia_wall_sign minecraft:dark_oak_wall_sign minecraft:mangrove_wall_sign minecraft:crimson_wall_sign minecraft:warped_wall_sign
|
||||||
|
|
||||||
|
## workaround mixed render stages
|
||||||
|
##= BLOCK_REDSTONE_WIRE
|
||||||
|
##block.*= minecraft:redstone_wire
|
|
@ -0,0 +1,15 @@
|
||||||
|
# USAGE
|
||||||
|
# dimension.<Shader to use> = <dimension(s) that use this shader. use " * " for fallback>
|
||||||
|
# "shader to use" refers to shaderpacks/EXAMPLESHADER/shaders/<name "Shader to use" >..., like how optifine has world0, world1, but you can name these anything here.
|
||||||
|
# the dimension "ID's" to use are equivalent to the "ID's" from the /execute in <dimension> command in-game.
|
||||||
|
|
||||||
|
# EXAMPLE
|
||||||
|
# dimension.world0 = minecraft:overworld twilightforest:twilight_forest
|
||||||
|
# dimension.world-1 = minecraft:the_nether
|
||||||
|
# dimension.WHATEVER = somemod:whateverdimension
|
||||||
|
|
||||||
|
dimension.world0 = minecraft:overworld *
|
||||||
|
dimension.world-1 = minecraft:the_nether
|
||||||
|
dimension.world1 = minecraft:the_end
|
||||||
|
|
||||||
|
# dimension.unknown_dimension_fallback = *
|
|
@ -0,0 +1,161 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
varying vec4 pos;
|
||||||
|
varying vec4 gcolor;
|
||||||
|
varying vec2 lightmapCoords;
|
||||||
|
varying vec4 normals_and_materials;
|
||||||
|
flat varying float SSSAMOUNT;
|
||||||
|
flat varying float EMISSIVE;
|
||||||
|
flat varying int dh_material_id;
|
||||||
|
|
||||||
|
uniform float far;
|
||||||
|
// uniform int hideGUI;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
|
||||||
|
vec3 viewToWorld(vec3 viewPosition) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPosition;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec3 worldToView(vec3 worldPos) {
|
||||||
|
vec4 pos = vec4(worldPos, 0.0);
|
||||||
|
pos = gbufferModelView * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec4 encode (vec3 n, vec2 lightmaps){
|
||||||
|
n.xy = n.xy / dot(abs(n), vec3(1.0));
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - abs(n.yx)) * sign(n.xy) : n.xy;
|
||||||
|
vec2 encn = clamp(n.xy * 0.5 + 0.5,-1.0,1.0);
|
||||||
|
|
||||||
|
return vec4(encn,vec2(lightmaps.x,lightmaps.y));
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
|
||||||
|
// uniform sampler2D depthtex0;
|
||||||
|
// uniform vec2 texelSize;
|
||||||
|
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 feetPlayerPos = p * 2. - 1.;
|
||||||
|
vec4 viewPos = iProjDiag * feetPlayerPos.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return viewPos.xyz / viewPos.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise_temporal(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+frameTimeCounter*51.9521);
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
float R2_dither(){
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
//3D noise from 2d texture
|
||||||
|
float densityAtPos(in vec3 pos){
|
||||||
|
pos /= 18.;
|
||||||
|
pos.xz *= 0.5;
|
||||||
|
vec3 p = floor(pos);
|
||||||
|
vec3 f = fract(pos);
|
||||||
|
vec2 uv = p.xz + f.xz + p.y * vec2(0.0,193.0);
|
||||||
|
vec2 coord = uv / 512.0;
|
||||||
|
|
||||||
|
//The y channel has an offset to avoid using two textures fetches
|
||||||
|
vec2 xy = texture2D(noisetex, coord).yx;
|
||||||
|
|
||||||
|
return mix(xy.r,xy.g, f.y);
|
||||||
|
}
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
|
||||||
|
/* RENDERTARGETS:1,7,8 */
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
#ifdef DH_OVERDRAW_PREVENTION
|
||||||
|
if(clamp(1.0-length(pos.xyz)/max(far - 32.0,0.0),0.0,1.0) > 0.0 ){
|
||||||
|
discard;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 normals = viewToWorld(normals_and_materials.xyz);
|
||||||
|
float materials = normals_and_materials.a;
|
||||||
|
vec2 PackLightmaps = lightmapCoords;
|
||||||
|
|
||||||
|
PackLightmaps.y *= 1.05;
|
||||||
|
PackLightmaps = min(max(PackLightmaps - 0.001*blueNoise(),0.0)*1.002,1.0);
|
||||||
|
|
||||||
|
vec4 data1 = clamp( encode(normals.xyz, PackLightmaps), 0.0, 1.0);
|
||||||
|
|
||||||
|
// alpha is material masks, set it to 0.65 to make a DH LODs mask.
|
||||||
|
vec4 Albedo = vec4(gcolor.rgb, 1.0);
|
||||||
|
|
||||||
|
// vec3 worldPos = mat3(gbufferModelViewInverse)*pos.xyz + cameraPosition;
|
||||||
|
// worldPos = (worldPos*vec3(1.0,1./48.,1.0)/4) ;
|
||||||
|
// worldPos = floor(worldPos * 4.0 + 0.001) / 32.0;
|
||||||
|
// float noiseTexture = densityAtPos(worldPos* 5000 ) +0.5;
|
||||||
|
|
||||||
|
// float noiseFactor = max(1.0 - 0.3 * dot(Albedo.rgb, Albedo.rgb),0.0);
|
||||||
|
// Albedo.rgb *= pow(noiseTexture, 0.6 * noiseFactor);
|
||||||
|
// Albedo.rgb *= (noiseTexture*noiseTexture)*0.5 + 0.5;
|
||||||
|
|
||||||
|
#ifdef AEROCHROME_MODE
|
||||||
|
if(dh_material_id == DH_BLOCK_LEAVES || dh_material_id == DH_BLOCK_WATER) { // leaves and waterlogged blocks
|
||||||
|
float grey = dot(Albedo.rgb, vec3(0.2, 01.0, 0.07));
|
||||||
|
Albedo.rgb = mix(vec3(grey), aerochrome_color, 0.7);
|
||||||
|
|
||||||
|
} else if(dh_material_id == DH_BLOCK_GRASS) { // grass
|
||||||
|
Albedo.rgb = mix(Albedo.rgb, aerochrome_color, 1.0 - Albedo.g);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef WhiteWorld
|
||||||
|
Albedo.rgb = vec3(0.5);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(encodeVec2(Albedo.x,data1.x), encodeVec2(Albedo.y,data1.y), encodeVec2(Albedo.z,data1.z), encodeVec2(data1.w, materials));
|
||||||
|
|
||||||
|
gl_FragData[1].a = 0.0;
|
||||||
|
|
||||||
|
#if EMISSIVE_TYPE == 0
|
||||||
|
gl_FragData[2].a = 0.0;
|
||||||
|
#else
|
||||||
|
gl_FragData[2].a = EMISSIVE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if SSS_TYPE == 0
|
||||||
|
gl_FragData[2].b = 0.0;
|
||||||
|
#else
|
||||||
|
gl_FragData[2].b = SSSAMOUNT;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,114 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
varying vec4 pos;
|
||||||
|
varying vec4 gcolor;
|
||||||
|
varying vec2 lightmapCoords;
|
||||||
|
varying vec4 normals_and_materials;
|
||||||
|
flat varying float SSSAMOUNT;
|
||||||
|
flat varying float EMISSIVE;
|
||||||
|
flat varying int dh_material_id;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
uniform int hideGUI;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float aspectRatio;
|
||||||
|
uniform float screenBrightness;
|
||||||
|
uniform float far;
|
||||||
|
#include "/lib/bokeh.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform float far;
|
||||||
|
uniform mat4 dhProjection;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
vec4 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return vec4(projMAD(dhProjection, viewSpacePosition),-viewSpacePosition.z);
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define SEASONS_VSH
|
||||||
|
#define DH_SEASONS
|
||||||
|
#include "/lib/climate_settings.glsl"
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
/*
|
||||||
|
vec3 position = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz;
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * position + gbufferModelViewInverse[3].xyz;
|
||||||
|
|
||||||
|
float cellSize = 32*2;
|
||||||
|
vec3 modulusWorldPos = vec3(worldpos.x,worldpos.y,worldpos.z) + fract(cameraPosition/cellSize)*cellSize - cellSize*0.5;
|
||||||
|
|
||||||
|
worldpos.y -= (clamp(1.0-length(modulusWorldPos)/max(far-32,0.0),0.0,1.0)) * 50.0;
|
||||||
|
position = mat3(gbufferModelView) * worldpos + gbufferModelView[3].xyz;
|
||||||
|
gl_Position = toClipSpace3(position);
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w;
|
||||||
|
#endif
|
||||||
|
#ifdef TAA
|
||||||
|
gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
lightmapCoords = gl_MultiTexCoord1.xy; // is this even correct? lol'
|
||||||
|
|
||||||
|
gcolor = gl_Color;
|
||||||
|
pos = gl_ModelViewMatrix * gl_Vertex;
|
||||||
|
|
||||||
|
EMISSIVE = 0.0;
|
||||||
|
if(dhMaterialId == DH_BLOCK_ILLUMINATED || gl_MultiTexCoord1.x >= 0.95) EMISSIVE = 0.5;
|
||||||
|
|
||||||
|
SSSAMOUNT = 0.0;
|
||||||
|
if (dhMaterialId == DH_BLOCK_LEAVES) SSSAMOUNT = 1.0;
|
||||||
|
if (dhMaterialId == DH_BLOCK_SNOW) SSSAMOUNT = 0.5;
|
||||||
|
|
||||||
|
// a mask for DH terrain in general.
|
||||||
|
float MATERIALS = 0.65;
|
||||||
|
|
||||||
|
normals_and_materials = vec4(normalize(gl_NormalMatrix * gl_Normal), MATERIALS);
|
||||||
|
dh_material_id = dhMaterialId;
|
||||||
|
|
||||||
|
|
||||||
|
#if defined Seasons && defined OVERWORLD_SHADER
|
||||||
|
YearCycleColor(gcolor.rgb, gl_Color.rgb, dhMaterialId == DH_BLOCK_LEAVES, dhMaterialId == DH_BLOCK_GRASS);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
vec2 jitter = clamp(jitter_offsets[frameCounter % 64], -1.0, 1.0);
|
||||||
|
jitter = rotate(radians(float(frameCounter))) * jitter;
|
||||||
|
jitter.y *= aspectRatio;
|
||||||
|
jitter.x *= DOF_ANAMORPHIC_RATIO;
|
||||||
|
|
||||||
|
#if MANUAL_FOCUS == -2
|
||||||
|
float focusMul = 0;
|
||||||
|
#elif MANUAL_FOCUS == -1
|
||||||
|
float focusMul = gl_Position.z + (far / 3.0) - mix(pow(512.0, screenBrightness), 512.0 * screenBrightness, 0.25);
|
||||||
|
#else
|
||||||
|
float focusMul = gl_Position.z + (far / 3.0) - MANUAL_FOCUS;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 totalOffset = (jitter * JITTER_STRENGTH) * focusMul * 1e-2;
|
||||||
|
gl_Position.xy += hideGUI >= 1 ? totalOffset : vec2(0);
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,439 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/color_transforms.glsl"
|
||||||
|
#include "/lib/projections.glsl"
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
// uniform int moonPhase;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
|
||||||
|
const bool shadowHardwareFiltering = true;
|
||||||
|
uniform sampler2DShadow shadow;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
|
||||||
|
uniform sampler2D colortex12;
|
||||||
|
// uniform sampler2D colortex7;
|
||||||
|
uniform sampler2D colortex5;
|
||||||
|
|
||||||
|
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/waterBump.glsl"
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
varying vec4 pos;
|
||||||
|
varying vec4 gcolor;
|
||||||
|
|
||||||
|
varying vec4 normals_and_materials;
|
||||||
|
|
||||||
|
varying vec2 lightmapCoords;
|
||||||
|
|
||||||
|
flat varying int isWater;
|
||||||
|
|
||||||
|
// uniform float far;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
uniform vec3 previousCameraPosition;
|
||||||
|
// uniform vec3 cameraPosition;
|
||||||
|
|
||||||
|
// uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 gbufferPreviousModelView;
|
||||||
|
|
||||||
|
// uniform mat4 shadowModelView;
|
||||||
|
// uniform mat4 shadowModelViewInverse;
|
||||||
|
// uniform mat4 shadowProjection;
|
||||||
|
// uniform mat4 shadowProjectionInverse;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
|
||||||
|
|
||||||
|
// uniform sampler2D colortex4;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
flat varying vec3 WsunVec2;
|
||||||
|
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
// uniform mat4 dhPreviousProjection;
|
||||||
|
// uniform mat4 dhProjectionInverse;
|
||||||
|
// uniform mat4 dhProjection;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
vec3 DH_toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(dhProjectionInverse[0].x, dhProjectionInverse[1].y, dhProjectionInverse[2].zw);
|
||||||
|
vec3 feetPlayerPos = p * 2. - 1.;
|
||||||
|
vec4 viewPos = iProjDiag * feetPlayerPos.xyzz + dhProjectionInverse[3];
|
||||||
|
return viewPos.xyz / viewPos.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 DH_toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(dhProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
uniform float near;
|
||||||
|
float invLinZ (float lindepth){
|
||||||
|
return -((2.0*near/lindepth)-far-near)/(far-near);
|
||||||
|
}
|
||||||
|
float ld(float dist) {
|
||||||
|
return (2.0 * near) / (far + near - dist * (far - near));
|
||||||
|
}
|
||||||
|
|
||||||
|
// float DH_ld(float dist) {
|
||||||
|
// return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
// }
|
||||||
|
// float DH_invLinZ (float lindepth){
|
||||||
|
// return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
// }
|
||||||
|
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
|
||||||
|
uniform float rainStrength;
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
|
||||||
|
float GGX(vec3 n, vec3 v, vec3 l, float r, float f0) {
|
||||||
|
r = max(pow(r,2.5), 0.0001);
|
||||||
|
|
||||||
|
vec3 h = l + v;
|
||||||
|
float hn = inversesqrt(dot(h, h));
|
||||||
|
|
||||||
|
float dotLH = clamp(dot(h,l)*hn,0.,1.);
|
||||||
|
float dotNH = clamp(dot(h,n)*hn,0.,1.) ;
|
||||||
|
float dotNL = clamp(dot(n,l),0.,1.);
|
||||||
|
float dotNHsq = dotNH*dotNH;
|
||||||
|
|
||||||
|
float denom = dotNHsq * r - dotNHsq + 1.;
|
||||||
|
float D = r / (3.141592653589793 * denom * denom);
|
||||||
|
|
||||||
|
float F = f0 + (1. - f0) * exp2((-5.55473*dotLH-6.98316)*dotLH);
|
||||||
|
float k2 = .25 * r;
|
||||||
|
|
||||||
|
return dotNL * D * F / (dotLH*dotLH*(1.0-k2)+k2);
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
// float DH_ld(float dist) {
|
||||||
|
// return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
// }
|
||||||
|
// float DH_invLinZ (float lindepth){
|
||||||
|
// return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
// }
|
||||||
|
|
||||||
|
// float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
// return (near * far) / (depth * (near - far) + far);
|
||||||
|
// }
|
||||||
|
|
||||||
|
// uniform float far;
|
||||||
|
|
||||||
|
vec3 rayTrace(vec3 dir, vec3 position,float dither, float fresnel, bool inwater){
|
||||||
|
|
||||||
|
float quality = mix(15,SSR_STEPS,fresnel);
|
||||||
|
vec3 clipPosition = DH_toClipSpace3(position);
|
||||||
|
float rayLength = ((position.z + dir.z * dhFarPlane*sqrt(3.)) > -dhNearPlane) ?
|
||||||
|
(-dhNearPlane - position.z) / dir.z : dhFarPlane*sqrt(3.);
|
||||||
|
vec3 direction = normalize(DH_toClipSpace3(position+dir*rayLength)-clipPosition); //convert to clip space
|
||||||
|
direction.xy = normalize(direction.xy);
|
||||||
|
|
||||||
|
//get at which length the ray intersects with the edge of the screen
|
||||||
|
vec3 maxLengths = (step(0.,direction)-clipPosition) / direction;
|
||||||
|
float mult = min(min(maxLengths.x,maxLengths.y),maxLengths.z);
|
||||||
|
|
||||||
|
|
||||||
|
vec3 stepv = direction * mult / quality * vec3(RENDER_SCALE,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
vec3 spos = clipPosition*vec3(RENDER_SCALE,1.0) + stepv*dither;
|
||||||
|
float minZ = clipPosition.z;
|
||||||
|
float maxZ = spos.z+stepv.z*0.5;
|
||||||
|
|
||||||
|
spos.xy += offsets[framemod8]*texelSize*0.5/RENDER_SCALE;
|
||||||
|
|
||||||
|
for (int i = 0; i <= int(quality); i++) {
|
||||||
|
|
||||||
|
// float sp = DH_inv_ld(sqrt(texelFetch2D(colortex12,ivec2(spos.xy/texelSize/4),0).a/65000.0));
|
||||||
|
float sp = DH_inv_ld(sqrt(texelFetch2D(colortex12,ivec2(spos.xy/texelSize/4),0).a/64000.0));
|
||||||
|
|
||||||
|
if(sp <= max(maxZ,minZ) && sp >= min(maxZ,minZ)) return vec3(spos.xy/RENDER_SCALE,sp);
|
||||||
|
|
||||||
|
spos += stepv;
|
||||||
|
|
||||||
|
//small bias
|
||||||
|
minZ = maxZ-0.0000035/DH_ld(spos.z);
|
||||||
|
|
||||||
|
maxZ += stepv.z;
|
||||||
|
}
|
||||||
|
|
||||||
|
return vec3(1.1);
|
||||||
|
}
|
||||||
|
float R2_dither(){
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
float noise = fract( 52.9829189 * fract( (coord.x * 0.06711056) + (coord.y * 0.00583715) ) );
|
||||||
|
return noise ;
|
||||||
|
}
|
||||||
|
vec3 viewToWorld(vec3 viewPos) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPos;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec3 worldToView(vec3 worldPos) {
|
||||||
|
vec4 pos = vec4(worldPos, 0.0);
|
||||||
|
pos = gbufferModelView * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec4 encode (vec3 n, vec2 lightmaps){
|
||||||
|
n.xy = n.xy / dot(abs(n), vec3(1.0));
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - abs(n.yx)) * sign(n.xy) : n.xy;
|
||||||
|
vec2 encn = clamp(n.xy * 0.5 + 0.5,-1.0,1.0);
|
||||||
|
|
||||||
|
return vec4(encn,vec2(lightmaps.x,lightmaps.y));
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
vec3 applyBump(mat3 tbnMatrix, vec3 bump, float puddle_values){
|
||||||
|
float bumpmult = puddle_values;
|
||||||
|
bump = bump * vec3(bumpmult, bumpmult, bumpmult) + vec3(0.0f, 0.0f, 1.0f - bumpmult);
|
||||||
|
//
|
||||||
|
return normalize(bump*tbnMatrix);
|
||||||
|
}
|
||||||
|
|
||||||
|
varying vec4 tangent;
|
||||||
|
|
||||||
|
/* RENDERTARGETS:2,7 */
|
||||||
|
void main() {
|
||||||
|
if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) {
|
||||||
|
|
||||||
|
bool iswater = isWater > 0;
|
||||||
|
|
||||||
|
float material = 0.7;
|
||||||
|
if(iswater) material = 1.0;
|
||||||
|
|
||||||
|
vec3 normals = normals_and_materials.xyz;
|
||||||
|
vec3 viewPos = pos.xyz;
|
||||||
|
vec3 playerPos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz;
|
||||||
|
float transition = exp(-25* pow(clamp(1.0 - length(playerPos)/(far-8),0.0,1.0),2));
|
||||||
|
|
||||||
|
#ifdef DH_OVERDRAW_PREVENTION
|
||||||
|
if(length(playerPos) < max(far-16*4,16) ){ discard; return;}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
if(iswater){
|
||||||
|
vec3 posxz = playerPos+cameraPosition;
|
||||||
|
|
||||||
|
vec3 bump = normalize(getWaveNormal(posxz, true));
|
||||||
|
|
||||||
|
float bumpmult = 10.0 * WATER_WAVE_STRENGTH;
|
||||||
|
bump = bump * vec3(bumpmult, bumpmult, bumpmult) + vec3(0.0f, 0.0f, 1.0f - bumpmult);
|
||||||
|
|
||||||
|
normals.xz = bump.xy;
|
||||||
|
}
|
||||||
|
|
||||||
|
normals = worldToView(normals);
|
||||||
|
|
||||||
|
gl_FragData[0] = gcolor;
|
||||||
|
// float UnchangedAlpha = gl_FragData[0].a;
|
||||||
|
|
||||||
|
#ifdef WhiteWorld
|
||||||
|
gl_FragData[0].rgb = vec3(0.5);
|
||||||
|
gl_FragData[0].a = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 Albedo = toLinear(gl_FragData[0].rgb);
|
||||||
|
|
||||||
|
#ifndef WhiteWorld
|
||||||
|
#ifndef Vanilla_like_water
|
||||||
|
if (iswater){
|
||||||
|
Albedo = vec3(0.0);
|
||||||
|
gl_FragData[0].a = 1.0/255.0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// diffuse
|
||||||
|
vec3 Indirect_lighting = vec3(0.0);
|
||||||
|
// vec3 MinimumLightColor = vec3(1.0);
|
||||||
|
// if(isEyeInWater == 1) MinimumLightColor = vec3(10.0);
|
||||||
|
vec3 Direct_lighting = vec3(0.0);
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
vec3 DirectLightColor = lightCol.rgb/80.0;
|
||||||
|
|
||||||
|
float NdotL = clamp(dot(normals, normalize(WsunVec2)),0.0,1.0);
|
||||||
|
NdotL = clamp((-15 + NdotL*255.0) / 240.0 ,0.0,1.0);
|
||||||
|
|
||||||
|
float Shadows = 1.0;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS_SHADOWMAP
|
||||||
|
vec3 feetPlayerPos_shadow = mat3(gbufferModelViewInverse) * pos.xyz + gbufferModelViewInverse[3].xyz;
|
||||||
|
|
||||||
|
vec3 projectedShadowPosition = mat3(shadowModelView) * feetPlayerPos_shadow + shadowModelView[3].xyz;
|
||||||
|
projectedShadowPosition = diagonal3(shadowProjection) * projectedShadowPosition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
//apply distortion
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(projectedShadowPosition.xy);
|
||||||
|
projectedShadowPosition.xy *= distortFactor;
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float smallbias = -0.0035;
|
||||||
|
|
||||||
|
bool ShadowBounds = abs(projectedShadowPosition.x) < 1.0-1.5/shadowMapResolution && abs(projectedShadowPosition.y) < 1.0-1.5/shadowMapResolution && abs(projectedShadowPosition.z) < 6.0;
|
||||||
|
|
||||||
|
if(ShadowBounds){
|
||||||
|
Shadows = 0.0;
|
||||||
|
projectedShadowPosition = projectedShadowPosition * vec3(0.5,0.5,0.5/6.0) + vec3(0.5);
|
||||||
|
|
||||||
|
Shadows = shadow2D(shadow, projectedShadowPosition + vec3(0.0,0.0, smallbias)).x;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#ifdef CLOUDS_SHADOWS
|
||||||
|
Shadows *= pow(GetCloudShadow(playerPos),3);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Direct_lighting = DirectLightColor * NdotL * Shadows;
|
||||||
|
|
||||||
|
vec3 AmbientLightColor = averageSkyCol_Clouds/30.0;
|
||||||
|
|
||||||
|
vec3 ambientcoefs = normals_and_materials.xyz / dot(abs(normals_and_materials.xyz), vec3(1.0));
|
||||||
|
float SkylightDir = ambientcoefs.y*1.5;
|
||||||
|
|
||||||
|
float skylight = max(pow(viewToWorld(normals_and_materials.xyz).y*0.5+0.5,0.1) + SkylightDir, 0.2);
|
||||||
|
AmbientLightColor *= skylight;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
vec3 AmbientLightColor = vec3(0.5);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Indirect_lighting = AmbientLightColor;
|
||||||
|
|
||||||
|
vec3 FinalColor = (Indirect_lighting + Direct_lighting) * Albedo;
|
||||||
|
|
||||||
|
// specular
|
||||||
|
#ifdef WATER_REFLECTIONS
|
||||||
|
vec3 Reflections_Final = vec3(0.0);
|
||||||
|
vec4 Reflections = vec4(0.0);
|
||||||
|
vec3 BackgroundReflection = FinalColor;
|
||||||
|
vec3 SunReflection = vec3(0.0);
|
||||||
|
|
||||||
|
float roughness = 0.035;
|
||||||
|
float f0 = 0.02;
|
||||||
|
// f0 = 0.9;
|
||||||
|
|
||||||
|
vec3 reflectedVector = reflect(normalize(viewPos), normals);
|
||||||
|
float normalDotEye = dot(normals, normalize(viewPos));
|
||||||
|
|
||||||
|
float fresnel = pow(clamp(1.0 + normalDotEye, 0.0, 1.0),5.0);
|
||||||
|
|
||||||
|
fresnel = mix(f0, 1.0, fresnel);
|
||||||
|
|
||||||
|
#ifdef SNELLS_WINDOW
|
||||||
|
if(isEyeInWater == 1) fresnel = pow(clamp(1.5 + normalDotEye,0.0,1.0), 25.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef SCREENSPACE_REFLECTIONS
|
||||||
|
vec3 rtPos = rayTrace(reflectedVector, viewPos, interleaved_gradientNoise(), fresnel, false);
|
||||||
|
if (rtPos.z < 1.){
|
||||||
|
vec3 previousPosition = mat3(gbufferModelViewInverse) * DH_toScreenSpace(rtPos) + gbufferModelViewInverse[3].xyz + cameraPosition-previousCameraPosition;
|
||||||
|
previousPosition = mat3(gbufferPreviousModelView) * previousPosition + gbufferPreviousModelView[3].xyz;
|
||||||
|
previousPosition.xy = projMAD(dhPreviousProjection, previousPosition).xy / -previousPosition.z * 0.5 + 0.5;
|
||||||
|
if (previousPosition.x > 0.0 && previousPosition.y > 0.0 && previousPosition.x < 1.0 && previousPosition.x < 1.0) {
|
||||||
|
Reflections.a = 1.0;
|
||||||
|
Reflections.rgb = texture2D(colortex5, previousPosition.xy).rgb;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef WATER_BACKGROUND_SPECULAR
|
||||||
|
BackgroundReflection = skyCloudsFromTex(mat3(gbufferModelViewInverse) * reflectedVector, colortex4).rgb / 30.0;
|
||||||
|
#endif
|
||||||
|
#ifdef WATER_SUN_SPECULAR
|
||||||
|
SunReflection = Direct_lighting * GGX(normalize(normals), -normalize(viewPos), normalize(WsunVec2), roughness, f0);
|
||||||
|
#endif
|
||||||
|
Reflections_Final = mix(BackgroundReflection, Reflections.rgb, Reflections.a) * fresnel;
|
||||||
|
Reflections_Final += SunReflection;
|
||||||
|
|
||||||
|
//correct alpha channel with fresnel
|
||||||
|
float alpha0 = gl_FragData[0].a;
|
||||||
|
|
||||||
|
gl_FragData[0].a = -gl_FragData[0].a * fresnel + gl_FragData[0].a + fresnel;
|
||||||
|
|
||||||
|
// prevent reflections from being darkened by buffer blending
|
||||||
|
gl_FragData[0].rgb = clamp(FinalColor / gl_FragData[0].a*alpha0*(1.0-fresnel) * 0.1 + Reflections_Final / gl_FragData[0].a * 0.1,0.0,65100.0);
|
||||||
|
|
||||||
|
if (gl_FragData[0].r > 65000.) gl_FragData[0].rgba = vec4(0.0);
|
||||||
|
#else
|
||||||
|
gl_FragData[0].rgb = FinalColor*0.1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef DH_OVERDRAW_PREVENTION
|
||||||
|
float distancefade = min(max(1.0 - length(playerPos)/max(far-16*4,16),0.0)*5,1.0);
|
||||||
|
|
||||||
|
if(texture2D(depthtex0, gl_FragCoord.xy*texelSize).x < 1.0 || distancefade > 0.0){
|
||||||
|
gl_FragData[0].a = 0.0;
|
||||||
|
material = 0.0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if DEBUG_VIEW == debug_DH_WATER_BLENDING
|
||||||
|
if(gl_FragCoord.x*texelSize.x > 0.53) gl_FragData[0] = vec4(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[1] = vec4(Albedo, material);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,124 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
varying vec4 pos;
|
||||||
|
varying vec4 gcolor;
|
||||||
|
|
||||||
|
varying vec4 normals_and_materials;
|
||||||
|
varying vec2 lightmapCoords;
|
||||||
|
flat varying int isWater;
|
||||||
|
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
|
||||||
|
varying mat4 normalmatrix;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
flat varying vec3 WsunVec2;
|
||||||
|
uniform mat4 dhProjection;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
uniform int hideGUI;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float aspectRatio;
|
||||||
|
uniform float screenBrightness;
|
||||||
|
uniform float far;
|
||||||
|
#include "/lib/bokeh.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
vec4 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return vec4(projMAD(dhProjection, viewSpacePosition),-viewSpacePosition.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
vec3 position = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz;
|
||||||
|
|
||||||
|
pos = gl_ModelViewMatrix * gl_Vertex;
|
||||||
|
|
||||||
|
|
||||||
|
isWater = 0;
|
||||||
|
if (dhMaterialId == DH_BLOCK_WATER){
|
||||||
|
isWater = 1;
|
||||||
|
|
||||||
|
// offset water to not look like a full cube
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * position + gbufferModelViewInverse[3].xyz ;
|
||||||
|
worldpos.y -= 1.8/16.0;
|
||||||
|
position = mat3(gbufferModelView) * worldpos + gbufferModelView[3].xyz;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
gl_Position = toClipSpace3(position);
|
||||||
|
|
||||||
|
normals_and_materials = vec4(normalize(gl_Normal), 1.0);
|
||||||
|
|
||||||
|
gcolor = gl_Color;
|
||||||
|
lightmapCoords = gl_MultiTexCoord1.xy;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
lightCol.a = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
|
||||||
|
averageSkyCol_Clouds = texelFetch2D(colortex4,ivec2(0,37),0).rgb;
|
||||||
|
|
||||||
|
WsunVec = lightCol.a * normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
WsunVec2 = lightCol.a * normalize(sunPosition);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w;
|
||||||
|
#endif
|
||||||
|
#ifdef TAA
|
||||||
|
gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
vec2 jitter = clamp(jitter_offsets[frameCounter % 64], -1.0, 1.0);
|
||||||
|
jitter = rotate(radians(float(frameCounter))) * jitter;
|
||||||
|
jitter.y *= aspectRatio;
|
||||||
|
jitter.x *= DOF_ANAMORPHIC_RATIO;
|
||||||
|
|
||||||
|
#if MANUAL_FOCUS == -2
|
||||||
|
float focusMul = 0;
|
||||||
|
#elif MANUAL_FOCUS == -1
|
||||||
|
float focusMul = gl_Position.z + (far / 3.0) - mix(pow(512.0, screenBrightness), 512.0 * screenBrightness, 0.25);
|
||||||
|
#else
|
||||||
|
float focusMul = gl_Position.z + (far / 3.0) - MANUAL_FOCUS;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 totalOffset = (jitter * JITTER_STRENGTH) * focusMul * 1e-2;
|
||||||
|
gl_Position.xy += hideGUI >= 1 ? totalOffset : vec2(0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,446 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
// #if defined END_SHADER || defined NETHER_SHADER
|
||||||
|
// #undef IS_LPV_ENABLED
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
#extension GL_EXT_shader_image_load_store: enable
|
||||||
|
#extension GL_ARB_shading_language_packing: enable
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
varying vec4 lmtexcoord;
|
||||||
|
varying vec4 color;
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
#ifdef LINES
|
||||||
|
flat varying int SELECTION_BOX;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
const bool shadowHardwareFiltering = true;
|
||||||
|
uniform sampler2DShadow shadow;
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2DShadow shadowtex0;
|
||||||
|
uniform sampler2DShadow shadowtex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
|
||||||
|
uniform sampler2D texture;
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
uniform usampler1D texBlockData;
|
||||||
|
uniform sampler3D texLpv1;
|
||||||
|
uniform sampler3D texLpv2;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 shadowModelView;
|
||||||
|
uniform mat4 shadowProjection;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
uniform float rainStrength;
|
||||||
|
flat varying float HELD_ITEM_BRIGHTNESS;
|
||||||
|
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
uniform float nightVision;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
#define CLOUDSHADOWSONLY
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
uniform int heldItemId;
|
||||||
|
uniform int heldItemId2;
|
||||||
|
uniform int frameCounter;
|
||||||
|
|
||||||
|
#include "/lib/hsv.glsl"
|
||||||
|
#include "/lib/lpv_common.glsl"
|
||||||
|
#include "/lib/lpv_render.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "/lib/diffuse_lighting.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
|
||||||
|
vec3 toLinear(vec3 sRGB){
|
||||||
|
return sRGB * (sRGB * (sRGB * 0.305306011 + 0.682171111) + 0.012522878);
|
||||||
|
}
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return fragposition.xyz / fragposition.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
//Mie phase function
|
||||||
|
float phaseg(float x, float g){
|
||||||
|
float gg = g * g;
|
||||||
|
return (gg * -0.25 + 0.25) * pow(-2.0 * (g * x) + (gg + 1.0), -1.5) / 3.14;
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// #undef BASIC_SHADOW_FILTER
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float ComputeShadowMap(inout vec3 directLightColor, vec3 playerPos, float maxDistFade){
|
||||||
|
|
||||||
|
if(maxDistFade <= 0.0) return 1.0;
|
||||||
|
|
||||||
|
// setup shadow projection
|
||||||
|
vec3 projectedShadowPosition = mat3(shadowModelView) * playerPos + shadowModelView[3].xyz;
|
||||||
|
projectedShadowPosition = diagonal3(shadowProjection) * projectedShadowPosition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
// un-distort
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(projectedShadowPosition.xy);
|
||||||
|
projectedShadowPosition.xy *= distortFactor;
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// hamburger
|
||||||
|
projectedShadowPosition = projectedShadowPosition * vec3(0.5,0.5,0.5/6.0) + vec3(0.5);
|
||||||
|
|
||||||
|
float shadowmap = 0.0;
|
||||||
|
vec3 translucentTint = vec3(0.0);
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
|
||||||
|
// determine when opaque shadows are overlapping translucent shadows by getting the difference of opaque depth and translucent depth
|
||||||
|
float shadowDepthDiff = pow(clamp((shadow2D(shadowtex1, projectedShadowPosition).x - projectedShadowPosition.z) * 2.0,0.0,1.0),2.0);
|
||||||
|
|
||||||
|
// get opaque shadow data to get opaque data from translucent shadows.
|
||||||
|
float opaqueShadow = shadow2D(shadowtex0, projectedShadowPosition).x;
|
||||||
|
shadowmap += max(opaqueShadow, shadowDepthDiff);
|
||||||
|
|
||||||
|
// get translucent shadow data
|
||||||
|
vec4 translucentShadow = texture2D(shadowcolor0, projectedShadowPosition.xy);
|
||||||
|
|
||||||
|
// this curve simply looked the nicest. it has no other meaning.
|
||||||
|
float shadowAlpha = pow(1.0 - pow(translucentShadow.a,5.0),0.2);
|
||||||
|
|
||||||
|
// normalize the color to remove luminance, and keep the hue. remove all opaque color.
|
||||||
|
// mulitply shadow alpha to shadow color, but only on surfaces facing the lightsource. this is a tradeoff to protect subsurface scattering's colored shadow tint from shadow bias on the back of the caster.
|
||||||
|
translucentShadow.rgb = max(normalize(translucentShadow.rgb + 0.0001), max(opaqueShadow, 1.0-shadowAlpha)) * shadowAlpha;
|
||||||
|
|
||||||
|
// make it such that full alpha areas that arent in a shadow have a value of 1.0 instead of 0.0
|
||||||
|
translucentTint += mix(translucentShadow.rgb, vec3(1.0), opaqueShadow*shadowDepthDiff);
|
||||||
|
|
||||||
|
#else
|
||||||
|
shadowmap += shadow2D(shadow, projectedShadowPosition).x;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
// tint the lightsource color with the translucent shadow color
|
||||||
|
directLightColor *= mix(vec3(1.0), translucentTint.rgb, maxDistFade);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return mix(1.0, shadowmap, maxDistFade);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined DAMAGE_BLOCK_EFFECT && defined POM
|
||||||
|
#extension GL_ARB_shader_texture_lod : enable
|
||||||
|
|
||||||
|
mat3 inverseMatrix(mat3 m) {
|
||||||
|
float a00 = m[0][0], a01 = m[0][1], a02 = m[0][2];
|
||||||
|
float a10 = m[1][0], a11 = m[1][1], a12 = m[1][2];
|
||||||
|
float a20 = m[2][0], a21 = m[2][1], a22 = m[2][2];
|
||||||
|
|
||||||
|
float b01 = a22 * a11 - a12 * a21;
|
||||||
|
float b11 = -a22 * a10 + a12 * a20;
|
||||||
|
float b21 = a21 * a10 - a11 * a20;
|
||||||
|
|
||||||
|
float det = a00 * b01 + a01 * b11 + a02 * b21;
|
||||||
|
|
||||||
|
return mat3(b01, (-a22 * a01 + a02 * a21), (a12 * a01 - a02 * a11),
|
||||||
|
b11, (a22 * a00 - a02 * a20), (-a12 * a00 + a02 * a10),
|
||||||
|
b21, (-a21 * a00 + a01 * a20), (a11 * a00 - a01 * a10)) / det;
|
||||||
|
}
|
||||||
|
const float MAX_OCCLUSION_DISTANCE = MAX_DIST;
|
||||||
|
const float MIX_OCCLUSION_DISTANCE = MAX_DIST*0.9;
|
||||||
|
const int MAX_OCCLUSION_POINTS = MAX_ITERATIONS;
|
||||||
|
|
||||||
|
varying vec4 vtexcoordam; // .st for add, .pq for mul
|
||||||
|
varying vec4 vtexcoord;
|
||||||
|
|
||||||
|
vec2 dcdx = dFdx(vtexcoord.st*vtexcoordam.pq)*exp2(Texture_MipMap_Bias);
|
||||||
|
vec2 dcdy = dFdy(vtexcoord.st*vtexcoordam.pq)*exp2(Texture_MipMap_Bias);
|
||||||
|
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
|
||||||
|
vec3 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(gbufferProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec2;
|
||||||
|
const float mincoord = 1.0/4096.0;
|
||||||
|
const float maxcoord = 1.0-mincoord;
|
||||||
|
|
||||||
|
uniform sampler2D normals;
|
||||||
|
varying vec4 tangent;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
|
||||||
|
vec4 readNormal(in vec2 coord)
|
||||||
|
{
|
||||||
|
return texture2DGradARB(normals,fract(coord)*vtexcoordam.pq+vtexcoordam.st,dcdx,dcdy);
|
||||||
|
}
|
||||||
|
vec4 readTexture(in vec2 coord)
|
||||||
|
{
|
||||||
|
return texture2DGradARB(texture,fract(coord)*vtexcoordam.pq+vtexcoordam.st,dcdx,dcdy);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
uniform float near;
|
||||||
|
// uniform float far;
|
||||||
|
float ld(float dist) {
|
||||||
|
return (2.0 * near) / (far + near - dist * (far - near));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 texture2D_POMSwitch(
|
||||||
|
sampler2D sampler,
|
||||||
|
vec2 lightmapCoord,
|
||||||
|
vec4 dcdxdcdy
|
||||||
|
){
|
||||||
|
return texture2DGradARB(sampler, lightmapCoord, dcdxdcdy.xy, dcdxdcdy.zw).rgb;
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
#ifdef DAMAGE_BLOCK_EFFECT
|
||||||
|
/* RENDERTARGETS:11 */
|
||||||
|
#else
|
||||||
|
/* DRAWBUFFERS:29 */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
#ifdef DAMAGE_BLOCK_EFFECT
|
||||||
|
vec2 adjustedTexCoord = lmtexcoord.xy;
|
||||||
|
#ifdef POM
|
||||||
|
vec3 fragpos = toScreenSpace(gl_FragCoord.xyz*vec3(texelSize/RENDER_SCALE,1.0)-vec3(0.0));
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * fragpos + gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
|
||||||
|
vec3 normal = normalMat.xyz;
|
||||||
|
vec3 tangent2 = normalize(cross(tangent.rgb,normal)*tangent.w);
|
||||||
|
mat3 tbnMatrix = mat3(tangent.x, tangent2.x, normal.x,
|
||||||
|
tangent.y, tangent2.y, normal.y,
|
||||||
|
tangent.z, tangent2.z, normal.z);
|
||||||
|
|
||||||
|
adjustedTexCoord = fract(vtexcoord.st)*vtexcoordam.pq+vtexcoordam.st;
|
||||||
|
vec3 viewVector = normalize(tbnMatrix*fragpos);
|
||||||
|
|
||||||
|
float dist = length(fragpos);
|
||||||
|
|
||||||
|
float maxdist = MAX_OCCLUSION_DISTANCE;
|
||||||
|
|
||||||
|
// float depth = gl_FragCoord.z;
|
||||||
|
if (dist < maxdist) {
|
||||||
|
|
||||||
|
float depthmap = readNormal(vtexcoord.st).a;
|
||||||
|
float used_POM_DEPTH = 1.0;
|
||||||
|
|
||||||
|
if ( viewVector.z < 0.0 && depthmap < 0.9999 && depthmap > 0.00001) {
|
||||||
|
|
||||||
|
#ifdef Adaptive_Step_length
|
||||||
|
vec3 interval = (viewVector.xyz /-viewVector.z/MAX_OCCLUSION_POINTS * POM_DEPTH) * clamp(1.0-pow(depthmap,2),0.1,1.0);
|
||||||
|
used_POM_DEPTH = 1.0;
|
||||||
|
#else
|
||||||
|
vec3 interval = viewVector.xyz/-viewVector.z/ MAX_OCCLUSION_POINTS*POM_DEPTH;
|
||||||
|
#endif
|
||||||
|
vec3 coord = vec3(vtexcoord.st, 1.0);
|
||||||
|
|
||||||
|
coord += interval * used_POM_DEPTH;
|
||||||
|
|
||||||
|
float sumVec = 0.5;
|
||||||
|
for (int loopCount = 0; (loopCount < MAX_OCCLUSION_POINTS) && (1.0 - POM_DEPTH + POM_DEPTH * readNormal(coord.st).a ) < coord.p && coord.p >= 0.0; ++loopCount) {
|
||||||
|
coord = coord + interval * used_POM_DEPTH;
|
||||||
|
sumVec += used_POM_DEPTH;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (coord.t < mincoord) {
|
||||||
|
if (readTexture(vec2(coord.s,mincoord)).a == 0.0) {
|
||||||
|
coord.t = mincoord;
|
||||||
|
discard;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
adjustedTexCoord = mix(fract(coord.st)*vtexcoordam.pq+vtexcoordam.st, adjustedTexCoord, max(dist-MIX_OCCLUSION_DISTANCE,0.0)/(MAX_OCCLUSION_DISTANCE-MIX_OCCLUSION_DISTANCE));
|
||||||
|
|
||||||
|
// vec3 truePos = fragpos + sumVec*inverseMatrix(tbnMatrix)*interval;
|
||||||
|
|
||||||
|
// depth = toClipSpace3(truePos).z;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 Albedo = toLinear(texture2D_POMSwitch(texture, adjustedTexCoord.xy, vec4(dcdx,dcdy)));
|
||||||
|
#else
|
||||||
|
vec3 Albedo = toLinear(texture2D(texture, adjustedTexCoord.xy).rgb);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(dot(Albedo.rgb, vec3(0.33333)) < 1.0/255.0) { discard; return; }
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(encodeVec2(vec2(0.5)), encodeVec2(Albedo.rg), encodeVec2(vec2(Albedo.b,0.02)), 1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if !defined DAMAGE_BLOCK_EFFECT
|
||||||
|
#ifdef LINES
|
||||||
|
#ifndef SELECT_BOX
|
||||||
|
if(SELECTION_BOX > 0) discard;
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 tempOffset = offsets[framemod8];
|
||||||
|
vec3 viewPos = toScreenSpace(gl_FragCoord.xyz*vec3(texelSize/RENDER_SCALE,1.0)-vec3(vec2(tempOffset)*texelSize*0.5,0.0));
|
||||||
|
vec3 feetPlayerPos = mat3(gbufferModelViewInverse) * viewPos;
|
||||||
|
vec3 feetPlayerPos_normalized = normalize(feetPlayerPos);
|
||||||
|
|
||||||
|
vec4 TEXTURE = texture2D(texture, lmtexcoord.xy)*color;
|
||||||
|
|
||||||
|
#ifdef WhiteWorld
|
||||||
|
TEXTURE.rgb = vec3(0.5);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 Albedo = toLinear(TEXTURE.rgb);
|
||||||
|
|
||||||
|
vec2 lightmap = lmtexcoord.zw;
|
||||||
|
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
lightmap.y = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef Hand_Held_lights
|
||||||
|
lightmap.x = max(lightmap.x, HELD_ITEM_BRIGHTNESS * clamp( pow(max(1.0-length(viewPos)/HANDHELD_LIGHT_RANGE,0.0),1.5),0.0,1.0));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef WEATHER
|
||||||
|
gl_FragData[1].a = TEXTURE.a; // for bloomy rain and stuff
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef WEATHER
|
||||||
|
#ifndef LINES
|
||||||
|
gl_FragData[0].a = TEXTURE.a;
|
||||||
|
#else
|
||||||
|
gl_FragData[0].a = 1.0;
|
||||||
|
#endif
|
||||||
|
#ifndef BLOOMY_PARTICLES
|
||||||
|
gl_FragData[1].a = 0.0; // for bloomy rain and stuff
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 Direct_lighting = vec3(0.0);
|
||||||
|
vec3 directLightColor = vec3(0.0);
|
||||||
|
|
||||||
|
vec3 Indirect_lighting = vec3(0.0);
|
||||||
|
vec3 AmbientLightColor = vec3(0.0);
|
||||||
|
vec3 Torch_Color = vec3(TORCH_R,TORCH_G,TORCH_B);
|
||||||
|
vec3 MinimumLightColor = vec3(1.0);
|
||||||
|
|
||||||
|
if(isEyeInWater == 1) MinimumLightColor = vec3(10.0);
|
||||||
|
// if(lightmap.x >= 0.9) Torch_Color *= LIT_PARTICLE_BRIGHTNESS;
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
directLightColor = lightCol.rgb/80.0;
|
||||||
|
float Shadows = 1.0;
|
||||||
|
|
||||||
|
vec3 shadowPlayerPos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz;
|
||||||
|
|
||||||
|
float shadowMapFalloff = smoothstep(0.0, 1.0, min(max(1.0 - length(shadowPlayerPos) / (shadowDistance+16),0.0)*5.0,1.0));
|
||||||
|
float shadowMapFalloff2 = smoothstep(0.0, 1.0, min(max(1.0 - length(shadowPlayerPos) / (shadowDistance+11),0.0)*5.0,1.0));
|
||||||
|
|
||||||
|
float LM_shadowMapFallback = min(max(lightmap.y-0.8, 0.0) * 25,1.0);
|
||||||
|
|
||||||
|
Shadows = ComputeShadowMap(directLightColor, shadowPlayerPos, shadowMapFalloff);
|
||||||
|
|
||||||
|
Shadows = mix(LM_shadowMapFallback, Shadows, shadowMapFalloff2);
|
||||||
|
|
||||||
|
float cloudShadow = GetCloudShadow(feetPlayerPos);
|
||||||
|
|
||||||
|
Direct_lighting = directLightColor * Shadows * cloudShadow;
|
||||||
|
|
||||||
|
#ifndef LINES
|
||||||
|
Direct_lighting *= phaseg(clamp(dot(feetPlayerPos_normalized, WsunVec),0.0,1.0), 0.65)*2 + 0.5;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
AmbientLightColor = averageSkyCol_Clouds / 30.0;
|
||||||
|
AmbientLightColor *= 2.5;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
vec3 lpvPos = GetLpvPosition(feetPlayerPos);
|
||||||
|
#else
|
||||||
|
const vec3 lpvPos = vec3(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Indirect_lighting = DoAmbientLightColor(feetPlayerPos, lpvPos, AmbientLightColor, MinimumLightColor, Torch_Color, clamp(lightmap.xy,0,1), exposure);
|
||||||
|
|
||||||
|
#ifdef LINES
|
||||||
|
gl_FragData[0].rgb = (Indirect_lighting + Direct_lighting) * toLinear(color.rgb);
|
||||||
|
#else
|
||||||
|
gl_FragData[0].rgb = (Indirect_lighting + Direct_lighting) * Albedo;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// distance fade targeting the world border...
|
||||||
|
if(TEXTURE.a < 0.7 && TEXTURE.a > 0.2) gl_FragData[0] *= clamp(1.0 - length(feetPlayerPos) / 100.0 ,0.0,1.0);
|
||||||
|
|
||||||
|
gl_FragData[0].rgb *= 0.1;
|
||||||
|
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,156 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/items.glsl"
|
||||||
|
|
||||||
|
/*
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
This code is from Chocapic13' shaders
|
||||||
|
Read the terms of modification and sharing before changing something below please !
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
*/
|
||||||
|
|
||||||
|
varying vec4 lmtexcoord;
|
||||||
|
varying vec4 color;
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
#ifdef LINES
|
||||||
|
flat varying int SELECTION_BOX;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
|
||||||
|
uniform int heldItemId;
|
||||||
|
uniform int heldItemId2;
|
||||||
|
flat varying float HELD_ITEM_BRIGHTNESS;
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
vec4 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return vec4(projMAD(gl_ProjectionMatrix, viewSpacePosition),-viewSpacePosition.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef DAMAGE_BLOCK_EFFECT
|
||||||
|
varying vec4 vtexcoordam; // .st for add, .pq for mul
|
||||||
|
varying vec4 vtexcoord;
|
||||||
|
|
||||||
|
attribute vec4 mc_midTexCoord;
|
||||||
|
varying vec4 tangent;
|
||||||
|
attribute vec4 at_tangent;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
flat varying vec3 WsunVec2;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
#ifdef DAMAGE_BLOCK_EFFECT
|
||||||
|
WsunVec2 = (float(sunElevation > 1e-5)*2.0 - 1.0)*normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
#endif
|
||||||
|
lmtexcoord.xy = (gl_MultiTexCoord0).xy;
|
||||||
|
vec2 lmcoord = gl_MultiTexCoord1.xy / 240.0;
|
||||||
|
lmtexcoord.zw = lmcoord;
|
||||||
|
|
||||||
|
#ifdef DAMAGE_BLOCK_EFFECT
|
||||||
|
vec2 midcoord = (gl_TextureMatrix[0] * mc_midTexCoord).st;
|
||||||
|
vec2 texcoordminusmid = lmtexcoord.xy-midcoord;
|
||||||
|
vtexcoordam.pq = abs(texcoordminusmid)*2;
|
||||||
|
vtexcoordam.st = min(lmtexcoord.xy,midcoord-texcoordminusmid);
|
||||||
|
vtexcoord.xy = sign(texcoordminusmid)*0.5+0.5;
|
||||||
|
|
||||||
|
tangent = vec4(normalize(gl_NormalMatrix * at_tangent.rgb), at_tangent.w);
|
||||||
|
|
||||||
|
normalMat = vec4(normalize(gl_NormalMatrix * gl_Normal), 1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
HELD_ITEM_BRIGHTNESS = 0.0;
|
||||||
|
|
||||||
|
#ifdef Hand_Held_lights
|
||||||
|
if(heldItemId == ITEM_LIGHT_SOURCES || heldItemId2 == ITEM_LIGHT_SOURCES) HELD_ITEM_BRIGHTNESS = 0.9;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef WEATHER
|
||||||
|
vec3 position = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz;
|
||||||
|
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * position + gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
bool istopv = worldpos.y > cameraPosition.y + 5.0 && lmtexcoord.w > 0.94;
|
||||||
|
|
||||||
|
if(!istopv){
|
||||||
|
worldpos.xyz -= cameraPosition;
|
||||||
|
}else{
|
||||||
|
worldpos.xyz -= cameraPosition + vec3(2.0,0.0,2.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
position = mat3(gbufferModelView) * worldpos + gbufferModelView[3].xyz;
|
||||||
|
|
||||||
|
gl_Position = toClipSpace3(position);
|
||||||
|
#else
|
||||||
|
gl_Position = ftransform();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
color = gl_Color;
|
||||||
|
|
||||||
|
exposure = texelFetch2D(colortex4,ivec2(10,37),0).r;
|
||||||
|
// color.rgb = worldpos;
|
||||||
|
|
||||||
|
#ifdef LINES
|
||||||
|
SELECTION_BOX = 0;
|
||||||
|
if(dot(color.rgb,vec3(0.33333)) < 0.00001) SELECTION_BOX = 1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
lightCol.a = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
|
||||||
|
averageSkyCol_Clouds = texelFetch2D(colortex4,ivec2(0,37),0).rgb;
|
||||||
|
|
||||||
|
WsunVec = lightCol.a * normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef WEATHER
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w;
|
||||||
|
#endif
|
||||||
|
#ifdef TAA
|
||||||
|
gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize;
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,571 @@
|
||||||
|
#extension GL_ARB_shader_texture_lod : enable
|
||||||
|
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
flat varying int NameTags;
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
#undef POM
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef USE_LUMINANCE_AS_HEIGHTMAP
|
||||||
|
#ifndef MC_NORMAL_MAP
|
||||||
|
#undef POM
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef POM
|
||||||
|
#define MC_NORMAL_MAP
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
varying float VanillaAO;
|
||||||
|
|
||||||
|
const float mincoord = 1.0/4096.0;
|
||||||
|
const float maxcoord = 1.0-mincoord;
|
||||||
|
|
||||||
|
const float MAX_OCCLUSION_DISTANCE = MAX_DIST;
|
||||||
|
const float MIX_OCCLUSION_DISTANCE = MAX_DIST*0.9;
|
||||||
|
const int MAX_OCCLUSION_POINTS = MAX_ITERATIONS;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
// #ifdef POM
|
||||||
|
varying vec4 vtexcoordam; // .st for add, .pq for mul
|
||||||
|
varying vec4 vtexcoord;
|
||||||
|
|
||||||
|
vec2 dcdx = dFdx(vtexcoord.st*vtexcoordam.pq)*exp2(Texture_MipMap_Bias);
|
||||||
|
vec2 dcdy = dFdy(vtexcoord.st*vtexcoordam.pq)*exp2(Texture_MipMap_Bias);
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
varying vec4 lmtexcoord;
|
||||||
|
|
||||||
|
varying vec4 color;
|
||||||
|
|
||||||
|
uniform float far;
|
||||||
|
|
||||||
|
|
||||||
|
uniform float wetness;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef MC_NORMAL_MAP
|
||||||
|
uniform sampler2D normals;
|
||||||
|
varying vec4 tangent;
|
||||||
|
varying vec3 FlatNormals;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
uniform sampler2D specular;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
uniform sampler2D texture;
|
||||||
|
uniform sampler2D colortex1;//albedo(rgb),material(alpha) RGBA16
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform sampler2D noisetex;//depth
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec4 entityColor;
|
||||||
|
|
||||||
|
// in vec3 velocity;
|
||||||
|
|
||||||
|
flat varying float blockID;
|
||||||
|
|
||||||
|
flat varying float SSSAMOUNT;
|
||||||
|
flat varying float EMISSIVE;
|
||||||
|
flat varying int LIGHTNING;
|
||||||
|
flat varying int PORTAL;
|
||||||
|
flat varying int SIGN;
|
||||||
|
|
||||||
|
|
||||||
|
flat varying float HELD_ITEM_BRIGHTNESS;
|
||||||
|
uniform float noPuddleAreas;
|
||||||
|
|
||||||
|
|
||||||
|
// float interleaved_gradientNoise(){
|
||||||
|
// return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+frameTimeCounter*51.9521);
|
||||||
|
// }
|
||||||
|
float interleaved_gradientNoise_temporal(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+frameTimeCounter*51.9521);
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
float R2_dither(){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * gl_FragCoord.x + alpha.y * gl_FragCoord.y + 1.0/1.6180339887 * frameCounter) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
mat3 inverseMatrix(mat3 m) {
|
||||||
|
float a00 = m[0][0], a01 = m[0][1], a02 = m[0][2];
|
||||||
|
float a10 = m[1][0], a11 = m[1][1], a12 = m[1][2];
|
||||||
|
float a20 = m[2][0], a21 = m[2][1], a22 = m[2][2];
|
||||||
|
|
||||||
|
float b01 = a22 * a11 - a12 * a21;
|
||||||
|
float b11 = -a22 * a10 + a12 * a20;
|
||||||
|
float b21 = a21 * a10 - a11 * a20;
|
||||||
|
|
||||||
|
float det = a00 * b01 + a01 * b11 + a02 * b21;
|
||||||
|
|
||||||
|
return mat3(b01, (-a22 * a01 + a02 * a21), (a12 * a01 - a02 * a11),
|
||||||
|
b11, (a22 * a00 - a02 * a20), (-a12 * a00 + a02 * a10),
|
||||||
|
b21, (-a21 * a00 + a01 * a20), (a11 * a00 - a01 * a10)) / det;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 viewToWorld(vec3 viewPosition) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPosition;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec3 worldToView(vec3 worldPos) {
|
||||||
|
vec4 pos = vec4(worldPos, 0.0);
|
||||||
|
pos = gbufferModelView * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec4 encode (vec3 n, vec2 lightmaps){
|
||||||
|
n.xy = n.xy / dot(abs(n), vec3(1.0));
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - abs(n.yx)) * sign(n.xy) : n.xy;
|
||||||
|
vec2 encn = clamp(n.xy * 0.5 + 0.5,-1.0,1.0);
|
||||||
|
|
||||||
|
return vec4(encn,vec2(lightmaps.x,lightmaps.y));
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef MC_NORMAL_MAP
|
||||||
|
vec3 applyBump(mat3 tbnMatrix, vec3 bump, float puddle_values){
|
||||||
|
float bumpmult = clamp(puddle_values,0.0,1.0);
|
||||||
|
bump = bump * vec3(bumpmult, bumpmult, bumpmult) + vec3(0.0f, 0.0f, 1.0f - bumpmult);
|
||||||
|
return normalize(bump*tbnMatrix);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return fragposition.xyz / fragposition.w;
|
||||||
|
}
|
||||||
|
vec3 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(gbufferProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef POM
|
||||||
|
vec4 readNormal(in vec2 coord)
|
||||||
|
{
|
||||||
|
return texture2DGradARB(normals,fract(coord)*vtexcoordam.pq+vtexcoordam.st,dcdx,dcdy);
|
||||||
|
}
|
||||||
|
vec4 readTexture(in vec2 coord)
|
||||||
|
{
|
||||||
|
return texture2DGradARB(texture,fract(coord)*vtexcoordam.pq+vtexcoordam.st,dcdx,dcdy);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
float luma(vec3 color) {
|
||||||
|
return dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec3 toLinear(vec3 sRGB){
|
||||||
|
return sRGB * (sRGB * (sRGB * 0.305306011 + 0.682171111) + 0.012522878);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
uniform float near;
|
||||||
|
|
||||||
|
|
||||||
|
float ld(float dist) {
|
||||||
|
return (2.0 * near) / (far + near - dist * (far - near));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec4 readNoise(in vec2 coord){
|
||||||
|
// return texture2D(noisetex,coord*vtexcoordam.pq+vtexcoord.st);
|
||||||
|
return texture2DGradARB(noisetex,coord*vtexcoordam.pq + vtexcoordam.st,dcdx,dcdy);
|
||||||
|
}
|
||||||
|
float EndPortalEffect(
|
||||||
|
inout vec4 ALBEDO,
|
||||||
|
vec3 FragPos,
|
||||||
|
vec3 WorldPos,
|
||||||
|
mat3 tbnMatrix
|
||||||
|
){
|
||||||
|
|
||||||
|
int maxdist = 25;
|
||||||
|
int quality = 35;
|
||||||
|
|
||||||
|
vec3 viewVec = normalize(tbnMatrix*FragPos);
|
||||||
|
if ( viewVec.z < 0.0 && length(FragPos) < maxdist) {
|
||||||
|
float endportalGLow = 0.0;
|
||||||
|
float Depth = 0.3;
|
||||||
|
vec3 interval = (viewVec.xyz /-viewVec.z/quality*Depth) * (0.7 + (blueNoise()-0.5)*0.1);
|
||||||
|
|
||||||
|
vec3 coord = vec3(WorldPos.xz , 1.0);
|
||||||
|
coord += interval;
|
||||||
|
|
||||||
|
for (int loopCount = 0; (loopCount < quality) && (1.0 - Depth + Depth * ( 1.0-readNoise(coord.st).r - readNoise(-coord.st*3).b*0.2 ) ) < coord.p && coord.p >= 0.0; ++loopCount) {
|
||||||
|
coord = coord+interval ;
|
||||||
|
endportalGLow += (0.3/quality);
|
||||||
|
}
|
||||||
|
|
||||||
|
ALBEDO.rgb = vec3(0.5,0.75,1.0) * sqrt(endportalGLow);
|
||||||
|
|
||||||
|
return clamp(pow(endportalGLow*3.5,3),0,1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
float bias(){
|
||||||
|
// return (Texture_MipMap_Bias + (blueNoise()-0.5)*0.5) - (1.0-RENDER_SCALE.x) * 2.0;
|
||||||
|
return Texture_MipMap_Bias - (1.0-RENDER_SCALE.x) * 2.0;
|
||||||
|
}
|
||||||
|
vec4 texture2D_POMSwitch(
|
||||||
|
sampler2D sampler,
|
||||||
|
vec2 lightmapCoord,
|
||||||
|
vec4 dcdxdcdy,
|
||||||
|
bool ifPOM,
|
||||||
|
float LOD
|
||||||
|
){
|
||||||
|
if(ifPOM){
|
||||||
|
return texture2DGradARB(sampler, lightmapCoord, dcdxdcdy.xy, dcdxdcdy.zw);
|
||||||
|
}else{
|
||||||
|
return texture2D(sampler, lightmapCoord, LOD);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
#if defined HAND || defined ENTITIES || defined BLOCKENTITIES
|
||||||
|
/* RENDERTARGETS:1,8,15,2 */
|
||||||
|
#else
|
||||||
|
/* RENDERTARGETS:1,8,15 */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
bool ifPOM = false;
|
||||||
|
|
||||||
|
#ifdef POM
|
||||||
|
ifPOM = true;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(SIGN > 0) ifPOM = false;
|
||||||
|
|
||||||
|
vec3 normal = normalMat.xyz;
|
||||||
|
|
||||||
|
#ifdef MC_NORMAL_MAP
|
||||||
|
vec3 tangent2 = normalize(cross(tangent.rgb,normal)*tangent.w);
|
||||||
|
mat3 tbnMatrix = mat3(tangent.x, tangent2.x, normal.x,
|
||||||
|
tangent.y, tangent2.y, normal.y,
|
||||||
|
tangent.z, tangent2.z, normal.z);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 tempOffset=offsets[framemod8];
|
||||||
|
|
||||||
|
vec3 fragpos = toScreenSpace(gl_FragCoord.xyz*vec3(texelSize/RENDER_SCALE,1.0)-vec3(vec2(tempOffset)*texelSize*0.5,0.0));
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * fragpos + gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
|
||||||
|
float torchlightmap = lmtexcoord.z;
|
||||||
|
|
||||||
|
#ifdef Hand_Held_lights
|
||||||
|
if(HELD_ITEM_BRIGHTNESS > 0.0) torchlightmap = max(torchlightmap, HELD_ITEM_BRIGHTNESS * clamp( pow(max(1.0-length(fragpos)/HANDHELD_LIGHT_RANGE,0.0),1.5),0.0,1.0));
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
torchlightmap *= 0.9;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float lightmap = clamp( (lmtexcoord.w-0.8) * 10.0,0.,1.);
|
||||||
|
|
||||||
|
float rainfall = rainStrength * noPuddleAreas;
|
||||||
|
float Puddle_shape = 0.;
|
||||||
|
|
||||||
|
#if defined Puddles && defined WORLD && !defined ENTITIES && !defined HAND
|
||||||
|
Puddle_shape = (1.0 - clamp(exp(-15 * pow(texture2D(noisetex, worldpos.xz * (0.020 * Puddle_Size) ).b ,5)),0,1)) * lightmap ;
|
||||||
|
Puddle_shape *= clamp( viewToWorld(normal).y*0.5+0.5 ,0.0,1.0);
|
||||||
|
Puddle_shape *= rainfall;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
vec2 adjustedTexCoord = lmtexcoord.xy;
|
||||||
|
|
||||||
|
#if defined POM && defined WORLD && !defined ENTITIES && !defined HAND
|
||||||
|
// vec2 tempOffset=offsets[framemod8];
|
||||||
|
adjustedTexCoord = fract(vtexcoord.st)*vtexcoordam.pq+vtexcoordam.st;
|
||||||
|
// vec3 fragpos = toScreenSpace(gl_FragCoord.xyz*vec3(texelSize/RENDER_SCALE,1.0)-vec3(vec2(tempOffset)*texelSize*0.5,0.0));
|
||||||
|
vec3 viewVector = normalize(tbnMatrix*fragpos);
|
||||||
|
float dist = length(fragpos);
|
||||||
|
|
||||||
|
float maxdist = MAX_OCCLUSION_DISTANCE;
|
||||||
|
if(!ifPOM) maxdist = 0.0;
|
||||||
|
|
||||||
|
gl_FragDepth = gl_FragCoord.z;
|
||||||
|
|
||||||
|
if (dist < maxdist) {
|
||||||
|
|
||||||
|
float depthmap = readNormal(vtexcoord.st).a;
|
||||||
|
float used_POM_DEPTH = 1.0;
|
||||||
|
|
||||||
|
if ( viewVector.z < 0.0 && depthmap < 0.9999 && depthmap > 0.00001) {
|
||||||
|
// float noise = blueNoise();
|
||||||
|
#ifdef Adaptive_Step_length
|
||||||
|
vec3 interval = (viewVector.xyz /-viewVector.z/MAX_OCCLUSION_POINTS * POM_DEPTH) * clamp(1.0-pow(depthmap,2),0.1,1.0);
|
||||||
|
used_POM_DEPTH = 1.0;
|
||||||
|
#else
|
||||||
|
vec3 interval = viewVector.xyz /-viewVector.z/MAX_OCCLUSION_POINTS*POM_DEPTH;
|
||||||
|
#endif
|
||||||
|
vec3 coord = vec3(vtexcoord.st , 1.0);
|
||||||
|
|
||||||
|
coord += interval * used_POM_DEPTH;
|
||||||
|
|
||||||
|
float sumVec = 0.5;
|
||||||
|
for (int loopCount = 0; (loopCount < MAX_OCCLUSION_POINTS) && (1.0 - POM_DEPTH + POM_DEPTH * readNormal(coord.st).a ) < coord.p && coord.p >= 0.0; ++loopCount) {
|
||||||
|
coord = coord + interval * used_POM_DEPTH;
|
||||||
|
sumVec += used_POM_DEPTH;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (coord.t < mincoord) {
|
||||||
|
if (readTexture(vec2(coord.s,mincoord)).a == 0.0) {
|
||||||
|
coord.t = mincoord;
|
||||||
|
discard;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
adjustedTexCoord = mix(fract(coord.st)*vtexcoordam.pq+vtexcoordam.st, adjustedTexCoord, max(dist-MIX_OCCLUSION_DISTANCE,0.0)/(MAX_OCCLUSION_DISTANCE-MIX_OCCLUSION_DISTANCE));
|
||||||
|
|
||||||
|
vec3 truePos = fragpos + sumVec*inverseMatrix(tbnMatrix)*interval;
|
||||||
|
|
||||||
|
gl_FragDepth = toClipSpace3(truePos).z;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
if(!ifPOM) adjustedTexCoord = lmtexcoord.xy;
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
//////////////////////////////// ALBEDO ////////////////////////////////
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
float textureLOD = bias();
|
||||||
|
vec4 Albedo = texture2D_POMSwitch(texture, adjustedTexCoord.xy, vec4(dcdx,dcdy), ifPOM, textureLOD) * color;
|
||||||
|
|
||||||
|
#if defined HAND
|
||||||
|
if (Albedo.a < 0.1) discard;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(LIGHTNING > 0) Albedo = vec4(1);
|
||||||
|
|
||||||
|
// float ENDPORTAL_EFFECT = 0.0;
|
||||||
|
// #ifndef ENTITIES
|
||||||
|
// ENDPORTAL_EFFECT = PORTAL > 0 ? EndPortalEffect(Albedo, fragpos, worldpos, tbnMatrix) : 0;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
#ifdef WhiteWorld
|
||||||
|
Albedo.rgb = vec3(0.5);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef AEROCHROME_MODE
|
||||||
|
float gray = dot(Albedo.rgb, vec3(0.2, 1.0, 0.07));
|
||||||
|
if (
|
||||||
|
blockID == BLOCK_AMETHYST_BUD_MEDIUM || blockID == BLOCK_AMETHYST_BUD_LARGE || blockID == BLOCK_AMETHYST_CLUSTER ||
|
||||||
|
blockID == BLOCK_SSS_STRONG || blockID == BLOCK_SSS_WEAK ||
|
||||||
|
blockID >= 10 && blockId < 80
|
||||||
|
) {
|
||||||
|
// IR Reflective (Pink-red)
|
||||||
|
Albedo.rgb = mix(vec3(gray), aerochrome_color, 0.7);
|
||||||
|
}
|
||||||
|
else if(blockID == BLOCK_GRASS) {
|
||||||
|
// Special handling for grass block
|
||||||
|
float strength = 1.0 - color.b;
|
||||||
|
Albedo.rgb = mix(Albedo.rgb, aerochrome_color, strength);
|
||||||
|
}
|
||||||
|
#ifdef AEROCHROME_WOOL_ENABLED
|
||||||
|
else if(blockID == BLOCK_SSS_WEAK_2) {
|
||||||
|
// Wool
|
||||||
|
Albedo.rgb = mix(Albedo.rgb, aerochrome_color, 0.3);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
else if(blockID == BLOCK_WATER || (blockID >= 300 && blockID < 400))
|
||||||
|
{
|
||||||
|
// IR Absorbsive? Dark.
|
||||||
|
Albedo.rgb = mix(Albedo.rgb, vec3(0.01, 0.08, 0.15), 0.5);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef WORLD
|
||||||
|
if (Albedo.a > 0.1) Albedo.a = normalMat.a;
|
||||||
|
else Albedo.a = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
if (Albedo.a > 0.1){
|
||||||
|
Albedo.a = 0.75;
|
||||||
|
gl_FragData[3].a = 0.0;
|
||||||
|
} else {
|
||||||
|
Albedo.a = 1.0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined PARTICLE_RENDERING_FIX && (defined ENTITIES || defined BLOCKENTITIES)
|
||||||
|
gl_FragData[3].a = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
//////////////////////////////// NORMAL ////////////////////////////////
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
|
||||||
|
#if defined WORLD && defined MC_NORMAL_MAP
|
||||||
|
vec4 NormalTex = texture2D_POMSwitch(normals, adjustedTexCoord.xy, vec4(dcdx,dcdy), ifPOM,textureLOD).xyzw;
|
||||||
|
|
||||||
|
#ifdef MATERIAL_AO
|
||||||
|
Albedo.rgb *= NormalTex.b*0.5+0.5;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float Heightmap = 1.0 - NormalTex.w;
|
||||||
|
|
||||||
|
NormalTex.xy = NormalTex.xy * 2.0-1.0;
|
||||||
|
NormalTex.z = sqrt(max(1.0 - dot(NormalTex.xy, NormalTex.xy), 0.0));
|
||||||
|
|
||||||
|
// #if defined HEIGTHMAP_DEPTH_OFFSET && !defined HAND
|
||||||
|
// gl_FragDepth = gl_FragCoord.z;
|
||||||
|
// vec3 truePos = fragpos;
|
||||||
|
// truePos.z -= Heightmap * POM_DEPTH * (1.0 + ld(truePos.z));
|
||||||
|
|
||||||
|
// gl_FragDepth = toClipSpace3(truePos).z;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
normal = applyBump(tbnMatrix, NormalTex.xyz, mix(1.0,1-Puddle_shape,rainfall) );
|
||||||
|
// normal = applyBump(tbnMatrix, NormalTex.xyz, 0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
//////////////////////////////// SPECULAR ////////////////////////////////
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
|
||||||
|
#ifdef WORLD
|
||||||
|
vec4 SpecularTex = texture2D_POMSwitch(specular, adjustedTexCoord.xy, vec4(dcdx,dcdy), ifPOM,textureLOD);
|
||||||
|
|
||||||
|
SpecularTex.r = max(SpecularTex.r, Puddle_shape);
|
||||||
|
SpecularTex.g = max(SpecularTex.g, Puddle_shape*0.02);
|
||||||
|
|
||||||
|
gl_FragData[1].rg = SpecularTex.rg;
|
||||||
|
|
||||||
|
#if EMISSIVE_TYPE == 0
|
||||||
|
gl_FragData[1].a = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if EMISSIVE_TYPE == 1
|
||||||
|
gl_FragData[1].a = EMISSIVE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if EMISSIVE_TYPE == 2
|
||||||
|
gl_FragData[1].a = SpecularTex.a;
|
||||||
|
if(SpecularTex.a <= 0.0) gl_FragData[2].a = EMISSIVE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if EMISSIVE_TYPE == 3
|
||||||
|
gl_FragData[1].a = SpecularTex.a;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if SSS_TYPE == 0
|
||||||
|
gl_FragData[1].b = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if SSS_TYPE == 1
|
||||||
|
gl_FragData[1].b = SSSAMOUNT;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if SSS_TYPE == 2
|
||||||
|
gl_FragData[1].b = SpecularTex.b;
|
||||||
|
if(SpecularTex.b < 65.0/255.0) gl_FragData[1].b = SSSAMOUNT;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if SSS_TYPE == 3
|
||||||
|
gl_FragData[1].b = SpecularTex.b;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// #ifndef ENTITIES
|
||||||
|
// if(PORTAL > 0){
|
||||||
|
// gl_FragData[2].rgb = vec3(0);
|
||||||
|
// gl_FragData[2].a = clamp(ENDPORTAL_EFFECT * 0.9, 0,0.9);
|
||||||
|
// }
|
||||||
|
// #endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// hit glow effect...
|
||||||
|
#ifdef ENTITIES
|
||||||
|
Albedo.rgb = mix(Albedo.rgb, entityColor.rgb, clamp(entityColor.a*1.5,0,1));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
//////////////////////////////// FINALIZE ////////////////////////////////
|
||||||
|
//////////////////////////////// ////////////////////////////////
|
||||||
|
|
||||||
|
#ifdef WORLD
|
||||||
|
|
||||||
|
#ifdef Puddles
|
||||||
|
float porosity = 0.4;
|
||||||
|
#ifdef Porosity
|
||||||
|
porosity = SpecularTex.z >= 64.5/255.0 ? 0.0 : (SpecularTex.z*255.0/64.0)*0.65;
|
||||||
|
#endif
|
||||||
|
if(SpecularTex.g < 229.5/255.0) Albedo.rgb = mix(Albedo.rgb, vec3(0), Puddle_shape*porosity);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// apply noise to lightmaps to reduce banding.
|
||||||
|
vec2 PackLightmaps = vec2(torchlightmap, lmtexcoord.w);
|
||||||
|
|
||||||
|
vec4 data1 = clamp( encode(viewToWorld(normal), PackLightmaps), 0.0, 1.0);
|
||||||
|
// gl_FragData[0] = vec4(.0);
|
||||||
|
gl_FragData[0] = vec4(encodeVec2(Albedo.x,data1.x), encodeVec2(Albedo.y,data1.y), encodeVec2(Albedo.z,data1.z), encodeVec2(data1.w,Albedo.w));
|
||||||
|
|
||||||
|
|
||||||
|
gl_FragData[2] = vec4(FlatNormals * 0.5 + 0.5, VanillaAO);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,386 @@
|
||||||
|
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/bokeh.glsl"
|
||||||
|
#include "/lib/blocks.glsl"
|
||||||
|
#include "/lib/entities.glsl"
|
||||||
|
#include "/lib/items.glsl"
|
||||||
|
|
||||||
|
/*
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
This code is from Chocapic13' shaders
|
||||||
|
Read the terms of modification and sharing before changing something below please !
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
#undef POM
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef USE_LUMINANCE_AS_HEIGHTMAP
|
||||||
|
#ifndef MC_NORMAL_MAP
|
||||||
|
#undef POM
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef POM
|
||||||
|
#define MC_NORMAL_MAP
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
varying vec4 color;
|
||||||
|
varying float VanillaAO;
|
||||||
|
|
||||||
|
varying vec4 lmtexcoord;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
|
||||||
|
// #ifdef POM
|
||||||
|
varying vec4 vtexcoordam; // .st for add, .pq for mul
|
||||||
|
varying vec4 vtexcoord;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
#ifdef MC_NORMAL_MAP
|
||||||
|
varying vec4 tangent;
|
||||||
|
attribute vec4 at_tangent;
|
||||||
|
varying vec3 FlatNormals;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
const float PI48 = 150.796447372*WAVY_SPEED;
|
||||||
|
float pi2wt = PI48*frameTimeCounter;
|
||||||
|
|
||||||
|
attribute vec4 mc_Entity;
|
||||||
|
attribute vec4 mc_midTexCoord;
|
||||||
|
|
||||||
|
uniform int blockEntityId;
|
||||||
|
uniform int entityId;
|
||||||
|
flat varying float blockID;
|
||||||
|
|
||||||
|
uniform int heldItemId;
|
||||||
|
uniform int heldItemId2;
|
||||||
|
flat varying float HELD_ITEM_BRIGHTNESS;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
flat varying int NameTags;
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float far;
|
||||||
|
uniform float aspectRatio;
|
||||||
|
uniform float viewHeight;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform int hideGUI;
|
||||||
|
uniform float screenBrightness;
|
||||||
|
|
||||||
|
flat varying float SSSAMOUNT;
|
||||||
|
flat varying float EMISSIVE;
|
||||||
|
flat varying int LIGHTNING;
|
||||||
|
flat varying int PORTAL;
|
||||||
|
flat varying int SIGN;
|
||||||
|
|
||||||
|
// in vec3 at_velocity;
|
||||||
|
// out vec3 velocity;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
vec4 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return vec4(projMAD(gl_ProjectionMatrix, viewSpacePosition),-viewSpacePosition.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 calcWave(in vec3 pos) {
|
||||||
|
|
||||||
|
float magnitude = abs(sin(dot(vec4(frameTimeCounter, pos),vec4(1.0,0.005,0.005,0.005)))*0.5+0.72)*0.013;
|
||||||
|
vec2 ret = (sin(pi2wt*vec2(0.0063,0.0015)*4. - pos.xz + pos.y*0.05)+0.1)*magnitude;
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 calcMovePlants(in vec3 pos) {
|
||||||
|
vec2 move1 = calcWave(pos );
|
||||||
|
float move1y = -length(move1);
|
||||||
|
return vec3(move1.x,move1y,move1.y)*5.*WAVY_STRENGTH;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 calcWaveLeaves(in vec3 pos, in float fm, in float mm, in float ma, in float f0, in float f1, in float f2, in float f3, in float f4, in float f5) {
|
||||||
|
|
||||||
|
float magnitude = abs(sin(dot(vec4(frameTimeCounter, pos),vec4(1.0,0.005,0.005,0.005)))*0.5+0.72)*0.013;
|
||||||
|
vec3 ret = (sin(pi2wt*vec3(0.0063,0.0224,0.0015)*1.5 - pos))*magnitude;
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 calcMoveLeaves(in vec3 pos, in float f0, in float f1, in float f2, in float f3, in float f4, in float f5, in vec3 amp1, in vec3 amp2) {
|
||||||
|
vec3 move1 = calcWaveLeaves(pos , 0.0054, 0.0400, 0.0400, 0.0127, 0.0089, 0.0114, 0.0063, 0.0224, 0.0015) * amp1;
|
||||||
|
return move1*5.*WAVY_STRENGTH;
|
||||||
|
}
|
||||||
|
vec3 srgbToLinear2(vec3 srgb){
|
||||||
|
return mix(
|
||||||
|
srgb / 12.92,
|
||||||
|
pow(.947867 * srgb + .0521327, vec3(2.4) ),
|
||||||
|
step( .04045, srgb )
|
||||||
|
);
|
||||||
|
}
|
||||||
|
vec3 blackbody2(float Temp)
|
||||||
|
{
|
||||||
|
float t = pow(Temp, -1.5);
|
||||||
|
float lt = log(Temp);
|
||||||
|
|
||||||
|
vec3 col = vec3(0.0);
|
||||||
|
col.x = 220000.0 * t + 0.58039215686;
|
||||||
|
col.y = 0.39231372549 * lt - 2.44549019608;
|
||||||
|
col.y = Temp > 6500. ? 138039.215686 * t + 0.72156862745 : col.y;
|
||||||
|
col.z = 0.76078431372 * lt - 5.68078431373;
|
||||||
|
col = clamp(col,0.0,1.0);
|
||||||
|
col = Temp < 1000. ? col * Temp * 0.001 : col;
|
||||||
|
|
||||||
|
return srgbToLinear2(col);
|
||||||
|
}
|
||||||
|
// float luma(vec3 color) {
|
||||||
|
// return dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
// }
|
||||||
|
|
||||||
|
#define SEASONS_VSH
|
||||||
|
#include "/lib/climate_settings.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;//depth
|
||||||
|
float densityAtPos(in vec3 pos){
|
||||||
|
pos /= 18.;
|
||||||
|
pos.xz *= 0.5;
|
||||||
|
vec3 p = floor(pos);
|
||||||
|
vec3 f = fract(pos);
|
||||||
|
vec2 uv = p.xz + f.xz + p.y * vec2(0.0,193.0);
|
||||||
|
vec2 coord = uv / 512.0;
|
||||||
|
|
||||||
|
//The y channel has an offset to avoid using two textures fetches
|
||||||
|
vec2 xy = texture2D(noisetex, coord).yx;
|
||||||
|
|
||||||
|
return mix(xy.r,xy.g, f.y);
|
||||||
|
}
|
||||||
|
float luma(vec3 color) {
|
||||||
|
return dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
vec3 position = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz;
|
||||||
|
|
||||||
|
/////// ----- COLOR STUFF ----- ///////
|
||||||
|
color = gl_Color;
|
||||||
|
|
||||||
|
VanillaAO = 1.0 - clamp(color.a,0,1);
|
||||||
|
if (color.a < 0.3) color.a = 1.0; // fix vanilla ao on some custom block models.
|
||||||
|
|
||||||
|
/////// ----- RANDOM STUFF ----- ///////
|
||||||
|
// gl_TextureMatrix[0] for animated things like charged creepers
|
||||||
|
lmtexcoord.xy = (gl_TextureMatrix[0] * gl_MultiTexCoord0).xy;
|
||||||
|
|
||||||
|
// #ifdef POM
|
||||||
|
vec2 midcoord = (gl_TextureMatrix[0] * mc_midTexCoord).st;
|
||||||
|
vec2 texcoordminusmid = lmtexcoord.xy-midcoord;
|
||||||
|
vtexcoordam.pq = abs(texcoordminusmid)*2;
|
||||||
|
vtexcoordam.st = min(lmtexcoord.xy,midcoord-texcoordminusmid);
|
||||||
|
vtexcoord.xy = sign(texcoordminusmid)*0.5+0.5;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
|
||||||
|
vec2 lmcoord = gl_MultiTexCoord1.xy / 240.0;
|
||||||
|
lmtexcoord.zw = lmcoord;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef MC_NORMAL_MAP
|
||||||
|
tangent = vec4(normalize(gl_NormalMatrix * at_tangent.rgb), at_tangent.w);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
normalMat = vec4(normalize(gl_NormalMatrix * gl_Normal), 1.0);
|
||||||
|
FlatNormals = normalMat.xyz;
|
||||||
|
|
||||||
|
blockID = mc_Entity.x;
|
||||||
|
// velocity = at_velocity;
|
||||||
|
|
||||||
|
if(mc_Entity.x == BLOCK_GROUND_WAVING_VERTICAL || mc_Entity.x == BLOCK_GRASS_SHORT) normalMat.a = 0.60;
|
||||||
|
|
||||||
|
|
||||||
|
PORTAL = 0;
|
||||||
|
SIGN = 0;
|
||||||
|
|
||||||
|
#ifdef WORLD
|
||||||
|
if(blockEntityId == BLOCK_SIGN) SIGN = 1;
|
||||||
|
|
||||||
|
if(blockEntityId == BLOCK_END_PORTAL) PORTAL = 1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
NameTags = 0;
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef ENTITIES
|
||||||
|
// disallow POM to work on item frames.
|
||||||
|
if(entityId == ENTITY_ITEM_FRAME) SIGN = 1;
|
||||||
|
|
||||||
|
|
||||||
|
// try and single out nametag text and then discard nametag background
|
||||||
|
// if( dot(gl_Color.rgb, vec3(1.0/3.0)) < 1.0) NameTags = 1;
|
||||||
|
// if(gl_Color.a < 1.0) NameTags = 1;
|
||||||
|
// if(gl_Color.a >= 0.24 && gl_Color.a <= 0.25 ) gl_Position = vec4(10,10,10,1);
|
||||||
|
if(entityId == ENTITY_SSS_MEDIUM || entityId == ENTITY_SSS_WEAK || entityId == ENTITY_PLAYER || entityId == 2468) normalMat.a = 0.45;
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(mc_Entity.x == BLOCK_AIR_WAVING) normalMat.a = 0.55;
|
||||||
|
|
||||||
|
/////// ----- EMISSIVE STUFF ----- ///////
|
||||||
|
EMISSIVE = 0.0;
|
||||||
|
LIGHTNING = 0;
|
||||||
|
// if(NameTags > 0) EMISSIVE = 0.9;
|
||||||
|
|
||||||
|
// normal block lightsources
|
||||||
|
if(mc_Entity.x >= 100 && mc_Entity.x < 300) EMISSIVE = 0.5;
|
||||||
|
|
||||||
|
// special cases light lightning and beacon beams...
|
||||||
|
#ifdef ENTITIES
|
||||||
|
if(entityId == ENTITY_LIGHTNING){
|
||||||
|
LIGHTNING = 1;
|
||||||
|
normalMat.a = 0.50;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/////// ----- SSS STUFF ----- ///////
|
||||||
|
SSSAMOUNT = 0.0;
|
||||||
|
|
||||||
|
HELD_ITEM_BRIGHTNESS = 0.0;
|
||||||
|
|
||||||
|
#ifdef Hand_Held_lights
|
||||||
|
if(heldItemId == ITEM_LIGHT_SOURCES || heldItemId2 == ITEM_LIGHT_SOURCES) HELD_ITEM_BRIGHTNESS = 0.9;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef WORLD
|
||||||
|
/////// ----- SSS ON BLOCKS ----- ///////
|
||||||
|
// strong
|
||||||
|
if (
|
||||||
|
mc_Entity.x == BLOCK_GROUND_WAVING || mc_Entity.x == BLOCK_GROUND_WAVING_VERTICAL || mc_Entity.x == BLOCK_AIR_WAVING ||
|
||||||
|
mc_Entity.x == BLOCK_GRASS_SHORT || mc_Entity.x == BLOCK_GRASS_TALL_UPPER || mc_Entity.x == BLOCK_GRASS_TALL_LOWER ||
|
||||||
|
mc_Entity.x == BLOCK_SSS_STRONG || mc_Entity.x == BLOCK_SAPLING
|
||||||
|
) {
|
||||||
|
SSSAMOUNT = 1.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// medium
|
||||||
|
if (
|
||||||
|
mc_Entity.x == BLOCK_SSS_WEAK || mc_Entity.x == BLOCK_SSS_WEAK_2 ||
|
||||||
|
mc_Entity.x == BLOCK_AMETHYST_BUD_MEDIUM || mc_Entity.x == BLOCK_AMETHYST_BUD_LARGE || mc_Entity.x == BLOCK_AMETHYST_CLUSTER ||
|
||||||
|
mc_Entity.x == BLOCK_BAMBOO || mc_Entity.x == BLOCK_SAPLING || mc_Entity.x == BLOCK_VINE
|
||||||
|
) {
|
||||||
|
SSSAMOUNT = 0.75;
|
||||||
|
}
|
||||||
|
// low
|
||||||
|
#ifdef MISC_BLOCK_SSS
|
||||||
|
if(mc_Entity.x == BLOCK_SSS_WEIRD || mc_Entity.x == BLOCK_GRASS) SSSAMOUNT = 0.5; // weird SSS on blocks like grass and stuff
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef ENTITIES
|
||||||
|
#ifdef MOB_SSS
|
||||||
|
/////// ----- SSS ON MOBS----- ///////
|
||||||
|
// strong
|
||||||
|
if(entityId == ENTITY_SSS_MEDIUM) SSSAMOUNT = 0.75;
|
||||||
|
|
||||||
|
// medium
|
||||||
|
|
||||||
|
// low
|
||||||
|
if(entityId == ENTITY_SSS_WEAK || entityId == ENTITY_PLAYER) SSSAMOUNT = 0.3;
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BLOCKENTITIES
|
||||||
|
/////// ----- SSS ON BLOCK ENTITIES----- ///////
|
||||||
|
// strong
|
||||||
|
|
||||||
|
// medium
|
||||||
|
if(blockEntityId == BLOCK_SSS_WEAK_3) SSSAMOUNT = 0.4;
|
||||||
|
|
||||||
|
// low
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef WAVY_PLANTS
|
||||||
|
bool istopv = gl_MultiTexCoord0.t < mc_midTexCoord.t;
|
||||||
|
|
||||||
|
if (
|
||||||
|
(
|
||||||
|
mc_Entity.x == BLOCK_GROUND_WAVING || mc_Entity.x == BLOCK_GROUND_WAVING_VERTICAL ||
|
||||||
|
mc_Entity.x == BLOCK_GRASS_SHORT || mc_Entity.x == BLOCK_GRASS_TALL_UPPER ||
|
||||||
|
mc_Entity.x == BLOCK_SAPLING
|
||||||
|
) && istopv && abs(position.z) < 64.0
|
||||||
|
) {
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * position + gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
worldpos.xyz += calcMovePlants(worldpos.xyz)*lmtexcoord.w - cameraPosition;
|
||||||
|
position = mat3(gbufferModelView) * worldpos + gbufferModelView[3].xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (mc_Entity.x == BLOCK_AIR_WAVING && abs(position.z) < 64.0) {
|
||||||
|
vec3 worldpos = mat3(gbufferModelViewInverse) * position + gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
worldpos.xyz += calcMoveLeaves(worldpos.xyz, 0.0040, 0.0064, 0.0043, 0.0035, 0.0037, 0.0041, vec3(1.0,0.2,1.0), vec3(0.5,0.1,0.5))*lmtexcoord.w - cameraPosition;
|
||||||
|
position = mat3(gbufferModelView) * worldpos + gbufferModelView[3].xyz;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
gl_Position = toClipSpace3(position);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined Seasons && defined WORLD && !defined ENTITIES && !defined BLOCKENTITIES && !defined HAND
|
||||||
|
YearCycleColor(color.rgb, gl_Color.rgb, mc_Entity.x == BLOCK_AIR_WAVING, true);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w;
|
||||||
|
#endif
|
||||||
|
#ifdef TAA
|
||||||
|
gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
vec2 jitter = clamp(jitter_offsets[frameCounter % 64], -1.0, 1.0);
|
||||||
|
jitter = rotate(radians(float(frameCounter))) * jitter;
|
||||||
|
jitter.y *= aspectRatio;
|
||||||
|
jitter.x *= DOF_ANAMORPHIC_RATIO;
|
||||||
|
|
||||||
|
#if MANUAL_FOCUS == -2
|
||||||
|
float focusMul = 0;
|
||||||
|
#elif MANUAL_FOCUS == -1
|
||||||
|
float focusMul = gl_Position.z - mix(pow(512.0, screenBrightness), 512.0 * screenBrightness, 0.25);
|
||||||
|
#else
|
||||||
|
float focusMul = gl_Position.z - MANUAL_FOCUS;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 totalOffset = (jitter * JITTER_STRENGTH) * focusMul * 1e-2;
|
||||||
|
gl_Position.xy += hideGUI >= 1 ? totalOffset : vec2(0);
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,909 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
// #if defined END_SHADER || defined NETHER_SHADER
|
||||||
|
// #undef IS_LPV_ENABLED
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
#extension GL_EXT_shader_image_load_store: enable
|
||||||
|
#extension GL_ARB_shading_language_packing: enable
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
varying vec4 lmtexcoord;
|
||||||
|
varying vec4 color;
|
||||||
|
uniform vec4 entityColor;
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
const bool shadowHardwareFiltering = true;
|
||||||
|
uniform sampler2DShadow shadow;
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2DShadow shadowtex0;
|
||||||
|
uniform sampler2DShadow shadowtex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform float lightSign;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
flat varying float HELD_ITEM_BRIGHTNESS;
|
||||||
|
|
||||||
|
const bool colortex4MipmapEnabled = true;
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
uniform sampler2D colortex7;
|
||||||
|
uniform sampler2D colortex12;
|
||||||
|
uniform sampler2D colortex14;
|
||||||
|
uniform sampler2D colortex5;
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
|
||||||
|
uniform sampler2D texture;
|
||||||
|
uniform sampler2D specular;
|
||||||
|
uniform sampler2D normals;
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
uniform usampler1D texBlockData;
|
||||||
|
uniform sampler3D texLpv1;
|
||||||
|
uniform sampler3D texLpv2;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
varying vec4 tangent;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
varying vec3 binormal;
|
||||||
|
varying vec3 flatnormal;
|
||||||
|
|
||||||
|
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform float near;
|
||||||
|
// uniform float far;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform float skyIntensityNight;
|
||||||
|
uniform float skyIntensity;
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
uniform mat4 gbufferPreviousModelView;
|
||||||
|
uniform vec3 previousCameraPosition;
|
||||||
|
|
||||||
|
|
||||||
|
uniform float moonIntensity;
|
||||||
|
uniform float sunIntensity;
|
||||||
|
uniform vec3 sunColor;
|
||||||
|
uniform vec3 nsunColor;
|
||||||
|
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
#include "/lib/color_transforms.glsl"
|
||||||
|
#include "/lib/projections.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/waterBump.glsl"
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
flat varying float Flashing;
|
||||||
|
#include "/lib/lightning_stuff.glsl"
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#else
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
uniform float nightVision;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
#include "/lib/end_fog.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
uniform int heldItemId;
|
||||||
|
uniform int heldItemId2;
|
||||||
|
|
||||||
|
#include "/lib/hsv.glsl"
|
||||||
|
#include "/lib/lpv_common.glsl"
|
||||||
|
#include "/lib/lpv_render.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "/lib/diffuse_lighting.glsl"
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
vec4 blueNoise(vec2 coord){
|
||||||
|
return texelFetch2D(colortex6, ivec2(coord)%512 , 0) ;
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise_temporal(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+frameTimeCounter*51.9521);
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
float R2_dither(){
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#define PW_DEPTH 1.5 //[0.5 1.0 1.5 2.0 2.5 3.0]
|
||||||
|
#define PW_POINTS 2 //[2 4 6 8 16 32]
|
||||||
|
|
||||||
|
varying vec3 viewVector;
|
||||||
|
vec3 getParallaxDisplacement(vec3 posxz) {
|
||||||
|
|
||||||
|
vec3 parallaxPos = posxz;
|
||||||
|
vec2 vec = viewVector.xy * (1.0 / float(PW_POINTS)) * 22.0 * PW_DEPTH;
|
||||||
|
// float waterHeight = (1.0 - (getWaterHeightmap(posxz.xz)*0.5+0.5)) * 2.0 - 1.0;
|
||||||
|
float waterHeight = getWaterHeightmap(posxz.xz) * 2.0;
|
||||||
|
parallaxPos.xz -= waterHeight * vec;
|
||||||
|
|
||||||
|
return parallaxPos;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec3 applyBump(mat3 tbnMatrix, vec3 bump, float puddle_values){
|
||||||
|
float bumpmult = puddle_values;
|
||||||
|
bump = bump * vec3(bumpmult, bumpmult, bumpmult) + vec3(0.0f, 0.0f, 1.0f - bumpmult);
|
||||||
|
//
|
||||||
|
return normalize(bump*tbnMatrix);
|
||||||
|
}
|
||||||
|
|
||||||
|
// vec2 tapLocation(int sampleNumber,int nb, float nbRot,float jitter,float distort)
|
||||||
|
// {
|
||||||
|
// float alpha = (sampleNumber+jitter)/nb;
|
||||||
|
// float angle = jitter*6.28 + alpha * nbRot * 6.28;
|
||||||
|
|
||||||
|
// float sin_v, cos_v;
|
||||||
|
|
||||||
|
// sin_v = sin(angle);
|
||||||
|
// cos_v = cos(angle);
|
||||||
|
|
||||||
|
// return vec2(cos_v, sin_v)*sqrt(alpha);
|
||||||
|
// }
|
||||||
|
vec2 tapLocation_simple(
|
||||||
|
int samples, int totalSamples, float rotation, float rng
|
||||||
|
){
|
||||||
|
const float PI = 3.141592653589793238462643383279502884197169;
|
||||||
|
float alpha = float(samples + rng) * (1.0 / float(totalSamples));
|
||||||
|
float angle = alpha * (rotation * PI);
|
||||||
|
|
||||||
|
float sin_v = sin(angle);
|
||||||
|
float cos_v = cos(angle);
|
||||||
|
|
||||||
|
return vec2(cos_v, sin_v) * sqrt(alpha);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 CleanSample(
|
||||||
|
int samples, float totalSamples, float noise
|
||||||
|
){
|
||||||
|
|
||||||
|
// this will be used to make 1 full rotation of the spiral. the mulitplication is so it does nearly a single rotation, instead of going past where it started
|
||||||
|
float variance = noise * 0.897;
|
||||||
|
|
||||||
|
// for every sample input, it will have variance applied to it.
|
||||||
|
float variedSamples = float(samples) + variance;
|
||||||
|
|
||||||
|
// for every sample, the sample position must change its distance from the origin.
|
||||||
|
// otherwise, you will just have a circle.
|
||||||
|
float spiralShape = pow(variedSamples / (totalSamples + variance),0.5);
|
||||||
|
|
||||||
|
float shape = 2.26; // this is very important. 2.26 is very specific
|
||||||
|
float theta = variedSamples * (PI * shape);
|
||||||
|
|
||||||
|
float x = cos(theta) * spiralShape;
|
||||||
|
float y = sin(theta) * spiralShape;
|
||||||
|
|
||||||
|
return vec2(x, y);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 viewToWorld(vec3 viewPos) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPos;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 worldToView(vec3 worldPos) {
|
||||||
|
vec4 pos = vec4(worldPos, 0.0);
|
||||||
|
pos = gbufferModelView * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
vec4 encode (vec3 n, vec2 lightmaps){
|
||||||
|
n.xy = n.xy / dot(abs(n), vec3(1.0));
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - abs(n.yx)) * sign(n.xy) : n.xy;
|
||||||
|
vec2 encn = clamp(n.xy * 0.5 + 0.5,-1.0,1.0);
|
||||||
|
|
||||||
|
return vec4(encn,vec2(lightmaps.x,lightmaps.y));
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
float invLinZ (float lindepth){
|
||||||
|
return -((2.0*near/lindepth)-far-near)/(far-near);
|
||||||
|
}
|
||||||
|
float ld(float dist) {
|
||||||
|
return (2.0 * near) / (far + near - dist * (far - near));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 rayTrace(vec3 dir, vec3 position,float dither, float fresnel, bool inwater, inout float reflectLength){
|
||||||
|
|
||||||
|
float quality = mix(15,SSR_STEPS,fresnel);
|
||||||
|
|
||||||
|
// quality = SSR_STEPS;
|
||||||
|
|
||||||
|
vec3 clipPosition = toClipSpace3(position);
|
||||||
|
float rayLength = ((position.z + dir.z * far*sqrt(3.)) > -near) ?
|
||||||
|
(-near -position.z) / dir.z : far*sqrt(3.);
|
||||||
|
vec3 direction = normalize(toClipSpace3(position+dir*rayLength)-clipPosition); //convert to clip space
|
||||||
|
direction.xy = normalize(direction.xy);
|
||||||
|
|
||||||
|
//get at which length the ray intersects with the edge of the screen
|
||||||
|
vec3 maxLengths = (step(0.,direction)-clipPosition) / direction;
|
||||||
|
float mult = min(min(maxLengths.x,maxLengths.y),maxLengths.z);
|
||||||
|
|
||||||
|
|
||||||
|
vec3 stepv = direction * mult / quality * vec3(RENDER_SCALE,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
vec3 spos = clipPosition*vec3(RENDER_SCALE,1.0) + stepv*dither;
|
||||||
|
float minZ = clipPosition.z;
|
||||||
|
float maxZ = spos.z+stepv.z*0.5;
|
||||||
|
|
||||||
|
spos.xy += offsets[framemod8]*texelSize*0.5/RENDER_SCALE;
|
||||||
|
|
||||||
|
float dist = 1.0 + clamp(position.z*position.z/50.0,0,2); // shrink sample size as distance increases
|
||||||
|
for (int i = 0; i <= int(quality); i++) {
|
||||||
|
|
||||||
|
// decode depth buffer
|
||||||
|
// float sp = sqrt(texelFetch2D(colortex4,ivec2(spos.xy/texelSize/4),0).w/65000.0);
|
||||||
|
|
||||||
|
float sp = sqrt(texelFetch2D(colortex4,ivec2(spos.xy/texelSize/4.0),0).a/65000.0);
|
||||||
|
sp = invLinZ(sp);
|
||||||
|
|
||||||
|
if(sp <= max(maxZ,minZ) && sp >= min(maxZ,minZ)) return vec3(spos.xy/RENDER_SCALE,sp);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
spos += stepv;
|
||||||
|
//small bias
|
||||||
|
if(inwater) {
|
||||||
|
minZ = maxZ-0.00035/ld(spos.z);
|
||||||
|
}else{
|
||||||
|
minZ = maxZ-0.0001/max(ld(spos.z), (0.0 + position.z*position.z*0.001));
|
||||||
|
}
|
||||||
|
maxZ += stepv.z;
|
||||||
|
|
||||||
|
|
||||||
|
reflectLength += 1.0 / quality; // for shit
|
||||||
|
}
|
||||||
|
|
||||||
|
return vec3(1.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
float GGX(vec3 n, vec3 v, vec3 l, float r, float f0) {
|
||||||
|
r = max(pow(r,2.5), 0.0001);
|
||||||
|
|
||||||
|
vec3 h = l + v;
|
||||||
|
float hn = inversesqrt(dot(h, h));
|
||||||
|
|
||||||
|
float dotLH = clamp(dot(h,l)*hn,0.,1.);
|
||||||
|
float dotNH = clamp(dot(h,n)*hn,0.,1.) ;
|
||||||
|
float dotNL = clamp(dot(n,l),0.,1.);
|
||||||
|
float dotNHsq = dotNH*dotNH;
|
||||||
|
|
||||||
|
float denom = dotNHsq * r - dotNHsq + 1.;
|
||||||
|
float D = r / (3.141592653589793 * denom * denom);
|
||||||
|
|
||||||
|
float F = f0 + (1. - f0) * exp2((-5.55473*dotLH-6.98316)*dotLH);
|
||||||
|
float k2 = .25 * r;
|
||||||
|
|
||||||
|
return dotNL * D * F / (dotLH*dotLH*(1.0-k2)+k2);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// #undef BASIC_SHADOW_FILTER
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float ComputeShadowMap(inout vec3 directLightColor, vec3 playerPos, float maxDistFade, float noise){
|
||||||
|
|
||||||
|
if(maxDistFade <= 0.0) return 1.0;
|
||||||
|
|
||||||
|
// setup shadow projection
|
||||||
|
vec3 projectedShadowPosition = mat3(shadowModelView) * playerPos + shadowModelView[3].xyz;
|
||||||
|
projectedShadowPosition = diagonal3(shadowProjection) * projectedShadowPosition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
// un-distort
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(projectedShadowPosition.xy);
|
||||||
|
projectedShadowPosition.xy *= distortFactor;
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// hamburger
|
||||||
|
projectedShadowPosition = projectedShadowPosition * vec3(0.5,0.5,0.5/6.0) + vec3(0.5);
|
||||||
|
|
||||||
|
float shadowmap = 0.0;
|
||||||
|
vec3 translucentTint = vec3(0.0);
|
||||||
|
|
||||||
|
#ifndef HAND
|
||||||
|
projectedShadowPosition.z -= 0.0001;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined ENTITIES
|
||||||
|
projectedShadowPosition.z -= 0.0002;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BASIC_SHADOW_FILTER
|
||||||
|
int samples = int(SHADOW_FILTER_SAMPLE_COUNT * 0.5);
|
||||||
|
float rdMul = 14.0*distortFactor*d0*k/shadowMapResolution;
|
||||||
|
|
||||||
|
for(int i = 0; i < samples; i++){
|
||||||
|
// vec2 offsetS = tapLocation_simple(i, 7, 9, noise) * 0.5;
|
||||||
|
vec2 offsetS = CleanSample(i, samples - 1, noise) * 0.3;
|
||||||
|
projectedShadowPosition.xy += rdMul*offsetS;
|
||||||
|
#else
|
||||||
|
int samples = 1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
|
||||||
|
// determine when opaque shadows are overlapping translucent shadows by getting the difference of opaque depth and translucent depth
|
||||||
|
float shadowDepthDiff = pow(clamp((shadow2D(shadowtex1, projectedShadowPosition).x - projectedShadowPosition.z) * 2.0,0.0,1.0),2.0);
|
||||||
|
|
||||||
|
// get opaque shadow data to get opaque data from translucent shadows.
|
||||||
|
float opaqueShadow = shadow2D(shadowtex0, projectedShadowPosition).x;
|
||||||
|
shadowmap += max(opaqueShadow, shadowDepthDiff);
|
||||||
|
|
||||||
|
// get translucent shadow data
|
||||||
|
vec4 translucentShadow = texture2D(shadowcolor0, projectedShadowPosition.xy);
|
||||||
|
|
||||||
|
// this curve simply looked the nicest. it has no other meaning.
|
||||||
|
float shadowAlpha = pow(1.0 - pow(translucentShadow.a,5.0),0.2);
|
||||||
|
|
||||||
|
// normalize the color to remove luminance, and keep the hue. remove all opaque color.
|
||||||
|
// mulitply shadow alpha to shadow color, but only on surfaces facing the lightsource. this is a tradeoff to protect subsurface scattering's colored shadow tint from shadow bias on the back of the caster.
|
||||||
|
translucentShadow.rgb = max(normalize(translucentShadow.rgb + 0.0001), max(opaqueShadow, 1.0-shadowAlpha)) * shadowAlpha;
|
||||||
|
|
||||||
|
// make it such that full alpha areas that arent in a shadow have a value of 1.0 instead of 0.0
|
||||||
|
translucentTint += mix(translucentShadow.rgb, vec3(1.0), opaqueShadow*shadowDepthDiff);
|
||||||
|
|
||||||
|
#else
|
||||||
|
shadowmap += shadow2D(shadow, projectedShadowPosition).x;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BASIC_SHADOW_FILTER
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
// tint the lightsource color with the translucent shadow color
|
||||||
|
directLightColor *= mix(vec3(1.0), translucentTint.rgb / samples, maxDistFade);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return mix(1.0, shadowmap / samples, maxDistFade);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
void convertHandDepth(inout float depth) {
|
||||||
|
float ndcDepth = depth * 2.0 - 1.0;
|
||||||
|
ndcDepth /= MC_HAND_DEPTH;
|
||||||
|
depth = ndcDepth * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
void Emission(
|
||||||
|
inout vec3 Lighting,
|
||||||
|
vec3 Albedo,
|
||||||
|
float Emission,
|
||||||
|
float exposure
|
||||||
|
){
|
||||||
|
float autoBrightnessAdjust = mix(5.0, 100.0, clamp(exp(-10.0*exposure),0.0,1.0));
|
||||||
|
if( Emission < 254.5/255.0) Lighting = mix(Lighting, Albedo * Emissive_Brightness * autoBrightnessAdjust * 0.1, pow(Emission, Emissive_Curve)); // old method.... idk why
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
void frisvad(in vec3 n, out vec3 f, out vec3 r){
|
||||||
|
if(n.z < -0.9) {
|
||||||
|
f = vec3(0.,-1,0);
|
||||||
|
r = vec3(-1, 0, 0);
|
||||||
|
} else {
|
||||||
|
float a = 1./(1.+n.z);
|
||||||
|
float b = -n.x*n.y*a;
|
||||||
|
f = vec3(1. - n.x*n.x*a, b, -n.x) ;
|
||||||
|
r = vec3(b, 1. - n.y*n.y*a , -n.y);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
mat3 CoordBase(vec3 n){
|
||||||
|
vec3 x,y;
|
||||||
|
frisvad(n,x,y);
|
||||||
|
return mat3(x,y,n);
|
||||||
|
}
|
||||||
|
vec2 R2_samples(int n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
float fma(float a,float b,float c){
|
||||||
|
return a * b + c;
|
||||||
|
}
|
||||||
|
//// thank you Zombye | the paper: https://ggx-research.github.io/publication/2023/06/09/publication-ggx.html
|
||||||
|
vec3 SampleVNDFGGX(
|
||||||
|
vec3 viewerDirection, // Direction pointing towards the viewer, oriented such that +Z corresponds to the surface normal
|
||||||
|
vec2 alpha, // Roughness parameter along X and Y of the distribution
|
||||||
|
float xy // Pair of uniformly distributed numbers in [0, 1)
|
||||||
|
) {
|
||||||
|
// alpha *= alpha;
|
||||||
|
// Transform viewer direction to the hemisphere configuration
|
||||||
|
viewerDirection = normalize(vec3(alpha * viewerDirection.xy, viewerDirection.z));
|
||||||
|
|
||||||
|
// Sample a reflection direction off the hemisphere
|
||||||
|
const float tau = 6.2831853; // 2 * pi
|
||||||
|
float phi = tau * xy;
|
||||||
|
|
||||||
|
float cosTheta = fma(1.0 - xy, 1.0 + viewerDirection.z, -viewerDirection.z) ;
|
||||||
|
float sinTheta = sqrt(clamp(1.0 - cosTheta * cosTheta, 0.0, 1.0));
|
||||||
|
|
||||||
|
// xonk note, i dont know what im doing but this kinda does what i want so whatever
|
||||||
|
float attemptTailClamp = clamp(sinTheta,max(cosTheta-0.25,0), cosTheta);
|
||||||
|
float attemptTailClamp2 = clamp(cosTheta,max(sinTheta-0.25,0), sinTheta);
|
||||||
|
|
||||||
|
vec3 reflected = vec3(vec2(cos(phi), sin(phi)) * attemptTailClamp2, attemptTailClamp);
|
||||||
|
// vec3 reflected = vec3(vec2(cos(phi), sin(phi)) * sinTheta, cosTheta);
|
||||||
|
|
||||||
|
// Evaluate halfway direction
|
||||||
|
// This gives the normal on the hemisphere
|
||||||
|
vec3 halfway = reflected + viewerDirection;
|
||||||
|
|
||||||
|
// Transform the halfway direction back to hemiellispoid configuation
|
||||||
|
// This gives the final sampled normal
|
||||||
|
return normalize(vec3(alpha * halfway.xy, halfway.z));
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
/* RENDERTARGETS:2,7,11,14 */
|
||||||
|
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) {
|
||||||
|
|
||||||
|
vec3 FragCoord = gl_FragCoord.xyz;
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
convertHandDepth(FragCoord.z);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 tempOffset = offsets[framemod8];
|
||||||
|
|
||||||
|
vec3 viewPos = toScreenSpace(FragCoord*vec3(texelSize/RENDER_SCALE,1.0)-vec3(vec2(tempOffset)*texelSize*0.5, 0.0));
|
||||||
|
|
||||||
|
vec3 feetPlayerPos = mat3(gbufferModelViewInverse) * viewPos;
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
//////////////////////////////// MATERIAL MASKS ////////////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
float MATERIALS = normalMat.w;
|
||||||
|
|
||||||
|
// 1.0 = water mask
|
||||||
|
// 0.9 = entity mask
|
||||||
|
// 0.8 = reflective entities
|
||||||
|
// 0.7 = reflective blocks
|
||||||
|
// 0.1 = hand mask
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
MATERIALS = 0.1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// bool isHand = abs(MATERIALS - 0.1) < 0.01;
|
||||||
|
bool isWater = MATERIALS > 0.99;
|
||||||
|
bool isReflectiveEntity = abs(MATERIALS - 0.8) < 0.01;
|
||||||
|
bool isReflective = abs(MATERIALS - 0.7) < 0.01 || isWater || isReflectiveEntity;
|
||||||
|
bool isEntity = abs(MATERIALS - 0.9) < 0.01 || isReflectiveEntity;
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
/////////////////////////////////// ALBEDO /////////////////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
gl_FragData[0] = texture2D(texture, lmtexcoord.xy, Texture_MipMap_Bias) * color;
|
||||||
|
|
||||||
|
float UnchangedAlpha = gl_FragData[0].a;
|
||||||
|
|
||||||
|
#ifdef WhiteWorld
|
||||||
|
gl_FragData[0].rgb = vec3(0.5);
|
||||||
|
gl_FragData[0].a = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 Albedo = toLinear(gl_FragData[0].rgb);
|
||||||
|
|
||||||
|
#ifndef WhiteWorld
|
||||||
|
#ifdef Vanilla_like_water
|
||||||
|
if (isWater) Albedo *= sqrt(luma(Albedo));
|
||||||
|
#else
|
||||||
|
if (isWater){
|
||||||
|
Albedo = vec3(0.0);
|
||||||
|
gl_FragData[0].a = 1.0/255.0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef ENTITIES
|
||||||
|
Albedo.rgb = mix(Albedo.rgb, entityColor.rgb, clamp(entityColor.a*1.5,0,1));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec4 GLASS_TINT_COLORS = vec4(Albedo, UnchangedAlpha);
|
||||||
|
|
||||||
|
#ifdef BIOME_TINT_WATER
|
||||||
|
if (isWater) GLASS_TINT_COLORS.rgb = toLinear(color.rgb);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
//////////////////////////////// NORMALS ///////////////////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
vec3 normal = normalMat.xyz; // in viewSpace
|
||||||
|
vec3 worldSpaceNormal = viewToWorld(normal).xyz;
|
||||||
|
vec2 TangentNormal = vec2(0); // for refractions
|
||||||
|
|
||||||
|
vec3 tangent2 = normalize(cross(tangent.rgb,normal)*tangent.w);
|
||||||
|
mat3 tbnMatrix = mat3(tangent.x, tangent2.x, normal.x,
|
||||||
|
tangent.y, tangent2.y, normal.y,
|
||||||
|
tangent.z, tangent2.z, normal.z);
|
||||||
|
|
||||||
|
vec3 NormalTex = vec3(texture2D(normals, lmtexcoord.xy, Texture_MipMap_Bias).xy,0.0);
|
||||||
|
NormalTex.xy = NormalTex.xy*2.0-1.0;
|
||||||
|
NormalTex.z = clamp(sqrt(1.0 - dot(NormalTex.xy, NormalTex.xy)),0.0,1.0) ;
|
||||||
|
|
||||||
|
// tangent space normals for refraction
|
||||||
|
TangentNormal = NormalTex.xy*0.5+0.5;
|
||||||
|
|
||||||
|
#ifndef HAND
|
||||||
|
if (isWater){
|
||||||
|
vec3 posxz = (mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz) + cameraPosition;
|
||||||
|
|
||||||
|
// make the waves flow in the direction the water faces, except for perfectly up facing parts.
|
||||||
|
if(abs(worldSpaceNormal.y) < 0.9995) posxz.xz -= (posxz.y + frameTimeCounter*3 * WATER_WAVE_SPEED) * normalize(worldSpaceNormal.xz) ;
|
||||||
|
|
||||||
|
posxz.xyz = getParallaxDisplacement(posxz);
|
||||||
|
vec3 bump = normalize(getWaveNormal(posxz, false));
|
||||||
|
|
||||||
|
float bumpmult = 10.0 * WATER_WAVE_STRENGTH;
|
||||||
|
bump = bump * vec3(bumpmult, bumpmult, bumpmult) + vec3(0.0f, 0.0f, 1.0f - bumpmult);
|
||||||
|
|
||||||
|
NormalTex.xyz = bump;
|
||||||
|
|
||||||
|
// tangent space normals for refraction
|
||||||
|
TangentNormal = (bump.xy/3.0)*0.5+0.5;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
normal = applyBump(tbnMatrix, NormalTex.xyz, 1.0);
|
||||||
|
|
||||||
|
gl_FragData[2] = vec4(encodeVec2(TangentNormal), encodeVec2(GLASS_TINT_COLORS.rg), encodeVec2(GLASS_TINT_COLORS.ba), 1.0);
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
//////////////////////////////// SPECULARS /////////////////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
vec3 SpecularTex = texture2D(specular, lmtexcoord.xy, Texture_MipMap_Bias).rga;
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
//////////////////////////////// DIFFUSE LIGHTING //////////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
vec2 lightmap = lmtexcoord.zw;
|
||||||
|
|
||||||
|
// lightmap.y = 1.0;
|
||||||
|
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
lightmap.y = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef Hand_Held_lights
|
||||||
|
lightmap.x = max(lightmap.x, HELD_ITEM_BRIGHTNESS*clamp( pow(max(1.0-length(viewPos)/HANDHELD_LIGHT_RANGE,0.0),1.5),0.0,1.0));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 Indirect_lighting = vec3(0.0);
|
||||||
|
vec3 MinimumLightColor = vec3(1.0);
|
||||||
|
if(isEyeInWater == 1) MinimumLightColor = vec3(10.0);
|
||||||
|
|
||||||
|
vec3 Direct_lighting = vec3(0.0);
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
vec3 DirectLightColor = lightCol.rgb/80.0;
|
||||||
|
float NdotL = clamp(dot(normal, normalize(WsunVec*mat3(gbufferModelViewInverse))),0.0,1.0); NdotL = clamp((-15 + NdotL*255.0) / 240.0 ,0.0,1.0);
|
||||||
|
float Shadows = 1.0;
|
||||||
|
|
||||||
|
float shadowMapFalloff = smoothstep(0.0, 1.0, min(max(1.0 - length(feetPlayerPos) / (shadowDistance+16),0.0)*5.0,1.0));
|
||||||
|
float shadowMapFalloff2 = smoothstep(0.0, 1.0, min(max(1.0 - length(feetPlayerPos) / shadowDistance,0.0)*5.0,1.0));
|
||||||
|
|
||||||
|
float LM_shadowMapFallback = min(max(lightmap.y-0.8, 0.0) * 25,1.0);
|
||||||
|
|
||||||
|
vec3 shadowPlayerPos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz;
|
||||||
|
|
||||||
|
Shadows = ComputeShadowMap(DirectLightColor, shadowPlayerPos, shadowMapFalloff, blueNoise());
|
||||||
|
|
||||||
|
Shadows = mix(LM_shadowMapFallback, Shadows, shadowMapFalloff2);
|
||||||
|
|
||||||
|
Shadows *= pow(GetCloudShadow(feetPlayerPos),3);
|
||||||
|
|
||||||
|
Direct_lighting = DirectLightColor * NdotL * Shadows;
|
||||||
|
|
||||||
|
vec3 AmbientLightColor = averageSkyCol_Clouds/30.0;
|
||||||
|
|
||||||
|
vec3 ambientcoefs = worldSpaceNormal / dot(abs(worldSpaceNormal), vec3(1.0));
|
||||||
|
float SkylightDir = ambientcoefs.y*1.5;
|
||||||
|
|
||||||
|
float skylight = max(pow(viewToWorld(flatnormal).y*0.5+0.5,0.1) + SkylightDir, 0.2);
|
||||||
|
AmbientLightColor *= skylight;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef NETHER_SHADER
|
||||||
|
// vec3 AmbientLightColor = skyCloudsFromTexLOD2(worldSpaceNormal, colortex4, 6).rgb / 15.0;
|
||||||
|
|
||||||
|
// vec3 up = skyCloudsFromTexLOD2(vec3( 0, 1, 0), colortex4, 6).rgb/ 30.0;
|
||||||
|
// vec3 down = skyCloudsFromTexLOD2(vec3( 0,-1, 0), colortex4, 6).rgb/ 30.0;
|
||||||
|
|
||||||
|
// up *= pow( max( worldSpaceNormal.y, 0), 2);
|
||||||
|
// down *= pow( max(-worldSpaceNormal.y, 0), 2);
|
||||||
|
// AmbientLightColor += up + down;
|
||||||
|
|
||||||
|
vec3 AmbientLightColor = vec3(0.1);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
float vortexBounds = clamp(vortexBoundRange - length(feetPlayerPos+cameraPosition), 0.0,1.0);
|
||||||
|
vec3 lightPos = LightSourcePosition(feetPlayerPos+cameraPosition, cameraPosition,vortexBounds);
|
||||||
|
|
||||||
|
|
||||||
|
float lightningflash = texelFetch2D(colortex4,ivec2(1,1),0).x/150.0;
|
||||||
|
vec3 lightColors = LightSourceColors(vortexBounds, lightningflash);
|
||||||
|
|
||||||
|
float NdotL = clamp(dot(worldSpaceNormal, normalize(-lightPos))*0.5+0.5,0.0,1.0);
|
||||||
|
|
||||||
|
NdotL *= NdotL;
|
||||||
|
|
||||||
|
Direct_lighting = lightColors * endFogPhase(lightPos) * NdotL;
|
||||||
|
|
||||||
|
vec3 AmbientLightColor = vec3(0.5,0.75,1.0) * 0.9 + 0.1;
|
||||||
|
AmbientLightColor *= clamp(1.5 + dot(worldSpaceNormal, normalize(feetPlayerPos))*0.5,0,2);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
vec3 normalOffset = 0.5*worldSpaceNormal;
|
||||||
|
|
||||||
|
#if LPV_NORMAL_STRENGTH > 0
|
||||||
|
vec3 texNormalOffset = -normalOffset + viewToWorld(normal);
|
||||||
|
normalOffset = mix(normalOffset, texNormalOffset, (LPV_NORMAL_STRENGTH*0.01));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 lpvPos = GetLpvPosition(feetPlayerPos) + normalOffset;
|
||||||
|
#else
|
||||||
|
const vec3 lpvPos = vec3(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Indirect_lighting = DoAmbientLightColor(feetPlayerPos, lpvPos, AmbientLightColor, MinimumLightColor, vec3(TORCH_R,TORCH_G,TORCH_B), lightmap.xy, exposure);
|
||||||
|
|
||||||
|
vec3 FinalColor = (Indirect_lighting + Direct_lighting) * Albedo;
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
//////////////////////////////// SPECULAR LIGHTING /////////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#ifdef DAMAGE_BLOCK_EFFECT
|
||||||
|
#undef WATER_REFLECTIONS
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// #ifdef ENTITIES
|
||||||
|
// #undef WATER_BACKGROUND_SPECULAR
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
#undef WATER_SUN_SPECULAR
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef WATER_REFLECTIONS
|
||||||
|
// vec2 SpecularTex = texture2D(specular, lmtexcoord.xy, Texture_MipMap_Bias).rg;
|
||||||
|
|
||||||
|
// if nothing is chosen, no smoothness and no reflectance
|
||||||
|
vec2 specularValues = vec2(1.0, 0.0);
|
||||||
|
|
||||||
|
// hardcode specular values for select blocks like glass, water, and slime
|
||||||
|
if(isReflective) specularValues = vec2(1.0, 0.02);
|
||||||
|
|
||||||
|
// detect if the specular texture is used, if it is, overwrite hardcoded values
|
||||||
|
if(SpecularTex.r > 0.0 && SpecularTex.g <= 1.0) specularValues = SpecularTex.rg;
|
||||||
|
|
||||||
|
float roughness = pow(1.0-specularValues.r,2.0);
|
||||||
|
float f0 = isReflective ? max(specularValues.g, 0.02) : specularValues.g;
|
||||||
|
|
||||||
|
#ifdef HAND
|
||||||
|
f0 = max(specularValues.g, 0.02);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// f0 = SpecularTex.g;
|
||||||
|
// roughness = pow(1.0-specularValues.r,2.0);
|
||||||
|
// f0 = 0.9;
|
||||||
|
// roughness = 0.0;
|
||||||
|
|
||||||
|
vec3 Metals = f0 > 229.5/255.0 ? normalize(Albedo+1e-7) * (dot(Albedo,vec3(0.21, 0.72, 0.07)) * 0.7 + 0.3) : vec3(1.0);
|
||||||
|
|
||||||
|
// make sure zero alpha is not forced to be full alpha by fresnel on items with funny normal padding
|
||||||
|
if(UnchangedAlpha <= 0.0 && !isReflective) f0 = 0.0;
|
||||||
|
|
||||||
|
if (f0 > 0.0){
|
||||||
|
|
||||||
|
if(isReflective) f0 = max(f0, 0.02);
|
||||||
|
|
||||||
|
vec3 Reflections_Final = vec3(0.0);
|
||||||
|
vec4 Reflections = vec4(0.0);
|
||||||
|
vec3 BackgroundReflection = FinalColor;
|
||||||
|
vec3 SunReflection = vec3(0.0);
|
||||||
|
float indoors = pow(1.0-pow(1.0-min(max(lightmap.y-0.6,0.0)*3.0,1.0),0.5),2.0);
|
||||||
|
|
||||||
|
vec3 reflectedVector = reflect(normalize(viewPos), normal);
|
||||||
|
float normalDotEye = dot(normal, normalize(viewPos));
|
||||||
|
|
||||||
|
float fresnel = pow(clamp(1.0 + normalDotEye, 0.0, 1.0),5.0);
|
||||||
|
|
||||||
|
/*
|
||||||
|
int seed = (frameCounter%40000) + frameCounter*2;
|
||||||
|
float noise = fract(R2_samples(seed).y + (1-blueNoise()));
|
||||||
|
mat3 Basis = CoordBase(viewToWorld(normal));
|
||||||
|
vec3 ViewDir = -normalize(feetPlayerPos)*Basis;
|
||||||
|
vec3 SamplePoints = SampleVNDFGGX(ViewDir, vec2(roughness), noise);
|
||||||
|
vec3 Ln = reflect(-ViewDir, SamplePoints);
|
||||||
|
vec3 L = Basis * Ln;
|
||||||
|
fresnel = pow(clamp(1.0 + dot(-Ln, SamplePoints),0.0,1.0), 5.0);
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifdef SNELLS_WINDOW
|
||||||
|
// snells window looking thing
|
||||||
|
if(isEyeInWater == 1) fresnel = pow(clamp(1.5 + normalDotEye,0.0,1.0), 25.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
fresnel = mix(f0, 1.0, fresnel);
|
||||||
|
|
||||||
|
// Sun, Sky, and screen-space reflections
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
#ifdef WATER_SUN_SPECULAR
|
||||||
|
SunReflection = Direct_lighting * GGX(normal, -normalize(viewPos), WsunVec*mat3(gbufferModelViewInverse), max(roughness,0.035), f0) * Metals;
|
||||||
|
#endif
|
||||||
|
#ifdef WATER_BACKGROUND_SPECULAR
|
||||||
|
if(isEyeInWater == 0 && !isReflectiveEntity) BackgroundReflection = skyCloudsFromTex(mat3(gbufferModelViewInverse) * reflectedVector, colortex4).rgb / 30.0 * Metals;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(isEyeInWater == 1 && isWater) BackgroundReflection.rgb = exp(-8.0 * vec3(Water_Absorb_R, Water_Absorb_G, Water_Absorb_B)) * clamp(WsunVec.y*lightCol.a,0,1);
|
||||||
|
#else
|
||||||
|
#ifdef WATER_BACKGROUND_SPECULAR
|
||||||
|
if(isEyeInWater == 0) BackgroundReflection = skyCloudsFromTexLOD2(mat3(gbufferModelViewInverse) * reflectedVector, colortex4, 0).rgb / 30.0 * Metals;
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef SCREENSPACE_REFLECTIONS
|
||||||
|
float reflectLength = 0.0;
|
||||||
|
vec3 rtPos = rayTrace(reflectedVector, viewPos.xyz, interleaved_gradientNoise_temporal(), fresnel, isEyeInWater == 1,reflectLength);
|
||||||
|
if (rtPos.z < 1.0){
|
||||||
|
vec3 previousPosition = mat3(gbufferModelViewInverse) * toScreenSpace(rtPos) + gbufferModelViewInverse[3].xyz + cameraPosition-previousCameraPosition;
|
||||||
|
previousPosition = mat3(gbufferPreviousModelView) * previousPosition + gbufferPreviousModelView[3].xyz;
|
||||||
|
previousPosition.xy = projMAD(gbufferPreviousProjection, previousPosition).xy / -previousPosition.z * 0.5 + 0.5;
|
||||||
|
if (previousPosition.x > 0.0 && previousPosition.y > 0.0 && previousPosition.x < 1.0 && previousPosition.x < 1.0) {
|
||||||
|
Reflections.a = 1.0;
|
||||||
|
Reflections.rgb = texture2D(colortex5, previousPosition.xy).rgb * Metals;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float visibilityFactor = clamp(exp2((pow(roughness,3.0) / f0) * -4),0,1);
|
||||||
|
|
||||||
|
Reflections_Final = mix(mix(FinalColor, BackgroundReflection, indoors), Reflections.rgb, Reflections.a) * fresnel * visibilityFactor;
|
||||||
|
Reflections_Final += SunReflection;
|
||||||
|
|
||||||
|
//correct alpha channel with fresnel
|
||||||
|
float alpha0 = gl_FragData[0].a;
|
||||||
|
|
||||||
|
gl_FragData[0].a = -gl_FragData[0].a * fresnel + gl_FragData[0].a + fresnel;
|
||||||
|
|
||||||
|
// prevent reflections from being darkened by buffer blending
|
||||||
|
gl_FragData[0].rgb = clamp(FinalColor / gl_FragData[0].a*alpha0*(1.0-fresnel) * 0.1 + Reflections_Final / gl_FragData[0].a * 0.1,0.0,65100.0);
|
||||||
|
|
||||||
|
if (gl_FragData[0].r > 65000.) gl_FragData[0].rgba = vec4(0.0);
|
||||||
|
|
||||||
|
} else {
|
||||||
|
gl_FragData[0].rgb = FinalColor*0.1;
|
||||||
|
}
|
||||||
|
|
||||||
|
#else
|
||||||
|
gl_FragData[0].rgb = FinalColor*0.1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if EMISSIVE_TYPE == 2 || EMISSIVE_TYPE == 3
|
||||||
|
Emission(gl_FragData[0].rgb, Albedo, SpecularTex.b, exposure);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined DISTANT_HORIZONS && defined DH_OVERDRAW_PREVENTION && !defined HAND
|
||||||
|
bool WATER = texture2D(colortex7, gl_FragCoord.xy*texelSize).a > 0.0 && length(feetPlayerPos) > far-16*4 && texture2D(depthtex1, gl_FragCoord.xy*texelSize).x >= 1.0;
|
||||||
|
|
||||||
|
if(WATER) gl_FragData[0].a = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAND
|
||||||
|
gl_FragData[1] = vec4(Albedo, MATERIALS);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if DEBUG_VIEW == debug_DH_WATER_BLENDING
|
||||||
|
if(gl_FragCoord.x*texelSize.x < 0.47) gl_FragData[0] = vec4(0.0);
|
||||||
|
#endif
|
||||||
|
#if DEBUG_VIEW == debug_NORMALS
|
||||||
|
gl_FragData[0].rgb = normalize(normal.xyz) * 0.1;
|
||||||
|
#endif
|
||||||
|
#if DEBUG_VIEW == debug_INDIRECT
|
||||||
|
gl_FragData[0].rgb = Indirect_lighting* 0.1;
|
||||||
|
#endif
|
||||||
|
#if DEBUG_VIEW == debug_DIRECT
|
||||||
|
gl_FragData[0].rgb = Direct_lighting * 0.1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[3].a = encodeVec2(lightmap);
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,180 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/bokeh.glsl"
|
||||||
|
#include "/lib/items.glsl"
|
||||||
|
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
/*
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
This code is from Chocapic13' shaders
|
||||||
|
Read the terms of modification and sharing before changing something below please !
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
*/
|
||||||
|
|
||||||
|
varying vec4 lmtexcoord;
|
||||||
|
varying vec4 color;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
varying vec4 normalMat;
|
||||||
|
varying vec3 binormal;
|
||||||
|
varying vec4 tangent;
|
||||||
|
varying vec3 flatnormal;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
varying vec3 viewVector;
|
||||||
|
|
||||||
|
flat varying int glass;
|
||||||
|
|
||||||
|
attribute vec4 at_tangent;
|
||||||
|
attribute vec4 mc_Entity;
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
varying vec4 tangent_other;
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
// uniform float far;
|
||||||
|
uniform float aspectRatio;
|
||||||
|
uniform float viewHeight;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform int hideGUI;
|
||||||
|
uniform float screenBrightness;
|
||||||
|
|
||||||
|
uniform int heldItemId;
|
||||||
|
uniform int heldItemId2;
|
||||||
|
flat varying float HELD_ITEM_BRIGHTNESS;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
vec4 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return vec4(projMAD(gl_ProjectionMatrix, viewSpacePosition),-viewSpacePosition.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
// lmtexcoord.xy = (gl_MultiTexCoord0).xy;
|
||||||
|
lmtexcoord.xy = (gl_TextureMatrix[0] * gl_MultiTexCoord0).xy;
|
||||||
|
vec2 lmcoord = gl_MultiTexCoord1.xy / 240.0;
|
||||||
|
lmtexcoord.zw = lmcoord;
|
||||||
|
|
||||||
|
vec3 position = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz;
|
||||||
|
|
||||||
|
gl_Position = toClipSpace3(position);
|
||||||
|
|
||||||
|
|
||||||
|
HELD_ITEM_BRIGHTNESS = 0.0;
|
||||||
|
|
||||||
|
#ifdef Hand_Held_lights
|
||||||
|
if(heldItemId == ITEM_LIGHT_SOURCES || heldItemId2 == ITEM_LIGHT_SOURCES) HELD_ITEM_BRIGHTNESS = 0.9;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// 1.0 = water mask
|
||||||
|
// 0.9 = entity mask
|
||||||
|
// 0.8 = reflective entities
|
||||||
|
// 0.7 = reflective blocks
|
||||||
|
float mat = 0.0;
|
||||||
|
|
||||||
|
// water mask
|
||||||
|
if(mc_Entity.x == 8.0) {
|
||||||
|
mat = 1.0;
|
||||||
|
gl_Position.z -= 1e-4;
|
||||||
|
}
|
||||||
|
|
||||||
|
// translucent entities
|
||||||
|
#if defined ENTITIES || defined BLOCKENTITIES
|
||||||
|
mat = 0.9;
|
||||||
|
if (entityId == 1403) mat = 0.8;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// translucent blocks
|
||||||
|
if (mc_Entity.x >= 301 && mc_Entity.x <= 321) mat = 0.7;
|
||||||
|
|
||||||
|
tangent = vec4(normalize(gl_NormalMatrix *at_tangent.rgb),at_tangent.w);
|
||||||
|
|
||||||
|
normalMat = vec4(normalize(gl_NormalMatrix * gl_Normal), 1.0);
|
||||||
|
normalMat.a = mat;
|
||||||
|
|
||||||
|
vec3 tangent2 = normalize( gl_NormalMatrix *at_tangent.rgb);
|
||||||
|
binormal = normalize(cross(tangent2.rgb,normalMat.xyz)*at_tangent.w);
|
||||||
|
|
||||||
|
mat3 tbnMatrix = mat3(tangent2.x, binormal.x, normalMat.x,
|
||||||
|
tangent2.y, binormal.y, normalMat.y,
|
||||||
|
tangent2.z, binormal.z, normalMat.z);
|
||||||
|
|
||||||
|
flatnormal = normalMat.xyz;
|
||||||
|
|
||||||
|
viewVector = ( gl_ModelViewMatrix * gl_Vertex).xyz;
|
||||||
|
viewVector = normalize(tbnMatrix * viewVector);
|
||||||
|
|
||||||
|
|
||||||
|
color = vec4(gl_Color.rgb, 1.0);
|
||||||
|
exposure = texelFetch2D(colortex4,ivec2(10,37),0).r;
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
lightCol.a = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
|
||||||
|
averageSkyCol_Clouds = texelFetch2D(colortex4,ivec2(0,37),0).rgb;
|
||||||
|
|
||||||
|
WsunVec = lightCol.a * normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
// WsunVec = normalize(LightDir);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w;
|
||||||
|
#endif
|
||||||
|
#ifdef TAA
|
||||||
|
gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
vec2 jitter = clamp(jitter_offsets[frameCounter % 64], -1.0, 1.0);
|
||||||
|
jitter = rotate(radians(float(frameCounter))) * jitter;
|
||||||
|
jitter.y *= aspectRatio;
|
||||||
|
jitter.x *= DOF_ANAMORPHIC_RATIO;
|
||||||
|
|
||||||
|
#if MANUAL_FOCUS == -2
|
||||||
|
float focusMul = 0;
|
||||||
|
#elif MANUAL_FOCUS == -1
|
||||||
|
float focusMul = gl_Position.z - mix(pow(512.0, screenBrightness), 512.0 * screenBrightness, 0.25);
|
||||||
|
#else
|
||||||
|
float focusMul = gl_Position.z - MANUAL_FOCUS;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 totalOffset = (jitter * JITTER_STRENGTH) * focusMul * 1e-2;
|
||||||
|
gl_Position.xy += hideGUI >= 1 ? totalOffset : vec2(0);
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,101 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
varying vec4 color;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
|
||||||
|
uniform sampler2D texture;
|
||||||
|
uniform sampler2D normals;
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
varying vec4 tangent;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
attribute vec4 at_tangent;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
|
||||||
|
//faster and actually more precise than pow 2.2
|
||||||
|
vec3 toLinear(vec3 sRGB){
|
||||||
|
return sRGB * (sRGB * (sRGB * 0.305306011 + 0.682171111) + 0.012522878);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 encode (vec3 n, vec2 lightmaps){
|
||||||
|
n.xy = n.xy / dot(abs(n), vec3(1.0));
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - abs(n.yx)) * sign(n.xy) : n.xy;
|
||||||
|
vec2 encn = clamp(n.xy * 0.5 + 0.5,-1.0,1.0);
|
||||||
|
|
||||||
|
return vec4(encn,vec2(lightmaps.x,lightmaps.y));
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
|
||||||
|
vec3 viewToWorld(vec3 viewPos) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPos;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
/* DRAWBUFFERS:2 */
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
vec4 Albedo = texture2D(texture, texcoord);
|
||||||
|
Albedo.rgb = toLinear(Albedo.rgb * color.rgb);
|
||||||
|
|
||||||
|
#if defined SPIDER_EYES || defined BEACON_BEAM || defined GLOWING
|
||||||
|
|
||||||
|
if(Albedo.a < 0.102 || dot(Albedo.rgb, vec3(0.33333)) < 1.0/255.0) { discard; return; }
|
||||||
|
|
||||||
|
float minimumBrightness = 0.5;
|
||||||
|
|
||||||
|
#ifdef BEACON_BEAM
|
||||||
|
minimumBrightness = 10.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float autoBrightnessAdjust = mix(minimumBrightness, 100.0, clamp(exp(-10.0*exposure),0.0,1.0));
|
||||||
|
|
||||||
|
#ifdef DISABLE_VANILLA_EMISSIVES
|
||||||
|
vec3 emissiveColor = vec3(0.0);
|
||||||
|
Albedo.a = 0.0;
|
||||||
|
#else
|
||||||
|
vec3 emissiveColor = Albedo.rgb * color.a * autoBrightnessAdjust;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(emissiveColor*0.1, Albedo.a * sqrt(color.a));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef ENCHANT_GLINT
|
||||||
|
float autoBrightnessAdjust = mix(0.1, 100.0, clamp(exp(-10.0*exposure),0.0,1.0));
|
||||||
|
|
||||||
|
Albedo.rgb = clamp(Albedo.rgb ,0.0,1.0); // for safety
|
||||||
|
|
||||||
|
#ifdef DISABLE_ENCHANT_GLINT
|
||||||
|
vec3 GlintColor = vec3(0.0);
|
||||||
|
Albedo.a = 0.0;
|
||||||
|
#else
|
||||||
|
vec3 GlintColor = Albedo.rgb * autoBrightnessAdjust * Emissive_Brightness;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(GlintColor*0.1, dot(Albedo.rgb,vec3(0.333)) * Albedo.a );
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,76 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
/*
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
This code is from Chocapic13' shaders
|
||||||
|
Read the terms of modification and sharing before changing something below please !
|
||||||
|
!! DO NOT REMOVE !!
|
||||||
|
*/
|
||||||
|
|
||||||
|
varying vec4 color;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
|
||||||
|
varying vec4 tangent;
|
||||||
|
varying vec4 normalMat;
|
||||||
|
attribute vec4 at_tangent;
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform int framemod8;
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
vec4 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return vec4(projMAD(gl_ProjectionMatrix, viewSpacePosition),-viewSpacePosition.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
color = gl_Color;
|
||||||
|
|
||||||
|
texcoord = (gl_TextureMatrix[0] * gl_MultiTexCoord0).st;
|
||||||
|
|
||||||
|
#if defined ENCHANT_GLINT || defined SPIDER_EYES || defined BEACON_BEAM
|
||||||
|
exposure = texelFetch2D(colortex4,ivec2(10,37),0).r;
|
||||||
|
|
||||||
|
vec3 position = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz;
|
||||||
|
gl_Position = toClipSpace3(position);
|
||||||
|
#else
|
||||||
|
gl_Position = ftransform();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef BEACON_BEAM
|
||||||
|
if(gl_Color.a < 1.0) gl_Position = vec4(10,10,10,0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef ENCHANT_GLINT
|
||||||
|
tangent = vec4(normalize(gl_NormalMatrix * at_tangent.rgb), at_tangent.w);
|
||||||
|
|
||||||
|
normalMat = vec4(normalize(gl_NormalMatrix * gl_Normal), 1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w;
|
||||||
|
#endif
|
||||||
|
#ifdef TAA
|
||||||
|
gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,540 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
flat varying vec2 TAA_Offset;
|
||||||
|
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform sampler2D colortex1;
|
||||||
|
uniform sampler2D colortex3; // Noise
|
||||||
|
uniform sampler2D colortex6; // Noise
|
||||||
|
uniform sampler2D colortex8; // Noise
|
||||||
|
uniform sampler2D colortex14; // Noise
|
||||||
|
uniform sampler2D colortex12; // Noise
|
||||||
|
uniform sampler2D colortex15; // Noise
|
||||||
|
|
||||||
|
uniform sampler2D shadow;
|
||||||
|
|
||||||
|
// #ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2D shadowtex0;
|
||||||
|
uniform sampler2D shadowtex1;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform int frameCounter;
|
||||||
|
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
|
||||||
|
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
|
||||||
|
uniform vec3 previousCameraPosition;
|
||||||
|
uniform mat4 gbufferPreviousProjection;
|
||||||
|
uniform mat4 gbufferPreviousModelView;
|
||||||
|
|
||||||
|
uniform mat4 shadowModelView;
|
||||||
|
uniform mat4 shadowProjection;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float aspectRatio;
|
||||||
|
uniform float viewHeight;
|
||||||
|
|
||||||
|
// uniform float far;
|
||||||
|
uniform float near;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
#define ffstep(x,y) clamp((y - x) * 1e35,0.0,1.0)
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return fragposition.xyz / fragposition.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec3 worldToView(vec3 worldPos) {
|
||||||
|
vec4 pos = vec4(worldPos, 0.0);
|
||||||
|
pos = gbufferModelView * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 tapLocation(int sampleNumber,int nb, float nbRot,float jitter,float distort)
|
||||||
|
{
|
||||||
|
float alpha = (sampleNumber+jitter)/nb;
|
||||||
|
float angle = jitter*6.28+alpha * nbRot * 6.28;
|
||||||
|
float sin_v, cos_v;
|
||||||
|
|
||||||
|
sin_v = sin(angle);
|
||||||
|
cos_v = cos(angle);
|
||||||
|
|
||||||
|
return vec2(cos_v, sin_v)*alpha;
|
||||||
|
}
|
||||||
|
vec2 tapLocation2(int sampleNumber, int nb, float jitter){
|
||||||
|
float alpha = (sampleNumber+jitter)/nb;
|
||||||
|
float angle = jitter*6.28 + alpha * 84.0 * 6.28;
|
||||||
|
|
||||||
|
float sin_v, cos_v;
|
||||||
|
|
||||||
|
sin_v = sin(angle);
|
||||||
|
cos_v = cos(angle);
|
||||||
|
|
||||||
|
return vec2(cos_v, sin_v)*sqrt(alpha);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 decode (vec2 encn){
|
||||||
|
vec3 n = vec3(0.0);
|
||||||
|
encn = encn * 2.0 - 1.0;
|
||||||
|
n.xy = abs(encn);
|
||||||
|
n.z = 1.0 - n.x - n.y;
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - n.yx) * sign(encn) : encn;
|
||||||
|
return clamp(normalize(n.xyz),-1.0,1.0);
|
||||||
|
}
|
||||||
|
vec2 decodeVec2(float a){
|
||||||
|
const vec2 constant1 = 65535. / vec2( 256., 65536.);
|
||||||
|
const float constant2 = 256. / 255.;
|
||||||
|
return fract( a * constant1 ) * constant2 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
float interleaved_gradientNoise_temporal(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+frameTimeCounter*51.9521);
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
|
||||||
|
float R2_dither(){
|
||||||
|
#ifdef TAA
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
#else
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
#endif
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
vec4 blueNoise(vec2 coord){
|
||||||
|
return texelFetch2D(colortex6, ivec2(coord )%512 , 0);
|
||||||
|
}
|
||||||
|
vec2 R2_samples(int n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
vec3 viewToWorld(vec3 viewPos) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPos;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
const float PI = 3.141592653589793238462643383279502884197169;
|
||||||
|
vec2 SpiralSample(
|
||||||
|
int samples, int totalSamples, float rotation, float Xi
|
||||||
|
){
|
||||||
|
Xi = max(Xi,0.0015);
|
||||||
|
|
||||||
|
float alpha = float(samples + Xi) * (1.0 / float(totalSamples));
|
||||||
|
|
||||||
|
float theta = (2.0 *3.14159265359) * alpha * rotation;
|
||||||
|
|
||||||
|
float r = sqrt(Xi);
|
||||||
|
float x = r * sin(theta);
|
||||||
|
float y = r * cos(theta);
|
||||||
|
|
||||||
|
return vec2(x, y);
|
||||||
|
}
|
||||||
|
vec2 CleanSample(
|
||||||
|
int samples, float totalSamples, float noise
|
||||||
|
){
|
||||||
|
|
||||||
|
// this will be used to make 1 full rotation of the spiral. the mulitplication is so it does nearly a single rotation, instead of going past where it started
|
||||||
|
float variance = noise * 0.897;
|
||||||
|
|
||||||
|
// for every sample input, it will have variance applied to it.
|
||||||
|
float variedSamples = float(samples) + variance;
|
||||||
|
|
||||||
|
// for every sample, the sample position must change its distance from the origin.
|
||||||
|
// otherwise, you will just have a circle.
|
||||||
|
float spiralShape = variedSamples / (totalSamples + variance);
|
||||||
|
|
||||||
|
float shape = 2.26;
|
||||||
|
float theta = variedSamples * (PI * shape);
|
||||||
|
|
||||||
|
float x = cos(theta) * spiralShape;
|
||||||
|
float y = sin(theta) * spiralShape;
|
||||||
|
|
||||||
|
return vec2(x, y);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
void convertHandDepth(inout float depth) {
|
||||||
|
float ndcDepth = depth * 2.0 - 1.0;
|
||||||
|
ndcDepth /= MC_HAND_DEPTH;
|
||||||
|
depth = ndcDepth * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
float convertHandDepth_2(in float depth, bool hand) {
|
||||||
|
if(!hand) return depth;
|
||||||
|
|
||||||
|
float ndcDepth = depth * 2.0 - 1.0;
|
||||||
|
ndcDepth /= MC_HAND_DEPTH;
|
||||||
|
return ndcDepth * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
vec2 SSAO(
|
||||||
|
vec3 viewPos, vec3 normal, bool hand, bool leaves, float noise
|
||||||
|
){
|
||||||
|
// if(hand) return vec2(1.0,0.0);
|
||||||
|
int samples = 7;
|
||||||
|
float occlusion = 0.0;
|
||||||
|
float sss = 0.0;
|
||||||
|
|
||||||
|
|
||||||
|
float dist = 1.0 + clamp(viewPos.z*viewPos.z/50.0,0,5); // shrink sample size as distance increases
|
||||||
|
float mulfov2 = gbufferProjection[1][1]/(3 * dist);
|
||||||
|
float maxR2 = viewPos.z*viewPos.z*mulfov2*2.0 * 5.0 / mix(4.0, 50.0, clamp(viewPos.z*viewPos.z - 0.1,0,1));
|
||||||
|
|
||||||
|
#ifdef Ambient_SSS
|
||||||
|
float maxR2_2 = viewPos.z;//*viewPos.z*mulfov2*2.*2./4.0;
|
||||||
|
|
||||||
|
float dist3 = clamp(1-exp( viewPos.z*viewPos.z / -50),0,1);
|
||||||
|
// if(leaves) maxR2_2 = 0.1;
|
||||||
|
// if(leaves) maxR2_2 = mix(10, maxR2_2, dist3);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 acc = -(TAA_Offset*(texelSize/2.0))*RENDER_SCALE ;
|
||||||
|
|
||||||
|
// vec2 BLUENOISE = blueNoise(gl_FragCoord.xy).rg;
|
||||||
|
|
||||||
|
int n = 0;
|
||||||
|
|
||||||
|
float leaf = leaves ? -0.5 : 0.0;
|
||||||
|
|
||||||
|
for (int i = 0; i < samples; i++) {
|
||||||
|
|
||||||
|
// vec2 sampleOffset = (SpiralSample(i, 7, 8 , noise)) * mulfov2 * clamp(0.05 + i*0.095, 0.0,0.3) ;
|
||||||
|
vec2 sampleOffset = CleanSample(i, samples - 1, noise) * mulfov2 * 0.3 ;
|
||||||
|
|
||||||
|
ivec2 offset = ivec2(gl_FragCoord.xy + sampleOffset*vec2(viewWidth,viewHeight*aspectRatio)*RENDER_SCALE);
|
||||||
|
|
||||||
|
if (offset.x >= 0 && offset.y >= 0 && offset.x < viewWidth*RENDER_SCALE.x && offset.y < viewHeight*RENDER_SCALE.y ) {
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float dhdepth = texelFetch2D(dhDepthTex1, offset,0).x;
|
||||||
|
#else
|
||||||
|
float dhdepth = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 t0 = toScreenSpace_DH((offset*texelSize+acc+0.5*texelSize) * (1.0/RENDER_SCALE), convertHandDepth_2(texelFetch2D(depthtex1, offset,0).x, hand), dhdepth);
|
||||||
|
|
||||||
|
vec3 vec = (t0.xyz - viewPos);
|
||||||
|
float dsquared = dot(vec, vec);
|
||||||
|
|
||||||
|
if (dsquared > 1e-5){
|
||||||
|
|
||||||
|
if( dsquared < maxR2){
|
||||||
|
float NdotV = clamp(dot(vec*inversesqrt(dsquared), normalize(normal)),0.,1.);
|
||||||
|
occlusion += NdotV * clamp(1.0-dsquared/maxR2,0.0,1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef Ambient_SSS
|
||||||
|
sss += clamp(leaf - dot(vec, normalize(normal)),0.0,1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
n += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return max(1.0 - vec2(occlusion, sss)/n, 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 encode (vec3 n, vec2 lightmaps){
|
||||||
|
n.xy = n.xy / dot(abs(n), vec3(1.0));
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - abs(n.yx)) * sign(n.xy) : n.xy;
|
||||||
|
vec2 encn = clamp(n.xy * 0.5 + 0.5,-1.0,1.0);
|
||||||
|
|
||||||
|
return vec4(encn,vec2(lightmaps.x,lightmaps.y));
|
||||||
|
}
|
||||||
|
|
||||||
|
//encoding by jodie
|
||||||
|
float encodeVec2(vec2 a){
|
||||||
|
const vec2 constant1 = vec2( 1., 256.) / 65535.;
|
||||||
|
vec2 temp = floor( a * 255. );
|
||||||
|
return temp.x*constant1.x+temp.y*constant1.y;
|
||||||
|
}
|
||||||
|
float encodeVec2(float x,float y){
|
||||||
|
return encodeVec2(vec2(x,y));
|
||||||
|
}
|
||||||
|
|
||||||
|
// #include "/lib/indirect_lighting_effects.glsl"
|
||||||
|
|
||||||
|
vec3 toClipSpace3Prev(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(gbufferPreviousProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 closestToCamera5taps(vec2 texcoord, sampler2D depth, bool hand)
|
||||||
|
{
|
||||||
|
vec2 du = vec2(texelSize.x*2., 0.0);
|
||||||
|
vec2 dv = vec2(0.0, texelSize.y*2.);
|
||||||
|
|
||||||
|
vec3 dtl = vec3(texcoord,0.) + vec3(-texelSize, texture2D(depth, texcoord - dv - du).x);
|
||||||
|
vec3 dtr = vec3(texcoord,0.) + vec3( texelSize.x, -texelSize.y, texture2D(depth, texcoord - dv + du).x);
|
||||||
|
vec3 dmc = vec3(texcoord,0.) + vec3( 0.0, 0.0, texture2D(depth, texcoord).x);
|
||||||
|
vec3 dbl = vec3(texcoord,0.) + vec3(-texelSize.x, texelSize.y, texture2D(depth, texcoord + dv - du).x);
|
||||||
|
vec3 dbr = vec3(texcoord,0.) + vec3( texelSize.x, texelSize.y, texture2D(depth, texcoord + dv + du).x);
|
||||||
|
|
||||||
|
if(hand){
|
||||||
|
convertHandDepth(dtl.z);
|
||||||
|
convertHandDepth(dtr.z);
|
||||||
|
convertHandDepth(dmc.z);
|
||||||
|
convertHandDepth(dbl.z);
|
||||||
|
convertHandDepth(dbr.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 dmin = dmc;
|
||||||
|
dmin = dmin.z > dtr.z ? dtr : dmin;
|
||||||
|
dmin = dmin.z > dtl.z ? dtl : dmin;
|
||||||
|
dmin = dmin.z > dbl.z ? dbl : dmin;
|
||||||
|
dmin = dmin.z > dbr.z ? dbr : dmin;
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
dmin.xy = dmin.xy/RENDER_SCALE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return dmin;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ld(float dist) {
|
||||||
|
return (2.0 * near) / (far + near - dist * (far - near));
|
||||||
|
}
|
||||||
|
float sampleDepth(sampler2D depthTex, vec2 texcoord, bool hand){
|
||||||
|
// return texture2D(depthTex, texcoord).r;
|
||||||
|
return convertHandDepth_2(texture2D(depthTex, texcoord).r, hand);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* RENDERTARGETS:3,14,12*/
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
float noise = R2_dither();
|
||||||
|
|
||||||
|
vec2 texcoord = gl_FragCoord.xy*texelSize;
|
||||||
|
|
||||||
|
float z = texture2D(depthtex1,texcoord).x;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float DH_depth1 = texture2D(dhDepthTex1,texcoord).x;
|
||||||
|
float swappedDepth = z >= 1.0 ? DH_depth1 : z;
|
||||||
|
#else
|
||||||
|
float DH_depth1 = 1.0;
|
||||||
|
float swappedDepth = z;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
vec4 SHADOWDATA = vec4(0.0);
|
||||||
|
|
||||||
|
vec4 data = texture2D(colortex1,texcoord);
|
||||||
|
vec4 dataUnpacked0 = vec4(decodeVec2(data.x),decodeVec2(data.y));
|
||||||
|
vec4 dataUnpacked1 = vec4(decodeVec2(data.z),decodeVec2(data.w));
|
||||||
|
vec3 normal = mat3(gbufferModelViewInverse) * clamp(worldToView( decode(dataUnpacked0.yw) ),-1.,1.);
|
||||||
|
vec2 lightmap = dataUnpacked1.yz;
|
||||||
|
|
||||||
|
|
||||||
|
gl_FragData[1] = vec4(0.0,0.0,0.0, texture2D(colortex14,floor(gl_FragCoord.xy)/VL_RENDER_RESOLUTION*texelSize+0.5*texelSize).a);
|
||||||
|
|
||||||
|
|
||||||
|
// bool lightningBolt = abs(dataUnpacked1.w-0.5) <0.01;
|
||||||
|
bool isLeaf = abs(dataUnpacked1.w-0.55) <0.01;
|
||||||
|
// bool translucent2 = abs(dataUnpacked1.w-0.6) <0.01; // Weak translucency
|
||||||
|
// bool translucent4 = abs(dataUnpacked1.w-0.65) <0.01; // Weak translucency
|
||||||
|
bool entities = abs(dataUnpacked1.w-0.45) < 0.01;
|
||||||
|
bool hand = abs(dataUnpacked1.w-0.75) < 0.01;
|
||||||
|
// bool blocklights = abs(dataUnpacked1.w-0.8) <0.01;
|
||||||
|
|
||||||
|
|
||||||
|
if(hand){
|
||||||
|
convertHandDepth(z);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 viewPos = toScreenSpace_DH(texcoord/RENDER_SCALE - TAA_Offset*texelSize*0.5, z, DH_depth1);
|
||||||
|
|
||||||
|
|
||||||
|
#if defined DENOISE_SSS_AND_SSAO && indirect_effect == 1
|
||||||
|
float depth = z;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float _near = near;
|
||||||
|
float _far = far*4.0;
|
||||||
|
if (depth >= 1.0) {
|
||||||
|
depth = DH_depth1;
|
||||||
|
_near = dhNearPlane;
|
||||||
|
_far = dhFarPlane;
|
||||||
|
}
|
||||||
|
|
||||||
|
depth = linearizeDepthFast(depth, _near, _far);
|
||||||
|
depth = depth / dhFarPlane;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(depth < 1.0)
|
||||||
|
gl_FragData[2] = vec4(vec3(0.0), depth * depth * 65000.0);
|
||||||
|
else
|
||||||
|
gl_FragData[2] = vec4(vec3(0.0), 65000.0);
|
||||||
|
|
||||||
|
|
||||||
|
vec3 FlatNormals = texture2D(colortex15,texcoord).rgb * 2.0 - 1.0;
|
||||||
|
|
||||||
|
if(z >= 1.0){
|
||||||
|
FlatNormals = worldToView(normal);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 SSAO_SSS = SSAO(viewPos, FlatNormals, hand, isLeaf, noise);
|
||||||
|
|
||||||
|
if(swappedDepth >= 1.0) SSAO_SSS = vec2(1.0,0.0);
|
||||||
|
|
||||||
|
gl_FragData[1].xy = SSAO_SSS;
|
||||||
|
#else
|
||||||
|
vec2 SSAO_SSS = vec2(1.0,0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float SpecularTex = texture2D(colortex8,texcoord).z;
|
||||||
|
float LabSSS = clamp((-64.0 + SpecularTex * 255.0) / 191.0 ,0.0,1.0);
|
||||||
|
|
||||||
|
float NdotL = clamp(dot(normal,WsunVec),0.0,1.0);
|
||||||
|
float vanillAO = clamp(texture2D(colortex15,texcoord).a,0.0,1.0) ;
|
||||||
|
|
||||||
|
float minshadowfilt = Min_Shadow_Filter_Radius;
|
||||||
|
float maxshadowfilt = Max_Shadow_Filter_Radius;
|
||||||
|
|
||||||
|
// if(lightmap.y < 0.1 && !entities){
|
||||||
|
// maxshadowfilt = mix(minshadowfilt, maxshadowfilt, vanillAO);
|
||||||
|
// }
|
||||||
|
|
||||||
|
#ifdef BASIC_SHADOW_FILTER
|
||||||
|
if (LabSSS > 0.0 && NdotL < 0.001){
|
||||||
|
minshadowfilt = 50;
|
||||||
|
// maxshadowfilt = 50;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (z < 1.0){
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(minshadowfilt, 0.1, 0.0, 0.0);
|
||||||
|
|
||||||
|
#ifdef Variable_Penumbra_Shadows
|
||||||
|
if (LabSSS > -1) {
|
||||||
|
|
||||||
|
vec3 feetPlayerPos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 projectedShadowPosition = mat3(shadowModelView) * feetPlayerPos + shadowModelView[3].xyz;
|
||||||
|
projectedShadowPosition = diagonal3(shadowProjection) * projectedShadowPosition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
//apply distortion
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(projectedShadowPosition.xy);
|
||||||
|
projectedShadowPosition.xy *= distortFactor;
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//do shadows only if on shadow map
|
||||||
|
// if (abs(projectedShadowPosition.x) < 1.0-1.5/shadowMapResolution && abs(projectedShadowPosition.y) < 1.0-1.5/shadowMapResolution && abs(projectedShadowPosition.z) < 6.0 || length(feetPlayerPos) < far){
|
||||||
|
const float threshMul = max(2048.0/shadowMapResolution*shadowDistance/128.0,0.95);
|
||||||
|
float distortThresh = (sqrt(1.0-NdotL*NdotL)/NdotL+0.7)/distortFactor;
|
||||||
|
float diffthresh = distortThresh/6000.0*threshMul;
|
||||||
|
projectedShadowPosition = projectedShadowPosition * vec3(0.5,0.5,0.5/6.0) + vec3(0.5,0.5,0.5);
|
||||||
|
|
||||||
|
float mult = maxshadowfilt;
|
||||||
|
float avgBlockerDepth = 0.0;
|
||||||
|
vec2 scales = vec2(0.0, Max_Filter_Depth);
|
||||||
|
float blockerCount = 0.0;
|
||||||
|
float rdMul = distortFactor*(1.0+mult)*d0*k/shadowMapResolution;
|
||||||
|
float diffthreshM = diffthresh*mult*d0*k/20.;
|
||||||
|
float avgDepth = 0.0;
|
||||||
|
|
||||||
|
for(int i = 0; i < VPS_Search_Samples; i++){
|
||||||
|
|
||||||
|
// vec2 offsetS = SpiralSample(i, 7, 8, noise) * 0.5;
|
||||||
|
vec2 offsetS = CleanSample(i, VPS_Search_Samples - 1, noise) * 0.5;
|
||||||
|
|
||||||
|
float weight = 3.0 + (i+noise) *rdMul/SHADOW_FILTER_SAMPLE_COUNT*shadowMapResolution*distortFactor/2.7;
|
||||||
|
|
||||||
|
float d = texelFetch2D(shadow, ivec2((projectedShadowPosition.xy+offsetS*rdMul)*shadowMapResolution),0).x;
|
||||||
|
float b = smoothstep(weight*diffthresh/2.0, weight*diffthresh, projectedShadowPosition.z - d);
|
||||||
|
|
||||||
|
blockerCount += b;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS_SHADOWMAP
|
||||||
|
avgDepth += max(projectedShadowPosition.z - d, 0.0)*10000.0;
|
||||||
|
#else
|
||||||
|
avgDepth += max(projectedShadowPosition.z - d, 0.0)*1000.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
avgBlockerDepth += d * b;
|
||||||
|
}
|
||||||
|
|
||||||
|
gl_FragData[0].g = avgDepth / VPS_Search_Samples;
|
||||||
|
gl_FragData[0].b = blockerCount / VPS_Search_Samples;
|
||||||
|
|
||||||
|
if (blockerCount >= 0.9){
|
||||||
|
avgBlockerDepth /= blockerCount;
|
||||||
|
float ssample = max(projectedShadowPosition.z - avgBlockerDepth,0.0)*1500.0;
|
||||||
|
gl_FragData[0].r = clamp(ssample, scales.x, scales.y)/(scales.y)*(mult-minshadowfilt)+minshadowfilt;
|
||||||
|
}
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,39 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
flat varying vec2 TAA_Offset;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float sunElevation;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
uniform int framemod8;
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
WsunVec = (float(sunElevation > 1e-5)*2-1.)*normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef TAA
|
||||||
|
TAA_Offset = offsets[framemod8];
|
||||||
|
#else
|
||||||
|
TAA_Offset = vec2(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*RENDER_SCALE*2.0-1.0;
|
||||||
|
#endif
|
||||||
|
}
|
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1,71 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
flat varying float Flashing;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
flat varying vec3 unsigned_WsunVec;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
flat varying vec2 TAA_Offset;
|
||||||
|
flat varying vec3 zMults;
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
|
||||||
|
// uniform float far;
|
||||||
|
uniform float near;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform float sunElevation;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
|
||||||
|
uniform int framemod8;
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
Flashing = texelFetch2D(colortex4,ivec2(1,1),0).x/150.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
zMults = vec3(1.0/(far * near),far+near,far-near);
|
||||||
|
|
||||||
|
lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
lightCol.a = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
|
||||||
|
averageSkyCol_Clouds = texelFetch2D(colortex4,ivec2(0,37),0).rgb;
|
||||||
|
|
||||||
|
WsunVec = lightCol.a*normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
unsigned_WsunVec = normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
|
||||||
|
exposure = texelFetch2D(colortex4,ivec2(10,37),0).r;
|
||||||
|
|
||||||
|
#ifdef TAA
|
||||||
|
TAA_Offset = offsets[framemod8];
|
||||||
|
#else
|
||||||
|
TAA_Offset = vec2(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*RENDER_SCALE*2.0-1.0;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,113 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
|
||||||
|
float w0(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*(a*(-a + 3.0) - 3.0) + 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
float w1(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*a*(3.0*a - 6.0) + 4.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
float w2(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*(a*(-3.0*a + 3.0) + 3.0) + 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
float w3(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*a*a);
|
||||||
|
}
|
||||||
|
|
||||||
|
float g0(float a)
|
||||||
|
{
|
||||||
|
return w0(a) + w1(a);
|
||||||
|
}
|
||||||
|
|
||||||
|
float g1(float a)
|
||||||
|
{
|
||||||
|
return w2(a) + w3(a);
|
||||||
|
}
|
||||||
|
|
||||||
|
float h0(float a)
|
||||||
|
{
|
||||||
|
return -1.0 + w1(a) / (w0(a) + w1(a));
|
||||||
|
}
|
||||||
|
|
||||||
|
float h1(float a)
|
||||||
|
{
|
||||||
|
return 1.0 + w3(a) / (w2(a) + w3(a));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 texture2D_bicubic(sampler2D tex, vec2 uv)
|
||||||
|
{
|
||||||
|
vec4 texelSize = vec4(texelSize,1.0/texelSize);
|
||||||
|
uv = uv*texelSize.zw;
|
||||||
|
vec2 iuv = floor( uv );
|
||||||
|
vec2 fuv = fract( uv );
|
||||||
|
|
||||||
|
float g0x = g0(fuv.x);
|
||||||
|
float g1x = g1(fuv.x);
|
||||||
|
float h0x = h0(fuv.x);
|
||||||
|
float h1x = h1(fuv.x);
|
||||||
|
float h0y = h0(fuv.y);
|
||||||
|
float h1y = h1(fuv.y);
|
||||||
|
|
||||||
|
vec2 p0 = (vec2(iuv.x + h0x, iuv.y + h0y) - 0.5) * texelSize.xy;
|
||||||
|
vec2 p1 = (vec2(iuv.x + h1x, iuv.y + h0y) - 0.5) * texelSize.xy;
|
||||||
|
vec2 p2 = (vec2(iuv.x + h0x, iuv.y + h1y) - 0.5) * texelSize.xy;
|
||||||
|
vec2 p3 = (vec2(iuv.x + h1x, iuv.y + h1y) - 0.5) * texelSize.xy;
|
||||||
|
|
||||||
|
return g0(fuv.y) * (g0x * texture2D(tex, p0) +
|
||||||
|
g1x * texture2D(tex, p1)) +
|
||||||
|
g1(fuv.y) * (g0x * texture2D(tex, p2) +
|
||||||
|
g1x * texture2D(tex, p3));
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:3 */
|
||||||
|
vec2 resScale = vec2(1920.,1080.)/max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
vec2 texcoord = ((gl_FragCoord.xy)*2.0 + 0.5)*texelSize;
|
||||||
|
|
||||||
|
#ifdef OLD_BLOOM
|
||||||
|
vec3 bloom = texture2D_bicubic(colortex3,texcoord/2.).rgb; //1/4 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/4.).rgb; //1/8 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/8.+vec2(0.25*resScale.x+2.5*texelSize.x,.0)).rgb; //1/16 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/16.+vec2(0.375*resScale.x+4.5*texelSize.x,.0)).rgb; //1/32 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/32.+vec2(0.4375*resScale.x+6.5*texelSize.x,.0)).rgb; //1/64 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/64.+vec2(0.46875*resScale.x+8.5*texelSize.x,.0)).rgb; //1/128 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/128.+vec2(0.484375*resScale.x+10.5*texelSize.x,.0)).rgb; //1/256 res
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = bloom * 2.0;
|
||||||
|
#else
|
||||||
|
|
||||||
|
float weights[7] = float[]( 1.0, 1.0/2.0, 1.0/3.0, 1.0/5.5, 1.0/8.0, 1.0/10.0, 1.0/12.0 );
|
||||||
|
// float weights[7] = float[]( 0.7, pow(0.5,2), pow(0.5,3), pow(0.5,4), pow(0.5,5), pow(0.5,6), pow(0.5,7) );
|
||||||
|
|
||||||
|
vec3 bloom = texture2D_bicubic(colortex3,texcoord/2.).rgb * weights[0]; //1/4 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/4.).rgb * weights[1]; //1/8 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/8.+vec2(0.25*resScale.x+2.5*texelSize.x,.0)).rgb * weights[2]; //1/16 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/16.+vec2(0.375*resScale.x+4.5*texelSize.x,.0)).rgb * weights[3]; //1/32 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/32.+vec2(0.4375*resScale.x+6.5*texelSize.x,.0)).rgb * weights[4]; //1/64 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/64.+vec2(0.46875*resScale.x+8.5*texelSize.x,.0)).rgb * weights[5]; //1/128 res
|
||||||
|
bloom += texture2D_bicubic(colortex6,texcoord/128.+vec2(0.484375*resScale.x+10.5*texelSize.x,.0)).rgb * weights[6]; //1/256 res
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = bloom * 3.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(gl_FragData[0].rgb,0.0,65000.);
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
//Improves performances and makes sure bloom radius stays the same at high resolution (>1080p)
|
||||||
|
vec2 clampedRes = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
gl_Position = ftransform();
|
||||||
|
//*0.51 to avoid errors when sampling outside since clearing is disabled
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*0.51/clampedRes*vec2(1920.0,1080.)*2.0-1.0;
|
||||||
|
}
|
|
@ -0,0 +1,217 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
flat varying vec4 exposure;
|
||||||
|
flat varying vec2 rodExposureDepth;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
|
||||||
|
const bool colortex5MipmapEnabled = true;
|
||||||
|
// uniform sampler2D colortex4;
|
||||||
|
uniform sampler2D colortex5;
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
// uniform sampler2D colortex6;
|
||||||
|
uniform sampler2D colortex7;
|
||||||
|
// uniform sampler2D colortex8; // specular
|
||||||
|
// uniform sampler2D colortex9; // specular
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
uniform float near;
|
||||||
|
uniform float aspectRatio;
|
||||||
|
uniform float far;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform float screenBrightness;
|
||||||
|
uniform vec4 Moon_Weather_properties; // R = cloud coverage G = fog density
|
||||||
|
uniform int hideGUI;
|
||||||
|
|
||||||
|
uniform int framemod8;
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
vec4 Weather_properties = Moon_Weather_properties;
|
||||||
|
|
||||||
|
#include "/lib/color_transforms.glsl"
|
||||||
|
#include "/lib/color_dither.glsl"
|
||||||
|
// #include "/lib/biome_specifics.glsl"
|
||||||
|
#include "/lib/bokeh.glsl"
|
||||||
|
|
||||||
|
float cdist(vec2 coord) {
|
||||||
|
return max(abs(coord.s-0.5),abs(coord.t-0.5))*2.0;
|
||||||
|
}
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
float ld(float depth) {
|
||||||
|
return (2.0 * near) / (far + near - depth * (far - near)); // (-depth * (far - near)) = (2.0 * near)/ld - far - near
|
||||||
|
}
|
||||||
|
|
||||||
|
// uniform float viewWidth;
|
||||||
|
// uniform float viewHeight;
|
||||||
|
|
||||||
|
// uniform sampler2D depthtex0;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
#endif
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
float bloomWeight(){
|
||||||
|
|
||||||
|
float weights[7] = float[]( 1.0, 1.0/2.0, 1.0/3.0, 1.0/5.5, 1.0/8.0, 1.0/10.0, 1.0/12.0 );
|
||||||
|
// float weights[7] = float[]( 0.7, pow(0.5,2), pow(0.5,3), pow(0.5,4), pow(0.5,5), pow(0.5,6), pow(0.5,7) );
|
||||||
|
|
||||||
|
float result = 0.0;
|
||||||
|
|
||||||
|
for ( int i = 0; i < 7; i++) {
|
||||||
|
result += weights[i];
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
#define linear_to_srgb(x) (pow(x, vec3(1.0/2.2)))
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:7 */
|
||||||
|
float vignette = (1.5-dot(texcoord-0.5,texcoord-0.5)*2.);
|
||||||
|
vec3 col = texture2D(colortex5,texcoord).rgb;
|
||||||
|
|
||||||
|
#if DOF_QUALITY >= 0
|
||||||
|
/*--------------------------------*/
|
||||||
|
float z = ld(texture2D(depthtex0, texcoord.st*RENDER_SCALE).r)*far;
|
||||||
|
#if MANUAL_FOCUS == -2
|
||||||
|
float focus = rodExposureDepth.y*far;
|
||||||
|
#elif MANUAL_FOCUS == -1
|
||||||
|
float focus = mix(pow(512.0, screenBrightness), 512.0 * screenBrightness, 0.25);
|
||||||
|
#elif MANUAL_FOCUS > 0
|
||||||
|
float focus = MANUAL_FOCUS;
|
||||||
|
#endif
|
||||||
|
#if DOF_QUALITY < 5
|
||||||
|
float pcoc = min(abs(aperture * (focal/100.0 * (z - focus)) / (z * (focus - focal/100.0))),texelSize.x*15.0);
|
||||||
|
#ifdef FAR_BLUR_ONLY
|
||||||
|
pcoc *= float(z > focus);
|
||||||
|
#endif
|
||||||
|
float noise = blueNoise()*6.28318530718;
|
||||||
|
mat2 noiseM = mat2( cos( noise ), -sin( noise ),
|
||||||
|
sin( noise ), cos( noise )
|
||||||
|
);
|
||||||
|
vec3 bcolor = vec3(0.);
|
||||||
|
float nb = 0.0;
|
||||||
|
vec2 bcoord = vec2(0.0);
|
||||||
|
/*--------------------------------*/
|
||||||
|
float dofLodLevel = pcoc * 200.0;
|
||||||
|
for ( int i = 0; i < BOKEH_SAMPLES; i++) {
|
||||||
|
bcolor += texture2DLod(colortex5, texcoord.xy + bokeh_offsets[i]*pcoc*vec2(DOF_ANAMORPHIC_RATIO,aspectRatio), dofLodLevel).rgb;
|
||||||
|
}
|
||||||
|
col = bcolor/BOKEH_SAMPLES;
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 clampedRes = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef OLD_BLOOM
|
||||||
|
vec3 bloom = texture2D(colortex3,texcoord/clampedRes*vec2(1920.,1080.)*BLOOM_QUALITY).rgb / 2.0 / 7.0;
|
||||||
|
float lightScat = clamp((BLOOM_STRENGTH+3) * 0.05 * pow(exposure.a, 0.2) ,0.0,1.0) * vignette;
|
||||||
|
#else
|
||||||
|
vec3 bloom = texture2D(colortex3,texcoord/clampedRes*vec2(1920.,1080.)*BLOOM_QUALITY).rgb / 3.0 / bloomWeight();
|
||||||
|
float lightScat = clamp(BLOOM_STRENGTH * 0.5 * pow(exposure.a, 0.2) ,0.0,1.0) * vignette;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float VL_abs = texture2D(colortex7, texcoord*RENDER_SCALE).r;
|
||||||
|
|
||||||
|
#ifdef AUTO_EXPOSURE
|
||||||
|
float purkinje = clamp(exposure.a*exposure.a,0.0,1.0) * clamp(rodExposureDepth.x/(1.0+rodExposureDepth.x)*Purkinje_strength,0,1);
|
||||||
|
#else
|
||||||
|
float purkinje = clamp(rodExposureDepth.x/(1.0+rodExposureDepth.x)*Purkinje_strength,0,1);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
VL_abs = clamp((1.0-VL_abs)*BLOOMY_FOG*0.75*(1.0+rainStrength) * (1.0-purkinje*0.3),0.0,1.0)*clamp(1.0-pow(cdist(texcoord.xy),15.0),0.0,1.0);
|
||||||
|
|
||||||
|
col = (mix(col, bloom, VL_abs) + bloom * lightScat) * exposure.rgb;
|
||||||
|
|
||||||
|
// if(hideGUI > 0) col = bloom * lightScat* exposure.rgb;
|
||||||
|
|
||||||
|
float lum = dot(col, vec3(0.15,0.3,0.55));
|
||||||
|
float lum2 = dot(col, vec3(0.85,0.7,0.45));
|
||||||
|
float rodLum = lum2*200.0;
|
||||||
|
float rodCurve = clamp(mix(1.0, rodLum/(2.5+rodLum), purkinje),0.0,1.0);
|
||||||
|
|
||||||
|
col = mix(lum * vec3(Purkinje_R, Purkinje_G, Purkinje_B) * Purkinje_Multiplier, col, rodCurve);
|
||||||
|
|
||||||
|
#ifndef USE_ACES_COLORSPACE_APPROXIMATION
|
||||||
|
col = LinearTosRGB(TONEMAP(col));
|
||||||
|
#else
|
||||||
|
col = col * ACESInputMat;
|
||||||
|
col = TONEMAP(col);
|
||||||
|
|
||||||
|
col = LinearTosRGB(clamp(col * ACESOutputMat, 0.0, 1.0));
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(int8Dither(col,texcoord),0.0,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
#if DOF_QUALITY == 5
|
||||||
|
#if FOCUS_LASER_COLOR == 0 // Red
|
||||||
|
vec3 laserColor = vec3(25, 0, 0);
|
||||||
|
#elif FOCUS_LASER_COLOR == 1 // Green
|
||||||
|
vec3 laserColor = vec3(0, 25, 0);
|
||||||
|
#elif FOCUS_LASER_COLOR == 2 // Blue
|
||||||
|
vec3 laserColor = vec3(0, 0, 25);
|
||||||
|
#elif FOCUS_LASER_COLOR == 3 // Pink
|
||||||
|
vec3 laserColor = vec3(25, 10, 15);
|
||||||
|
#elif FOCUS_LASER_COLOR == 4 // Yellow
|
||||||
|
vec3 laserColor = vec3(25, 25, 0);
|
||||||
|
#elif FOCUS_LASER_COLOR == 5 // White
|
||||||
|
vec3 laserColor = vec3(25);
|
||||||
|
#endif
|
||||||
|
float depth = texture(depthtex0, texcoord).r;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float _near = near;
|
||||||
|
float _far = far*4.0;
|
||||||
|
|
||||||
|
if (depth >= 1.0) {
|
||||||
|
depth = texture2D(dhDepthTex, texcoord).x;
|
||||||
|
_near = dhNearPlane;
|
||||||
|
_far = dhFarPlane;
|
||||||
|
}
|
||||||
|
|
||||||
|
depth = linearizeDepthFast(depth, _near, _far);
|
||||||
|
#else
|
||||||
|
depth = linearizeDepthFast(depth, near, far);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// focus = gl_FragCoord.x * 0.1;
|
||||||
|
if( hideGUI < 1) gl_FragData[0].rgb += laserColor * pow( clamp( 1.0-abs(focus-abs(depth)) ,0,1),25) ;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,24 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
varying vec2 texcoord;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
|
||||||
|
flat varying vec4 exposure;
|
||||||
|
flat varying vec2 rodExposureDepth;
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
gl_Position = ftransform();
|
||||||
|
texcoord = gl_MultiTexCoord0.xy;
|
||||||
|
|
||||||
|
exposure = vec4(vec3(texelFetch2D(colortex4,ivec2(10,37),0).r),texelFetch2D(colortex4,ivec2(10,37),0).r);
|
||||||
|
rodExposureDepth = texelFetch2D(colortex4,ivec2(14,37),0).rg;
|
||||||
|
rodExposureDepth.y = sqrt(rodExposureDepth.y/65000.0);
|
||||||
|
}
|
|
@ -0,0 +1,430 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform sampler2D colortex2;
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
// uniform sampler2D colortex4;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform sampler2D colortex7;
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
// uniform float far;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
|
||||||
|
// varying vec2 texcoord;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
// flat varying vec2 TAA_Offset;
|
||||||
|
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
uniform float eyeAltitude;
|
||||||
|
|
||||||
|
#define DHVLFOG
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
#include "/lib/color_transforms.glsl"
|
||||||
|
#include "/lib/color_dither.glsl"
|
||||||
|
#include "/lib/projections.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
#include "/lib/waterBump.glsl"
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
const bool shadowHardwareFiltering = true;
|
||||||
|
uniform sampler2DShadow shadow;
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2DShadow shadowtex0;
|
||||||
|
uniform sampler2DShadow shadowtex1;
|
||||||
|
#endif
|
||||||
|
flat varying vec3 refractedSunVec;
|
||||||
|
|
||||||
|
#define TIMEOFDAYFOG
|
||||||
|
#include "/lib/lightning_stuff.glsl"
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#include "/lib/overworld_fog.glsl"
|
||||||
|
#endif
|
||||||
|
#ifdef NETHER_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#include "/lib/nether_fog.glsl"
|
||||||
|
#endif
|
||||||
|
#ifdef END_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#include "/lib/end_fog.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define fsign(a) (clamp((a)*1e35,0.,1.)*2.-1.)
|
||||||
|
|
||||||
|
float interleaved_gradientNoise_temporal(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+frameTimeCounter*51.9521);
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
|
||||||
|
// float interleaved_gradientNoise(){
|
||||||
|
// return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+ 1.0/1.6180339887 * frameCounter);
|
||||||
|
// }
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a+ 1.0/1.6180339887 * frameCounter );
|
||||||
|
}
|
||||||
|
float R2_dither(){
|
||||||
|
#ifdef TAA
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
#else
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
#endif
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
void waterVolumetrics_notoverworld(inout vec3 inColor, vec3 rayStart, vec3 rayEnd, float estEndDepth, float estSunDepth, float rayLength, float dither, vec3 waterCoefs, vec3 scatterCoef, vec3 ambient){
|
||||||
|
inColor *= exp(-rayLength * waterCoefs); //No need to take the integrated value
|
||||||
|
|
||||||
|
int spCount = rayMarchSampleCount;
|
||||||
|
vec3 start = toShadowSpaceProjected(rayStart);
|
||||||
|
vec3 end = toShadowSpaceProjected(rayEnd);
|
||||||
|
vec3 dV = (end-start);
|
||||||
|
//limit ray length at 32 blocks for performance and reducing integration error
|
||||||
|
//you can't see above this anyway
|
||||||
|
float maxZ = min(rayLength,12.0)/(1e-8+rayLength);
|
||||||
|
dV *= maxZ;
|
||||||
|
|
||||||
|
|
||||||
|
rayLength *= maxZ;
|
||||||
|
|
||||||
|
float dY = normalize(mat3(gbufferModelViewInverse) * rayEnd).y * rayLength;
|
||||||
|
estEndDepth *= maxZ;
|
||||||
|
estSunDepth *= maxZ;
|
||||||
|
|
||||||
|
vec3 wpos = mat3(gbufferModelViewInverse) * rayStart + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 dVWorld = (wpos-gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
vec3 absorbance = vec3(1.0);
|
||||||
|
vec3 vL = vec3(0.0);
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<spCount;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither)/float(spCount))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
float dd = pow(expFactor, float(i+dither)/float(spCount)) * log(expFactor) / float(spCount)/(expFactor-1.0);
|
||||||
|
vec3 spPos = start.xyz + dV*d;
|
||||||
|
|
||||||
|
vec3 progressW = start.xyz+cameraPosition+dVWorld;
|
||||||
|
|
||||||
|
vec3 ambientMul = exp(-max(estEndDepth * d,0.0) * waterCoefs );
|
||||||
|
vec3 Indirectlight = ambientMul*ambient;
|
||||||
|
|
||||||
|
vec3 light = Indirectlight * scatterCoef;
|
||||||
|
|
||||||
|
vL += (light - light * exp(-waterCoefs * dd * rayLength)) / waterCoefs * absorbance;
|
||||||
|
absorbance *= exp(-dd * rayLength * waterCoefs);
|
||||||
|
}
|
||||||
|
inColor += vL;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// #ifdef OVERWORLD_SHADER
|
||||||
|
// vec4 waterVolumetrics_test( vec3 rayStart, vec3 rayEnd, float estEndDepth, float estSunDepth, float rayLength, float dither, vec3 waterCoefs, vec3 scatterCoef, vec3 ambient, vec3 lightSource, float VdotL){
|
||||||
|
// int spCount = rayMarchSampleCount;
|
||||||
|
|
||||||
|
// vec3 start = toShadowSpaceProjected(rayStart);
|
||||||
|
// vec3 end = toShadowSpaceProjected(rayEnd);
|
||||||
|
// vec3 dV = (end-start);
|
||||||
|
|
||||||
|
// //limit ray length at 32 blocks for performance and reducing integration error
|
||||||
|
// //you can't see above this anyway
|
||||||
|
// float maxZ = min(rayLength,12.0)/(1e-8+rayLength);
|
||||||
|
// dV *= maxZ;
|
||||||
|
// rayLength *= maxZ;
|
||||||
|
// estEndDepth *= maxZ;
|
||||||
|
// estSunDepth *= maxZ;
|
||||||
|
|
||||||
|
// vec3 wpos = mat3(gbufferModelViewInverse) * rayStart + gbufferModelViewInverse[3].xyz;
|
||||||
|
// vec3 dVWorld = (wpos - gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
// vec3 newabsorbance = exp(-rayLength * waterCoefs); // No need to take the integrated value
|
||||||
|
|
||||||
|
// float phase = fogPhase(VdotL) * 5.0;
|
||||||
|
// vec3 absorbance = vec3(1.0);
|
||||||
|
// vec3 vL = vec3(0.0);
|
||||||
|
|
||||||
|
|
||||||
|
// float expFactor = 11.0;
|
||||||
|
// for (int i=0;i<spCount;i++) {
|
||||||
|
// float d = (pow(expFactor, float(i+dither)/float(spCount))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
// float dd = pow(expFactor, float(i+dither)/float(spCount)) * log(expFactor) / float(spCount)/(expFactor-1.0);
|
||||||
|
// vec3 spPos = start.xyz + dV*d;
|
||||||
|
|
||||||
|
// vec3 progressW = start.xyz+cameraPosition+dVWorld;
|
||||||
|
|
||||||
|
// //project into biased shadowmap space
|
||||||
|
// #ifdef DISTORT_SHADOWMAP
|
||||||
|
// float distortFactor = calcDistort(spPos.xy);
|
||||||
|
// #else
|
||||||
|
// float distortFactor = 1.0;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
// vec3 pos = vec3(spPos.xy*distortFactor, spPos.z);
|
||||||
|
// float sh = 1.0;
|
||||||
|
// if (abs(pos.x) < 1.0-0.5/2048. && abs(pos.y) < 1.0-0.5/2048){
|
||||||
|
// pos = pos*vec3(0.5,0.5,0.5/6.0)+0.5;
|
||||||
|
// sh = shadow2D( shadow, pos).x;
|
||||||
|
// }
|
||||||
|
|
||||||
|
// #ifdef VL_CLOUDS_SHADOWS
|
||||||
|
// sh *= GetCloudShadow_VLFOG(progressW,WsunVec);
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
// vec3 sunMul = exp(-estSunDepth * d * waterCoefs * 1.1);
|
||||||
|
// vec3 ambientMul = exp(-estEndDepth * d * waterCoefs );
|
||||||
|
|
||||||
|
// vec3 Directlight = (lightSource * phase * sunMul) * sh;
|
||||||
|
// // vec3 Indirectlight = ambient * ambientMul;
|
||||||
|
// vec3 Indirectlight = max(ambient * ambientMul, vec3(0.01,0.2,0.4) * ambientMul * 0.1) ;
|
||||||
|
|
||||||
|
// vec3 light = (Indirectlight + Directlight) * scatterCoef;
|
||||||
|
|
||||||
|
// vL += (light - light * exp(-waterCoefs * dd * rayLength)) / waterCoefs * absorbance;
|
||||||
|
// absorbance *= exp(-waterCoefs * dd * rayLength);
|
||||||
|
// }
|
||||||
|
// // inColor += vL;
|
||||||
|
// return vec4( vL, dot(newabsorbance,vec3(0.335)));
|
||||||
|
// }
|
||||||
|
|
||||||
|
|
||||||
|
void waterVolumetrics(inout vec3 inColor, vec3 rayStart, vec3 rayEnd, float estEyeDepth, float estSunDepth, float rayLength, float dither, vec3 waterCoefs, vec3 scatterCoef, vec3 ambient, vec3 lightSource, float VdotL){
|
||||||
|
int spCount = 8;
|
||||||
|
|
||||||
|
vec3 start = toShadowSpaceProjected(rayStart);
|
||||||
|
vec3 end = toShadowSpaceProjected(rayEnd);
|
||||||
|
vec3 dV = (end-start);
|
||||||
|
|
||||||
|
//limit ray length at 32 blocks for performance and reducing integration error
|
||||||
|
//you can't see above this anyway
|
||||||
|
float maxZ = min(rayLength,32.0)/(1e-8+rayLength);
|
||||||
|
dV *= maxZ;
|
||||||
|
vec3 dVWorld = mat3(gbufferModelViewInverse) * (rayEnd - rayStart) * maxZ;
|
||||||
|
rayLength *= maxZ;
|
||||||
|
float dY = normalize(mat3(gbufferModelViewInverse) * rayEnd).y * rayLength;
|
||||||
|
|
||||||
|
vec3 progressW = gbufferModelViewInverse[3].xyz+cameraPosition;
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float phase = fogPhase(VdotL) * 5.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 absorbance = vec3(1.0);
|
||||||
|
vec3 vL = vec3(0.0);
|
||||||
|
|
||||||
|
float YFade = pow(normalize(dVWorld).y*0.3+0.7,1.5);
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float lowlightlevel = clamp(eyeBrightnessSmooth.y/240.0,0.1,1.0);
|
||||||
|
#else
|
||||||
|
float lowlightlevel = 1.0;
|
||||||
|
#endif
|
||||||
|
// lowlightlevel = pow(lowlightlevel,0.5);
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<spCount;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither)/float(spCount))/expFactor - 1.0/expFactor)/(1-1.0/expFactor); // exponential step position (0-1)
|
||||||
|
float dd = pow(expFactor, float(i+dither)/float(spCount)) * log(expFactor) / float(spCount)/(expFactor-1.0); //step length (derivative)
|
||||||
|
|
||||||
|
progressW = gbufferModelViewInverse[3].xyz+cameraPosition + d*dVWorld;
|
||||||
|
|
||||||
|
vec3 sh = vec3(1.0);
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
vec3 spPos = start.xyz + dV*d;
|
||||||
|
|
||||||
|
//project into biased shadowmap space
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(spPos.xy);
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
vec3 pos = vec3(spPos.xy*distortFactor, spPos.z);
|
||||||
|
if (abs(pos.x) < 1.0-0.5/2048. && abs(pos.y) < 1.0-0.5/2048){
|
||||||
|
pos = pos*vec3(0.5,0.5,0.5/6.0)+0.5;
|
||||||
|
// sh = shadow2D( shadow, pos).x;
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
sh = vec3(shadow2D(shadowtex0, pos).x);
|
||||||
|
|
||||||
|
if(shadow2D(shadowtex1, pos).x > pos.z && sh.x < 1.0){
|
||||||
|
sh = normalize(texture2D(shadowcolor0, pos.xy).rgb+0.0001);
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
sh = vec3(shadow2D(shadow, pos).x);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef VL_CLOUDS_SHADOWS
|
||||||
|
sh *= GetCloudShadow_VLFOG(progressW,WsunVec);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
// float bubble = 1.0 - pow(1.0-pow(1.0-min(max(1.0 - length(d*dVWorld) / (16),0.0)*5.0,1.0),2.0),2.0);
|
||||||
|
float bubble = exp( -7.0 * clamp(1.0 - length(d*dVWorld) / 16.0, 0.0,1.0) );
|
||||||
|
float bubble2 = max(pow(length(d*dVWorld)/24,5)*100.0,0.0) + 1;
|
||||||
|
|
||||||
|
float sunCaustics = (waterCaustics(progressW, WsunVec)) * mix(0.25,10.0,bubble) + 0.75;
|
||||||
|
|
||||||
|
vec3 sunMul = exp(-1 * d * waterCoefs * 1.1);
|
||||||
|
vec3 Directlight = ((lightSource* sh) * phase * sunMul * sunCaustics) * lowlightlevel * pow(abs(WsunVec.y),1);
|
||||||
|
#else
|
||||||
|
vec3 Directlight = vec3(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 ambientMul = exp(-1 * d * waterCoefs);
|
||||||
|
vec3 Indirectlight = ambient * ambientMul * YFade * lowlightlevel;
|
||||||
|
|
||||||
|
vec3 light = (Indirectlight + Directlight) * scatterCoef;
|
||||||
|
|
||||||
|
vL += (light - light * exp(-waterCoefs * dd * rayLength)) / waterCoefs * absorbance;
|
||||||
|
absorbance *= exp(-waterCoefs * dd * rayLength);
|
||||||
|
}
|
||||||
|
inColor += vL;
|
||||||
|
}
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
vec4 blueNoise(vec2 coord){
|
||||||
|
return texelFetch2D(colortex6, ivec2(coord)%512 , 0) ;
|
||||||
|
}
|
||||||
|
vec2 R2_samples(int n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
|
||||||
|
float fogPhase2(float lightPoint){
|
||||||
|
float linear = 1.0 - clamp(lightPoint*0.5+0.5,0.0,1.0);
|
||||||
|
float linear2 = 1.0 - clamp(lightPoint,0.0,1.0);
|
||||||
|
|
||||||
|
float exponential = exp2(pow(linear,0.3) * -15.0 ) * 1.5;
|
||||||
|
exponential += sqrt(exp2(sqrt(linear) * -12.5));
|
||||||
|
|
||||||
|
return exponential;
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* RENDERTARGETS:0 */
|
||||||
|
|
||||||
|
float noise_1 = max(1.0 - R2_dither(),0.0015);
|
||||||
|
float noise_2 = blueNoise();
|
||||||
|
|
||||||
|
|
||||||
|
vec2 tc = floor(gl_FragCoord.xy)/VL_RENDER_RESOLUTION*texelSize+0.5*texelSize;
|
||||||
|
|
||||||
|
bool iswater = texture2D(colortex7,tc).a > 0.99;
|
||||||
|
|
||||||
|
float z0 = texture2D(depthtex0,tc).x;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float DH_z0 = texture2D(dhDepthTex,tc).x;
|
||||||
|
#else
|
||||||
|
float DH_z0 = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float z = texture2D(depthtex1,tc).x;
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float DH_z = texture2D(dhDepthTex1,tc).x;
|
||||||
|
#else
|
||||||
|
float DH_z = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 viewPos1 = toScreenSpace_DH(tc/RENDER_SCALE, z, DH_z);
|
||||||
|
vec3 viewPos0 = toScreenSpace_DH(tc/RENDER_SCALE, z0, DH_z0);
|
||||||
|
|
||||||
|
vec3 playerPos = normalize(mat3(gbufferModelViewInverse) * viewPos1);
|
||||||
|
// vec3 lightningColor = (lightningEffect / 3) * (max(eyeBrightnessSmooth.y,0)/240.);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
float dirtAmount = Dirt_Amount + 0.01;
|
||||||
|
vec3 waterEpsilon = vec3(Water_Absorb_R, Water_Absorb_G, Water_Absorb_B);
|
||||||
|
vec3 dirtEpsilon = vec3(Dirt_Absorb_R, Dirt_Absorb_G, Dirt_Absorb_B);
|
||||||
|
vec3 totEpsilon = dirtEpsilon*dirtAmount + waterEpsilon;
|
||||||
|
vec3 scatterCoef = dirtAmount * vec3(Dirt_Scatter_R, Dirt_Scatter_G, Dirt_Scatter_B) / 3.14;
|
||||||
|
|
||||||
|
vec3 directLightColor = lightCol.rgb/80.0;
|
||||||
|
vec3 indirectLightColor = averageSkyCol/30.0;
|
||||||
|
vec3 indirectLightColor_dynamic = averageSkyCol_Clouds/30.0;
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
///////////////// IN FRONT OF TRANSLUCENTS /////////////////
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
vec4 VolumetricFog = GetVolumetricFog(viewPos0, vec2(noise_1,noise_2), directLightColor, indirectLightColor);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined NETHER_SHADER || defined END_SHADER
|
||||||
|
vec4 VolumetricFog = GetVolumetricFog(viewPos0, noise_1, noise_2);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[0] = clamp(VolumetricFog, 0.0, 65000.0);
|
||||||
|
|
||||||
|
//////////////////////////////////////////////////////////
|
||||||
|
///////////////// BEHIND OF TRANSLUCENTS /////////////////
|
||||||
|
//////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
if (isEyeInWater == 1){
|
||||||
|
|
||||||
|
float estEyeDepth = clamp(eyeBrightnessSmooth.y/240.0,0.,1.0);
|
||||||
|
// estEyeDepth = pow(estEyeDepth,3.0) * 32.0;
|
||||||
|
estEyeDepth = 0.0;
|
||||||
|
|
||||||
|
// vec3 lightningColor = (lightningEffect / 3) * (max(eyeBrightnessSmooth.y,0)/240.);
|
||||||
|
|
||||||
|
vec3 vl = vec3(0.0);
|
||||||
|
waterVolumetrics(vl, vec3(0.0), viewPos0, estEyeDepth, estEyeDepth, length(viewPos0), noise_1, totEpsilon, scatterCoef, indirectLightColor_dynamic, directLightColor , dot(normalize(viewPos0), normalize(sunVec* lightCol.a ) ));
|
||||||
|
|
||||||
|
gl_FragData[0] = clamp(vec4(vl,1.0),0.000001,65000.);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// gl_FragData[0] = clamp(vec4(vl,1.0),0.000001,65000.);
|
||||||
|
}
|
|
@ -0,0 +1,69 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
flat varying vec3 refractedSunVec;
|
||||||
|
|
||||||
|
flat varying float tempOffsets;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
|
||||||
|
uniform float sunElevation;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform int frameCounter;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
// gl_Position.xy = (gl_Position.xy*0.5+0.5)*0.51*2.0-1.0;
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*(0.01+VL_RENDER_RESOLUTION)*2.0-1.0;
|
||||||
|
|
||||||
|
#ifdef TAA
|
||||||
|
tempOffsets = HaltonSeq2(frameCounter%10000);
|
||||||
|
#else
|
||||||
|
tempOffsets = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
averageSkyCol = texelFetch2D(colortex4,ivec2(1,37),0).rgb;
|
||||||
|
averageSkyCol_Clouds = texelFetch2D(colortex4,ivec2(0,37),0).rgb;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef NETHER_SHADER
|
||||||
|
lightCol.rgb = vec3(0.0);
|
||||||
|
averageSkyCol = vec3(0.0);
|
||||||
|
averageSkyCol_Clouds = vec3(2.0, 1.0, 0.5) * 10.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
lightCol.rgb = vec3(0.0);
|
||||||
|
averageSkyCol = vec3(0.0);
|
||||||
|
averageSkyCol_Clouds = vec3(5.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
lightCol.a = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
WsunVec = lightCol.a * normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
|
||||||
|
|
||||||
|
refractedSunVec = refract(WsunVec, -vec3(0.0,1.0,0.0), 1.0/1.33333);
|
||||||
|
}
|
|
@ -0,0 +1,460 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
flat varying vec3 zMults;
|
||||||
|
|
||||||
|
flat varying vec2 TAA_Offset;
|
||||||
|
flat varying vec3 skyGroundColor;
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform sampler2D colortex0;
|
||||||
|
uniform sampler2D colortex1;
|
||||||
|
uniform sampler2D colortex2;
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
uniform sampler2D colortex5;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform sampler2D colortex7;
|
||||||
|
uniform sampler2D colortex8;
|
||||||
|
uniform sampler2D colortex9;
|
||||||
|
uniform sampler2D colortex10;
|
||||||
|
uniform sampler2D colortex11;
|
||||||
|
uniform sampler2D colortex12;
|
||||||
|
uniform sampler2D colortex13;
|
||||||
|
uniform sampler2D colortex15;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
|
||||||
|
#if defined NETHER_SHADER || defined END_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec4 lightCol; //main light source color (rgb),used light source(1=sun,-1=moon)
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float far;
|
||||||
|
uniform float near;
|
||||||
|
uniform float farPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 gbufferPreviousModelView;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
uniform mat4 gbufferPreviousProjection;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
uniform vec3 previousCameraPosition;
|
||||||
|
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
uniform ivec2 eyeBrightness;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform float blindness;
|
||||||
|
uniform float darknessFactor;
|
||||||
|
uniform float darknessLightFactor;
|
||||||
|
|
||||||
|
|
||||||
|
#include "/lib/waterBump.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/lightning_stuff.glsl"
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#endif
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
#include "/lib/climate_settings.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
float ld(float depth) {
|
||||||
|
return 1.0 / (zMults.y - depth * zMults.z); // (-depth * (far - near)) = (2.0 * near)/ld - far - near
|
||||||
|
}
|
||||||
|
float luma(vec3 color) {
|
||||||
|
return dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
}
|
||||||
|
vec3 toLinear(vec3 sRGB){
|
||||||
|
return sRGB * (sRGB * (sRGB * 0.305306011 + 0.682171111) + 0.012522878);
|
||||||
|
}
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return fragposition.xyz / fragposition.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 BilateralUpscale(sampler2D tex, sampler2D depth, vec2 coord, float referenceDepth){
|
||||||
|
ivec2 scaling = ivec2(1.0/VL_RENDER_RESOLUTION);
|
||||||
|
ivec2 posDepth = ivec2(coord*VL_RENDER_RESOLUTION) * scaling;
|
||||||
|
ivec2 posColor = ivec2(coord*VL_RENDER_RESOLUTION);
|
||||||
|
ivec2 pos = ivec2(gl_FragCoord.xy*texelSize + 1);
|
||||||
|
|
||||||
|
ivec2 getRadius[4] = ivec2[](
|
||||||
|
ivec2(-2,-2),
|
||||||
|
ivec2(-2, 0),
|
||||||
|
ivec2( 0, 0),
|
||||||
|
ivec2( 0,-2)
|
||||||
|
);
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float diffThreshold = 0.01;
|
||||||
|
#else
|
||||||
|
float diffThreshold = zMults.x;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
vec4 RESULT = vec4(0.0);
|
||||||
|
float SUM = 0.0;
|
||||||
|
|
||||||
|
for (int i = 0; i < 4; i++) {
|
||||||
|
|
||||||
|
ivec2 radius = getRadius[i];
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float offsetDepth = sqrt(texelFetch2D(depth, posDepth + radius * scaling + pos * scaling,0).a/65000.0);
|
||||||
|
#else
|
||||||
|
float offsetDepth = ld(texelFetch2D(depth, posDepth + radius * scaling + pos * scaling, 0).r);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float EDGES = abs(offsetDepth - referenceDepth) < diffThreshold ? 1.0 : 1e-5;
|
||||||
|
|
||||||
|
RESULT += texelFetch2D(tex, posColor + radius + pos, 0) * EDGES;
|
||||||
|
|
||||||
|
SUM += EDGES;
|
||||||
|
}
|
||||||
|
// return vec4(1) * SUM;
|
||||||
|
return RESULT / SUM;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 decode (vec2 encn){
|
||||||
|
vec3 n = vec3(0.0);
|
||||||
|
encn = encn * 2.0 - 1.0;
|
||||||
|
n.xy = abs(encn);
|
||||||
|
n.z = 1.0 - n.x - n.y;
|
||||||
|
n.xy = n.z <= 0.0 ? (1.0 - n.yx) * sign(encn) : encn;
|
||||||
|
return clamp(normalize(n.xyz),-1.0,1.0);
|
||||||
|
}
|
||||||
|
vec2 decodeVec2(float a){
|
||||||
|
const vec2 constant1 = 65535. / vec2( 256., 65536.);
|
||||||
|
const float constant2 = 256. / 255.;
|
||||||
|
return fract( a * constant1 ) * constant2 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 worldToView(vec3 worldPos) {
|
||||||
|
vec4 pos = vec4(worldPos, 0.0);
|
||||||
|
pos = gbufferModelView * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
vec4 blueNoise(vec2 coord){
|
||||||
|
return texelFetch2D(colortex6, ivec2(coord )%512 , 0);
|
||||||
|
}
|
||||||
|
vec3 normVec (vec3 vec){
|
||||||
|
return vec*inversesqrt(dot(vec,vec));
|
||||||
|
}
|
||||||
|
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
vec3 viewToWorld(vec3 viewPosition) {
|
||||||
|
vec4 pos;
|
||||||
|
pos.xyz = viewPosition;
|
||||||
|
pos.w = 0.0;
|
||||||
|
pos = gbufferModelViewInverse * pos;
|
||||||
|
return pos.xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// thanks stackoverflow https://stackoverflow.com/questions/944713/help-with-pixel-shader-effect-for-brightness-and-contrast#3027595
|
||||||
|
void applyContrast(inout vec3 color, float contrast){
|
||||||
|
color = ((color - 0.5) * max(contrast, 0.0)) + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ApplyDistortion(inout vec2 Texcoord, vec2 TangentNormals, float lineardistance, bool isTranslucentEntity){
|
||||||
|
|
||||||
|
vec2 UnalteredTexcoord = Texcoord;
|
||||||
|
|
||||||
|
float refractionStrength = isTranslucentEntity ? 0.25 : 1.0 ;
|
||||||
|
|
||||||
|
// Texcoord = abs(Texcoord + (TangentNormals * clamp((ld(depths.x) - ld(depths.y)) * 0.5,0.0,0.15)) * RENDER_SCALE * refractionStrength );
|
||||||
|
Texcoord = abs(Texcoord + (TangentNormals * mix(0.01, 0.1, pow(clamp(1.0-lineardistance/(32*4),0.0,1.0),2))) * RENDER_SCALE * refractionStrength );
|
||||||
|
|
||||||
|
float DistortedAlpha = decodeVec2(texture2D(colortex11,Texcoord).b).g;
|
||||||
|
// float DistortedAlpha = decodeVec2(texelFetch2D(colortex11,ivec2(Texcoord/texelSize),0).b).g;
|
||||||
|
// float DistortedAlpha = texelFetch2D(colortex2,ivec2(Texcoord/texelSize),0).a;
|
||||||
|
|
||||||
|
Texcoord = mix(Texcoord, UnalteredTexcoord, min(max(0.1-DistortedAlpha,0.0) * 1000.0,1.0)); // remove distortion on non-translucents
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform int dhRenderDistance;
|
||||||
|
uniform float eyeAltitude;
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:73 */
|
||||||
|
|
||||||
|
////// --------------- SETUP STUFF --------------- //////
|
||||||
|
vec2 texcoord = gl_FragCoord.xy*texelSize;
|
||||||
|
|
||||||
|
float z = texture2D(depthtex0,texcoord).x;
|
||||||
|
float z2 = texture2D(depthtex1,texcoord).x;
|
||||||
|
float frDepth = ld(z);
|
||||||
|
|
||||||
|
float swappedDepth = z;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float DH_depth0 = texture2D(dhDepthTex,texcoord).x;
|
||||||
|
float depthOpaque = z;
|
||||||
|
float depthOpaqueL = linearizeDepthFast(depthOpaque, near, farPlane);
|
||||||
|
|
||||||
|
float dhDepthOpaque = DH_depth0;
|
||||||
|
float dhDepthOpaqueL = linearizeDepthFast(dhDepthOpaque, dhNearPlane, dhFarPlane);
|
||||||
|
if (depthOpaque >= 1.0 || (dhDepthOpaqueL < depthOpaqueL && dhDepthOpaque > 0.0)){
|
||||||
|
depthOpaque = dhDepthOpaque;
|
||||||
|
depthOpaqueL = dhDepthOpaqueL;
|
||||||
|
}
|
||||||
|
|
||||||
|
swappedDepth = depthOpaque;
|
||||||
|
|
||||||
|
#else
|
||||||
|
float DH_depth0 = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 fragpos = toScreenSpace_DH(texcoord/RENDER_SCALE-vec2(TAA_Offset)*texelSize*0.5, z, DH_depth0);
|
||||||
|
|
||||||
|
// vec3 fragpos = toScreenSpace(vec3(texcoord/RENDER_SCALE-vec2(TAA_Offset)*texelSize*0.5,z));
|
||||||
|
vec3 p3 = mat3(gbufferModelViewInverse) * fragpos;
|
||||||
|
vec3 np3 = normVec(p3);
|
||||||
|
|
||||||
|
float linearDistance = length(p3);
|
||||||
|
float linearDistance_cylinder = length(p3.xz);
|
||||||
|
|
||||||
|
float lightleakfix = clamp(pow(eyeBrightnessSmooth.y/240.,2) ,0.0,1.0);
|
||||||
|
float lightleakfixfast = clamp(eyeBrightness.y/240.,0.0,1.0);
|
||||||
|
|
||||||
|
////// --------------- UNPACK TRANSLUCENT GBUFFERS --------------- //////
|
||||||
|
vec4 data = texture2D(colortex11,texcoord).rgba;
|
||||||
|
vec4 unpack0 = vec4(decodeVec2(data.r),decodeVec2(data.g)) ;
|
||||||
|
vec4 unpack1 = vec4(decodeVec2(data.b),0,0) ;
|
||||||
|
|
||||||
|
vec4 albedo = vec4(unpack0.ba,unpack1.rg);
|
||||||
|
vec2 tangentNormals = unpack0.xy*2.0-1.0;
|
||||||
|
if(albedo.a < 0.01) tangentNormals = vec2(0.0);
|
||||||
|
|
||||||
|
vec4 TranslucentShader = texture2D(colortex2, texcoord);
|
||||||
|
|
||||||
|
////// --------------- UNPACK MISC --------------- //////
|
||||||
|
// 1.0 = water mask
|
||||||
|
// 0.9 = entity mask
|
||||||
|
// 0.8 = reflective entities
|
||||||
|
// 0.7 = reflective blocks
|
||||||
|
float translucentMasks = texture2D(colortex7, texcoord).a;
|
||||||
|
|
||||||
|
bool isWater = translucentMasks > 0.99;
|
||||||
|
bool isReflectiveEntity = abs(translucentMasks - 0.8) < 0.01;
|
||||||
|
bool isReflective = abs(translucentMasks - 0.7) < 0.01 || isWater || isReflectiveEntity;
|
||||||
|
bool isEntity = abs(translucentMasks - 0.9) < 0.01 || isReflectiveEntity;
|
||||||
|
|
||||||
|
|
||||||
|
////// --------------- get volumetrics
|
||||||
|
#ifdef TOGGLE_VL_FOG
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
vec4 vl = BilateralUpscale(colortex0, colortex12, gl_FragCoord.xy, sqrt(texture2D(colortex12,texcoord).a/65000.0));
|
||||||
|
#else
|
||||||
|
vec4 vl = BilateralUpscale(colortex0, depthtex0, gl_FragCoord.xy, frDepth);
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
vec4 vl = vec4(0,0,0,1);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float bloomyFogMult = 1.0;
|
||||||
|
|
||||||
|
////// --------------- distort texcoords as a refraction effect
|
||||||
|
vec2 refractedCoord = texcoord;
|
||||||
|
|
||||||
|
#ifdef Refraction
|
||||||
|
ApplyDistortion(refractedCoord, tangentNormals, linearDistance, isEntity);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
////// --------------- MAIN COLOR BUFFER
|
||||||
|
vec3 color = texture2D(colortex3, refractedCoord).rgb;
|
||||||
|
|
||||||
|
// apply block breaking effect.
|
||||||
|
if(albedo.a > 0.01 && !isWater && TranslucentShader.a <= 0.0) color = mix(color*6.0, color, luma(albedo.rgb)) * albedo.rgb;
|
||||||
|
|
||||||
|
////// --------------- BLEND TRANSLUCENT GBUFFERS
|
||||||
|
//////////// and do border fog on opaque and translucents
|
||||||
|
|
||||||
|
#if defined BorderFog
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float fog = smoothstep(1.0, 0.0, min(max(1.0 - linearDistance_cylinder / dhRenderDistance,0.0)*3.0,1.0) );
|
||||||
|
#else
|
||||||
|
float fog = smoothstep(1.0, 0.0, min(max(1.0 - linearDistance_cylinder / far,0.0)*3.0,1.0) );
|
||||||
|
#endif
|
||||||
|
|
||||||
|
fog *= exp(-10.0 * pow(clamp(np3.y,0.0,1.0)*4.0,2.0));
|
||||||
|
|
||||||
|
if(swappedDepth >= 1.0 || isEyeInWater != 0) fog = 0.0;
|
||||||
|
|
||||||
|
if(lightleakfixfast < 1.0) fog *= lightleakfix;
|
||||||
|
|
||||||
|
#ifdef SKY_GROUND
|
||||||
|
vec3 borderFogColor = skyGroundColor;
|
||||||
|
#else
|
||||||
|
vec3 borderFogColor = skyFromTex(np3, colortex4)/30.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
color.rgb = mix(color.rgb, borderFogColor, fog);
|
||||||
|
#else
|
||||||
|
float fog = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (TranslucentShader.a > 0.0){
|
||||||
|
#ifdef Glass_Tint
|
||||||
|
if(!isWater) color *= mix(normalize(albedo.rgb+0.0001)*0.9+0.1, vec3(1.0), max(fog, min(max(0.1-albedo.a,0.0) * 1000.0,1.0))) ;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BorderFog
|
||||||
|
TranslucentShader = mix(TranslucentShader, vec4(0.0), fog);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
color = color*(1.0-TranslucentShader.a) + TranslucentShader.rgb*10.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
////// --------------- VARIOUS FOG EFFECTS (behind volumetric fog)
|
||||||
|
//////////// blindness, nightvision, liquid fogs and misc fogs
|
||||||
|
|
||||||
|
#if defined OVERWORLD_SHADER && defined CAVE_FOG
|
||||||
|
if (isEyeInWater == 0 && eyeAltitude < 1500 && lightleakfix < 1.0){
|
||||||
|
|
||||||
|
float cavefog = clamp( pow(linearDistance / far, CaveFogFallOff) ,0.0,1.0);
|
||||||
|
cavefog = cavefog*0.95 + clamp( pow(1.0 - exp((linearDistance / far) * -5), 2.0) ,0.0,1.0)*0.05;
|
||||||
|
|
||||||
|
cavefog *= exp(-30.0*(pow(clamp(np3.y-0.5,0.0,1.0),2.0))); // create a hole in the fog above, so the sky is a little visible.
|
||||||
|
|
||||||
|
vec3 cavefogCol = vec3(CaveFogColor_R, CaveFogColor_G, CaveFogColor_B);
|
||||||
|
cavefogCol *= clamp( exp(clamp(np3.y * 0.5 + 0.5,0,1) * -3.0) ,0.0,1.0); // apply a vertical gradient to the fog color
|
||||||
|
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
BiomeFogColor(cavefogCol);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
color.rgb = mix(color.rgb, cavefogCol, cavefog * (1.0-lightleakfix));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
////// --------------- Distance fog for the end shader
|
||||||
|
#ifdef END_SHADER
|
||||||
|
if (isEyeInWater == 0){
|
||||||
|
vec3 hazeColor = vec3(0.3,0.75,1.0) * 0.3;
|
||||||
|
|
||||||
|
float hazeDensity = clamp(1.0 - linearDistance / max(far, 32.0 * 24.0),0.0,1.0);
|
||||||
|
color.rgb = mix(hazeColor, color.rgb, hazeDensity) ;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
////// --------------- underwater fog
|
||||||
|
if (isEyeInWater == 1){
|
||||||
|
float dirtAmount = Dirt_Amount + 0.01;
|
||||||
|
vec3 waterEpsilon = vec3(Water_Absorb_R, Water_Absorb_G, Water_Absorb_B);
|
||||||
|
vec3 dirtEpsilon = vec3(Dirt_Absorb_R, Dirt_Absorb_G, Dirt_Absorb_B);
|
||||||
|
vec3 totEpsilon = dirtEpsilon*dirtAmount + waterEpsilon;
|
||||||
|
|
||||||
|
vec3 absorbColor = exp(-totEpsilon*linearDistance);
|
||||||
|
vec3 maxAbsorb = exp(-8.0 * totEpsilon);
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
|
||||||
|
linearDistance = length(vec3(p3.x,max(-p3.y,0.0),p3.z));
|
||||||
|
float fogfade = exp(-0.001*(linearDistance*linearDistance));
|
||||||
|
vec3 thresholdAbsorbedColor = mix(maxAbsorb, absorbColor, clamp(dot(absorbColor,vec3(0.33333)),0.0,1.0));
|
||||||
|
color.rgb = mix(vec3(1.0) * clamp(WsunVec.y,0,1) * pow(normalize(np3).y*0.3+0.7,1.5) * maxAbsorb, color.rgb * thresholdAbsorbedColor, clamp(fogfade,0.0,1.0));
|
||||||
|
|
||||||
|
#else
|
||||||
|
|
||||||
|
color.rgb *= absorbColor;
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
bloomyFogMult *= 0.4;
|
||||||
|
}
|
||||||
|
|
||||||
|
////// --------------- BLEND FOG INTO SCENE
|
||||||
|
//////////// apply VL fog over opaque and translucents
|
||||||
|
color *= vl.a;
|
||||||
|
color += vl.rgb;
|
||||||
|
bloomyFogMult *= vl.a;
|
||||||
|
|
||||||
|
////// --------------- VARIOUS FOG EFFECTS (in front of volumetric fog)
|
||||||
|
//////////// blindness, nightvision, liquid fogs and misc fogs
|
||||||
|
|
||||||
|
////// --------------- bloomy rain effect
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float rainDrops = clamp(texture2D(colortex9,texcoord).a, 0.0,1.0);
|
||||||
|
if(rainDrops > 0.0) bloomyFogMult *= clamp(1.0 - pow(rainDrops*5.0,2),0.0,1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
////// --------------- lava.
|
||||||
|
if (isEyeInWater == 2){
|
||||||
|
color.rgb = vec3(4.0,0.5,0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
///////// --------------- powdered snow
|
||||||
|
if (isEyeInWater == 3){
|
||||||
|
color.rgb = mix(color.rgb,vec3(10,15,20),clamp(linearDistance*0.5,0.,1.));
|
||||||
|
bloomyFogMult = 0.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
////// --------------- blidnesss
|
||||||
|
color.rgb *= mix(1.0,clamp( exp(pow(linearDistance*(blindness*0.2),2) * -5),0.,1.) , blindness);
|
||||||
|
|
||||||
|
//////// --------------- darkness effect
|
||||||
|
color.rgb *= mix(1.0, (1.0-darknessLightFactor*2.0) * clamp(1.0-pow(length(fragpos)*(darknessFactor*0.07),2.0),0.0,1.0), darknessFactor);
|
||||||
|
|
||||||
|
////// --------------- FINALIZE
|
||||||
|
#ifdef display_LUT
|
||||||
|
vec3 thingy = texelFetch2D(colortex4,ivec2(gl_FragCoord.xy),0).rgb / 30;
|
||||||
|
|
||||||
|
if(luma(thingy) > 0.0){
|
||||||
|
color.rgb = thingy;
|
||||||
|
vl.a = 1.0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
gl_FragData[0].r = bloomyFogMult; // pass fog alpha so bloom can do bloomy fog
|
||||||
|
gl_FragData[1].rgb = clamp(color.rgb, 0.0,68000.0);
|
||||||
|
|
||||||
|
// gl_FragData[1].rgb = vec3(tangentNormals.xy,0.0) ;
|
||||||
|
// gl_FragData[1].rgb = vec3(1.0) * ld( (data.a > 0.0 ? data.a : texture2D(depthtex0, texcoord).x ) ) ;
|
||||||
|
// gl_FragData[1].rgb = gl_FragData[1].rgb * (1.0-TranslucentShader.a) + TranslucentShader.rgb*10.0;
|
||||||
|
// gl_FragData[1].rgb = 1-(texcoord.x > 0.5 ? vec3(TranslucentShader.a) : vec3(data.a));
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,58 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
varying vec2 texcoord;
|
||||||
|
flat varying vec3 zMults;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
|
||||||
|
uniform float far;
|
||||||
|
uniform float near;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform float sunElevation;
|
||||||
|
flat varying vec2 TAA_Offset;
|
||||||
|
uniform int framemod8;
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef BorderFog
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
flat varying vec3 skyGroundColor;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
#ifdef BorderFog
|
||||||
|
skyGroundColor = texelFetch2D(colortex4,ivec2(1,37),0).rgb / 30.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA
|
||||||
|
TAA_Offset = offsets[framemod8];
|
||||||
|
#else
|
||||||
|
TAA_Offset = vec2(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float lightCola = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
WsunVec = normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
|
||||||
|
zMults = vec3(1.0/(far * near),far+near,far-near);
|
||||||
|
|
||||||
|
gl_Position = ftransform();
|
||||||
|
texcoord = gl_MultiTexCoord0.xy;
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,44 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
// Compute 3x3 min max for TAA
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:06 */
|
||||||
|
ivec2 center = ivec2(gl_FragCoord.xy);
|
||||||
|
vec3 current = texelFetch2D(colortex3, center, 0).rgb;
|
||||||
|
vec3 cMin = current;
|
||||||
|
vec3 cMax = current;
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(-1, -1), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(-1, 0), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(-1, 1), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(0, -1), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(0, 1), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(1, -1), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(1, 0), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
current = texelFetch2D(colortex3, center + ivec2(1, 1), 0).rgb;
|
||||||
|
cMin = min(cMin, current);
|
||||||
|
cMax = max(cMax, current);
|
||||||
|
gl_FragData[0].rgb = cMax;
|
||||||
|
gl_FragData[1].rgb = cMin;
|
||||||
|
}
|
|
@ -0,0 +1,16 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*RENDER_SCALE*2.0-1.0;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,456 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
/*
|
||||||
|
const int colortex0Format = RGBA16F; // low res clouds (deferred->composite2) + low res VL (composite5->composite15)
|
||||||
|
const int colortex1Format = RGBA16; // terrain gbuffer (gbuffer->composite2)
|
||||||
|
const int colortex2Format = RGBA16F; // forward + transparencies (gbuffer->composite4)
|
||||||
|
const int colortex3Format = R11F_G11F_B10F; // frame buffer + bloom (deferred6->final)
|
||||||
|
const int colortex4Format = RGBA16F; // light values and skyboxes (everything)
|
||||||
|
const int colortex6Format = R11F_G11F_B10F; // additionnal buffer for bloom (composite3->final)
|
||||||
|
const int colortex7Format = RGBA8; // Final output, transparencies id (gbuffer->composite4)
|
||||||
|
const int colortex8Format = RGBA8; // Specular Texture
|
||||||
|
const int colortex9Format = RGBA8; // rain in alpha
|
||||||
|
const int colortex10Format = RGBA16; // resourcepack Skies
|
||||||
|
const int colortex11Format = RGBA16; // unchanged translucents albedo, alpha and tangent normals
|
||||||
|
const int colortex12Format = RGBA16F; // DISTANT HORIZONS + VANILLA MIXED DEPTHs
|
||||||
|
|
||||||
|
const int colortex13Format = RGBA16F; // low res VL (composite5->composite15)
|
||||||
|
const int colortex14Format = RGBA16; // rg = SSAO and SS-SSS. a = skylightmap for translucents.
|
||||||
|
const int colortex15Format = RGBA8; // flat normals and vanilla AO
|
||||||
|
*/
|
||||||
|
|
||||||
|
//no need to clear the buffers, saves a few fps
|
||||||
|
const bool colortex0Clear = false;
|
||||||
|
const bool colortex1Clear = false;
|
||||||
|
const bool colortex2Clear = true;
|
||||||
|
const bool colortex3Clear = false;
|
||||||
|
const bool colortex4Clear = false;
|
||||||
|
const bool colortex5Clear = false;
|
||||||
|
const bool colortex6Clear = false;
|
||||||
|
const bool colortex7Clear = false;
|
||||||
|
const bool colortex8Clear = false;
|
||||||
|
const bool colortex9Clear = true;
|
||||||
|
const bool colortex10Clear = true;
|
||||||
|
const bool colortex11Clear = true;
|
||||||
|
const bool colortex12Clear = false;
|
||||||
|
const bool colortex13Clear = false;
|
||||||
|
const bool colortex14Clear = true;
|
||||||
|
const bool colortex15Clear = false;
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef SCREENSHOT_MODE
|
||||||
|
/*
|
||||||
|
const int colortex5Format = RGBA32F; //TAA buffer (everything)
|
||||||
|
*/
|
||||||
|
#else
|
||||||
|
/*
|
||||||
|
const int colortex5Format = R11F_G11F_B10F; //TAA buffer (everything)
|
||||||
|
*/
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
varying vec2 texcoord;
|
||||||
|
flat varying float tempOffsets;
|
||||||
|
uniform sampler2D colortex0;
|
||||||
|
uniform sampler2D colortex1;
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
uniform sampler2D colortex5;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform sampler2D colortex10;
|
||||||
|
uniform sampler2D colortex12;
|
||||||
|
uniform sampler2D colortex14;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform int framemod8;
|
||||||
|
uniform float viewHeight;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform vec3 previousCameraPosition;
|
||||||
|
uniform mat4 gbufferPreviousModelView;
|
||||||
|
|
||||||
|
uniform int hideGUI;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#define fsign(a) (clamp((a)*1e35,0.,1.)*2.-1.)
|
||||||
|
|
||||||
|
#include "/lib/projections.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
float luma(vec3 color) {
|
||||||
|
return dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+tempOffsets);
|
||||||
|
}
|
||||||
|
float triangularize(float dither)
|
||||||
|
{
|
||||||
|
float center = dither*2.0-1.0;
|
||||||
|
dither = center*inversesqrt(abs(center));
|
||||||
|
return clamp(dither-fsign(center),0.0,1.0);
|
||||||
|
}
|
||||||
|
vec4 fp10Dither(vec4 color ,float dither){
|
||||||
|
const vec3 mantissaBits = vec3(6.,6.,5.);
|
||||||
|
vec3 exponent = floor(log2(color.rgb));
|
||||||
|
return vec4(color.rgb + dither*exp2(-mantissaBits)*exp2(exponent), color.a);
|
||||||
|
}
|
||||||
|
|
||||||
|
//Modified texture interpolation from inigo quilez
|
||||||
|
vec4 smoothfilter(in sampler2D tex, in vec2 uv)
|
||||||
|
{
|
||||||
|
vec2 textureResolution = vec2(viewWidth,viewHeight);
|
||||||
|
uv = uv*textureResolution + 0.5;
|
||||||
|
vec2 iuv = floor( uv );
|
||||||
|
vec2 fuv = fract( uv );
|
||||||
|
|
||||||
|
#ifndef SMOOTHESTSTEP_INTERPOLATION
|
||||||
|
uv = iuv + (fuv*fuv)*(3.0-2.0*fuv);
|
||||||
|
#endif
|
||||||
|
#ifdef SMOOTHESTSTEP_INTERPOLATION
|
||||||
|
uv = iuv + fuv*fuv*fuv*(fuv*(fuv*6.0-15.0)+10.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uv = (uv - 0.5)/textureResolution;
|
||||||
|
|
||||||
|
return texture2D( tex, uv);
|
||||||
|
}
|
||||||
|
//approximation from SMAA presentation from siggraph 2016
|
||||||
|
vec3 FastCatmulRom(sampler2D colorTex, vec2 texcoord, vec4 rtMetrics, float sharpenAmount)
|
||||||
|
{
|
||||||
|
vec2 position = rtMetrics.zw * texcoord;
|
||||||
|
vec2 centerPosition = floor(position - 0.5) + 0.5;
|
||||||
|
vec2 f = position - centerPosition;
|
||||||
|
vec2 f2 = f * f;
|
||||||
|
vec2 f3 = f * f2;
|
||||||
|
|
||||||
|
float c = sharpenAmount;
|
||||||
|
vec2 w0 = -c * f3 + 2.0 * c * f2 - c * f;
|
||||||
|
vec2 w1 = (2.0 - c) * f3 - (3.0 - c) * f2 + 1.0;
|
||||||
|
vec2 w2 = -(2.0 - c) * f3 + (3.0 - 2.0 * c) * f2 + c * f;
|
||||||
|
vec2 w3 = c * f3 - c * f2;
|
||||||
|
|
||||||
|
vec2 w12 = w1 + w2;
|
||||||
|
vec2 tc12 = rtMetrics.xy * (centerPosition + w2 / w12);
|
||||||
|
vec3 centerColor = texture2D(colorTex, vec2(tc12.x, tc12.y)).rgb;
|
||||||
|
|
||||||
|
vec2 tc0 = rtMetrics.xy * (centerPosition - 1.0);
|
||||||
|
vec2 tc3 = rtMetrics.xy * (centerPosition + 2.0);
|
||||||
|
vec4 color = vec4(texture2D(colorTex, vec2(tc12.x, tc0.y )).rgb, 1.0) * (w12.x * w0.y ) +
|
||||||
|
vec4(texture2D(colorTex, vec2(tc0.x, tc12.y)).rgb, 1.0) * (w0.x * w12.y) +
|
||||||
|
vec4(centerColor, 1.0) * (w12.x * w12.y) +
|
||||||
|
vec4(texture2D(colorTex, vec2(tc3.x, tc12.y)).rgb, 1.0) * (w3.x * w12.y) +
|
||||||
|
vec4(texture2D(colorTex, vec2(tc12.x, tc3.y )).rgb, 1.0) * (w12.x * w3.y );
|
||||||
|
return color.rgb/color.a;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 clip_aabb(vec3 q, vec3 aabb_min, vec3 aabb_max)
|
||||||
|
{
|
||||||
|
vec3 p_clip = 0.5 * (aabb_max + aabb_min);
|
||||||
|
vec3 e_clip = 0.5 * (aabb_max - aabb_min) + 0.00000001;
|
||||||
|
|
||||||
|
vec3 v_clip = q - vec3(p_clip);
|
||||||
|
vec3 v_unit = v_clip.xyz / e_clip;
|
||||||
|
vec3 a_unit = abs(v_unit);
|
||||||
|
float ma_unit = max(a_unit.x, max(a_unit.y, a_unit.z));
|
||||||
|
|
||||||
|
if (ma_unit > 1.0)
|
||||||
|
return vec3(p_clip) + v_clip / ma_unit;
|
||||||
|
else
|
||||||
|
return q;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toClipSpace3Prev(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(gbufferPreviousProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
vec3 tonemap(vec3 col){
|
||||||
|
return col/(1+luma(col));
|
||||||
|
}
|
||||||
|
vec3 invTonemap(vec3 col){
|
||||||
|
return col/(1-luma(col));
|
||||||
|
}
|
||||||
|
void convertHandDepth(inout float depth) {
|
||||||
|
float ndcDepth = depth * 2.0 - 1.0;
|
||||||
|
ndcDepth /= MC_HAND_DEPTH;
|
||||||
|
depth = ndcDepth * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 closestToCamera5taps(vec2 texcoord, sampler2D depth, bool hand)
|
||||||
|
{
|
||||||
|
vec2 du = vec2(texelSize.x*2., 0.0);
|
||||||
|
vec2 dv = vec2(0.0, texelSize.y*2.);
|
||||||
|
|
||||||
|
vec3 dtl = vec3(texcoord,0.) + vec3(-texelSize, texture2D(depth, texcoord - dv - du).x);
|
||||||
|
vec3 dtr = vec3(texcoord,0.) + vec3( texelSize.x, -texelSize.y, texture2D(depth, texcoord - dv + du).x);
|
||||||
|
vec3 dmc = vec3(texcoord,0.) + vec3( 0.0, 0.0, texture2D(depth, texcoord).x);
|
||||||
|
vec3 dbl = vec3(texcoord,0.) + vec3(-texelSize.x, texelSize.y, texture2D(depth, texcoord + dv - du).x);
|
||||||
|
vec3 dbr = vec3(texcoord,0.) + vec3( texelSize.x, texelSize.y, texture2D(depth, texcoord + dv + du).x);
|
||||||
|
|
||||||
|
if(hand){
|
||||||
|
convertHandDepth(dtl.z);
|
||||||
|
convertHandDepth(dtr.z);
|
||||||
|
convertHandDepth(dmc.z);
|
||||||
|
convertHandDepth(dbl.z);
|
||||||
|
convertHandDepth(dbr.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 dmin = dmc;
|
||||||
|
dmin = dmin.z > dtr.z ? dtr : dmin;
|
||||||
|
dmin = dmin.z > dtl.z ? dtl : dmin;
|
||||||
|
dmin = dmin.z > dbl.z ? dbl : dmin;
|
||||||
|
dmin = dmin.z > dbr.z ? dbr : dmin;
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
dmin.xy = dmin.xy/RENDER_SCALE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return dmin;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 closestToCamera5taps_DH(vec2 texcoord, sampler2D depth, sampler2D dhDepth, bool depthCheck, bool hand)
|
||||||
|
{
|
||||||
|
vec2 du = vec2(texelSize.x*2., 0.0);
|
||||||
|
vec2 dv = vec2(0.0, texelSize.y*2.);
|
||||||
|
|
||||||
|
vec3 dtl = vec3(texcoord,0.);
|
||||||
|
vec3 dtr = vec3(texcoord,0.);
|
||||||
|
vec3 dmc = vec3(texcoord,0.);
|
||||||
|
vec3 dbl = vec3(texcoord,0.);
|
||||||
|
vec3 dbr = vec3(texcoord,0.);
|
||||||
|
|
||||||
|
dtl += vec3(-texelSize, depthCheck ? texture2D(dhDepth, texcoord - dv - du).x : texture2D(depth, texcoord - dv - du).x);
|
||||||
|
dtr += vec3( texelSize.x, -texelSize.y, depthCheck ? texture2D(dhDepth, texcoord - dv + du).x : texture2D(depth, texcoord - dv + du).x);
|
||||||
|
dmc += vec3( 0.0, 0.0, depthCheck ? texture2D(dhDepth, texcoord).x : texture2D(depth, texcoord).x);
|
||||||
|
dbl += vec3(-texelSize.x, texelSize.y, depthCheck ? texture2D(dhDepth, texcoord + dv - du).x : texture2D(depth, texcoord + dv - du).x);
|
||||||
|
dbr += vec3( texelSize.x, texelSize.y, depthCheck ? texture2D(dhDepth, texcoord + dv + du).x : texture2D(depth, texcoord + dv + du).x);
|
||||||
|
|
||||||
|
if(hand){
|
||||||
|
convertHandDepth(dtl.z);
|
||||||
|
convertHandDepth(dtr.z);
|
||||||
|
convertHandDepth(dmc.z);
|
||||||
|
convertHandDepth(dbl.z);
|
||||||
|
convertHandDepth(dbr.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 dmin = dmc;
|
||||||
|
dmin = dmin.z > dtr.z ? dtr : dmin;
|
||||||
|
dmin = dmin.z > dtl.z ? dtl : dmin;
|
||||||
|
dmin = dmin.z > dbl.z ? dbl : dmin;
|
||||||
|
dmin = dmin.z > dbr.z ? dbr : dmin;
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
dmin.xy = dmin.xy/RENDER_SCALE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return dmin;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
#endif
|
||||||
|
uniform float near;
|
||||||
|
uniform float far;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
float ld(float dist) {
|
||||||
|
return (2.0 * near) / (far + near - dist * (far - near));
|
||||||
|
}
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
float invertlinearDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return ((2.0*near/depth)-far-near)/(far-near);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toClipSpace3Prev_DH( vec3 viewSpacePosition, bool depthCheck ) {
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
mat4 projectionMatrix = depthCheck ? dhPreviousProjection : gbufferPreviousProjection;
|
||||||
|
return projMAD(projectionMatrix, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
#else
|
||||||
|
return projMAD(gbufferPreviousProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toScreenSpace_DH_special(vec3 POS, bool depthCheck ) {
|
||||||
|
|
||||||
|
vec4 viewPos = vec4(0.0);
|
||||||
|
vec3 feetPlayerPos = vec3(0.0);
|
||||||
|
vec4 iProjDiag = vec4(0.0);
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
if (depthCheck) {
|
||||||
|
iProjDiag = vec4(dhProjectionInverse[0].x, dhProjectionInverse[1].y, dhProjectionInverse[2].zw);
|
||||||
|
|
||||||
|
feetPlayerPos = POS * 2.0 - 1.0;
|
||||||
|
viewPos = iProjDiag * feetPlayerPos.xyzz + dhProjectionInverse[3];
|
||||||
|
viewPos.xyz /= viewPos.w;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
#endif
|
||||||
|
iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
|
||||||
|
feetPlayerPos = POS * 2.0 - 1.0;
|
||||||
|
viewPos = iProjDiag * feetPlayerPos.xyzz + gbufferProjectionInverse[3];
|
||||||
|
viewPos.xyz /= viewPos.w;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return viewPos.xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
vec4 TAA_hq(bool hand){
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
vec2 adjTC = clamp(texcoord*RENDER_SCALE, vec2(0.0), RENDER_SCALE - texelSize*2.0);
|
||||||
|
#else
|
||||||
|
vec2 adjTC = texcoord;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
bool depthCheck = texture2D(depthtex0,adjTC).x >= 1.0;
|
||||||
|
|
||||||
|
//use velocity from the nearest texel from camera in a 3x3 box in order to improve edge quality in motion
|
||||||
|
#ifdef CLOSEST_VELOCITY
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
vec3 closestToCamera = closestToCamera5taps_DH(adjTC, depthtex0, dhDepthTex, depthCheck, hand);
|
||||||
|
#else
|
||||||
|
vec3 closestToCamera = closestToCamera5taps(adjTC,depthtex0, hand);
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef CLOSEST_VELOCITY
|
||||||
|
vec3 closestToCamera = vec3(texcoord, texture2D(depthtex1,adjTC).x);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//reproject previous frame
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
vec3 viewPos = toScreenSpace_DH_special(closestToCamera, depthCheck);
|
||||||
|
#else
|
||||||
|
vec3 viewPos = toScreenSpace(closestToCamera);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
viewPos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz + (cameraPosition - previousCameraPosition);
|
||||||
|
|
||||||
|
vec3 previousPosition = mat3(gbufferPreviousModelView) * viewPos + gbufferPreviousModelView[3].xyz;
|
||||||
|
previousPosition = toClipSpace3Prev_DH(previousPosition, depthCheck);
|
||||||
|
|
||||||
|
vec2 velocity = previousPosition.xy - closestToCamera.xy;
|
||||||
|
previousPosition.xy = texcoord + velocity;
|
||||||
|
|
||||||
|
//reject history if off-screen and early exit
|
||||||
|
if (previousPosition.x < 0.0 || previousPosition.y < 0.0 || previousPosition.x > 1.0 || previousPosition.y > 1.0)
|
||||||
|
return vec4(smoothfilter(colortex3, adjTC + offsets[framemod8]*texelSize*0.5).xyz,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
vec3 albedoCurrent0 = smoothfilter(colortex3, adjTC + offsets[framemod8]*texelSize*0.5).xyz;
|
||||||
|
// Interpolating neighboorhood clampling boundaries between pixels
|
||||||
|
vec3 cMax = texture2D(colortex0, adjTC).rgb;
|
||||||
|
vec3 cMin = texture2D(colortex6, adjTC).rgb;
|
||||||
|
#else
|
||||||
|
vec3 albedoCurrent0 = texture2D(colortex3, adjTC).rgb;
|
||||||
|
vec3 albedoCurrent1 = texture2D(colortex3, adjTC + vec2(texelSize.x,texelSize.y)).rgb;
|
||||||
|
vec3 albedoCurrent2 = texture2D(colortex3, adjTC + vec2(texelSize.x,-texelSize.y)).rgb;
|
||||||
|
vec3 albedoCurrent3 = texture2D(colortex3, adjTC + vec2(-texelSize.x,-texelSize.y)).rgb;
|
||||||
|
vec3 albedoCurrent4 = texture2D(colortex3, adjTC + vec2(-texelSize.x,texelSize.y)).rgb;
|
||||||
|
vec3 albedoCurrent5 = texture2D(colortex3, adjTC + vec2(0.0,texelSize.y)).rgb;
|
||||||
|
vec3 albedoCurrent6 = texture2D(colortex3, adjTC + vec2(0.0,-texelSize.y)).rgb;
|
||||||
|
vec3 albedoCurrent7 = texture2D(colortex3, adjTC + vec2(-texelSize.x,0.0)).rgb;
|
||||||
|
vec3 albedoCurrent8 = texture2D(colortex3, adjTC + vec2(texelSize.x,0.0)).rgb;
|
||||||
|
//Assuming the history color is a blend of the 3x3 neighborhood, we clamp the history to the min and max of each channel in the 3x3 neighborhood
|
||||||
|
vec3 cMax = max(max(max(albedoCurrent0,albedoCurrent1),albedoCurrent2),max(albedoCurrent3,max(albedoCurrent4,max(albedoCurrent5,max(albedoCurrent6,max(albedoCurrent7,albedoCurrent8))))));
|
||||||
|
vec3 cMin = min(min(min(albedoCurrent0,albedoCurrent1),albedoCurrent2),min(albedoCurrent3,min(albedoCurrent4,min(albedoCurrent5,min(albedoCurrent6,min(albedoCurrent7,albedoCurrent8))))));
|
||||||
|
albedoCurrent0 = smoothfilter(colortex3, adjTC + offsets[framemod8]*texelSize*0.5).rgb;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef SCREENSHOT_MODE
|
||||||
|
|
||||||
|
vec3 albedoPrev = max(FastCatmulRom(colortex5, previousPosition.xy,vec4(texelSize, 1.0/texelSize), 0.75).xyz, 0.0);
|
||||||
|
vec3 finalcAcc = clamp(albedoPrev, cMin, cMax);
|
||||||
|
|
||||||
|
//Increases blending factor when far from AABB and in motion, reduces ghosting
|
||||||
|
float isclamped = distance(albedoPrev,finalcAcc)/luma(albedoPrev) * 0.5;
|
||||||
|
float movementRejection = (0.12+isclamped)*clamp(length(velocity/texelSize),0.0,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
float depthDiff = texture2D(colortex14, previousPosition.xy).a;
|
||||||
|
// movementRejection = mix( 0.0, 1.0, depthDiff);
|
||||||
|
|
||||||
|
if(hand) movementRejection *= 5.0;
|
||||||
|
|
||||||
|
//Blend current pixel with clamped history, apply fast tonemap beforehand to reduce flickering
|
||||||
|
vec4 supersampled = vec4(invTonemap(mix(tonemap(finalcAcc), tonemap(albedoCurrent0), clamp(BLEND_FACTOR + movementRejection, 0.0,1.0))), 1.0);
|
||||||
|
|
||||||
|
//De-tonemap
|
||||||
|
return supersampled;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef SCREENSHOT_MODE
|
||||||
|
vec4 albedoPrev = texture2D(colortex5, previousPosition.xy);
|
||||||
|
vec3 supersampled = albedoPrev.rgb * albedoPrev.a + albedoCurrent0;
|
||||||
|
|
||||||
|
if ( hideGUI < 1) return vec4(albedoCurrent0,1.0);
|
||||||
|
return vec4(supersampled/(albedoPrev.a+1.0), albedoPrev.a+1.0);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec2 decodeVec2(float a){
|
||||||
|
const vec2 constant1 = 65535. / vec2( 256., 65536.);
|
||||||
|
const float constant2 = 256. / 255.;
|
||||||
|
return fract( a * constant1 ) * constant2 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:5 */
|
||||||
|
|
||||||
|
gl_FragData[0].a = 1.0;
|
||||||
|
|
||||||
|
#ifdef TAA
|
||||||
|
float dataUnpacked = decodeVec2(texture2D(colortex1,texcoord).w).y;
|
||||||
|
bool hand = abs(dataUnpacked-0.75) < 0.01 && texture2D(depthtex1,texcoord).x < 1.0;
|
||||||
|
|
||||||
|
vec4 color = TAA_hq(hand);
|
||||||
|
|
||||||
|
#if DEBUG_VIEW == debug_TEMPORAL_REPROJECTION
|
||||||
|
color.rgb = texture2D(colortex3, texcoord).rgb;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef SCREENSHOT_MODE
|
||||||
|
gl_FragData[0] = clamp(color, 0.0, 65000.0);
|
||||||
|
#else
|
||||||
|
gl_FragData[0] = clamp(fp10Dither(color, triangularize(interleaved_gradientNoise())), 0.0, 65000.0);
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
vec3 color = clamp(fp10Dither(vec4(texture2D(colortex3,texcoord).rgb,1.0), triangularize(interleaved_gradientNoise())).rgb,0.0,65000.);
|
||||||
|
gl_FragData[0].rgb = color;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,29 @@
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
varying vec2 texcoord;
|
||||||
|
flat varying float tempOffsets;
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
uniform int frameCounter;
|
||||||
|
|
||||||
|
|
||||||
|
uniform int framemod8;
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
gl_Position = ftransform();
|
||||||
|
texcoord = gl_MultiTexCoord0.xy;
|
||||||
|
|
||||||
|
tempOffsets = HaltonSeq2(frameCounter%10000);
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*RENDER_SCALE*2.0-1.0;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,58 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D colortex1;
|
||||||
|
uniform sampler2D colortex5;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
|
||||||
|
vec2 decodeVec2(float a){
|
||||||
|
const vec2 constant1 = 65535. / vec2( 256., 65536.);
|
||||||
|
const float constant2 = 256. / 255.;
|
||||||
|
return fract( a * constant1 ) * constant2 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
/* DRAWBUFFERS:3 */
|
||||||
|
|
||||||
|
vec2 resScale = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.))/vec2(1920.,1080.);
|
||||||
|
vec2 quarterResTC = gl_FragCoord.xy*2.0*resScale*texelSize;
|
||||||
|
|
||||||
|
// vec2 texcoord = (gl_FragCoord.xy*2.0*resScale*texelSize) * RENDER_SCALE;
|
||||||
|
|
||||||
|
// bool hand = abs(decodeVec2(texture2D(colortex1,texcoord).w).y-0.75) < 0.01 && texture2D(depthtex0,texcoord).x < 1.0;
|
||||||
|
|
||||||
|
//0.5
|
||||||
|
gl_FragData[0] = texture2D(colortex5,quarterResTC-1.0*vec2(texelSize.x,texelSize.y))/4.*0.5;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+1.0*vec2(texelSize.x,texelSize.y))/4.*0.5;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+vec2(-1.0*texelSize.x,1.0*texelSize.y))/4.*0.5;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+vec2(1.0*texelSize.x,-1.0*texelSize.y))/4.*0.5;
|
||||||
|
|
||||||
|
//0.25
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC-2.0*vec2(texelSize.x,0.0))/2.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+2.0*vec2(0.0,texelSize.y))/2.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+2.0*vec2(0,-texelSize.y))/2*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+2.0*vec2(-texelSize.x,0.0))/2*0.125;
|
||||||
|
|
||||||
|
//0.125
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC-2.0*vec2(texelSize.x,texelSize.y))/4.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+2.0*vec2(texelSize.x,texelSize.y))/4.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+vec2(-2.0*texelSize.x,2.0*texelSize.y))/4.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC+vec2(2.0*texelSize.x,-2.0*texelSize.y))/4.*0.125;
|
||||||
|
|
||||||
|
//0.125
|
||||||
|
gl_FragData[0] += texture2D(colortex5,quarterResTC)*0.125;
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(gl_FragData[0].rgb,0.0,65000.);
|
||||||
|
if (quarterResTC.x > 1.0 - 3.5*texelSize.x || quarterResTC.y > 1.0 -3.5*texelSize.y || quarterResTC.x < 3.5*texelSize.x || quarterResTC.y < 3.5*texelSize.y) gl_FragData[0].rgb = vec3(0.0);
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
//Improves performances and makes sure bloom radius stays the same at high resolution (>1080p)
|
||||||
|
vec2 clampedRes = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
gl_Position = ftransform();
|
||||||
|
//*0.51 to avoid errors when sampling outside since clearing is disabled
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*0.51/clampedRes*vec2(1920.0,1080.)*2.0-1.0;
|
||||||
|
}
|
|
@ -0,0 +1,42 @@
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
/* DRAWBUFFERS:6 */
|
||||||
|
vec2 resScale = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.))/vec2(1920.,1080.);
|
||||||
|
vec2 quarterResTC = gl_FragCoord.xy*2.*texelSize;
|
||||||
|
|
||||||
|
//0.5
|
||||||
|
gl_FragData[0] = texture2D(colortex3,quarterResTC-1.0*vec2(texelSize.x,texelSize.y))/4.*0.5;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+1.0*vec2(texelSize.x,texelSize.y))/4.*0.5;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+vec2(-1.0*texelSize.x,1.0*texelSize.y))/4.*0.5;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+vec2(1.0*texelSize.x,-1.0*texelSize.y))/4.*0.5;
|
||||||
|
|
||||||
|
//0.25
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC-2.0*vec2(texelSize.x,0.0))/2.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+2.0*vec2(0.0,texelSize.y))/2.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+2.0*vec2(0,-texelSize.y))/2*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+2.0*vec2(-texelSize.x,0.0))/2*0.125;
|
||||||
|
|
||||||
|
//0.125
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC-2.0*vec2(texelSize.x,texelSize.y))/4.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+2.0*vec2(texelSize.x,texelSize.y))/4.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+vec2(-2.0*texelSize.x,2.0*texelSize.y))/4.*0.125;
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC+vec2(2.0*texelSize.x,-2.0*texelSize.y))/4.*0.125;
|
||||||
|
|
||||||
|
//0.125
|
||||||
|
gl_FragData[0] += texture2D(colortex3,quarterResTC)*0.125;
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(gl_FragData[0].rgb,0.0,65000.);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
//Improves performances and makes sure bloom radius stays the same at high resolution (>1080p)
|
||||||
|
vec2 clampedRes = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
gl_Position = ftransform();
|
||||||
|
//*0.51 to avoid errors when sampling outside since clearing is disabled
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*0.26/clampedRes*vec2(1920.0,1080.)*2-1.0;
|
||||||
|
}
|
|
@ -0,0 +1,57 @@
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
vec2 resScale = vec2(1920.,1080.)/max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
vec3 gauss1D(vec2 coord,vec2 dir,float alpha,int maxIT){
|
||||||
|
vec4 tot = vec4(0.);
|
||||||
|
float maxTC = 0.25*resScale.x;
|
||||||
|
float minTC = 0.;
|
||||||
|
for (int i = -maxIT;i<maxIT+1;i++){
|
||||||
|
float weight = exp(-i*i*alpha*4.0);
|
||||||
|
//here we take advantage of bilinear filtering for 2x less sample, as a side effect the gaussian won't be totally centered for small blurs
|
||||||
|
vec2 spCoord = coord+dir*texelSize*(2.0*i+0.5);
|
||||||
|
tot += vec4(texture2D(colortex6,spCoord).rgb,1.0)*weight*float(spCoord.x > minTC && spCoord.x < maxTC);
|
||||||
|
}
|
||||||
|
return tot.rgb/max(1.0,tot.a);
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:6 */
|
||||||
|
|
||||||
|
vec2 texcoord = (gl_FragCoord.xy*vec2(2.0,4.0))*texelSize;
|
||||||
|
vec2 gaussDir = vec2(1.0,0.0);
|
||||||
|
gl_FragData[0].rgb = vec3(0.0);
|
||||||
|
vec2 tc2 = texcoord*vec2(2.0,1.)/2.;
|
||||||
|
if (tc2.x < 1.0*resScale.x && tc2.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(tc2/2,gaussDir,0.16,0);
|
||||||
|
|
||||||
|
vec2 tc4 = texcoord*vec2(4.0,1.)/2.-vec2(0.5*resScale.x+4.0*texelSize.x,0.)*2.0;
|
||||||
|
if (tc4.x > 0.0 && tc4.y > 0.0 && tc4.x < 1.0*resScale.x && tc4.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(tc4/2,gaussDir,0.16,3);
|
||||||
|
|
||||||
|
vec2 tc8 = texcoord*vec2(8.0,1.)/2.-vec2(0.75*resScale.x+8.*texelSize.x,0.)*4.0;
|
||||||
|
if (tc8.x > 0.0 && tc8.y > 0.0 && tc8.x < 1.0*resScale.x && tc8.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(tc8/2,gaussDir,0.035,6);
|
||||||
|
|
||||||
|
vec2 tc16 = texcoord*vec2(8.0,1./2.)-vec2(0.875*resScale.x+12.*texelSize.x,0.)*8.0;
|
||||||
|
if (tc16.x > 0.0 && tc16.y > 0.0 && tc16.x < 1.0*resScale.x && tc16.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(tc16/2,gaussDir,0.0085,12);
|
||||||
|
|
||||||
|
vec2 tc32 = texcoord*vec2(16.0,1./2.)-vec2(0.9375*resScale.x+16.*texelSize.x,0.)*16.0;
|
||||||
|
if (tc32.x > 0.0 && tc32.y > 0.0 && tc32.x < 1.0*resScale.x && tc32.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(tc32/2,gaussDir,0.002,28);
|
||||||
|
|
||||||
|
vec2 tc64 = texcoord*vec2(32.0,1./2.)-vec2(0.96875*resScale.x+20.*texelSize.x,0.)*32.0;
|
||||||
|
if (tc64.x > 0.0 && tc64.y > 0.0 && tc64.x < 1.0*resScale.x && tc64.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(tc64/2,gaussDir,0.0005,60);
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(gl_FragData[0].rgb,0.0,65000.);
|
||||||
|
}
|
|
@ -0,0 +1,18 @@
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
vec2 clampedRes = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.0));
|
||||||
|
gl_Position = ftransform();
|
||||||
|
//0-0.25
|
||||||
|
gl_Position.y = (gl_Position.y*0.5+0.5)*0.25/clampedRes.y*1080.0*2.0-1.0;
|
||||||
|
//0-0.5
|
||||||
|
gl_Position.x = (gl_Position.x*0.5+0.5)*0.5/clampedRes.x*1920.0*2.0-1.0;
|
||||||
|
texcoord = gl_MultiTexCoord0.xy/clampedRes*vec2(1920.,1080.);
|
||||||
|
}
|
|
@ -0,0 +1,56 @@
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
vec2 resScale = vec2(1920.,1080.)/max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.));
|
||||||
|
vec3 gauss1D(vec2 coord,vec2 dir,float alpha,int maxIT){
|
||||||
|
vec4 tot = vec4(0.);
|
||||||
|
float maxTC = 0.25*resScale.y;
|
||||||
|
float minTC = 0.;
|
||||||
|
for (int i = -maxIT;i<maxIT+1;i++){
|
||||||
|
float weight = exp(-i*i*alpha*4.0);
|
||||||
|
vec2 spCoord = coord+dir*texelSize*(2.0*i+0.5);
|
||||||
|
tot += vec4(texture2D(colortex6,spCoord).rgb,1.0)*weight*float(spCoord.y > minTC && spCoord.y < maxTC);
|
||||||
|
}
|
||||||
|
return tot.rgb/max(1.0,tot.a);
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:6 */
|
||||||
|
vec2 texcoord = (gl_FragCoord.xy*vec2(2.0,4.0))*texelSize;
|
||||||
|
|
||||||
|
vec2 gaussDir = vec2(0.0,1.0);
|
||||||
|
gl_FragData[0].rgb = vec3(0.0);
|
||||||
|
vec2 tc2 = texcoord*vec2(2.0,1.);
|
||||||
|
if (tc2.x < 1.0*resScale.x && tc2.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(texcoord/vec2(2.0,4.0),gaussDir,0.16,0);
|
||||||
|
|
||||||
|
vec2 tc4 = texcoord*vec2(4.0,2.)-vec2(0.5*resScale.x+4.0*texelSize.x,0.)*4.0;
|
||||||
|
if (tc4.x > 0.0 && tc4.y > 0.0 && tc4.x < 1.0*resScale.x && tc4.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(texcoord/vec2(2.0,2.0),gaussDir,0.16,3);
|
||||||
|
|
||||||
|
vec2 tc8 = texcoord*vec2(8.0,4.)-vec2(0.75*resScale.x+8.*texelSize.x,0.)*8.0;
|
||||||
|
if (tc8.x > 0.0 && tc8.y > 0.0 && tc8.x < 1.0*resScale.x && tc8.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(texcoord*vec2(1.0,2.0)/vec2(2.0,2.0),gaussDir,0.035,6);
|
||||||
|
|
||||||
|
vec2 tc16 = texcoord*vec2(16.0,8.)-vec2(0.875*resScale.x+12.*texelSize.x,0.)*16.0;
|
||||||
|
if (tc16.x > 0.0 && tc16.y > 0.0 && tc16.x < 1.0*resScale.x && tc16.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(texcoord*vec2(1.0,4.0)/vec2(2.0,2.0),gaussDir,0.0085,12);
|
||||||
|
|
||||||
|
vec2 tc32 = texcoord*vec2(32.0,16.)-vec2(0.9375*resScale.x+16.*texelSize.x,0.)*32.0;
|
||||||
|
if (tc32.x > 0.0 && tc32.y > 0.0 && tc32.x < 1.0*resScale.x && tc32.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(texcoord*vec2(1.0,8.0)/vec2(2.0,2.0),gaussDir,0.002,30);
|
||||||
|
|
||||||
|
vec2 tc64 = texcoord*vec2(64.0,32.)-vec2(0.96875*resScale.x+20.*texelSize.x,0.)*64.0;
|
||||||
|
if (tc64.x > 0.0 && tc64.y > 0.0 && tc64.x < 1.0*resScale.x && tc64.y <1.0*resScale.y)
|
||||||
|
gl_FragData[0].xyz = gauss1D(texcoord*vec2(1.0,16.0)/vec2(2.0,2.0),gaussDir,0.0005,60);
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(gl_FragData[0].rgb,0.0,65000.);
|
||||||
|
}
|
|
@ -0,0 +1,19 @@
|
||||||
|
uniform float viewWidth;
|
||||||
|
uniform float viewHeight;
|
||||||
|
varying vec2 texcoord;
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
vec2 clampedRes = max(vec2(viewWidth,viewHeight),vec2(1920.0,1080.0));
|
||||||
|
gl_Position = ftransform();
|
||||||
|
//0-0.25
|
||||||
|
gl_Position.y = (gl_Position.y*0.5+0.5)*0.25/clampedRes.y*1080.0*2.0-1.0;
|
||||||
|
//0-0.5
|
||||||
|
gl_Position.x = (gl_Position.x*0.5+0.5)*0.5/clampedRes.x*1920.0*2.0-1.0;
|
||||||
|
texcoord = gl_MultiTexCoord0.xy/clampedRes*vec2(1920.,1080.);
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,395 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
#define ReflectedFog
|
||||||
|
|
||||||
|
#define USE_WEATHER_PARAMS
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
flat varying vec4 dailyWeatherParams0;
|
||||||
|
flat varying vec4 dailyWeatherParams1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
|
||||||
|
flat varying vec3 lightSourceColor;
|
||||||
|
flat varying vec3 sunColor;
|
||||||
|
flat varying vec3 moonColor;
|
||||||
|
// flat varying vec3 zenithColor;
|
||||||
|
// flat varying vec3 rayleighAborbance;
|
||||||
|
|
||||||
|
// flat varying vec3 WsunVec;
|
||||||
|
|
||||||
|
flat varying vec2 tempOffsets;
|
||||||
|
|
||||||
|
flat varying float exposure;
|
||||||
|
flat varying float avgBrightness;
|
||||||
|
flat varying float rodExposure;
|
||||||
|
flat varying float avgL2;
|
||||||
|
flat varying float centerDepth;
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
|
||||||
|
uniform float frameTime;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform float eyeAltitude;
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
uniform mat4 gbufferPreviousProjection;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 shadowModelView;
|
||||||
|
uniform mat4 shadowProjection;
|
||||||
|
uniform float sunElevation;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
// uniform float far;
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
|
||||||
|
|
||||||
|
vec4 lightCol = vec4(lightSourceColor, float(sunElevation > 1e-5)*2-1.);
|
||||||
|
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/ROBOBO_sky.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
vec3 WsunVec = mat3(gbufferModelViewInverse)*sunVec;
|
||||||
|
// vec3 WsunVec = normalize(LightDir);
|
||||||
|
|
||||||
|
vec3 toShadowSpaceProjected(vec3 p3){
|
||||||
|
p3 = mat3(gbufferModelViewInverse) * p3 + gbufferModelViewInverse[3].xyz;
|
||||||
|
p3 = mat3(shadowModelView) * p3 + shadowModelView[3].xyz;
|
||||||
|
p3 = diagonal3(shadowProjection) * p3 + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
return p3;
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y)+frameCounter/1.6180339887);
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
|
||||||
|
#define DHVLFOG
|
||||||
|
// #define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
// #define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 feetPlayerPos = p * 2. - 1.;
|
||||||
|
vec4 viewPos = iProjDiag * feetPlayerPos.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return viewPos.xyz / viewPos.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
vec3 DH_toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(dhProjectionInverse[0].x, dhProjectionInverse[1].y, dhProjectionInverse[2].zw);
|
||||||
|
vec3 feetPlayerPos = p * 2. - 1.;
|
||||||
|
vec4 viewPos = iProjDiag * feetPlayerPos.xyzz + dhProjectionInverse[3];
|
||||||
|
return viewPos.xyz / viewPos.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 DH_toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(dhProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
// float DH_ld(float dist) {
|
||||||
|
// return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
// }
|
||||||
|
// float DH_invLinZ (float lindepth){
|
||||||
|
// return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
// }
|
||||||
|
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
|
||||||
|
// uniform sampler2D colortex12;
|
||||||
|
// const bool shadowHardwareFiltering = true;
|
||||||
|
uniform sampler2DShadow shadow;
|
||||||
|
|
||||||
|
// #undef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2DShadow shadowtex0;
|
||||||
|
uniform sampler2DShadow shadowtex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define TEST
|
||||||
|
#define TIMEOFDAYFOG
|
||||||
|
#include "/lib/lightning_stuff.glsl"
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#include "/lib/overworld_fog.glsl"
|
||||||
|
|
||||||
|
#endif
|
||||||
|
#ifdef NETHER_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#include "/lib/nether_fog.glsl"
|
||||||
|
#endif
|
||||||
|
#ifdef END_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#include "/lib/end_fog.glsl"
|
||||||
|
#endif
|
||||||
|
vec3 rodSample(vec2 Xi)
|
||||||
|
{
|
||||||
|
float r = sqrt(1.0f - Xi.x*Xi.y);
|
||||||
|
float phi = 2 * 3.14159265359 * Xi.y;
|
||||||
|
|
||||||
|
return normalize(vec3(cos(phi) * r, sin(phi) * r, Xi.x)).xzy;
|
||||||
|
}
|
||||||
|
//Low discrepancy 2D sequence, integration error is as low as sobol but easier to compute : http://extremelearning.com.au/unreasonable-effectiveness-of-quasirandom-sequences/
|
||||||
|
vec2 R2_samples(float n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:4 */
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(0.0);
|
||||||
|
float mixhistory = 0.06;
|
||||||
|
|
||||||
|
float accumuteSpeed = texelFetch2D(colortex4, ivec2(5,5), 0).r/150.0;
|
||||||
|
|
||||||
|
vec2 pixelPos6 = vec2(5,5);
|
||||||
|
|
||||||
|
if (gl_FragCoord.x > pixelPos6.x && gl_FragCoord.x < pixelPos6.x + 1 && gl_FragCoord.y > pixelPos6.y && gl_FragCoord.y < pixelPos6.y + 1){
|
||||||
|
mixhistory = 0.1;
|
||||||
|
gl_FragData[0] = vec4(1,0,0,1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
|
||||||
|
//////////////////////////////////////////////
|
||||||
|
/// --- STORE DAILY WEATHER PARAMETERS --- ///
|
||||||
|
//////////////////////////////////////////////
|
||||||
|
|
||||||
|
// the idea is to store the 8 values, coverage + density of 3 cloud layers and 2 fog density values.
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
ivec2 pixelPos = ivec2(0,0);
|
||||||
|
if (gl_FragCoord.x > 1 && gl_FragCoord.x < 3 && gl_FragCoord.y > 1 && gl_FragCoord.y < 2){
|
||||||
|
|
||||||
|
mixhistory = 0.01;
|
||||||
|
|
||||||
|
if(gl_FragCoord.x < 2) gl_FragData[0] = dailyWeatherParams0;
|
||||||
|
if(gl_FragCoord.x > 2) gl_FragData[0] = dailyWeatherParams1;
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
///////////////////////////////
|
||||||
|
/// --- STORE COLOR LUT --- ///
|
||||||
|
///////////////////////////////
|
||||||
|
|
||||||
|
vec3 AmbientLightTint = vec3(AmbientLight_R, AmbientLight_G, AmbientLight_B);
|
||||||
|
|
||||||
|
// --- the color of the atmosphere + the average color of the atmosphere.
|
||||||
|
vec3 skyGroundCol = skyFromTex(vec3(0, -1 ,0), colortex4).rgb;// * clamp(WsunVec.y*2.0,0.2,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/// --- Save light values
|
||||||
|
if (gl_FragCoord.x < 1. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(averageSkyCol_Clouds * AmbientLightTint,1.0);
|
||||||
|
|
||||||
|
if (gl_FragCoord.x > 1. && gl_FragCoord.x < 2. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4((skyGroundCol/150.0) * AmbientLightTint,1.0);
|
||||||
|
|
||||||
|
#ifdef ambientLight_only
|
||||||
|
if (gl_FragCoord.x > 6. && gl_FragCoord.x < 7. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(0.0,0.0,0.0,1.0);
|
||||||
|
|
||||||
|
if (gl_FragCoord.x > 8. && gl_FragCoord.x < 9. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(0.0,0.0,0.0,1.0);
|
||||||
|
|
||||||
|
if (gl_FragCoord.x > 13. && gl_FragCoord.x < 14. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(0.0,0.0,0.0,1.0);
|
||||||
|
#else
|
||||||
|
if (gl_FragCoord.x > 6. && gl_FragCoord.x < 7. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(lightSourceColor,1.0);
|
||||||
|
|
||||||
|
if (gl_FragCoord.x > 8. && gl_FragCoord.x < 9. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(sunColor,1.0);
|
||||||
|
if (gl_FragCoord.x > 9. && gl_FragCoord.x < 10. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(moonColor,1.0);
|
||||||
|
// if (gl_FragCoord.x > 16. && gl_FragCoord.x < 17. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
// gl_FragData[0] = vec4(rayleighAborbance,1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
////////////////////////////////
|
||||||
|
/// --- ATMOSPHERE IMAGE --- ///
|
||||||
|
////////////////////////////////
|
||||||
|
|
||||||
|
/// --- Sky only
|
||||||
|
if (gl_FragCoord.x > 18. && gl_FragCoord.y > 1. && gl_FragCoord.x < 18+257){
|
||||||
|
|
||||||
|
|
||||||
|
vec2 p = clamp(floor(gl_FragCoord.xy-vec2(18.,1.))/256.+tempOffsets/256.,0.0,1.0);
|
||||||
|
vec3 viewVector = cartToSphere(p);
|
||||||
|
|
||||||
|
vec2 planetSphere = vec2(0.0);
|
||||||
|
vec3 sky = vec3(0.0);
|
||||||
|
vec3 skyAbsorb = vec3(0.0);
|
||||||
|
|
||||||
|
// float GroundDarkening = (exp2(-15 * clamp(-viewVector.y,0.0,1.0)) * 0.7+0.3); // darken the ground in the sky.
|
||||||
|
sky = calculateAtmosphere((averageSkyCol*4000./2.0) , viewVector, vec3(0.0,1.0,0.0), WsunVec, -WsunVec, planetSphere, skyAbsorb, 10, blueNoise());
|
||||||
|
|
||||||
|
// sky = mix(sky, (averageSkyCol + skyAbsorb)*4000./2.0, (1.0 - exp(pow(clamp(-viewVector.y+0.5,0.0,1.0),2) * -25)));
|
||||||
|
|
||||||
|
// fade atmosphere conditions for rain away when you pass above the cloud plane.
|
||||||
|
float heightRelativeToClouds = clamp(1.0 - max(eyeAltitude - CloudLayer0_height,0.0) / 200.0 ,0.0,1.0);
|
||||||
|
if(rainStrength > 0.0) sky = mix(sky, 3.0 + averageSkyCol*4000 * (skyAbsorb*0.7+0.3), clamp(1.0 - exp(pow(clamp(-viewVector.y+0.9,0.0,1.0),2) * -5.0),0.0,1.0) * heightRelativeToClouds * rainStrength);
|
||||||
|
|
||||||
|
#ifdef AEROCHROME_MODE
|
||||||
|
sky *= vec3(0.0, 0.18, 0.35);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(sky / 4000.0 * Sky_Brightness, 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// --- Sky + clouds + fog
|
||||||
|
if (gl_FragCoord.x > 18.+257. && gl_FragCoord.y > 1. && gl_FragCoord.x < 18+257+257.){
|
||||||
|
vec2 p = clamp(floor(gl_FragCoord.xy-vec2(18.+257,1.))/256.+tempOffsets/256.,0.0,1.0);
|
||||||
|
vec3 viewVector = cartToSphere(p);
|
||||||
|
|
||||||
|
WsunVec = normalize(mat3(gbufferModelViewInverse) * sunPosition) * ( float(sunElevation > 1e-5)*2.0-1.0 );
|
||||||
|
|
||||||
|
vec3 sky = texelFetch2D(colortex4,ivec2(gl_FragCoord.xy)-ivec2(257,0),0).rgb/150.0;
|
||||||
|
|
||||||
|
vec3 suncol = lightSourceColor;
|
||||||
|
|
||||||
|
#ifdef ambientLight_only
|
||||||
|
suncol = vec3(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec4 clouds = renderClouds(mat3(gbufferModelView)*viewVector*1024., vec2(fract(frameCounter/1.6180339887),1-fract(frameCounter/1.6180339887)), suncol*2.0, skyGroundCol/30.0);
|
||||||
|
sky = sky*clouds.a + clouds.rgb / 5.0;
|
||||||
|
|
||||||
|
sky = mix(dot(sky,vec3(0.333)) * vec3(0.5), sky, pow(clamp(viewVector.y+1.0,0.0,1.0),5));
|
||||||
|
vec4 VL_Fog = GetVolumetricFog(mat3(gbufferModelView)*viewVector*1024., vec2(fract(frameCounter/1.6180339887),1-fract(frameCounter/1.6180339887)), suncol*1.75, skyGroundCol/30.0);
|
||||||
|
|
||||||
|
sky = sky * VL_Fog.a + VL_Fog.rgb / 5.0;
|
||||||
|
|
||||||
|
|
||||||
|
// if(p.y < 0.05) sky = averageSkyCol_Clouds;
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(sky,1.0);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined NETHER_SHADER || defined END_SHADER
|
||||||
|
vec2 fogPos = vec2(256.0 - 256.0*0.12,1.0);
|
||||||
|
|
||||||
|
//Sky gradient with clouds
|
||||||
|
if (gl_FragCoord.x > (fogPos.x - fogPos.x*0.22) && gl_FragCoord.y > 0.4 && gl_FragCoord.x < 535){
|
||||||
|
vec2 p = clamp(floor(gl_FragCoord.xy-fogPos)/256.+tempOffsets/256.,-0.2,1.2);
|
||||||
|
vec3 viewVector = cartToSphere(p);
|
||||||
|
|
||||||
|
vec3 BackgroundColor = vec3(0.0);
|
||||||
|
|
||||||
|
vec4 VL_Fog = GetVolumetricFog(mat3(gbufferModelView)*viewVector*256., fract(frameCounter/1.6180339887), fract(frameCounter/2.6180339887));
|
||||||
|
|
||||||
|
BackgroundColor += VL_Fog.rgb/5.0;
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(BackgroundColor, 1.0);
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
/* ---------------------- TIMER ---------------------- */
|
||||||
|
|
||||||
|
float flash = 0.0;
|
||||||
|
float maxWaitTime = 5;
|
||||||
|
|
||||||
|
float Timer = texelFetch2D(colortex4, ivec2(3,1), 0).x/150.0;
|
||||||
|
Timer -= frameTime;
|
||||||
|
|
||||||
|
if(Timer <= 0.0){
|
||||||
|
flash = 1.0;
|
||||||
|
|
||||||
|
Timer = pow(hash11(frameCounter), 5) * maxWaitTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 pixelPos0 = vec2(3,1);
|
||||||
|
if (gl_FragCoord.x > pixelPos0.x && gl_FragCoord.x < pixelPos0.x + 1 && gl_FragCoord.y > pixelPos0.y && gl_FragCoord.y < pixelPos0.y + 1){
|
||||||
|
mixhistory = 1.0;
|
||||||
|
gl_FragData[0] = vec4(Timer, 0.0, 0.0, 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---------------------- FLASHING ---------------------- */
|
||||||
|
|
||||||
|
vec2 pixelPos1 = vec2(1,1);
|
||||||
|
if (gl_FragCoord.x > pixelPos1.x && gl_FragCoord.x < pixelPos1.x + 1 && gl_FragCoord.y > pixelPos1.y && gl_FragCoord.y < pixelPos1.y + 1){
|
||||||
|
mixhistory = clamp(4.0 * frameTime,0.0,1.0);
|
||||||
|
gl_FragData[0] = vec4(flash, 0.0, 0.0, 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---------------------- POSITION ---------------------- */
|
||||||
|
|
||||||
|
vec2 pixelPos2 = vec2(2,1);
|
||||||
|
if (gl_FragCoord.x > pixelPos2.x && gl_FragCoord.x < pixelPos2.x + 1 && gl_FragCoord.y > pixelPos2.y && gl_FragCoord.y < pixelPos2.y + 1){
|
||||||
|
mixhistory = clamp(500.0 * frameTime,0.0,1.0);
|
||||||
|
|
||||||
|
vec3 LastPos = (texelFetch2D(colortex4,ivec2(2,1),0).xyz/150.0) * 2.0 - 1.0;
|
||||||
|
|
||||||
|
LastPos += (hash31(frameCounter / 50) * 2.0 - 1.0);
|
||||||
|
LastPos = LastPos * 0.5 + 0.5;
|
||||||
|
|
||||||
|
if(Timer > maxWaitTime * 0.7 ){
|
||||||
|
LastPos = vec3(0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
gl_FragData[0] = vec4(LastPos, 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//Temporally accumulate sky and light values
|
||||||
|
vec3 temp = texelFetch2D(colortex4,ivec2(gl_FragCoord.xy),0).rgb;
|
||||||
|
vec3 curr = gl_FragData[0].rgb*150.;
|
||||||
|
|
||||||
|
if(accumuteSpeed < 1.0) mixhistory = 1.0;
|
||||||
|
|
||||||
|
gl_FragData[0].rgb = clamp(mix(temp, curr, mixhistory),0.0,65000.);
|
||||||
|
|
||||||
|
|
||||||
|
//Exposure values
|
||||||
|
if (gl_FragCoord.x > 10. && gl_FragCoord.x < 11. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(exposure, avgBrightness, avgL2,1.0);
|
||||||
|
if (gl_FragCoord.x > 14. && gl_FragCoord.x < 15. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
|
||||||
|
gl_FragData[0] = vec4(rodExposure, centerDepth,0.0, 1.0);
|
||||||
|
}
|
|
@ -0,0 +1,231 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
|
||||||
|
flat varying vec3 sunColor;
|
||||||
|
flat varying vec3 moonColor;
|
||||||
|
flat varying vec3 lightSourceColor;
|
||||||
|
flat varying vec3 zenithColor;
|
||||||
|
|
||||||
|
flat varying vec2 tempOffsets;
|
||||||
|
|
||||||
|
flat varying float exposure;
|
||||||
|
flat varying float avgBrightness;
|
||||||
|
flat varying float rodExposure;
|
||||||
|
flat varying float avgL2;
|
||||||
|
flat varying float centerDepth;
|
||||||
|
|
||||||
|
flat varying vec4 dailyWeatherParams0;
|
||||||
|
flat varying vec4 dailyWeatherParams1;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
uniform sampler2D depthtex2;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float sunElevation;
|
||||||
|
uniform float eyeAltitude;
|
||||||
|
uniform float near;
|
||||||
|
// uniform float far;
|
||||||
|
uniform float frameTime;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float rainStrength;
|
||||||
|
|
||||||
|
// uniform int worldTime;
|
||||||
|
vec3 sunVec = normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
|
||||||
|
// vec3 sunVec = normalize(LightDir);
|
||||||
|
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/ROBOBO_sky.glsl"
|
||||||
|
|
||||||
|
float luma(vec3 color) {
|
||||||
|
return dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
}
|
||||||
|
vec3 rodSample(vec2 Xi)
|
||||||
|
{
|
||||||
|
float r = sqrt(1.0f - Xi.x*Xi.y);
|
||||||
|
float phi = 2 * 3.14159265359 * Xi.y;
|
||||||
|
|
||||||
|
return normalize(vec3(cos(phi) * r, sin(phi) * r, Xi.x)).xzy;
|
||||||
|
}
|
||||||
|
//Low discrepancy 2D sequence, integration error is as low as sobol but easier to compute : http://extremelearning.com.au/unreasonable-effectiveness-of-quasirandom-sequences/
|
||||||
|
vec2 R2_samples(int n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
float tanh(float x){
|
||||||
|
return (exp(x) - exp(-x))/(exp(x) + exp(-x));
|
||||||
|
}
|
||||||
|
float ld(float depth) {
|
||||||
|
return (2.0 * near) / (far + near - depth * (far - near)); // (-depth * (far - near)) = (2.0 * near)/ld - far - near
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform float nightVision;
|
||||||
|
|
||||||
|
uniform int worldDay;
|
||||||
|
void getWeatherParams(
|
||||||
|
inout vec4 weatherParams0,
|
||||||
|
inout vec4 weatherParams1,
|
||||||
|
|
||||||
|
float layer0_coverage,
|
||||||
|
float layer1_coverage,
|
||||||
|
float layer2_coverage,
|
||||||
|
float uniformFog_density,
|
||||||
|
|
||||||
|
float layer0_density,
|
||||||
|
float layer1_density,
|
||||||
|
float layer2_density,
|
||||||
|
float cloudyFog_density
|
||||||
|
){
|
||||||
|
weatherParams0 = vec4(layer0_coverage, layer1_coverage, layer2_coverage, uniformFog_density);
|
||||||
|
weatherParams1 = vec4(layer0_density, layer1_density, layer2_density, cloudyFog_density);
|
||||||
|
}
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
gl_Position = ftransform()*0.5+0.5;
|
||||||
|
gl_Position.xy = gl_Position.xy*vec2(18.+258*2,258.)*texelSize;
|
||||||
|
gl_Position.xy = gl_Position.xy*2.-1.0;
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
|
||||||
|
///////////////////////////////////
|
||||||
|
/// --- AMBIENT LIGHT STUFF --- ///
|
||||||
|
///////////////////////////////////
|
||||||
|
|
||||||
|
averageSkyCol_Clouds = vec3(0.0);
|
||||||
|
averageSkyCol = vec3(0.0);
|
||||||
|
|
||||||
|
vec2 sample3x3[9] = vec2[](
|
||||||
|
|
||||||
|
vec2(-1.0, -0.3),
|
||||||
|
vec2( 0.0, 0.0),
|
||||||
|
vec2( 1.0, -0.3),
|
||||||
|
|
||||||
|
vec2(-1.0, -0.5),
|
||||||
|
vec2( 0.0, -0.5),
|
||||||
|
vec2( 1.0, -0.5),
|
||||||
|
|
||||||
|
vec2(-1.0, -1.0),
|
||||||
|
vec2( 0.0, -1.0),
|
||||||
|
vec2( 1.0, -1.0)
|
||||||
|
);
|
||||||
|
|
||||||
|
// sample in a 3x3 pattern to get a good area for average color
|
||||||
|
|
||||||
|
int maxIT = 9;
|
||||||
|
// int maxIT = 20;
|
||||||
|
for (int i = 0; i < maxIT; i++) {
|
||||||
|
vec3 pos = vec3(0.0,1.0,0.0);
|
||||||
|
pos.xy += normalize(sample3x3[i]) * vec2(0.3183,0.9000);
|
||||||
|
|
||||||
|
averageSkyCol_Clouds += 1.5 * (skyCloudsFromTex(pos,colortex4).rgb/maxIT/150.0);
|
||||||
|
averageSkyCol += 1.5 * (skyFromTex(pos,colortex4).rgb/maxIT/150.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
// only need to sample one spot for this
|
||||||
|
// averageSkyCol_Clouds = max(averageSkyCol_Clouds * (1.0/(luma(averageSkyCol_Clouds)*0.25+0.75)), minimumlight);
|
||||||
|
// averageSkyCol = max(averageSkyCol*PLANET_GROUND_BRIGHTNESS, minimumlight);
|
||||||
|
|
||||||
|
// maximum control of color and luminance
|
||||||
|
vec3 minimumlight = vec3(0.2,0.4,1.0) * (MIN_LIGHT_AMOUNT*0.003 + nightVision);
|
||||||
|
averageSkyCol_Clouds = max( normalize(averageSkyCol_Clouds) * min(luma(averageSkyCol_Clouds) * 3.0,2.5), minimumlight);
|
||||||
|
averageSkyCol = max(averageSkyCol * PLANET_GROUND_BRIGHTNESS, minimumlight);
|
||||||
|
|
||||||
|
////////////////////////////////////////
|
||||||
|
/// --- SUNLIGHT/MOONLIGHT STUFF --- ///
|
||||||
|
////////////////////////////////////////
|
||||||
|
|
||||||
|
vec2 planetSphere = vec2(0.0);
|
||||||
|
|
||||||
|
float sunVis = clamp(sunElevation,0.0,0.05)/0.05*clamp(sunElevation,0.0,0.05)/0.05;
|
||||||
|
float moonVis = clamp(-sunElevation,0.0,0.05)/0.05*clamp(-sunElevation,0.0,0.05)/0.05;
|
||||||
|
|
||||||
|
vec3 skyAbsorb = vec3(0.0);
|
||||||
|
sunColor = calculateAtmosphere(vec3(0.0), sunVec, vec3(0.0,1.0,0.0), sunVec, -sunVec, planetSphere, skyAbsorb, 25,0.0);
|
||||||
|
sunColor = sunColorBase/4000.0 * skyAbsorb;
|
||||||
|
moonColor = moonColorBase/4000.0;
|
||||||
|
|
||||||
|
lightSourceColor = (sunVis >= 1e-5 ? sunColor * sunVis : moonColor * moonVis) ;
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////////
|
||||||
|
/// --- WEATHER PARAMETERS --- ///
|
||||||
|
//////////////////////////////////
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
int dayCounter = int(mod(worldDay, 10));
|
||||||
|
|
||||||
|
if(dayCounter == 0) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY0_l0_coverage, DAY0_l1_coverage, DAY0_l2_coverage, DAY0_ufog_density, DAY0_l0_density, DAY0_l1_density, DAY0_l2_density, DAY0_cfog_density);
|
||||||
|
if(dayCounter == 1) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY1_l0_coverage, DAY1_l1_coverage, DAY1_l2_coverage, DAY1_ufog_density, DAY1_l0_density, DAY1_l1_density, DAY1_l2_density, DAY1_cfog_density);
|
||||||
|
if(dayCounter == 2) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY2_l0_coverage, DAY2_l1_coverage, DAY2_l2_coverage, DAY2_ufog_density, DAY2_l0_density, DAY2_l1_density, DAY2_l2_density, DAY2_cfog_density);
|
||||||
|
if(dayCounter == 3) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY3_l0_coverage, DAY3_l1_coverage, DAY3_l2_coverage, DAY3_ufog_density, DAY3_l0_density, DAY3_l1_density, DAY3_l2_density, DAY3_cfog_density);
|
||||||
|
if(dayCounter == 4) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY4_l0_coverage, DAY4_l1_coverage, DAY4_l2_coverage, DAY4_ufog_density, DAY4_l0_density, DAY4_l1_density, DAY4_l2_density, DAY4_cfog_density);
|
||||||
|
if(dayCounter == 5) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY5_l0_coverage, DAY5_l1_coverage, DAY5_l2_coverage, DAY5_ufog_density, DAY5_l0_density, DAY5_l1_density, DAY5_l2_density, DAY5_cfog_density);
|
||||||
|
if(dayCounter == 6) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY6_l0_coverage, DAY6_l1_coverage, DAY6_l2_coverage, DAY6_ufog_density, DAY6_l0_density, DAY6_l1_density, DAY6_l2_density, DAY6_cfog_density);
|
||||||
|
if(dayCounter == 7) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY7_l0_coverage, DAY7_l1_coverage, DAY7_l2_coverage, DAY7_ufog_density, DAY7_l0_density, DAY7_l1_density, DAY7_l2_density, DAY7_cfog_density);
|
||||||
|
if(dayCounter == 8) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY8_l0_coverage, DAY8_l1_coverage, DAY8_l2_coverage, DAY8_ufog_density, DAY8_l0_density, DAY8_l1_density, DAY8_l2_density, DAY8_cfog_density);
|
||||||
|
if(dayCounter == 9) getWeatherParams(dailyWeatherParams0, dailyWeatherParams1, DAY9_l0_coverage, DAY9_l1_coverage, DAY9_l2_coverage, DAY9_ufog_density, DAY9_l0_density, DAY9_l1_density, DAY9_l2_density, DAY9_cfog_density);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////
|
||||||
|
/// --- EXPOSURE STUFF --- ///
|
||||||
|
//////////////////////////////
|
||||||
|
|
||||||
|
float avgLuma = 0.0;
|
||||||
|
float m2 = 0.0;
|
||||||
|
int n=100;
|
||||||
|
vec2 clampedRes = max(1.0/texelSize,vec2(1920.0,1080.));
|
||||||
|
float avgExp = 0.0;
|
||||||
|
float avgB = 0.0;
|
||||||
|
vec2 resScale = vec2(1920.,1080.)/clampedRes;
|
||||||
|
const int maxITexp = 50;
|
||||||
|
float w = 0.0;
|
||||||
|
for (int i = 0; i < maxITexp; i++){
|
||||||
|
vec2 ij = R2_samples((frameCounter%2000)*maxITexp+i);
|
||||||
|
vec2 tc = 0.5 + (ij-0.5) * 0.7;
|
||||||
|
vec3 sp = texture2D(colortex6, tc/16. * resScale+vec2(0.375*resScale.x+4.5*texelSize.x,.0)).rgb;
|
||||||
|
avgExp += log(luma(sp));
|
||||||
|
avgB += log(min(dot(sp,vec3(0.07,0.22,0.71)),8e-2));
|
||||||
|
}
|
||||||
|
|
||||||
|
avgExp = exp(avgExp/maxITexp);
|
||||||
|
avgB = exp(avgB/maxITexp);
|
||||||
|
|
||||||
|
avgBrightness = clamp(mix(avgExp,texelFetch2D(colortex4,ivec2(10,37),0).g,0.95),0.00003051757,65000.0);
|
||||||
|
|
||||||
|
float L = max(avgBrightness,1e-8);
|
||||||
|
float keyVal = 1.03-2.0/(log(L*4000/150.*8./3.0+1.0)/log(10.0)+2.0);
|
||||||
|
float expFunc = 0.5+0.5*tanh(log(L));
|
||||||
|
float targetExposure = 0.18/log2(L*2.5+1.045)*0.62;
|
||||||
|
|
||||||
|
avgL2 = clamp(mix(avgB,texelFetch2D(colortex4,ivec2(10,37),0).b,0.985),0.00003051757,65000.0);
|
||||||
|
float targetrodExposure = max(0.012/log2(avgL2+1.002)-0.1,0.0)*1.2;
|
||||||
|
|
||||||
|
|
||||||
|
exposure = max(targetExposure*EXPOSURE_MULTIPLIER, 0);
|
||||||
|
float currCenterDepth = ld(texture2D(depthtex2, vec2(0.5)).r);
|
||||||
|
centerDepth = mix(sqrt(texelFetch2D(colortex4,ivec2(14,37),0).g/65000.0), currCenterDepth, clamp(DoF_Adaptation_Speed*exp(-0.016/frameTime+1.0)/(6.0+currCenterDepth*far),0.0,1.0));
|
||||||
|
centerDepth = centerDepth * centerDepth * 65000.0;
|
||||||
|
|
||||||
|
rodExposure = targetrodExposure;
|
||||||
|
|
||||||
|
#ifndef AUTO_EXPOSURE
|
||||||
|
exposure = Manual_exposure_value;
|
||||||
|
rodExposure = clamp(log(Manual_exposure_value*2.0+1.0)-0.1,0.0,2.0);
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,57 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
uniform sampler2D colortex12;
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
uniform float near;
|
||||||
|
uniform float far;
|
||||||
|
|
||||||
|
float linZ(float depth) {
|
||||||
|
return (2.0 * near) / (far + near - depth * (far - near));
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_invLinZ (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* RENDERTARGETS:4,12 */
|
||||||
|
vec3 oldTex = texelFetch2D(colortex4, ivec2(gl_FragCoord.xy), 0).xyz;
|
||||||
|
|
||||||
|
float newTex = texelFetch2D(depthtex1, ivec2(gl_FragCoord.xy*4), 0).x;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float QuarterResDepth = texelFetch2D(dhDepthTex, ivec2(gl_FragCoord.xy*4), 0).x;
|
||||||
|
if(newTex >= 1.0) newTex = sqrt(QuarterResDepth);
|
||||||
|
|
||||||
|
gl_FragData[1].a = (DH_ld(QuarterResDepth)*DH_ld(QuarterResDepth))*65000.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (newTex < 1.0)
|
||||||
|
gl_FragData[0] = vec4(oldTex, linZ(newTex)*linZ(newTex)*65000.0);
|
||||||
|
else
|
||||||
|
gl_FragData[0] = vec4(oldTex, 2.0);
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,9 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
vec2 scaleRatio = max(vec2(0.25), vec2(18.+258*2,258.)*texelSize);
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*clamp(scaleRatio+0.01,0.0,1.0)*2.0-1.0;
|
||||||
|
}
|
|
@ -0,0 +1,118 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
//Computes volumetric clouds at variable resolution (default 1/4 res)
|
||||||
|
|
||||||
|
#define USE_WEATHER_PARAMS
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
flat varying vec3 dailyWeatherParams0;
|
||||||
|
flat varying vec3 dailyWeatherParams1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec3 sunColor;
|
||||||
|
// flat varying vec3 moonColor;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
|
||||||
|
flat varying float tempOffsets;
|
||||||
|
// uniform float far;
|
||||||
|
uniform float near;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
#endif
|
||||||
|
// uniform sampler2D colortex4;
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
|
||||||
|
uniform sampler2D colortex12;
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform int framemod8;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
// flat varying vec2 TAA_Offset;
|
||||||
|
|
||||||
|
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return fragposition.xyz / fragposition.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
float R2_dither(){
|
||||||
|
#ifdef TAA
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
#else
|
||||||
|
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
#endif
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
vec2 coord = vec2(alpha.x * gl_FragCoord.x,alpha.y * gl_FragCoord.y)+ 1.0/1.6180339887 * frameCounter;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const vec2[8] offsets = vec2[8](vec2(1./8.,-3./8.),
|
||||||
|
vec2(-1.,3.)/8.,
|
||||||
|
vec2(5.0,1.)/8.,
|
||||||
|
vec2(-3,-5.)/8.,
|
||||||
|
vec2(-5.,5.)/8.,
|
||||||
|
vec2(-7.,-1.)/8.,
|
||||||
|
vec2(3,7.)/8.,
|
||||||
|
vec2(7.,-7.)/8.);
|
||||||
|
float blueNoise(){
|
||||||
|
#ifdef TAA
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 * frameCounter);
|
||||||
|
#else
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec3 normVec (vec3 vec){
|
||||||
|
return vec*inversesqrt(dot(vec,vec));
|
||||||
|
}
|
||||||
|
|
||||||
|
#include "/lib/lightning_stuff.glsl"
|
||||||
|
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* DRAWBUFFERS:0 */
|
||||||
|
#if defined OVERWORLD_SHADER && defined VOLUMETRIC_CLOUDS
|
||||||
|
vec2 halfResTC = vec2(floor(gl_FragCoord.xy)/CLOUDS_QUALITY/RENDER_SCALE+0.5+offsets[framemod8]*CLOUDS_QUALITY*RENDER_SCALE*0.5);
|
||||||
|
|
||||||
|
vec3 viewPos = toScreenSpace(vec3(halfResTC*texelSize,1.0));
|
||||||
|
|
||||||
|
vec4 VolumetricClouds = renderClouds(viewPos, vec2(R2_dither(), blueNoise()), sunColor/80.0, averageSkyCol/30.0);
|
||||||
|
|
||||||
|
// gl_FragData[0] = vec4(0.0,0.0,0.0,1.0);
|
||||||
|
gl_FragData[0] = VolumetricClouds;
|
||||||
|
#else
|
||||||
|
gl_FragData[0] = vec4(0.0,0.0,0.0,1.0);
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,48 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
flat varying vec3 dailyWeatherParams0;
|
||||||
|
flat varying vec3 dailyWeatherParams1;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
flat varying vec3 sunColor;
|
||||||
|
// flat varying vec3 moonColor;
|
||||||
|
|
||||||
|
|
||||||
|
flat varying float tempOffsets;
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
|
||||||
|
gl_Position = ftransform();
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*clamp(CLOUDS_QUALITY+0.01,0.0,1.0)*2.0-1.0;
|
||||||
|
|
||||||
|
dailyWeatherParams0 = texelFetch2D(colortex4,ivec2(1,1),0).rgb/150.0;
|
||||||
|
dailyWeatherParams1 = texelFetch2D(colortex4,ivec2(2,1),0).rgb/150.0;
|
||||||
|
|
||||||
|
averageSkyCol = texelFetch2D(colortex4,ivec2(1,37),0).rgb;
|
||||||
|
sunColor = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
// moonColor = texelFetch2D(colortex4,ivec2(13,37),0).rgb;
|
||||||
|
|
||||||
|
// sunColor = texelFetch2D(colortex4,ivec2(8,37),0).rgb;
|
||||||
|
// moonColor = texelFetch2D(colortex4,ivec2(9,37),0).rgb;
|
||||||
|
|
||||||
|
|
||||||
|
WsunVec = normalize(mat3(gbufferModelViewInverse) * sunPosition) * (float(sunElevation > 1e-5)*2.0-1.0);
|
||||||
|
// WsunVec = normalize(LightDir);
|
||||||
|
|
||||||
|
tempOffsets = HaltonSeq2(frameCounter%10000);
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*RENDER_SCALE*2.0-1.0;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,171 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
varying vec2 texcoord;
|
||||||
|
|
||||||
|
uniform sampler2D colortex7;
|
||||||
|
uniform sampler2D colortex14;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
|
||||||
|
uniform sampler2D shadow;
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2D shadowcolor1;
|
||||||
|
uniform sampler2D shadowtex0;
|
||||||
|
uniform sampler2D shadowtex1;
|
||||||
|
|
||||||
|
#include "/lib/color_transforms.glsl"
|
||||||
|
#include "/lib/color_dither.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/gameplay_effects.glsl"
|
||||||
|
|
||||||
|
uniform int hideGUI;
|
||||||
|
|
||||||
|
vec4 SampleTextureCatmullRom(sampler2D tex, vec2 uv, vec2 texSize )
|
||||||
|
{
|
||||||
|
// We're going to sample a a 4x4 grid of texels surrounding the target UV coordinate. We'll do this by rounding
|
||||||
|
// down the sample location to get the exact center of our "starting" texel. The starting texel will be at
|
||||||
|
// location [1, 1] in the grid, where [0, 0] is the top left corner.
|
||||||
|
vec2 samplePos = uv * texSize;
|
||||||
|
vec2 texPos1 = floor(samplePos - 0.5) + 0.5;
|
||||||
|
|
||||||
|
// Compute the fractional offset from our starting texel to our original sample location, which we'll
|
||||||
|
// feed into the Catmull-Rom spline function to get our filter weights.
|
||||||
|
vec2 f = samplePos - texPos1;
|
||||||
|
|
||||||
|
// Compute the Catmull-Rom weights using the fractional offset that we calculated earlier.
|
||||||
|
// These equations are pre-expanded based on our knowledge of where the texels will be located,
|
||||||
|
// which lets us avoid having to evaluate a piece-wise function.
|
||||||
|
vec2 w0 = f * ( -0.5 + f * (1.0 - 0.5*f));
|
||||||
|
vec2 w1 = 1.0 + f * f * (-2.5 + 1.5*f);
|
||||||
|
vec2 w2 = f * ( 0.5 + f * (2.0 - 1.5*f) );
|
||||||
|
vec2 w3 = f * f * (-0.5 + 0.5 * f);
|
||||||
|
|
||||||
|
// Work out weighting factors and sampling offsets that will let us use bilinear filtering to
|
||||||
|
// simultaneously evaluate the middle 2 samples from the 4x4 grid.
|
||||||
|
vec2 w12 = w1 + w2;
|
||||||
|
vec2 offset12 = w2 / (w1 + w2);
|
||||||
|
|
||||||
|
// Compute the final UV coordinates we'll use for sampling the texture
|
||||||
|
vec2 texPos0 = texPos1 - vec2(1.0);
|
||||||
|
vec2 texPos3 = texPos1 + vec2(2.0);
|
||||||
|
vec2 texPos12 = texPos1 + offset12;
|
||||||
|
|
||||||
|
texPos0 *= texelSize;
|
||||||
|
texPos3 *= texelSize;
|
||||||
|
texPos12 *= texelSize;
|
||||||
|
|
||||||
|
vec4 result = vec4(0.0);
|
||||||
|
result += texture2D(tex, vec2(texPos0.x, texPos0.y)) * w0.x * w0.y;
|
||||||
|
result += texture2D(tex, vec2(texPos12.x, texPos0.y)) * w12.x * w0.y;
|
||||||
|
result += texture2D(tex, vec2(texPos3.x, texPos0.y)) * w3.x * w0.y;
|
||||||
|
|
||||||
|
result += texture2D(tex, vec2(texPos0.x, texPos12.y)) * w0.x * w12.y;
|
||||||
|
result += texture2D(tex, vec2(texPos12.x, texPos12.y)) * w12.x * w12.y;
|
||||||
|
result += texture2D(tex, vec2(texPos3.x, texPos12.y)) * w3.x * w12.y;
|
||||||
|
|
||||||
|
result += texture2D(tex, vec2(texPos0.x, texPos3.y)) * w0.x * w3.y;
|
||||||
|
result += texture2D(tex, vec2(texPos12.x, texPos3.y)) * w12.x * w3.y;
|
||||||
|
result += texture2D(tex, vec2(texPos3.x, texPos3.y)) * w3.x * w3.y;
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// thanks stackoverflow https://stackoverflow.com/questions/944713/help-with-pixel-shader-effect-for-brightness-and-contrast#3027595
|
||||||
|
void applyContrast(inout vec3 color, float contrast){
|
||||||
|
color = (color - 0.5) * contrast + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
float lowerCurve(float x) {
|
||||||
|
float y = 16 * x * (0.5 - x) * 0.1;
|
||||||
|
return clamp(y, 0.0, 1.0);
|
||||||
|
}
|
||||||
|
float upperCurve(float x) {
|
||||||
|
float y = 16 * (0.5 - x) * (x - 1.0) * 0.1;
|
||||||
|
return clamp(y, 0.0, 1.0);
|
||||||
|
}
|
||||||
|
vec3 toneCurve(vec3 color){
|
||||||
|
color.r += LOWER_CURVE * lowerCurve(color.r) + UPPER_CURVE * upperCurve(color.r);
|
||||||
|
color.g += LOWER_CURVE * lowerCurve(color.g) + UPPER_CURVE * upperCurve(color.g);
|
||||||
|
color.b += LOWER_CURVE * lowerCurve(color.b) + UPPER_CURVE * upperCurve(color.b);
|
||||||
|
return color;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 colorGrading(vec3 color) {
|
||||||
|
float grade_luma = dot(color, vec3(1.0 / 3.0));
|
||||||
|
float shadows_amount = saturate(-6.0 * grade_luma + 2.75);
|
||||||
|
float mids_amount = saturate(-abs(6.0 * grade_luma - 3.0) + 1.25);
|
||||||
|
float highlights_amount = saturate(6.0 * grade_luma - 3.25);
|
||||||
|
|
||||||
|
vec3 graded_shadows = color * SHADOWS_TARGET * SHADOWS_GRADE_MUL * 1.7320508076;
|
||||||
|
vec3 graded_mids = color * MIDS_TARGET * MIDS_GRADE_MUL * 1.7320508076;
|
||||||
|
vec3 graded_highlights = color * HIGHLIGHTS_TARGET * HIGHLIGHTS_GRADE_MUL * 1.7320508076;
|
||||||
|
|
||||||
|
return saturate(graded_shadows * shadows_amount + graded_mids * mids_amount + graded_highlights * highlights_amount);
|
||||||
|
}
|
||||||
|
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
float noise = fract(52.9829189*fract(0.06711056*coord.x + 0.00583715*coord.y));
|
||||||
|
return noise;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
#ifdef BICUBIC_UPSCALING
|
||||||
|
vec3 col = SampleTextureCatmullRom(colortex7,texcoord,1.0/texelSize).rgb;
|
||||||
|
#else
|
||||||
|
vec3 col = texture2D(colortex7,texcoord).rgb;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef CONTRAST_ADAPTATIVE_SHARPENING
|
||||||
|
//Weights : 1 in the center, 0.5 middle, 0.25 corners
|
||||||
|
vec3 albedoCurrent1 = texture2D(colortex7, texcoord + vec2(texelSize.x,texelSize.y)/MC_RENDER_QUALITY*0.5).rgb;
|
||||||
|
vec3 albedoCurrent2 = texture2D(colortex7, texcoord + vec2(texelSize.x,-texelSize.y)/MC_RENDER_QUALITY*0.5).rgb;
|
||||||
|
vec3 albedoCurrent3 = texture2D(colortex7, texcoord + vec2(-texelSize.x,-texelSize.y)/MC_RENDER_QUALITY*0.5).rgb;
|
||||||
|
vec3 albedoCurrent4 = texture2D(colortex7, texcoord + vec2(-texelSize.x,texelSize.y)/MC_RENDER_QUALITY*0.5).rgb;
|
||||||
|
|
||||||
|
|
||||||
|
vec3 m1 = -0.5/3.5*col + albedoCurrent1/3.5 + albedoCurrent2/3.5 + albedoCurrent3/3.5 + albedoCurrent4/3.5;
|
||||||
|
vec3 std = abs(col - m1) + abs(albedoCurrent1 - m1) + abs(albedoCurrent2 - m1) +
|
||||||
|
abs(albedoCurrent3 - m1) + abs(albedoCurrent3 - m1) + abs(albedoCurrent4 - m1);
|
||||||
|
float contrast = 1.0 - luma(std)/5.0;
|
||||||
|
col = col*(1.0+(SHARPENING+UPSCALING_SHARPNENING)*contrast)
|
||||||
|
- (SHARPENING+UPSCALING_SHARPNENING)/(1.0-0.5/3.5)*contrast*(m1 - 0.5/3.5*col);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float lum = luma(col);
|
||||||
|
vec3 diff = col-lum;
|
||||||
|
col = col + diff*(-lum*CROSSTALK + SATURATION);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
vec3 FINAL_COLOR = clamp(int8Dither(col,texcoord),0.0,1.0);
|
||||||
|
|
||||||
|
#ifdef TONE_CURVE
|
||||||
|
FINAL_COLOR = toneCurve(FINAL_COLOR);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef COLOR_GRADING_ENABLED
|
||||||
|
FINAL_COLOR = colorGrading(FINAL_COLOR);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
applyContrast(FINAL_COLOR, CONTRAST); // for fun
|
||||||
|
|
||||||
|
applyGameplayEffects_FRAGMENT(FINAL_COLOR, texcoord, interleaved_gradientNoise()); // for making the fun, more fun
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// float reprojectedBuffer = texture2D(colortex14, texcoord).a;
|
||||||
|
|
||||||
|
// gl_FragColor.rgb = vec3(1.0) * reprojectedBuffer;
|
||||||
|
|
||||||
|
gl_FragColor.rgb = FINAL_COLOR;
|
||||||
|
|
||||||
|
#if DEBUG_VIEW == debug_SHADOWMAP
|
||||||
|
if(texcoord.x < 0.25 && texcoord.y < 0.5) gl_FragColor.rgb = texture2D(shadowcolor0, (texcoord * vec2(2.0, 1.0) * 2 - vec2(0.0, 0.0)) ).rgb;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
|
||||||
|
varying vec2 texcoord;
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
texcoord = gl_MultiTexCoord0.xy;
|
||||||
|
}
|
|
@ -0,0 +1,372 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
// #if defined END_SHADER || defined NETHER_SHADER
|
||||||
|
#undef IS_LPV_ENABLED
|
||||||
|
// #endif
|
||||||
|
#ifndef OVERWORLD_SHADER
|
||||||
|
uniform float nightVision;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
uniform sampler2D noisetex;
|
||||||
|
uniform sampler2D depthtex0;
|
||||||
|
uniform sampler2D depthtex1;
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
uniform sampler2D dhDepthTex;
|
||||||
|
uniform sampler2D dhDepthTex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform sampler2D colortex2;
|
||||||
|
uniform sampler2D colortex3;
|
||||||
|
// uniform sampler2D colortex4;
|
||||||
|
uniform sampler2D colortex6;
|
||||||
|
uniform sampler2D colortex7;
|
||||||
|
uniform sampler2D colortex14;
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
uniform vec3 sunVec;
|
||||||
|
uniform float sunElevation;
|
||||||
|
|
||||||
|
// uniform float far;
|
||||||
|
uniform float dhFarPlane;
|
||||||
|
uniform float dhNearPlane;
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
|
||||||
|
// varying vec2 texcoord;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
// flat varying vec2 TAA_Offset;
|
||||||
|
|
||||||
|
uniform int isEyeInWater;
|
||||||
|
uniform float rainStrength;
|
||||||
|
uniform ivec2 eyeBrightnessSmooth;
|
||||||
|
uniform float eyeAltitude;
|
||||||
|
|
||||||
|
#define DHVLFOG
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
#include "/lib/color_transforms.glsl"
|
||||||
|
#include "/lib/color_dither.glsl"
|
||||||
|
#include "/lib/projections.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
#include "/lib/waterBump.glsl"
|
||||||
|
|
||||||
|
#include "/lib/DistantHorizons_projections.glsl"
|
||||||
|
|
||||||
|
float DH_ld(float dist) {
|
||||||
|
return (2.0 * dhNearPlane) / (dhFarPlane + dhNearPlane - dist * (dhFarPlane - dhNearPlane));
|
||||||
|
}
|
||||||
|
float DH_inv_ld (float lindepth){
|
||||||
|
return -((2.0*dhNearPlane/lindepth)-dhFarPlane-dhNearPlane)/(dhFarPlane-dhNearPlane);
|
||||||
|
}
|
||||||
|
|
||||||
|
float linearizeDepthFast(const in float depth, const in float near, const in float far) {
|
||||||
|
return (near * far) / (depth * (near - far) + far);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
const bool shadowHardwareFiltering = true;
|
||||||
|
uniform sampler2DShadow shadow;
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
uniform sampler2D shadowcolor0;
|
||||||
|
uniform sampler2DShadow shadowtex0;
|
||||||
|
uniform sampler2DShadow shadowtex1;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
flat varying vec3 refractedSunVec;
|
||||||
|
|
||||||
|
|
||||||
|
#define TIMEOFDAYFOG
|
||||||
|
#include "/lib/lightning_stuff.glsl"
|
||||||
|
#include "/lib/volumetricClouds.glsl"
|
||||||
|
#include "/lib/overworld_fog.glsl"
|
||||||
|
|
||||||
|
#endif
|
||||||
|
#ifdef NETHER_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#include "/lib/nether_fog.glsl"
|
||||||
|
#endif
|
||||||
|
#ifdef END_SHADER
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
#include "/lib/end_fog.glsl"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "/lib/diffuse_lighting.glsl"
|
||||||
|
|
||||||
|
#define fsign(a) (clamp((a)*1e35,0.,1.)*2.-1.)
|
||||||
|
|
||||||
|
float interleaved_gradientNoise(){
|
||||||
|
return fract(52.9829189*fract(0.06711056*gl_FragCoord.x + 0.00583715*gl_FragCoord.y)+ 1.0/1.6180339887 * frameCounter);
|
||||||
|
}
|
||||||
|
float blueNoise(){
|
||||||
|
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a+ 1.0/1.6180339887 * frameCounter );
|
||||||
|
}
|
||||||
|
float R2_dither(){
|
||||||
|
#ifdef TAA
|
||||||
|
vec2 coord = gl_FragCoord.xy + (frameCounter%40000) * 2.0;
|
||||||
|
#else
|
||||||
|
vec2 coord = gl_FragCoord.xy;
|
||||||
|
#endif
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha.x * coord.x + alpha.y * coord.y ) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
void waterVolumetrics_notoverworld(inout vec3 inColor, vec3 rayStart, vec3 rayEnd, float estEndDepth, float estSunDepth, float rayLength, float dither, vec3 waterCoefs, vec3 scatterCoef, vec3 ambient){
|
||||||
|
inColor *= exp(-rayLength * waterCoefs); //No need to take the integrated value
|
||||||
|
|
||||||
|
int spCount = rayMarchSampleCount;
|
||||||
|
vec3 start = toShadowSpaceProjected(rayStart);
|
||||||
|
vec3 end = toShadowSpaceProjected(rayEnd);
|
||||||
|
vec3 dV = (end-start);
|
||||||
|
//limit ray length at 32 blocks for performance and reducing integration error
|
||||||
|
//you can't see above this anyway
|
||||||
|
float maxZ = min(rayLength,12.0)/(1e-8+rayLength);
|
||||||
|
dV *= maxZ;
|
||||||
|
|
||||||
|
|
||||||
|
rayLength *= maxZ;
|
||||||
|
|
||||||
|
float dY = normalize(mat3(gbufferModelViewInverse) * rayEnd).y * rayLength;
|
||||||
|
estEndDepth *= maxZ;
|
||||||
|
estSunDepth *= maxZ;
|
||||||
|
|
||||||
|
vec3 wpos = mat3(gbufferModelViewInverse) * rayStart + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 dVWorld = (wpos-gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
vec3 absorbance = vec3(1.0);
|
||||||
|
vec3 vL = vec3(0.0);
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<spCount;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither)/float(spCount))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
float dd = pow(expFactor, float(i+dither)/float(spCount)) * log(expFactor) / float(spCount)/(expFactor-1.0);
|
||||||
|
vec3 spPos = start.xyz + dV*d;
|
||||||
|
|
||||||
|
vec3 progressW = start.xyz+cameraPosition+dVWorld;
|
||||||
|
|
||||||
|
vec3 ambientMul = exp(-max(estEndDepth * d,0.0) * waterCoefs );
|
||||||
|
vec3 Indirectlight = ambientMul*ambient;
|
||||||
|
|
||||||
|
vec3 light = Indirectlight * scatterCoef;
|
||||||
|
|
||||||
|
vL += (light - light * exp(-waterCoefs * dd * rayLength)) / waterCoefs * absorbance;
|
||||||
|
absorbance *= exp(-dd * rayLength * waterCoefs);
|
||||||
|
}
|
||||||
|
inColor += vL;
|
||||||
|
|
||||||
|
}
|
||||||
|
vec4 blueNoise(vec2 coord){
|
||||||
|
return texelFetch2D(colortex6, ivec2(coord)%512 , 0) ;
|
||||||
|
}
|
||||||
|
vec2 R2_samples(int n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
|
||||||
|
float fogPhase2(float lightPoint){
|
||||||
|
float linear = 1.0 - clamp(lightPoint*0.5+0.5,0.0,1.0);
|
||||||
|
float linear2 = 1.0 - clamp(lightPoint,0.0,1.0);
|
||||||
|
|
||||||
|
float exponential = exp2(pow(linear,0.3) * -15.0 ) * 1.5;
|
||||||
|
exponential += sqrt(exp2(sqrt(linear) * -12.5));
|
||||||
|
|
||||||
|
return exponential;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 waterVolumetrics_test( vec3 rayStart, vec3 rayEnd, float estEndDepth, float estSunDepth, float rayLength, float dither, vec3 waterCoefs, vec3 scatterCoef, vec3 ambient, vec3 lightSource, float VdotL){
|
||||||
|
int spCount = rayMarchSampleCount;
|
||||||
|
|
||||||
|
vec3 start = toShadowSpaceProjected(rayStart);
|
||||||
|
vec3 end = toShadowSpaceProjected(rayEnd);
|
||||||
|
vec3 dV = (end-start);
|
||||||
|
|
||||||
|
//limit ray length at 32 blocks for performance and reducing integration error
|
||||||
|
//you can't see above this anyway
|
||||||
|
float maxZ = min(rayLength,12.0)/(1e-8+rayLength);
|
||||||
|
dV *= maxZ;
|
||||||
|
rayLength *= maxZ;
|
||||||
|
estEndDepth *= maxZ;
|
||||||
|
estSunDepth *= maxZ;
|
||||||
|
|
||||||
|
vec3 wpos = mat3(gbufferModelViewInverse) * rayStart + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 dVWorld = (wpos - gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
vec3 newabsorbance = exp(-rayLength * waterCoefs); // No need to take the integrated value
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
float phase = fogPhase(VdotL) * 5.0;
|
||||||
|
#else
|
||||||
|
float phase = 1.0;
|
||||||
|
#endif
|
||||||
|
vec3 absorbance = vec3(1.0);
|
||||||
|
vec3 vL = vec3(0.0);
|
||||||
|
|
||||||
|
ambient = max(ambient * (normalize(wpos).y*0.3+0.7),0.0);
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<spCount;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither)/float(spCount))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
float dd = pow(expFactor, float(i+dither)/float(spCount)) * log(expFactor) / float(spCount)/(expFactor-1.0);
|
||||||
|
|
||||||
|
vec3 progressW = start.xyz+cameraPosition+dVWorld;
|
||||||
|
|
||||||
|
vec3 sh = vec3(1.0);
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
vec3 spPos = start.xyz + dV*d;
|
||||||
|
|
||||||
|
//project into biased shadowmap space
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(spPos.xy);
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 pos = vec3(spPos.xy*distortFactor, spPos.z);
|
||||||
|
if (abs(pos.x) < 1.0-0.5/2048. && abs(pos.y) < 1.0-0.5/2048){
|
||||||
|
pos = pos*vec3(0.5,0.5,0.5/6.0)+0.5;
|
||||||
|
// sh = shadow2D( shadow, pos).x;
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
sh = vec3(shadow2D(shadowtex0, pos).x);
|
||||||
|
|
||||||
|
if(shadow2D(shadowtex1, pos).x > pos.z && sh.x < 1.0){
|
||||||
|
vec4 translucentShadow = texture2D(shadowcolor0, pos.xy);
|
||||||
|
if(translucentShadow.a < 0.9) sh = normalize(translucentShadow.rgb+0.0001);
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
sh = vec3(shadow2D(shadow, pos).x);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef VL_CLOUDS_SHADOWS
|
||||||
|
sh *= GetCloudShadow_VLFOG(progressW,WsunVec);
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 sunMul = exp(-estSunDepth * d * waterCoefs * 1.1);
|
||||||
|
vec3 ambientMul = exp(-estEndDepth * d * waterCoefs );
|
||||||
|
|
||||||
|
vec3 Directlight = ((lightSource * sh) * phase * sunMul) ;
|
||||||
|
vec3 Indirectlight = max(ambient * ambientMul, vec3(0.01,0.2,0.4) * ambientMul * MIN_LIGHT_AMOUNT * 0.03) ;
|
||||||
|
|
||||||
|
vec3 light = (Indirectlight + Directlight) * scatterCoef;
|
||||||
|
|
||||||
|
vL += (light - light * exp(-waterCoefs * dd * rayLength)) / waterCoefs * absorbance;
|
||||||
|
absorbance *= exp(-waterCoefs * dd * rayLength);
|
||||||
|
}
|
||||||
|
// inColor += vL;
|
||||||
|
return vec4( vL, dot(newabsorbance,vec3(0.335)));
|
||||||
|
}
|
||||||
|
vec2 decodeVec2(float a){
|
||||||
|
const vec2 constant1 = 65535. / vec2( 256., 65536.);
|
||||||
|
const float constant2 = 256. / 255.;
|
||||||
|
return fract( a * constant1 ) * constant2 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
/* RENDERTARGETS:13 */
|
||||||
|
|
||||||
|
float noise_1 = R2_dither();
|
||||||
|
float noise_2 = blueNoise();
|
||||||
|
|
||||||
|
|
||||||
|
vec2 tc = floor(gl_FragCoord.xy)/VL_RENDER_RESOLUTION*texelSize+0.5*texelSize;
|
||||||
|
|
||||||
|
bool iswater = texture2D(colortex7,tc).a > 0.99;
|
||||||
|
|
||||||
|
float z0 = texture2D(depthtex0,tc).x;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float DH_z0 = texture2D(dhDepthTex,tc).x;
|
||||||
|
#else
|
||||||
|
float DH_z0 = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float z = texture2D(depthtex1,tc).x;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float DH_z = texture2D(dhDepthTex1,tc).x;
|
||||||
|
#else
|
||||||
|
float DH_z = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 viewPos1 = toScreenSpace_DH(tc/RENDER_SCALE, z, DH_z);
|
||||||
|
vec3 viewPos0 = toScreenSpace_DH(tc/RENDER_SCALE, z0, DH_z0);
|
||||||
|
|
||||||
|
vec3 playerPos = normalize(mat3(gbufferModelViewInverse) * viewPos1);
|
||||||
|
// vec3 lightningColor = (lightningEffect / 3) * (max(eyeBrightnessSmooth.y,0)/240.);
|
||||||
|
|
||||||
|
float dirtAmount = Dirt_Amount + 0.1;
|
||||||
|
// float dirtAmount = Dirt_Amount + 0.01;
|
||||||
|
vec3 waterEpsilon = vec3(Water_Absorb_R, Water_Absorb_G, Water_Absorb_B);
|
||||||
|
vec3 dirtEpsilon = vec3(Dirt_Absorb_R, Dirt_Absorb_G, Dirt_Absorb_B);
|
||||||
|
vec3 totEpsilon = dirtEpsilon*dirtAmount + waterEpsilon;
|
||||||
|
vec3 scatterCoef = dirtAmount * vec3(Dirt_Scatter_R, Dirt_Scatter_G, Dirt_Scatter_B) / 3.14;
|
||||||
|
|
||||||
|
vec3 directLightColor = lightCol.rgb/80.0;
|
||||||
|
vec3 indirectLightColor = averageSkyCol/30.0;
|
||||||
|
vec3 indirectLightColor_dynamic = averageSkyCol_Clouds/30.0;
|
||||||
|
|
||||||
|
//////////////////////////////////////////////////////////
|
||||||
|
///////////////// BEHIND OF TRANSLUCENTS /////////////////
|
||||||
|
//////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
if(texture2D(colortex2, tc).a > 0.0 || iswater){
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
vec2 lightmap = decodeVec2(texture2D(colortex14, tc).a);
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
if(z >= 1.0) lightmap.y = 0.99;
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
vec2 lightmap = decodeVec2(texture2D(colortex14, tc).a);
|
||||||
|
lightmap.y = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
float Vdiff = distance(viewPos1, viewPos0) * 2.0;
|
||||||
|
float VdotU = playerPos.y;
|
||||||
|
float estimatedDepth = Vdiff * abs(VdotU) ; //assuming water plane
|
||||||
|
float estimatedSunDepth = estimatedDepth / abs(WsunVec.y); //assuming water plane
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
indirectLightColor_dynamic *= ambient_brightness * pow(1.0-pow(1.0-lightmap.y,0.5),3.0) ;
|
||||||
|
float TorchBrightness_autoAdjust = mix(1.0, 30.0, clamp(exp(-10.0*exposure),0.0,1.0)) ;
|
||||||
|
indirectLightColor_dynamic += vec3(TORCH_R,TORCH_G,TORCH_B) * TorchBrightness_autoAdjust * pow(1.0-sqrt(1.0-clamp(lightmap.x,0.0,1.0)),2.0) * 2.0;
|
||||||
|
|
||||||
|
vec4 VolumetricFog2 = vec4(0,0,0,1);
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
if(!iswater) VolumetricFog2 = GetVolumetricFog(viewPos1, vec2(noise_1, noise_2), directLightColor, indirectLightColor);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec4 underwaterVlFog = vec4(0,0,0,1);
|
||||||
|
if(iswater) underwaterVlFog = waterVolumetrics_test(viewPos0, viewPos1, estimatedDepth, estimatedSunDepth, Vdiff, noise_1, totEpsilon, scatterCoef, indirectLightColor_dynamic, directLightColor, dot(normalize(viewPos1), normalize(sunVec*lightCol.a)) );
|
||||||
|
|
||||||
|
vec4 fogFinal = vec4(underwaterVlFog.rgb * VolumetricFog2.a + VolumetricFog2.rgb, VolumetricFog2.a * underwaterVlFog.a);
|
||||||
|
|
||||||
|
gl_FragData[0] = clamp(fogFinal, 0.0, 65000.0);
|
||||||
|
|
||||||
|
}else{
|
||||||
|
gl_FragData[0] = vec4(0,0,0,1);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,74 @@
|
||||||
|
#include "/lib/settings.glsl"
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/res_params.glsl"
|
||||||
|
|
||||||
|
flat varying vec4 lightCol;
|
||||||
|
flat varying vec3 averageSkyCol;
|
||||||
|
flat varying vec3 averageSkyCol_Clouds;
|
||||||
|
|
||||||
|
flat varying vec3 WsunVec;
|
||||||
|
flat varying vec3 refractedSunVec;
|
||||||
|
|
||||||
|
flat varying float tempOffsets;
|
||||||
|
|
||||||
|
uniform sampler2D colortex4;
|
||||||
|
flat varying float exposure;
|
||||||
|
|
||||||
|
uniform float sunElevation;
|
||||||
|
uniform vec2 texelSize;
|
||||||
|
uniform vec3 sunPosition;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform int frameCounter;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
//////////////////////////////VOID MAIN//////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
uniform float frameTimeCounter;
|
||||||
|
#include "/lib/Shadow_Params.glsl"
|
||||||
|
#include "/lib/sky_gradient.glsl"
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
gl_Position = ftransform();
|
||||||
|
|
||||||
|
// gl_Position.xy = (gl_Position.xy*0.5+0.5)*0.51*2.0-1.0;
|
||||||
|
gl_Position.xy = (gl_Position.xy*0.5+0.5)*(0.01+VL_RENDER_RESOLUTION)*2.0-1.0;
|
||||||
|
|
||||||
|
#ifdef TAA
|
||||||
|
tempOffsets = HaltonSeq2(frameCounter%10000);
|
||||||
|
#else
|
||||||
|
tempOffsets = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb;
|
||||||
|
averageSkyCol = texelFetch2D(colortex4,ivec2(1,37),0).rgb;
|
||||||
|
averageSkyCol_Clouds = texelFetch2D(colortex4,ivec2(0,37),0).rgb;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef NETHER_SHADER
|
||||||
|
lightCol.rgb = vec3(0.0);
|
||||||
|
averageSkyCol = vec3(0.0);
|
||||||
|
averageSkyCol_Clouds = vec3(2.0, 1.0, 0.5) * 5.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef END_SHADER
|
||||||
|
lightCol.rgb = vec3(0.0);
|
||||||
|
averageSkyCol = vec3(0.0);
|
||||||
|
averageSkyCol_Clouds = vec3(15);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
lightCol.a = float(sunElevation > 1e-5)*2.0 - 1.0;
|
||||||
|
WsunVec = lightCol.a * normalize(mat3(gbufferModelViewInverse) * sunPosition);
|
||||||
|
// WsunVec = normalize(LightDir);
|
||||||
|
|
||||||
|
refractedSunVec = refract(WsunVec, -vec3(0.0,1.0,0.0), 1.0/1.33333);
|
||||||
|
|
||||||
|
exposure = texelFetch2D(colortex4,ivec2(10,37),0).r;
|
||||||
|
}
|
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1,159 @@
|
||||||
|
#define RENDER_SHADOWCOMP
|
||||||
|
|
||||||
|
layout (local_size_x = 8, local_size_y = 8, local_size_z = 8) in;
|
||||||
|
|
||||||
|
#if LPV_SIZE == 8
|
||||||
|
const ivec3 workGroups = ivec3(32, 32, 32);
|
||||||
|
#elif LPV_SIZE == 7
|
||||||
|
const ivec3 workGroups = ivec3(16, 16, 16);
|
||||||
|
#elif LPV_SIZE == 6
|
||||||
|
const ivec3 workGroups = ivec3(8, 8, 8);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
shared vec4 lpvSharedData[10*10*10];
|
||||||
|
shared uint voxelSharedData[10*10*10];
|
||||||
|
|
||||||
|
const vec2 LpvBlockSkyFalloff = vec2(0.96, 0.96);
|
||||||
|
const ivec3 lpvFlatten = ivec3(1, 10, 100);
|
||||||
|
|
||||||
|
uniform int frameCounter;
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
uniform vec3 previousCameraPosition;
|
||||||
|
|
||||||
|
#include "/lib/hsv.glsl"
|
||||||
|
#include "/lib/util.glsl"
|
||||||
|
#include "/lib/blocks.glsl"
|
||||||
|
#include "/lib/lpv_common.glsl"
|
||||||
|
#include "/lib/lpv_blocks.glsl"
|
||||||
|
#include "/lib/lpv_buffer.glsl"
|
||||||
|
#include "/lib/voxel_common.glsl"
|
||||||
|
|
||||||
|
int sumOf(ivec3 vec) {return vec.x + vec.y + vec.z;}
|
||||||
|
|
||||||
|
vec3 Lpv_RgbToHsv(const in vec3 lightColor, const in float lightRange) {
|
||||||
|
vec3 lightValue = RgbToHsv(lightColor);
|
||||||
|
lightValue.b = lightRange / LpvBlockSkyRange.x;
|
||||||
|
return lightValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 GetLpvValue(in ivec3 texCoord) {
|
||||||
|
if (clamp(texCoord, ivec3(0), ivec3(LpvSize) - 1) != texCoord) return vec4(0.0);
|
||||||
|
|
||||||
|
vec4 lpvSample = (frameCounter % 2) == 0
|
||||||
|
? imageLoad(imgLpv2, texCoord)
|
||||||
|
: imageLoad(imgLpv1, texCoord);
|
||||||
|
|
||||||
|
lpvSample.ba = exp2(lpvSample.ba * LpvBlockSkyRange) - 1.0;
|
||||||
|
lpvSample.rgb = HsvToRgb(lpvSample.rgb);
|
||||||
|
|
||||||
|
return lpvSample;
|
||||||
|
}
|
||||||
|
|
||||||
|
int getSharedIndex(ivec3 pos) {
|
||||||
|
return sumOf(pos * lpvFlatten);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 sampleShared(ivec3 pos, int mask_index) {
|
||||||
|
int shared_index = getSharedIndex(pos + 1);
|
||||||
|
|
||||||
|
float mixWeight = 1.0;
|
||||||
|
uint mask = 0xFFFF;
|
||||||
|
uint blockId = voxelSharedData[shared_index];
|
||||||
|
|
||||||
|
if (blockId > 0 && blockId != BLOCK_EMPTY) {
|
||||||
|
uvec2 blockData = imageLoad(imgBlockData, int(blockId)).rg;
|
||||||
|
mask = (blockData.g >> 24) & 0xFFFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
return lpvSharedData[shared_index] * ((mask >> mask_index) & 1u);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 mixNeighbours(const in ivec3 fragCoord, const in uint mask) {
|
||||||
|
vec4 nX1 = sampleShared(fragCoord + ivec3(-1, 0, 0), 1) * ((mask ) & 1u);
|
||||||
|
vec4 nX2 = sampleShared(fragCoord + ivec3( 1, 0, 0), 0) * ((mask >> 1) & 1u);
|
||||||
|
vec4 nY1 = sampleShared(fragCoord + ivec3( 0, -1, 0), 3) * ((mask >> 2) & 1u);
|
||||||
|
vec4 nY2 = sampleShared(fragCoord + ivec3( 0, 1, 0), 2) * ((mask >> 3) & 1u);
|
||||||
|
vec4 nZ1 = sampleShared(fragCoord + ivec3( 0, 0, -1), 5) * ((mask >> 4) & 1u);
|
||||||
|
vec4 nZ2 = sampleShared(fragCoord + ivec3( 0, 0, 1), 4) * ((mask >> 5) & 1u);
|
||||||
|
|
||||||
|
const vec4 avgFalloff = (1.0/6.0) * LpvBlockSkyFalloff.xxxy;
|
||||||
|
return (nX1 + nX2 + nY1 + nY2 + nZ1 + nZ2) * avgFalloff;
|
||||||
|
}
|
||||||
|
|
||||||
|
uint GetVoxelBlock(const in ivec3 voxelPos) {
|
||||||
|
if (clamp(voxelPos, ivec3(0), ivec3(VoxelSize3-1u)) != voxelPos)
|
||||||
|
return BLOCK_EMPTY;
|
||||||
|
|
||||||
|
return imageLoad(imgVoxelMask, voxelPos).r;
|
||||||
|
}
|
||||||
|
|
||||||
|
void PopulateSharedIndex(const in ivec3 imgCoordOffset, const in ivec3 workGroupOffset, const in uint i) {
|
||||||
|
ivec3 pos = workGroupOffset + ivec3(i / lpvFlatten) % 10;
|
||||||
|
|
||||||
|
lpvSharedData[i] = GetLpvValue(imgCoordOffset + pos);
|
||||||
|
voxelSharedData[i] = GetVoxelBlock(pos);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
////////////////////////////// VOID MAIN //////////////////////////////
|
||||||
|
|
||||||
|
void main() {
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
uvec3 chunkPos = gl_WorkGroupID * gl_WorkGroupSize;
|
||||||
|
if (any(greaterThanEqual(chunkPos, LpvSize3))) return;
|
||||||
|
|
||||||
|
uint i = uint(gl_LocalInvocationIndex) * 2u;
|
||||||
|
if (i < 1000u) {
|
||||||
|
ivec3 imgCoordOffset = ivec3(floor(cameraPosition) - floor(previousCameraPosition));
|
||||||
|
ivec3 workGroupOffset = ivec3(gl_WorkGroupID * gl_WorkGroupSize) - 1;
|
||||||
|
|
||||||
|
PopulateSharedIndex(imgCoordOffset, workGroupOffset, i);
|
||||||
|
PopulateSharedIndex(imgCoordOffset, workGroupOffset, i + 1u);
|
||||||
|
}
|
||||||
|
|
||||||
|
barrier();
|
||||||
|
|
||||||
|
ivec3 imgCoord = ivec3(gl_GlobalInvocationID);
|
||||||
|
if (any(greaterThanEqual(imgCoord, LpvSize3))) return;
|
||||||
|
|
||||||
|
uint blockId = voxelSharedData[getSharedIndex(ivec3(gl_LocalInvocationID) + 1)];
|
||||||
|
vec4 lightValue = vec4(0.0);
|
||||||
|
vec3 tintColor = vec3(1.0);
|
||||||
|
uint mixMask = 0xFFFF;
|
||||||
|
|
||||||
|
if (blockId > 0u) {
|
||||||
|
tintColor = vec3(0.0);
|
||||||
|
|
||||||
|
uvec2 blockData = imageLoad(imgBlockData, int(blockId)).rg;
|
||||||
|
vec4 lightColorRange = unpackUnorm4x8(blockData.r);
|
||||||
|
vec4 tintColorMask = unpackUnorm4x8(blockData.g);
|
||||||
|
tintColor = srgbToLinear(tintColorMask.rgb);
|
||||||
|
mixMask = (blockData.g >> 24) & 0xFFFF;
|
||||||
|
|
||||||
|
vec3 lightColor = srgbToLinear(lightColorRange.rgb);
|
||||||
|
float lightRange = lightColorRange.a * 255.0;
|
||||||
|
|
||||||
|
if (lightRange > 0.0) {
|
||||||
|
lightValue.rgb = Lpv_RgbToHsv(lightColor, lightRange);
|
||||||
|
lightValue.ba = exp2(lightValue.ba * LpvBlockSkyRange) - 1.0;
|
||||||
|
lightValue.rgb = HsvToRgb(lightValue.rgb);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (any(greaterThan(tintColor, vec3(0.0)))) {
|
||||||
|
vec4 lightMixed = mixNeighbours(ivec3(gl_LocalInvocationID), mixMask);
|
||||||
|
lightMixed.rgb *= tintColor;
|
||||||
|
lightValue += lightMixed;
|
||||||
|
}
|
||||||
|
|
||||||
|
lightValue.rgb = RgbToHsv(lightValue.rgb);
|
||||||
|
lightValue.ba = log2(lightValue.ba + 1.0) / LpvBlockSkyRange;
|
||||||
|
|
||||||
|
if (frameCounter % 2 == 0)
|
||||||
|
imageStore(imgLpv1, imgCoord, lightValue);
|
||||||
|
else
|
||||||
|
imageStore(imgLpv2, imgCoord, lightValue);
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,38 @@
|
||||||
|
entity.1601=player
|
||||||
|
|
||||||
|
entity.1602=minecraft:lightning_bolt weather2:lightning_bolt
|
||||||
|
|
||||||
|
## misc stuff
|
||||||
|
|
||||||
|
entity.1603=blaze
|
||||||
|
|
||||||
|
entity.1604=ender_dragon wither
|
||||||
|
|
||||||
|
entity.1605=end_crystal
|
||||||
|
|
||||||
|
entity.1606=item_frame item_display
|
||||||
|
|
||||||
|
entity.1607=magma_cube
|
||||||
|
|
||||||
|
entity.1608=tnt firework_rocket
|
||||||
|
|
||||||
|
entity.1609=small_fireball
|
||||||
|
|
||||||
|
entity.1610=spectral_arrow bigglobe:torch_arrow
|
||||||
|
|
||||||
|
################################################
|
||||||
|
###### SUB-SURFACE SCATTERING
|
||||||
|
################################################
|
||||||
|
|
||||||
|
## medium sss (same as strong sss for blocks)
|
||||||
|
entity.1801=giant ghast elder_guardian
|
||||||
|
|
||||||
|
## weak sss (same as weak sss for blocks)
|
||||||
|
entity.1802=furnace_minecart sheep frog chicken iron_golem snow_golem polar_bear zombie_horse armor_stand arrow squid bat cat cod cow donkey fox horse mooshroom mule ocelot parrot pig piglin polar_bear pufferfish rabbit salmon strider tropical_fish turtle villager wandering_trader bee cave_spider dolphin enderman llama panda spider wolf zombified_piglin creeper drowned endermite evoker guardian hoglin husk phantom piglin_brute pillager ravager silverfish stray vex vindicator witch zoglin zombie zombie_villager trader_llama
|
||||||
|
#removed: player blaze magma_cube
|
||||||
|
|
||||||
|
################################################
|
||||||
|
###### REFLECTIVE TRANSLUCENTS
|
||||||
|
################################################
|
||||||
|
|
||||||
|
entity.1803=slime
|
|
@ -0,0 +1,52 @@
|
||||||
|
item.1000=soul_lantern conduit beacon sea_pickle sea_lantern glowstone redstone_torch jack_o_lantern magma_block lantern shroomlight end_rod lava_bucket conquest:white_paper_lantern conquest:yellow_paper_lantern conquest:small_red_paper_lantern conquest:chinese_palace_lantern conquest:campfire conquest:brazier conquest:hanging_brazier conquest:chandelier conquest:candelabra conquest:cross_chandelier conquest:conquest:iron_candelabrum_1 conquest:conquest:golden_candelabrum_1 conquest:candle conquest:hanging_candle_holder conquest:candle_in_a_lantern conquest:candles conquest:hand_candle conquest:torch_with_grille conquest:elven_hand_light conquest:ship_lantern conquest:victorian_lantern conquest:small_lantern conquest:big_lantern conquest:hanging_oil_lamp conquest:oil_lamp conquest:terracotta_oil_lamp conquest:invisible_light_low conquest:invisible_light_medium conquest:invisible_light
|
||||||
|
|
||||||
|
item.1001=large_amethyst_bud
|
||||||
|
|
||||||
|
item.1002=medium_amethyst_bud
|
||||||
|
|
||||||
|
item.1003=amethyst_cluster
|
||||||
|
|
||||||
|
item.1004=beacon
|
||||||
|
|
||||||
|
item.1005=blaze_rod
|
||||||
|
|
||||||
|
item.1006=end_rod
|
||||||
|
|
||||||
|
item.1007=ochre_froglight
|
||||||
|
|
||||||
|
item.1008=pearlescent_froglight
|
||||||
|
|
||||||
|
item.1009=verdant_froglight
|
||||||
|
|
||||||
|
item.1010=glow_berries
|
||||||
|
|
||||||
|
item.1011=glow_lichen
|
||||||
|
|
||||||
|
item.1012=glowstone
|
||||||
|
|
||||||
|
item.1013=glowstone_dust
|
||||||
|
|
||||||
|
item.1014=jack_o_lantern
|
||||||
|
|
||||||
|
item.1015=lantern
|
||||||
|
|
||||||
|
item.1016=lava_bucket
|
||||||
|
|
||||||
|
## ITEM_LIGHT
|
||||||
|
# item.* = light
|
||||||
|
|
||||||
|
item.1017=magma_block
|
||||||
|
|
||||||
|
item.1018=redstone_torch
|
||||||
|
|
||||||
|
item.1019=sculk_catalyst
|
||||||
|
|
||||||
|
item.1020=sea_lantern
|
||||||
|
|
||||||
|
item.1021=shroomlight
|
||||||
|
|
||||||
|
item.1022=soul_lantern
|
||||||
|
|
||||||
|
item.1023=soul_torch
|
||||||
|
|
||||||
|
item.1024=torch
|
|
@ -0,0 +1,700 @@
|
||||||
|
option.BLISS_SHADERS=Bliss
|
||||||
|
value.BLISS_SHADERS.0=A Chocapic13 Edit
|
||||||
|
value.BLISS_SHADERS.1=By Xonk
|
||||||
|
value.BLISS_SHADERS.2=Version GIT-HEAD
|
||||||
|
|
||||||
|
# if you're here to translate, this is a joke, these don't do what they say
|
||||||
|
profile.QUALITY=Quality
|
||||||
|
profile.PERFORMANCE=Performance
|
||||||
|
|
||||||
|
screen.Misc_Settings = Misc. Settings
|
||||||
|
screen.Sun_and_Moon_Colors = Sun/Moon Colors
|
||||||
|
option.sunPathRotation = Sun Angle
|
||||||
|
option.sun_illuminance = Sun Illuminance
|
||||||
|
option.moon_illuminance = Moon Illuminance
|
||||||
|
option.MOONPHASE_BASED_MOONLIGHT = Moonphase brightness levels
|
||||||
|
|
||||||
|
option.RESOURCEPACK_SKY = RP Sky
|
||||||
|
value.RESOURCEPACK_SKY.0 = Do not use
|
||||||
|
value.RESOURCEPACK_SKY.1 = Sky + Shader sun/moon
|
||||||
|
value.RESOURCEPACK_SKY.2 = Full sky
|
||||||
|
|
||||||
|
screen.Waving_Stuff = Waving Stuff
|
||||||
|
option.WAVY_PLANTS = Waving Plants
|
||||||
|
option.WAVY_STRENGTH = Waving Strength
|
||||||
|
option.WAVY_SPEED = Waving Speed
|
||||||
|
|
||||||
|
screen.Direct_Light = Direct Light
|
||||||
|
screen.Shadows = Shadows
|
||||||
|
option.TRANSLUCENT_COLORED_SHADOWS = Colored Shadows
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS = Screen-space Shadows
|
||||||
|
option.RENDER_ENTITY_SHADOWS = Shadows for Entities
|
||||||
|
option.RENDER_PLAYER_SHADOWS = Shadows for the Player
|
||||||
|
option.shadowMapResolution = Shadow Resolution
|
||||||
|
option.shadowDistance = Shadow Distance
|
||||||
|
value.shadowDistance.32.0 = 2 Chunks
|
||||||
|
value.shadowDistance.48.0 = 3 Chunks
|
||||||
|
value.shadowDistance.64.0 = 4 Chunks
|
||||||
|
value.shadowDistance.80.0 = 5 Chunks
|
||||||
|
value.shadowDistance.96.0 = 6 Chunks
|
||||||
|
value.shadowDistance.112.0 = 7 Chunks
|
||||||
|
value.shadowDistance.128.0 = 8 Chunks
|
||||||
|
value.shadowDistance.144.0 = 9 Chunks
|
||||||
|
value.shadowDistance.160.0 = 10 Chunks
|
||||||
|
value.shadowDistance.176.0 = 11 Chunks
|
||||||
|
value.shadowDistance.192.0 = 12 Chunks
|
||||||
|
value.shadowDistance.208.0 = 13 Chunks
|
||||||
|
value.shadowDistance.224.0 = 14 Chunks
|
||||||
|
value.shadowDistance.240.0 = 15 Chunks
|
||||||
|
value.shadowDistance.256.0 = 16 Chunks
|
||||||
|
value.shadowDistance.272.0 = 17 Chunks
|
||||||
|
value.shadowDistance.288.0 = 18 Chunks
|
||||||
|
value.shadowDistance.304.0 = 19 Chunks
|
||||||
|
value.shadowDistance.320.0 = 20 Chunks
|
||||||
|
value.shadowDistance.336.0 = 21 Chunks
|
||||||
|
value.shadowDistance.352.0 = 22 Chunks
|
||||||
|
value.shadowDistance.368.0 = 23 Chunks
|
||||||
|
value.shadowDistance.384.0 = 24 Chunks
|
||||||
|
value.shadowDistance.512.0 = 32 Chunks
|
||||||
|
value.shadowDistance.768.0 = 48 Chunks
|
||||||
|
value.shadowDistance.1024.0 = 64 Chunks
|
||||||
|
value.shadowDistance.1536.0 = 96 Chunks
|
||||||
|
value.shadowDistance.2048.0 = 128 Chunks
|
||||||
|
value.shadowDistance.4096.0 = 256 Chunks
|
||||||
|
value.shadowDistance.8192.0 = 512 Chunks
|
||||||
|
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE = Max Shadow Bounds
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.-1.0 = Un-Optimized
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.1.0 = Optimized
|
||||||
|
option.entityShadowDistanceMul = Entity Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.01 = 1% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.02 = 2% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.03 = 3% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.04 = 4% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.05 = 5% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.10 = 10% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.15 = 15% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.20 = 20% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.25 = 25% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.30 = 30% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.35 = 35% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.40 = 40% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.45 = 45% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.50 = 50% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.0.75 = 75% of Shadow Distance
|
||||||
|
value.entityShadowDistanceMul.1.00 = 100% of Shadow Distance
|
||||||
|
|
||||||
|
screen.Filtering = Shadow Filtering Settings
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT = Basic Shadow Filter Samples
|
||||||
|
option.Min_Shadow_Filter_Radius = Minimum Shadow filter Radius
|
||||||
|
option.Variable_Penumbra_Shadows = Variable Penumbra Shadows
|
||||||
|
option.VPS_Search_Samples = VPS Filter Samples
|
||||||
|
option.Max_Shadow_Filter_Radius = Maximum Shadow Filter Radius
|
||||||
|
option.Max_Filter_Depth = Sun Size Factor
|
||||||
|
|
||||||
|
screen.LPV = FloodFill
|
||||||
|
option.LPV_ENABLED = Enabled
|
||||||
|
option.LPV_SIZE = Size
|
||||||
|
value.LPV_SIZE.6 = Small [64]
|
||||||
|
value.LPV_SIZE.7 = Medium [128]
|
||||||
|
value.LPV_SIZE.8 = Large [256]
|
||||||
|
option.LPV_NORMAL_STRENGTH = Normal Strength
|
||||||
|
suffix.LPV_NORMAL_STRENGTH = %
|
||||||
|
value.LPV_NORMAL_STRENGTH.0 = OFF
|
||||||
|
option.LPV_ENTITY_LIGHTS = Entity Lights
|
||||||
|
option.LPV_REDSTONE_LIGHTS = Redstone Lights
|
||||||
|
option.LPV_COLORED_CANDLES = Colored Candles
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering = Sub-Surface Scattering
|
||||||
|
option.LabSSS_Curve = LabSSS Curve
|
||||||
|
option.MISC_BLOCK_SSS = SSS for random blocks
|
||||||
|
option.MOB_SSS = SSS for mobs
|
||||||
|
option.Ambient_SSS = SSS from the sky
|
||||||
|
option.ambientsss_brightness = Sky SSS Brightness
|
||||||
|
option.SSS_TYPE = Mode
|
||||||
|
value.SSS_TYPE.0 = None
|
||||||
|
value.SSS_TYPE.1 = Hardcoded only
|
||||||
|
value.SSS_TYPE.2 = Hardcoded + LabSSS
|
||||||
|
value.SSS_TYPE.3 = LabSSS only
|
||||||
|
|
||||||
|
|
||||||
|
screen.Ambient_light = Ambient Light
|
||||||
|
option.AO_Strength = AO Multiplier
|
||||||
|
option.GI_Strength = GI Multiplier
|
||||||
|
option.HQ_SSGI = Long Range SSGI
|
||||||
|
option.Hand_Held_lights = Hand Held Light
|
||||||
|
option.SKY_CONTRIBUTION_IN_SSRT = High Quality Ambient Light
|
||||||
|
option.ambientOcclusionLevel = Vanilla AO Amount
|
||||||
|
option.ambient_brightness = Ambient Light Brightness
|
||||||
|
option.MIN_LIGHT_AMOUNT = Minimum Light Brightness
|
||||||
|
option.indirect_effect = Indirect Lighting
|
||||||
|
value.indirect_effect.0 = Vanilla AO
|
||||||
|
value.indirect_effect.1 = SSAO
|
||||||
|
value.indirect_effect.2 = GTAO
|
||||||
|
value.indirect_effect.3 = RTAO
|
||||||
|
value.indirect_effect.4 = SSGI
|
||||||
|
|
||||||
|
screen.Ambient_Colors = Ambient Light Color
|
||||||
|
option.AmbientLight_R = Red Amount
|
||||||
|
option.AmbientLight_G = Green Amount
|
||||||
|
option.AmbientLight_B = Blue Amount
|
||||||
|
option.ambient_colortype = Coloring Type
|
||||||
|
value.ambient_colortype.0 = Temperature
|
||||||
|
value.ambient_colortype.1 = RGB
|
||||||
|
|
||||||
|
screen.Torch_Colors = Torch Color
|
||||||
|
option.TORCH_AMOUNT = Torch Light Multiplier
|
||||||
|
option.TORCH_R = Red Amount
|
||||||
|
option.TORCH_G = Green Amount
|
||||||
|
option.TORCH_B = Blue Amount
|
||||||
|
|
||||||
|
|
||||||
|
screen.Fog = Fog Settings
|
||||||
|
option.VL_RENDER_RESOLUTION = Fog Resolution Scaling
|
||||||
|
option.VL_SAMPLES = Fog Samples
|
||||||
|
option.BLOOMY_FOG = Bloomy Fog Multiplier
|
||||||
|
option.Haze_amount = Atmospheric Haze Density
|
||||||
|
option.RainFog_amount = Rain Fog Multiplier
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG = Render Clouds As Fog
|
||||||
|
option.BorderFog = Chunk Border Fog
|
||||||
|
|
||||||
|
screen.TOD_fog = Time Of Day Fog
|
||||||
|
option.TOD_Fog_mult = Fog Density Multiplier
|
||||||
|
option.Morning_Uniform_Fog = Morning Fog Density
|
||||||
|
option.Noon_Uniform_Fog = Noon Fog Density
|
||||||
|
option.Evening_Uniform_Fog = Evening Fog Density
|
||||||
|
option.Night_Uniform_Fog = Night Fog Density
|
||||||
|
option.Morning_Cloudy_Fog = Cloudy Morning Fog Density
|
||||||
|
option.Noon_Cloudy_Fog = Cloudy Noon Fog Density
|
||||||
|
option.Evening_Cloudy_Fog = Cloudy Evening Fog Density
|
||||||
|
option.Night_Cloudy_Fog = Cloudy Night Fog Density
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT = Per Biome Environments
|
||||||
|
|
||||||
|
screen.Cave_Fog = Cave Fog
|
||||||
|
option.Cave_Fog = Cave Fog
|
||||||
|
option.CaveFogFallOff = Fog Falloff
|
||||||
|
option.CaveFogColor_R = Fog R
|
||||||
|
option.CaveFogColor_G = Fog G
|
||||||
|
option.CaveFogColor_B = Fog B
|
||||||
|
|
||||||
|
screen.END_AND_NETHER_FOG = Nether/End Fog
|
||||||
|
option.END_STORM_DENSTIY = End Storm Density
|
||||||
|
option.NETHER_PLUME_DENSITY = Nether Smoke Density
|
||||||
|
|
||||||
|
screen.Clouds = Cloud Settings
|
||||||
|
option.VOLUMETRIC_CLOUDS = Volumetric Clouds
|
||||||
|
option.CLOUDS_QUALITY = Cloud Resolution Scaling
|
||||||
|
option.CLOUDS_SHADOWS = Cloud Shadows
|
||||||
|
option.Cloud_Speed = Cloud Speed Multiplier
|
||||||
|
option.Rain_coverage = Coverage When Raining
|
||||||
|
option.Daily_Weather = Daily Weather
|
||||||
|
|
||||||
|
option.CloudLayer0 = Small Cumulus Clouds
|
||||||
|
option.CloudLayer0_coverage = Coverage
|
||||||
|
option.CloudLayer0_density = Density
|
||||||
|
option.CloudLayer0_height = Height
|
||||||
|
|
||||||
|
option.CloudLayer1 = Large Cumulus Clouds
|
||||||
|
option.CloudLayer1_coverage = Coverage
|
||||||
|
option.CloudLayer1_density = Density
|
||||||
|
option.CloudLayer1_height = Height
|
||||||
|
|
||||||
|
option.CloudLayer2 = Altostratus Clouds
|
||||||
|
option.CloudLayer2_coverage = Coverage
|
||||||
|
option.CloudLayer2_density = Density
|
||||||
|
option.CloudLayer2_height = Height
|
||||||
|
|
||||||
|
screen.DAILY_WEATHER = Daily Weather Settings
|
||||||
|
screen.DAY0_WEATHER = Day 0 Weather
|
||||||
|
option.DAY0_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY0_l0_density = Small Cumulus Density
|
||||||
|
option.DAY0_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY0_l1_density = Large Cumulus Density
|
||||||
|
option.DAY0_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY0_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY0_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY0_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY1_WEATHER = Day 1 Weather
|
||||||
|
option.DAY1_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY1_l0_density = Small Cumulus Density
|
||||||
|
option.DAY1_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY1_l1_density = Large Cumulus Density
|
||||||
|
option.DAY1_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY1_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY1_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY1_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY2_WEATHER = Day 2 Weather
|
||||||
|
option.DAY2_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY2_l0_density = Small Cumulus Density
|
||||||
|
option.DAY2_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY2_l1_density = Large Cumulus Density
|
||||||
|
option.DAY2_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY2_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY2_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY2_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY3_WEATHER = Day 3 Weather
|
||||||
|
option.DAY3_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY3_l0_density = Small Cumulus Density
|
||||||
|
option.DAY3_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY3_l1_density = Large Cumulus Density
|
||||||
|
option.DAY3_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY3_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY3_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY3_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY4_WEATHER = Day 4 Weather
|
||||||
|
option.DAY4_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY4_l0_density = Small Cumulus Density
|
||||||
|
option.DAY4_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY4_l1_density = Large Cumulus Density
|
||||||
|
option.DAY4_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY4_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY4_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY4_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY5_WEATHER = Day 5 Weather
|
||||||
|
option.DAY5_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY5_l0_density = Small Cumulus Density
|
||||||
|
option.DAY5_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY5_l1_density = Large Cumulus Density
|
||||||
|
option.DAY5_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY5_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY5_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY5_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY6_WEATHER = Day 6 Weather
|
||||||
|
option.DAY6_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY6_l0_density = Small Cumulus Density
|
||||||
|
option.DAY6_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY6_l1_density = Large Cumulus Density
|
||||||
|
option.DAY6_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY6_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY6_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY6_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY7_WEATHER = Day 7 Weather
|
||||||
|
option.DAY7_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY7_l0_density = Small Cumulus Density
|
||||||
|
option.DAY7_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY7_l1_density = Large Cumulus Density
|
||||||
|
option.DAY7_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY7_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY7_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY7_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY8_WEATHER = Day 8 Weather
|
||||||
|
option.DAY8_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY8_l0_density = Small Cumulus Density
|
||||||
|
option.DAY8_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY8_l1_density = Large Cumulus Density
|
||||||
|
option.DAY8_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY8_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY8_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY8_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
screen.DAY9_WEATHER = Day 9 Weather
|
||||||
|
option.DAY9_l0_coverage = Small Cumulus coverage
|
||||||
|
option.DAY9_l0_density = Small Cumulus Density
|
||||||
|
option.DAY9_l1_coverage = Large Cumulus Coverage
|
||||||
|
option.DAY9_l1_density = Large Cumulus Density
|
||||||
|
option.DAY9_l2_coverage = Altostratus Clouds Coverage
|
||||||
|
option.DAY9_l2_density = Altostratus Clouds Density
|
||||||
|
option.DAY9_ufog_density = Uniform Fog Density
|
||||||
|
option.DAY9_cfog_density = Cloudy Fog Density
|
||||||
|
|
||||||
|
|
||||||
|
screen.Climate = Climate Settings
|
||||||
|
option.Seasons = Seasonal Colors
|
||||||
|
option.Season_Length = Season Length (In Days)
|
||||||
|
option.Start_Season = Starting Season
|
||||||
|
value.Start_Season.0 = Summer (Default)
|
||||||
|
value.Start_Season.1 = Fall
|
||||||
|
value.Start_Season.2 = Winter
|
||||||
|
value.Start_Season.3 = Spring
|
||||||
|
option.Snowy_Winter = Snow During Winter
|
||||||
|
screen.Summer_colors = Summer Colors
|
||||||
|
option.Summer_R = Red Amount
|
||||||
|
option.Summer_G = Green Amount
|
||||||
|
option.Summer_B = Blue Amount
|
||||||
|
option.Summer_Leaf_R = Red Amount (for leaves)
|
||||||
|
option.Summer_Leaf_G = Green Amount (for leaves)
|
||||||
|
option.Summer_Leaf_B = Blue Amount (for leaves)
|
||||||
|
|
||||||
|
screen.Fall_colors = Fall Colors
|
||||||
|
option.Fall_R = Red Amount
|
||||||
|
option.Fall_G = Green Amount
|
||||||
|
option.Fall_B = Blue Amount
|
||||||
|
option.Fall_Leaf_R = Red Amount (for leaves)
|
||||||
|
option.Fall_Leaf_G = Green Amount (for leaves)
|
||||||
|
option.Fall_Leaf_B = Blue Amount (for leaves)
|
||||||
|
|
||||||
|
screen.Winter_colors = Winter Colors
|
||||||
|
option.Winter_R = Red Amount
|
||||||
|
option.Winter_G = Green Amount
|
||||||
|
option.Winter_B = Blue Amount
|
||||||
|
option.Winter_Leaf_R = Red Amount (for leaves)
|
||||||
|
option.Winter_Leaf_G = Green Amount (for leaves)
|
||||||
|
option.Winter_Leaf_B = Blue Amount (for leaves)
|
||||||
|
|
||||||
|
screen.Spring_colors = Spring Colors
|
||||||
|
option.Spring_R = Red Amount
|
||||||
|
option.Spring_G = Green Amount
|
||||||
|
option.Spring_B = Blue Amount
|
||||||
|
option.Spring_Leaf_R = Red Amount (for leaves)
|
||||||
|
option.Spring_Leaf_G = Green Amount (for leaves)
|
||||||
|
option.Spring_Leaf_B = Blue Amount (for leaves)
|
||||||
|
|
||||||
|
screen.SWAMP = Swamp
|
||||||
|
option.SWAMP_ENV = Swamp Environment
|
||||||
|
option.SWAMP_UNIFORM_DENSITY = Uniform Fog Density
|
||||||
|
option.SWAMP_CLOUDY_DENSITY = Cloudy Fog Density
|
||||||
|
option.SWAMP_R = Red Amount
|
||||||
|
option.SWAMP_G = Green Amount
|
||||||
|
option.SWAMP_B = Blue Amount
|
||||||
|
|
||||||
|
screen.JUNGLE = Jungle
|
||||||
|
option.JUNGLE_ENV = Jungle Environment
|
||||||
|
option.JUNGLE_UNIFORM_DENSITY = Uniform Fog Density
|
||||||
|
option.JUNGLE_CLOUDY_DENSITY = Cloudy Fog Density
|
||||||
|
option.JUNGLE_R = Red Amount
|
||||||
|
option.JUNGLE_G = Green Amount
|
||||||
|
option.JUNGLE_B = Blue Amount
|
||||||
|
|
||||||
|
screen.DARKFOREST = Dark Forest
|
||||||
|
option.DARKFOREST_ENV = Dark Forest Environment
|
||||||
|
option.DARKFOREST_UNIFORM_DENSITY = Uniform Fog Density
|
||||||
|
option.DARKFOREST_CLOUDY_DENSITY = Cloudy Fog Density
|
||||||
|
option.DARKFOREST_R = Red Amount
|
||||||
|
option.DARKFOREST_G = Green Amount
|
||||||
|
option.DARKFOREST_B = Blue Amount
|
||||||
|
|
||||||
|
screen.World = World
|
||||||
|
screen.Water = Water Settings
|
||||||
|
option.WATER_REFLECTIONS = Specular Reflections for Water
|
||||||
|
option.SCREENSPACE_REFLECTIONS = Screen-Space Reflections
|
||||||
|
option.SSR_STEPS = SSR Quality
|
||||||
|
option.WATER_SUN_SPECULAR = Sun/Moon Reflections
|
||||||
|
option.WATER_BACKGROUND_SPECULAR = Sky/Fog Reflections
|
||||||
|
option.Refraction = Refraction In Water/Glass
|
||||||
|
option.Dirt_Amount = Dirt Amount
|
||||||
|
option.Water_Top_Layer = Ocean Y coordinate
|
||||||
|
option.WATER_WAVE_STRENGTH = Wave Strength
|
||||||
|
option.SNELLS_WINDOW = Snell's Window
|
||||||
|
|
||||||
|
screen.Water_fog_color = Water Fog Settings
|
||||||
|
option.Dirt_Scatter_R = Scatter Red (dirt)
|
||||||
|
option.Dirt_Scatter_G = Scatter Green (dirt)
|
||||||
|
option.Dirt_Scatter_B = Scatter Blue (dirt)
|
||||||
|
option.Dirt_Absorb_R = Absorb Red (dirt)
|
||||||
|
option.Dirt_Absorb_G = Absorb Green (dirt)
|
||||||
|
option.Dirt_Absorb_B = Absorb Blue (dirt)
|
||||||
|
option.Water_Absorb_R = Absorb Red (water)
|
||||||
|
option.Water_Absorb_G = Absorb Green (water)
|
||||||
|
option.Water_Absorb_B = Absorb Blue (water)
|
||||||
|
|
||||||
|
|
||||||
|
screen.Post_Processing = Post Processing
|
||||||
|
screen.Tonemapping = Tone-Map/Color Settings
|
||||||
|
screen.Exposure = Exposure Settings
|
||||||
|
screen.DepthOfField = Depth Of Field Settings
|
||||||
|
screen.Purkinje_effect = Purkinje Effect Settings
|
||||||
|
option.SHARPENING = Sharpening amount
|
||||||
|
option.BLOOM_STRENGTH = Bloom Multiplier
|
||||||
|
screen.TAA_OPTIONS = Anti-Aliasing Settings
|
||||||
|
option.SCREENSHOT_MODE = Screenshot Mode
|
||||||
|
option.TAA = TAA
|
||||||
|
option.BLEND_FACTOR = Blend Factor
|
||||||
|
option.TAA_UPSCALING = Temporal Upscaling
|
||||||
|
option.SCALE_FACTOR = Scale Factor
|
||||||
|
screen.COLOR_GRADING = Color Grading
|
||||||
|
option.TONE_CURVE = Tone Curve
|
||||||
|
option.LOWER_CURVE = Lower Curve
|
||||||
|
option.UPPER_CURVE = Upper Curve
|
||||||
|
option.COLOR_GRADING_ENABLED=Color Grading
|
||||||
|
option.SHADOWS_GRADE_R = Shadows §cRed
|
||||||
|
option.SHADOWS_GRADE_G = Shadows §aGreen
|
||||||
|
option.SHADOWS_GRADE_B = Shadows §9Blue
|
||||||
|
option.SHADOWS_GRADE_MUL = Shadows Brightness
|
||||||
|
option.MIDS_GRADE_R = Midtones §cRed
|
||||||
|
option.MIDS_GRADE_G = Midtones §aGreen
|
||||||
|
option.MIDS_GRADE_B = Midtones §9Blue
|
||||||
|
option.MIDS_GRADE_MUL = Midtones Brightness
|
||||||
|
option.HIGHLIGHTS_GRADE_R = Highlights §cRed
|
||||||
|
option.HIGHLIGHTS_GRADE_G = Highlights §aGreen
|
||||||
|
option.HIGHLIGHTS_GRADE_B = Highlights §9Blue
|
||||||
|
option.HIGHLIGHTS_GRADE_MUL = Highlights Brightness
|
||||||
|
|
||||||
|
|
||||||
|
screen.LabPBR = Lab PBR
|
||||||
|
screen.Reflections = Specular Reflections
|
||||||
|
option.Specular_Reflections = Specular Reflections
|
||||||
|
option.Screen_Space_Reflections = Screen-Space Reflections
|
||||||
|
option.Rough_reflections = Detailed Roughness
|
||||||
|
option.Sky_reflection = Sky/Fog in Reflections
|
||||||
|
option.Dynamic_SSR_quality = Dynamic SSR Quality
|
||||||
|
option.Roughness_Threshold = Reflection Threshold
|
||||||
|
option.Sun_specular_Strength = Sun Reflection Multiplier
|
||||||
|
option.reflection_quality = SSR Quality
|
||||||
|
|
||||||
|
screen.Emissives = Emissives
|
||||||
|
option.Emissive_Brightness = Emission Multiplier
|
||||||
|
option.Emissive_Curve = Emission Curve
|
||||||
|
option.EMISSIVE_TYPE = Mode
|
||||||
|
value.EMISSIVE_TYPE.0 = No emission
|
||||||
|
value.EMISSIVE_TYPE.1 = Hardcoded only
|
||||||
|
value.EMISSIVE_TYPE.2 = Hardcoded + Lab Emission
|
||||||
|
value.EMISSIVE_TYPE.3 = Lab Emission only
|
||||||
|
|
||||||
|
|
||||||
|
screen.POM = Parallax Occlusion Mapping / POM
|
||||||
|
option.HEIGTHMAP_DEPTH_OFFSET = Heightmap in Depth
|
||||||
|
option.POM = Parallax Occlusion Mapping
|
||||||
|
option.MAX_ITERATIONS = Quality
|
||||||
|
option.POM_DEPTH = Depth
|
||||||
|
option.MAX_DIST = Maximum Distance
|
||||||
|
option.Adaptive_Step_length = Dynamic Quality
|
||||||
|
option.Horrible_slope_normals = Horrible Slope Normals
|
||||||
|
|
||||||
|
|
||||||
|
screen.Porosity = Porosity / Puddles
|
||||||
|
option.Porosity = Porosity
|
||||||
|
option.Puddles = Puddles
|
||||||
|
option.Puddle_Size = Puddle Size Multiplier
|
||||||
|
|
||||||
|
option.MATERIAL_AO = Material Ambient Occlusion
|
||||||
|
|
||||||
|
option.DOF_QUALITY=Depth Of Field
|
||||||
|
value.DOF_QUALITY.-1=Off
|
||||||
|
value.DOF_QUALITY.0=Hexagonal
|
||||||
|
value.DOF_QUALITY.1=Low
|
||||||
|
value.DOF_QUALITY.2=Medium
|
||||||
|
value.DOF_QUALITY.3=High
|
||||||
|
value.DOF_QUALITY.4=Ultra
|
||||||
|
value.DOF_QUALITY.5=Jitter
|
||||||
|
option.MANUAL_FOCUS=Focus
|
||||||
|
option.DOF_ANAMORPHIC_RATIO=Anamorphic Ratio
|
||||||
|
value.MANUAL_FOCUS.-2=Autofocus
|
||||||
|
value.MANUAL_FOCUS.-1=Brightness Slider
|
||||||
|
|
||||||
|
screen.JITTER_DOF=Jitter DOF Settings
|
||||||
|
option.JITTER_STRENGTH=Jitter Strength
|
||||||
|
option.FOCUS_LASER_COLOR=Focus
|
||||||
|
value.FOCUS_LASER_COLOR.0=Red
|
||||||
|
value.FOCUS_LASER_COLOR.1=Green
|
||||||
|
value.FOCUS_LASER_COLOR.2=Blue
|
||||||
|
value.FOCUS_LASER_COLOR.3=Pink
|
||||||
|
value.FOCUS_LASER_COLOR.4=Yellow
|
||||||
|
value.FOCUS_LASER_COLOR.5=White
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE=Aerochrome Mode
|
||||||
|
option.AEROCHROME_PINKNESS=Aerochrome Red:Pink Ratio
|
||||||
|
option.AEROCHROME_WOOL_ENABLED=Aerochrome Wool
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE.comment = Infrared Film. Google "Aerochrome" to get an idea of what it does.
|
||||||
|
option.AEROCHROME_PINKNESS.comment = Higher = Pink. Lower = Red
|
||||||
|
option.AEROCHROME_WOOL_ENABLED.comment = Technically wool things should be affected but it ruins a lot of builds. Enable to be more technically correct.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
screen.Misc_Settings.comment = Random settings for DEBUGGING or other fun stuff.
|
||||||
|
screen.Sun_and_Moon_Colors.comment = Configure the color of the sun or moon.
|
||||||
|
option.sunPathRotation.comment = Configure the angle of the sun or moon
|
||||||
|
option.sun_illuminance.comment = Configure the brightness of the sun
|
||||||
|
option.moon_illuminance.comment = Configure the brightness of the moon
|
||||||
|
|
||||||
|
screen.Direct_Light.comment = Configure settings related to the sun and shadows.
|
||||||
|
|
||||||
|
screen.Shadows.comment = Configure the shadows from the sun to your liking.
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS.comment = §bWhat is this?§r These are shadows for things that are far away, and on small details nearby. §aPERFORMANCE COST:§r low to medium; it is more expensive at higher resolutions.
|
||||||
|
option.RENDER_ENTITY_SHADOWS.comment = §bWhat is this?§r Shadows on all types of entities, like mobs, chests, banners, or signs. §aPERFORMANCE COST:§r low to high; it is very expensive when there are many entities nearby.
|
||||||
|
option.shadowMapResolution.comment = The quality of shadows from the sun casted by things in the world. §aPERFORMANCE COST:§r medium to very high; Shadows must render the 3D world a second time from the perspective of the sun, this is why it cuts performance in half.
|
||||||
|
option.shadowDistance.comment = The maximum distance the shadowmap can render. The distance is not measured linearly in chunks when set to un-optimized. §aPERFORMANCE COST:§r medium to very high; If the chunk render distance is high, the shadows will become more expensive.
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE.comment = Render the shadows only in a sphere around you, limited to a max distance in chunks. Un-optimized does not render the shadows in a sphere and is not locked to chunks; it can cover alot more area with the same distance settings. The distance is not measured in chunks when set to un-optimized. §aPERFORMANCE COST:§r low to medium. Optimized is faster, and unoptimized is slower.
|
||||||
|
screen.Filtering.comment = Configure the filtering effects applied to the shadows.
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT.comment = The quality of the basic shadow filter. This filter just softens the shadows. §aPERFORMANCE COST:§r low to medium; Increasing this should reduce some noise at the edge of shadows.
|
||||||
|
option.Min_Shadow_Filter_Radius.comment = The maximum softness of the basic shadow filter.
|
||||||
|
option.Variable_Penumbra_Shadows.comment = This effect softens the shadows more and more the farther the shadow gets from what casted it. This effect is used to create higher quality shadows and Sub-surface scattering. §aPERFORMANCE COST:§r low to high;
|
||||||
|
option.VPS_Search_Samples.comment = The quality of the variable penumbra shadow filter. §aPERFORMANCE COST:§r low to high; Increasing this should reduce some noise in the sub-surface scattering and very soft shadows.
|
||||||
|
option.Max_Shadow_Filter_Radius.comment = The maximum softness the shadows can get when far away from what casted it.
|
||||||
|
option.Max_Filter_Depth.comment = Configure the size of the sun. If the sun is larger, shadows get softer closer to what casts them.
|
||||||
|
|
||||||
|
screen.Ambient_light.comment = Configure settings related to the lighting in shaded places
|
||||||
|
option.AO_Strength.comment = Configure the strength of the ambient occlusion created by SSAO, GTAO, RTAO, and SSGI. §bWhat is this?§r ambient occlusion is the small soft shadows in corners and such.
|
||||||
|
option.GI_Strength.comment = Configure the strength of the global illumination created by SSGI. §bWhat is this?§r global illumination in this scenario specifically is the light bouncing off a surface and onto some other area.
|
||||||
|
option.HQ_SSGI.comment = Toggle long range screen-space global illumination. §aPERFORMANCE COST:§r very high
|
||||||
|
option.Hand_Held_lights.comment = Toggle shader-side hand held lightsources. §aPERFORMANCE COST:§r very low
|
||||||
|
option.SKY_CONTRIBUTION_IN_SSRT.comment = Allow the RTAO or SSGI to take the entire sky and fog into account to create high quality lighting for shaded areas. This may introduce more noise. §aPERFORMANCE COST:§r medium
|
||||||
|
|
||||||
|
option.ambientOcclusionLevel.comment = Configure the strength of the ambient occlusion from vanilla minecraft. §bWhat is this?§r This ambient occlusion is in minecraft even without shaders enabled.
|
||||||
|
option.ambient_brightness.comment = Configure the brightnes of lighting in shaded places
|
||||||
|
option.MIN_LIGHT_AMOUNT.comment = Configure the minimum amount of light that can be in shaded places.
|
||||||
|
option.indirect_effect.comment = Toggle different types of effects to make lighting in shaded places higher quality. §aPERFORMANCE COSTS:§r. Vanilla AO: very low. SSAO: low to medium. GTAO: medium to high. RTAO or SSGI: high to very high
|
||||||
|
|
||||||
|
screen.Ambient_Colors.comment = Configure the color of light in shaded areas.
|
||||||
|
screen.Torch_Colors.comment = Configure the color of light from torches or other placed lightsources.
|
||||||
|
|
||||||
|
screen.LabPBR.comment = A handfull of effects that use information provided by any resourcepack that follows the LabPBR format.
|
||||||
|
screen.Reflections.comment = Configure the reflections that use information provided by a LabPBR resourcepack.
|
||||||
|
option.Specular_Reflections.comment = Toggle all reflections for Labpbr packs. This enables the sun reflection, and allows other settings to be enabled below. §aPERFORMANCE COST:§r low
|
||||||
|
option.Screen_Space_Reflections.comment = Toggle screen-space reflections. §aPERFORMANCE COST:§r medium
|
||||||
|
option.Rough_reflections.comment = Toggle more detailed roughness for higher quality reflection. This will cause a good amount of visible noise. §aPERFORMANCE COST:§r medium to high
|
||||||
|
option.Sky_reflection.comment = Toggle reflections of the sky and fog. §aPERFORMANCE COST:§r low to medium.
|
||||||
|
option.Dynamic_SSR_quality.comment = This lowers the quality of screen-space reflections based on how visible they are. it can improve performance but lower the quality.
|
||||||
|
option.Roughness_Threshold.comment = If the roughness reaches this threshold, all reflections except the sun do not render. it can improve performance.
|
||||||
|
option.Sun_specular_Strength.comment = Configure how bright the sun's reflection is.
|
||||||
|
option.reflection_quality.comment = Configure the quality of the screen-space reflections.
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering.comment = §bWhat is this?§r Sub-surface scattering is what happens when you put a bright light on your hand, and it starts to glow. The sun actually does the same thing to plants, cloth, skin, and other things.
|
||||||
|
option.SSS_TYPE.comment = Configure how the sub-surface scattering is applied to the world. §bHardcoded:§r The shader decides what gets it. §bLabSSS:§r The resourcepack decides what gets it. §aPERFORMANCE COST:§r very low
|
||||||
|
option.MOB_SSS.comment = Toggle sub-surface scattering for mobs. players are included. §aPERFORMANCE COST:§r very low
|
||||||
|
option.MISC_BLOCK_SSS.comment = Toggle sub-surface scattering for random blocks it may not fit. this is for grass and sand mostly. §aPERFORMANCE COST:§r very low
|
||||||
|
option.Ambient_SSS.comment = §bWhat is this?§r sub-surface scattering from light coming from the sky, instead of the sun. §aPERFORMANCE COST:§r very low to medium; if SSAO is enabled this costs very little, but costs more if SSAO is OFF
|
||||||
|
option.ambientsss_brightness.comment = Configure the brightness of sub-surface scattering from the sky's light
|
||||||
|
|
||||||
|
screen.Emissives.comment = §bWhat is this?§r Emissiveness is just how much light something is letting off, or how much something is glowing.
|
||||||
|
option.Emissive_Brightness.comment = Configure how bright the texture emission should be.
|
||||||
|
option.EMISSIVE_TYPE.comment = Configure how texture emission is applied to the world. §bHardcoded:§r The shader decides what gets it. §bLabSSS:§r The resourcepack decides what gets it. §aPERFORMANCE COST:§r very low
|
||||||
|
option.Emissive_Curve.comment = This determines how quickly the emissive texture reaches its brightest point. 1.0 is linear.
|
||||||
|
|
||||||
|
screen.POM.comment = Configure settings related to parallax occlusion mapping that uses information provided by a resourcepack.
|
||||||
|
option.HEIGTHMAP_DEPTH_OFFSET.comment = §bWhat is this?§r This makes the resourcepack provided "heightmap" offset the depth that a lot of effects use. This allows for finer details nearby, and can work as a "budget POM". §aPERFORMANCE COST:§r low to medium - use this if POM is too hard to run.
|
||||||
|
option.POM.comment = §bWhat is this?§r This effect attempts to create 3D geometry where there previously was none, by using a special image from a resourcepack. This effect basically only pushes inwards, so some artifacts can exist when looking at steep angles. §aPERFORMANCE COST:§r medium to high
|
||||||
|
option.MAX_ITERATIONS.comment = Configure the quality of the parallax occlusion mapping effect. if you see individual layers when looking up close, inscreasing this makes more layers, so they will become harder to see. §aPERFORMANCE COST:§r high
|
||||||
|
option.POM_DEPTH.comment = How deep the parallax occlusion mapping effect can go into a surface. §aPERFORMANCE COST:§r very low
|
||||||
|
option.MAX_DIST.comment = The maximum distance from the camera that the parallax occlusion mapping effect can render. §aPERFORMANCE COST:§r high
|
||||||
|
option.Adaptive_Step_length.comment = This will increase visual quality without needing to increase the actual quality. This causes some artifacts if you look really close, or have a very busy heightmap with sharp varying heights.
|
||||||
|
option.Horrible_slope_normals.comment = This is a poorly done implementation to give a surface to the sides of the parallax occlusion mapping. i do not recommend this. §aPERFORMANCE COST:§r low
|
||||||
|
|
||||||
|
screen.Porosity.comment = Configure settings related to wetness and puddles
|
||||||
|
option.Porosity.comment = §bWhat is this?§r Porosity is a description of how porous some material is, or essentially how much water can be held inside it. for examle, sponges are very porous; water is contained within and darkens it as a results. §aPERFORMANCE COST:§r low
|
||||||
|
option.Puddles.comment = Toggle puddles for when it rains. §aPERFORMANCE COST:§r low
|
||||||
|
option.Puddle_Size.comment = Configure the size of the puddles.
|
||||||
|
|
||||||
|
screen.Fog.comment = Configure settings related to the raymarched volumetric fog, or distance based fog.
|
||||||
|
option.VL_RENDER_RESOLUTION.comment = Configure the resolution of the volumetric fog. §aPERFORMANCE COST:§r high
|
||||||
|
option.VL_SAMPLES.comment = Configure the quality of the volumetric fog. §aPERFORMANCE COST:§r high
|
||||||
|
option.BLOOMY_FOG.comment = Configure the strength of bloom that is applied to fog. §bWhat is this?§r This effect makes the fog look soft, it helps hide a little noise too. can cause some visible flickering on detailed edges. §aPERFORMANCE COST:§r very low
|
||||||
|
option.Haze_amount.comment = Configure how dense the atmosphere around you is. §bWhat is this?§r This is the blue haze you see in the distance.
|
||||||
|
option.RainFog_amount.comment = Configure how dense the fog gets when it rains.
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG.comment = Toggle detailed fog when you go within or around a cloud. §aPERFORMANCE COST:§r medium to high
|
||||||
|
option.BorderFog.comment = §bWhat is this?§r Toggle a fog that attempts to hide the chunks loading in. But because the sky is all over the place, it is difficult to do well. §aPERFORMANCE COST:§r very very low
|
||||||
|
|
||||||
|
screen.TOD_fog.comment = Configure the density of fog that appears at specific times of the day.
|
||||||
|
option.TOD_Fog_mult.comment = Configure how much total fog there is that appears at specific times during the day. this does not effect the atmospheric haze.
|
||||||
|
|
||||||
|
screen.Cave_Fog.comment = Configure settings for fog that appears when you are in very dark places such as caves.
|
||||||
|
option.Cave_Fog.comment = Toggle the fog that appears in dark places. It is impossible to accurately tell when you are in a cave with a shader, so this fog might appear in places that are not a cave. §aPERFORMANCE COST:§r low
|
||||||
|
option.CaveFogFallOff.comment = Configure how quickly the fog gradient reaches its brightest part.
|
||||||
|
|
||||||
|
screen.Clouds.comment = Configure settings related to the raymarched volumetric clouds.
|
||||||
|
option.VOLUMETRIC_CLOUDS.comment = Toggle the clouds. §aPERFORMANCE COST:§r medium to high
|
||||||
|
option.CLOUDS_QUALITY.comment = Configure the resolution of the volumetric clouds. §aPERFORMANCE COST:§r high
|
||||||
|
option.CLOUDS_SHADOWS.comment = Toggle shadows that are casted from the clouds onto the ground, and fog below them. §aPERFORMANCE COST:§r low to medium
|
||||||
|
option.Daily_Weather.comment = Toggle the daily weather. There are 8 weather profiles i have set, that the shader cycles through every day. You cannot change any cloud coverage settings when this is enabled. §aPERFORMANCE COST:§r low
|
||||||
|
option.Cloud_Speed.comment = Configure how fast the clouds move as the day goes by.
|
||||||
|
option.Rain_coverage.comment = Configure how much of the sky the clouds cover during rain.
|
||||||
|
|
||||||
|
screen.World.comment = Configure settings for various things that happen in the world, from waving plants to water related settings.
|
||||||
|
screen.Water.comment = Configure settings related to the water.
|
||||||
|
option.WATER_REFLECTIONS.comment = Toggle all reflections for translucent things. This allows other settings to be enabled below. §aPERFORMANCE COST:§r low-high
|
||||||
|
option.SCREENSPACE_REFLECTIONS.comment = Toggle screen-space reflections on translucent things. §aPERFORMANCE COST:§r medium
|
||||||
|
option.SSR_STEPS.comment = Configure the quality of the screen-space reflections on translucent things. §aPERFORMANCE COST:§r medium to high
|
||||||
|
option.WATER_SUN_SPECULAR.comment = Toggle the sun and moon reflections on translucent things. §aPERFORMANCE COST:§r low
|
||||||
|
option.WATER_BACKGROUND_SPECULAR.comment = Toggle the sky and fog reflections on translucent things. §aPERFORMANCE COST:§r low to medium
|
||||||
|
option.Refraction.comment = Toggle refraction on translucent things. §bWhat is this?§r If you look at water, you can see the light refracting distorts what is in it. §aPERFORMANCE COST:§r low
|
||||||
|
option.Dirt_Amount.comment = Configure how much dirt is in water. This controls how much fog is within water.
|
||||||
|
option.Water_Top_Layer.comment = Configure the Y coordinate at which the ocean should be in the world.
|
||||||
|
|
||||||
|
screen.Water_fog_color.comment = Configure colors of the water fog.
|
||||||
|
|
||||||
|
screen.Climate.comment = Configure settings related to the climate, like seasonal colors, daily weather, and biome specific fog.
|
||||||
|
screen.Seasons.comment = Seasonal colors that cycle through, summer, fall, winter, and spring.
|
||||||
|
option.Seasons.comment = Seasonal colors that cycle through, summer, fall, winter, and spring. §aPERFORMANCE COST:§r low
|
||||||
|
option.Season_Length.comment = Control how long a single season lasts, in minecraft days.
|
||||||
|
option.Snowy_Winter.comment = Toggle snow during winter. §aPERFORMANCE COST:§r low
|
||||||
|
screen.Summer_colors.comment = Configure the colors of vegetation during summer.
|
||||||
|
screen.Fall_colors.comment = Configure the colors of vegetation during fall.
|
||||||
|
screen.Winter_colors.comment = Configure the colors of vegetation during winter.
|
||||||
|
screen.Spring_colors.comment = Configure the colors of vegetation during spring.
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT.comment = Toggle all special environments that only appear in some biomes. §aPERFORMANCE COST:§r low
|
||||||
|
|
||||||
|
screen.SWAMP.comment = Configure the environment in this biome type.
|
||||||
|
option.SWAMP_ENV.comment = Toggle the environment only for this biome type. The other biome environments remain active even if this one is disabled.
|
||||||
|
|
||||||
|
screen.JUNGLE.comment = Configure the environment in this biome type.
|
||||||
|
option.JUNGLE_ENV.comment = Toggle the environment only for this biome type. The other biome environments remain active even if this one is disabled.
|
||||||
|
|
||||||
|
screen.DARKFOREST.comment = Configure the environment in this biome type.
|
||||||
|
option.DARKFOREST_ENV.comment = Toggle the environment only for this biome type. The other biome environments remain active even if this one is disabled.
|
||||||
|
|
||||||
|
|
||||||
|
screen.Waving_Stuff.comment = Configure settings related to waving things.
|
||||||
|
option.WAVY_PLANTS.comment = Toggle waving plants. §aPERFORMANCE COST:§r very low
|
||||||
|
option.WAVY_STRENGTH.comment = Configure the amount the plants wave.
|
||||||
|
option.WAVY_SPEED.comment = Configure the speed the plants wave.
|
||||||
|
|
||||||
|
screen.Post_Processing.comment = Configure settings for all post processing effects, from anti aliasing to tonemapping.
|
||||||
|
screen.Tonemapping.comment = Configure settings related to color and tonemapping.
|
||||||
|
screen.Exposure.comment = Configure settings related to the exposure.
|
||||||
|
screen.DepthOfField.comment = Configure settings related to depth of field.
|
||||||
|
screen.Purkinje_effect.comment = Configure settings related to the purkinje effect.
|
||||||
|
option.SHARPENING.comment = Configure the amount of contrast adapitive sharpening that is applied to the image. This can really bring out lost details from anti-aliasing or upscaling.
|
||||||
|
option.BLOOM_STRENGTH.comment = Configure the amount of bloom that is applied to the image. §bWhat is this?§r Bloom is the soft glow on everything, to describe that something is bright or not.
|
||||||
|
screen.TAA_OPTIONS.comment = Configure settings related to anti-aliasing.
|
||||||
|
option.SCREENSHOT_MODE.comment = Toggle frame accumulation to get a low noise and high quality image. §bWhat is this?§r It stacks frames that happend onto the next frame that is generated, so it is like a long exposure photo.
|
||||||
|
option.TAA.comment = Toggle temporal anti-aliasing. This removes all jagged edges on things, softens the image, and helps remove noise for many effects. This will cause ghosting or trailing because it uses past frames for extra information on the world. §aPERFORMANCE COST:§r low
|
||||||
|
option.BLEND_FACTOR.comment = Configure how much of frame history is used. high numbers means it relies less on frame history, so it may look flickery and noisy. low numbers rely more on frame history, so it may look less moisy, but more smudged with more trailing.
|
||||||
|
option.TAA_UPSCALING.comment = Toggle temporal upscaling. This retains a good amount of quality from a lower resolution image when it upscales. so you can still have a high looking resolution compared to typical upsanpling and still have better performance.
|
||||||
|
option.SCALE_FACTOR.comment = Configure from what fraction of your resolution to upscale from. Below 0.5 is not recommended at all i only have it as an option because it's funny :P
|
||||||
|
screen.COLOR_GRADING.comment = Advanced color grading options
|
||||||
|
option.TONE_CURVE.comment = Enable the tone curve. This is independent from color grading and is applied first.
|
||||||
|
option.COLOR_GRADING_ENABLED.comment = Enable color grading. The RGB sliders will not affect the brightness. This is applied after the tone curve
|
||||||
|
|
||||||
|
option.RESOURCEPACK_SKY.comment = Toggle resourcepack sky support. Configure settings to use the whole resourcepack sky, or keep the shader's sun and moon. §aPERFORMANCE COST:§r very low
|
||||||
|
option.SKY_GROUND = Atmosphere ground
|
||||||
|
|
||||||
|
option.MATERIAL_AO.comment = Toggle the use of ambient occlusion based on what the resourcepack provides. §aPERFORMANCE COST:§r very low
|
||||||
|
option.WATER_WAVE_STRENGTH.comment = configure how strong the waves appear.
|
||||||
|
option.MOONPHASE_BASED_MOONLIGHT.comment = §bWhat is this?§r every night, the moon has different lighting. This setting adjusts the moonlight brightness based on how much of the moon is glowing. §aPERFORMANCE COST:§r nearly nothing
|
||||||
|
|
||||||
|
option.END_STORM_DENSTIY.comment = §bWhat is this?§r This is the dark cloudy fog in the end. Confingure the density of the end storm.
|
||||||
|
option.NETHER_PLUME_DENSITY.comment = §bWhat is this?§r This is the thick, glowing smoke towers in the nether. Confingure the density of the nether smoke.
|
||||||
|
|
||||||
|
option.CloudLayer0.comment = Toggle the layer of clouds that are small. §aPERFORMANCE COST:§r medium
|
||||||
|
option.CloudLayer0_coverage.comment = Configure how much of the sky these clouds cover.
|
||||||
|
option.CloudLayer0_density.comment = Configure how dense, or thick these clouds are.
|
||||||
|
option.CloudLayer0_height.comment = Configure the height at which these clouds fly at.
|
||||||
|
|
||||||
|
option.CloudLayer1.comment = Toggle the layer of clouds that are large. §aPERFORMANCE COST:§r medium
|
||||||
|
option.CloudLayer1_coverage.comment = Configure how much of the sky these clouds cover.
|
||||||
|
option.CloudLayer1_density.comment = Configure how dense, or thick these clouds are.
|
||||||
|
option.CloudLayer1_height.comment = Configure the height at which these clouds fly at. §cTHESE CANNOT BE LOWER THAN THE SMALL CLOUDS§r
|
||||||
|
|
||||||
|
option.CloudLayer2.comment = Toggle the layer of clouds that are very high and thin. §aPERFORMANCE COST:§r low
|
||||||
|
option.CloudLayer2_coverage.comment = Configure how much of the sky these clouds cover.
|
||||||
|
option.CloudLayer2_density.comment = Configure how dense, or thick these clouds are.
|
||||||
|
option.CloudLayer2_height.comment = Configure the height at which these clouds fly at. §cTHESE CANNOT BE LOWER THAN THE LARGE CLOUDS§r
|
||||||
|
|
||||||
|
option.SKY_GROUND.comment = §bWhat is this?§r This is the dark bottom half of the sky that WOULD be the ground, if minecraft had infinite render distance. §aPERFORMANCE COST:§r very very low. §cdisabling this is very slightly slower than having it on due to extra math.§r
|
||||||
|
option.SNELLS_WINDOW.comment = §bWhat is this?§r this is the dark reflective circle you see when under-water. This is an approximation of a thing that happens in reality known as "total internal reflection". §aPERFORMANCE COST:§r very very very small.
|
||||||
|
option.entityShadowDistanceMul.comment = §bWhat is this?§r Configure how far shadows should work for entities. This is good if you want to keep entity shadows and improved performance in high entity areas.
|
||||||
|
|
||||||
|
screen.DISTANT_HORIZONS_SETTINGS = §2Distant Horizons §fsettings
|
||||||
|
|
||||||
|
option.DH_KNOWN_ISSUES =
|
||||||
|
value.DH_KNOWN_ISSUES.0 = §c CLICK THIS TEXT TO LOOP THROUGH A LIST OF KNOWN ISSUES
|
||||||
|
value.DH_KNOWN_ISSUES.1 = §a GTAO, RTAO, and SSGI break on LODs - DH support unimplemented
|
||||||
|
|
||||||
|
option.DISTANT_HORIZONS_SHADOWMAP = §c(DO NOT USE IF YOU DO NOT KNOW WHAT THIS IS)§r DH shadowmap support
|
||||||
|
option.DISTANT_HORIZONS_SHADOWMAP.comment = §cTHIS SETTING WILL DESTROY PERFORMANCE THIS WILL MAKE SHADOWS LOOK BLOCKY, FLICKERY, AND LOW DETAIL§r. set shadow distance to 32 chunks (or more). set shadow resolution to 4096 (or more)
|
||||||
|
option.TOGGLE_VL_FOG = Toggle Volumetric Fog
|
||||||
|
option.TOGGLE_VL_FOG.comment = one big button to just turn all the fog off.
|
||||||
|
|
||||||
|
option.TRANSLUCENT_COLORED_SHADOWS.comment = §bWhat is this?§r This effect allows translucent things like stained glass to color the sunlight as it passes through it. §aPERFORMANCE COST:§r medium
|
|
@ -0,0 +1,486 @@
|
||||||
|
screen.Misc_Settings = Configurações Diversas
|
||||||
|
screen.the_orb = O Orb
|
||||||
|
option.THE_ORB = O Orb
|
||||||
|
option.ORB_X = Orb X
|
||||||
|
option.ORB_Y = Orb Y
|
||||||
|
option.ORB_Z = Orb Z
|
||||||
|
option.ORB_ColMult = Orb MultiplicadorCol
|
||||||
|
option.ORB_R = Orb Vermelho
|
||||||
|
option.ORB_G = Orb Verde
|
||||||
|
option.ORB_B = Orb Azul
|
||||||
|
|
||||||
|
option.WhiteWorld=Mundo Branco
|
||||||
|
option.ambientLight_only=Apenas Luz Ambiente
|
||||||
|
option.Glass_Tint=Tintura de Vidro
|
||||||
|
option.display_LUT=Mostrar LUT
|
||||||
|
option.SSS_view=Visualização de SSS vindo do Céu
|
||||||
|
|
||||||
|
screen.Sun_and_Moon_Colors = Cores Lua/Sol
|
||||||
|
option.sunPathRotation = Ângulo do Sol
|
||||||
|
option.sun_illuminance = Iluminância do Sol
|
||||||
|
option.moon_illuminance = Iluminância da Lua
|
||||||
|
option.OLD_LIGHTLEAK_FIX = Prevenão de Vazamento de Luz antiga
|
||||||
|
|
||||||
|
screen.Waving_Stuff = Plantas Balançando
|
||||||
|
option.WAVY_PLANTS = Plantas Balançando
|
||||||
|
option.WAVY_STRENGTH = Força do Balanço
|
||||||
|
option.WAVY_SPEED = Velocidade do Balanço
|
||||||
|
|
||||||
|
screen.Direct_Light = Luz Direta
|
||||||
|
screen.Shadows = Sombras
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS = Sombras de Contato
|
||||||
|
option.RENDER_ENTITY_SHADOWS = Sombras para Entidades
|
||||||
|
option.shadowMapResolution = Resolução da Sombra
|
||||||
|
option.shadowDistance = Distância da Sombra
|
||||||
|
value.shadowDistance.64.0 = 4 Chunks
|
||||||
|
value.shadowDistance.80.0 = 5 Chunks
|
||||||
|
value.shadowDistance.96.0 = 6 Chunks
|
||||||
|
value.shadowDistance.112.0 = 7 Chunks
|
||||||
|
value.shadowDistance.128.0 = 8 Chunks
|
||||||
|
value.shadowDistance.144.0 = 9 Chunks
|
||||||
|
value.shadowDistance.160.0 = 10 Chunks
|
||||||
|
value.shadowDistance.176.0 = 11 Chunks
|
||||||
|
value.shadowDistance.192.0 = 12 Chunks
|
||||||
|
value.shadowDistance.208.0 = 13 Chunks
|
||||||
|
value.shadowDistance.224.0 = 14 Chunks
|
||||||
|
value.shadowDistance.240.0 = 15 Chunks
|
||||||
|
value.shadowDistance.256.0 = 16 Chunks
|
||||||
|
value.shadowDistance.272.0 = 17 Chunks
|
||||||
|
value.shadowDistance.288.0 = 18 Chunks
|
||||||
|
value.shadowDistance.304.0 = 19 Chunks
|
||||||
|
value.shadowDistance.320.0 = 20 Chunks
|
||||||
|
value.shadowDistance.336.0 = 21 Chunks
|
||||||
|
value.shadowDistance.352.0 = 22 Chunks
|
||||||
|
value.shadowDistance.368.0 = 23 Chunks
|
||||||
|
value.shadowDistance.384.0 = 24 Chunks
|
||||||
|
value.shadowDistance.400.0 = 25 Chunks
|
||||||
|
value.shadowDistance.416.0 = 26 Chunks
|
||||||
|
value.shadowDistance.432.0 = 27 Chunks
|
||||||
|
value.shadowDistance.448.0 = 28 Chunks
|
||||||
|
value.shadowDistance.464.0 = 29 Chunks
|
||||||
|
value.shadowDistance.480.0 = 30 Chunks
|
||||||
|
value.shadowDistance.496.0 = 31 Chunks
|
||||||
|
value.shadowDistance.512.0 = 32 Chunks
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE = Limite Máximo da Sombra
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.-1.0 = Não Otimizado
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.1.0 = Otimizado
|
||||||
|
screen.Filtering = Ajuste do Filtro de Sombras
|
||||||
|
option.BASIC_SHADOW_FILTER = Filtro Básico de Sombra
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT = Amostragem do Filtro Básico de Sombra
|
||||||
|
option.Min_Shadow_Filter_Radius = Alcance Mínimo do Filtro de Sombra
|
||||||
|
option.Variable_Penumbra_Shadows = Sombras de Penumbra Variável
|
||||||
|
option.VPS_Search_Samples = Amostragem de Filtro SPV
|
||||||
|
option.Max_Shadow_Filter_Radius = Alcance Máximo do Filtro de Sombra
|
||||||
|
option.Max_Filter_Depth = Fator Tamanho do Sol
|
||||||
|
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering = Espalhamento de Subsuperfície/SSS
|
||||||
|
option.LabSSS_Curve = Curva LabSSS
|
||||||
|
option.MISC_BLOCK_SSS = SSS Para Blocos Diversos
|
||||||
|
option.MOB_SSS = SSS Para Criaturas
|
||||||
|
option.Ambient_SSS = SSS Vindo do Céu
|
||||||
|
option.ambientsss_brightness = Brilho do SSS Vindo do Céu
|
||||||
|
option.SSS_TYPE = Modo
|
||||||
|
value.SSS_TYPE.0 = Nenhum
|
||||||
|
value.SSS_TYPE.1 = Somente Embutido
|
||||||
|
value.SSS_TYPE.2 = Embutido + LabSSS
|
||||||
|
value.SSS_TYPE.3 = Somente LabSSS
|
||||||
|
|
||||||
|
|
||||||
|
screen.Ambient_light = Luz Ambiente
|
||||||
|
option.AO_Strength = Quantidade de AO
|
||||||
|
option.GI_Strength = Quantidade de GI
|
||||||
|
option.HQ_SSGI = SSGI de Longo Alcance
|
||||||
|
option.Hand_Held_lights = Luz Portátil
|
||||||
|
option.ambientOcclusionLevel = Quantidade de Vanilla AO
|
||||||
|
option.ambient_brightness = Brilho da Luz Ambiente
|
||||||
|
option.MIN_LIGHT_AMOUNT = Brilho Mínimo da Luz
|
||||||
|
option.indirect_effect = Luz Indireta
|
||||||
|
value.indirect_effect.0 = Vanilla AO
|
||||||
|
value.indirect_effect.1 = SSAO
|
||||||
|
value.indirect_effect.2 = GTAO
|
||||||
|
value.indirect_effect.3 = RTAO
|
||||||
|
value.indirect_effect.4 = SSGI
|
||||||
|
|
||||||
|
screen.Ambient_Colors = Cor da Luz Ambiente
|
||||||
|
option.AmbientLight_R = Quant. Vermelho
|
||||||
|
option.AmbientLight_G = Quant. Verde
|
||||||
|
option.AmbientLight_B = Quant. Azul
|
||||||
|
option.ambient_colortype = Tipo de Coloração
|
||||||
|
value.ambient_colortype.0 = Temperatura
|
||||||
|
value.ambient_colortype.1 = RGB
|
||||||
|
|
||||||
|
screen.Torch_Colors = Cor da Tocha
|
||||||
|
option.TORCH_AMOUNT = Quantiadade de Luz na Tocha
|
||||||
|
option.TORCH_R = Quant. Vermelho
|
||||||
|
option.TORCH_G = Quant. Verde
|
||||||
|
option.TORCH_B = Quant. Azul
|
||||||
|
|
||||||
|
|
||||||
|
screen.Fog = Ajustes da Névoa
|
||||||
|
option.VL_RENDER_RESOLUTION = Dimensionamento da Resolução da Névoa
|
||||||
|
option.VL_SAMPLES = Amostragem de Névoa
|
||||||
|
option.BLOOMY_FOG = Quantidade de Névoa Difusa
|
||||||
|
option.Haze_amount = Densidade da Névoa Atmosférica
|
||||||
|
option.RainFog_amount = Quantidade de Névoa na Chuva
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG = Névoa Dentro das Nuvens
|
||||||
|
option.BorderFog = Névoa na Borda dos Chunks
|
||||||
|
|
||||||
|
screen.TOD_fog = Névoa por Horário
|
||||||
|
option.TOD_Fog_mult = Valor de Densidade da Névoa
|
||||||
|
option.Morning_Uniform_Fog = Densidade da Névoa de Manhã
|
||||||
|
option.Noon_Uniform_Fog = Densidade da Névoa ao Meio-dia
|
||||||
|
option.Evening_Uniform_Fog = Densidade da Névoa à Tarde
|
||||||
|
option.Night_Uniform_Fog = Densidade da Névoa à Noite
|
||||||
|
option.Morning_Cloudy_Fog = Densidade da Nublagem de Manhã
|
||||||
|
option.Noon_Cloudy_Fog = Densidade da Nublagem ao Meio-Dia
|
||||||
|
option.Evening_Cloudy_Fog = Densidade da Nublagem à Tarde
|
||||||
|
option.Night_Cloudy_Fog = Densidade da Nublagem à Noite
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT = Névoa Própria de Bioma
|
||||||
|
|
||||||
|
screen.Cave_Fog = Névoa em Caverna
|
||||||
|
option.Cave_Fog = Névoa em Caverna
|
||||||
|
option.CaveFogFallOff = Diminuição da Névoa
|
||||||
|
option.CaveFogColor_R = Névoa R
|
||||||
|
option.CaveFogColor_G = Névoa G
|
||||||
|
option.CaveFogColor_B = Névoa B
|
||||||
|
|
||||||
|
|
||||||
|
screen.Clouds = Ajustes das Nuvens
|
||||||
|
option.VOLUMETRIC_CLOUDS = Nuvens Volumétricas
|
||||||
|
option.CLOUDS_QUALITY = Dimensionamento da Resolução das Nuvens
|
||||||
|
option.CLOUDS_SHADOWS = Sombras da Nuvens
|
||||||
|
option.Daily_Weather = Tempo Diário
|
||||||
|
option.Cloud_Speed = Quantiade de Velociade das Nuvens
|
||||||
|
option.Rain_coverage = Cobertura em Dias Chuvosos
|
||||||
|
|
||||||
|
option.Cumulus = Nuvens Cúmulos
|
||||||
|
option.Cumulus_coverage = Cobertura
|
||||||
|
option.Cumulus_density = Densidade
|
||||||
|
option.Cumulus_height = Altura
|
||||||
|
|
||||||
|
option.Altostratus = Nuvens Alto-estratos
|
||||||
|
option.Alto_coverage = Cobertura
|
||||||
|
option.Alto_density = Densidade
|
||||||
|
|
||||||
|
|
||||||
|
screen.Climate = Ajustes Climáticos
|
||||||
|
option.Seasons = Cores Sazonais
|
||||||
|
option.Season_Length = Duração das Estações (Em Dias)
|
||||||
|
option.Start_Season = Primeira Estação
|
||||||
|
value.Start_Season.0 = Verão (Padrão)
|
||||||
|
value.Start_Season.1 = Outono
|
||||||
|
value.Start_Season.2 = Inverno
|
||||||
|
value.Start_Season.3 = Primavera
|
||||||
|
option.Snowy_Winter = Neve Durante o Inverno
|
||||||
|
screen.Summer_colors = Cores do Verão
|
||||||
|
option.Summer_R = Quant. Vermelho
|
||||||
|
option.Summer_G = Quant. Verde
|
||||||
|
option.Summer_B = Quant. Azul
|
||||||
|
option.Summer_Leaf_R = Quant. Vermelho (Para Folhas)
|
||||||
|
option.Summer_Leaf_G = Quant. Verde (Para Folhas)
|
||||||
|
option.Summer_Leaf_B = Quant. Azul (Para Folhas)
|
||||||
|
|
||||||
|
screen.Fall_colors = Cores do Outono
|
||||||
|
option.Fall_R = Quant. Vermelho
|
||||||
|
option.Fall_G = Quant. Verde
|
||||||
|
option.Fall_B = Quant. Azul
|
||||||
|
option.Fall_Leaf_R = Quant. Vermelho (Para Folhas)
|
||||||
|
option.Fall_Leaf_G = Quant. Verde (Para Folhas)
|
||||||
|
option.Fall_Leaf_B = Quant. Azul (Para Folhas)
|
||||||
|
|
||||||
|
screen.Winter_colors = Cores do Inverno
|
||||||
|
option.Winter_R = Quant. Vermelho
|
||||||
|
option.Winter_G = Quant. Verde
|
||||||
|
option.Winter_B = Quant. Azul
|
||||||
|
option.Winter_Leaf_R = Quant. Vermelho (Para Folhas)
|
||||||
|
option.Winter_Leaf_G = Quant. Verde (Para Folhas)
|
||||||
|
option.Winter_Leaf_B = Quant. Azul (Para Folhas)
|
||||||
|
|
||||||
|
screen.Spring_colors = Cores da Primavera
|
||||||
|
option.Spring_R = Quant. Vermelho
|
||||||
|
option.Spring_G = Quant. Verde
|
||||||
|
option.Spring_B = Quant. Azul
|
||||||
|
option.Spring_Leaf_R = Quant. Vermelho (Para Folhas)
|
||||||
|
option.Spring_Leaf_G = Quant. Verde (Para Folhas)
|
||||||
|
option.Spring_Leaf_B = Quant. Azul (Para Folhas)
|
||||||
|
|
||||||
|
|
||||||
|
screen.World = Mundo
|
||||||
|
screen.Water = Ajustes da Água
|
||||||
|
option.WATER_REFLECTIONS = Reflexos Especulares na Água
|
||||||
|
option.SCREENSPACE_REFLECTIONS = Reflexos no Espaço da Tela / SSR
|
||||||
|
option.SSR_STEPS = Qualidade do SSR
|
||||||
|
option.WATER_SUN_SPECULAR = Reflexos do Sol/Lua
|
||||||
|
option.WATER_BACKGROUND_SPECULAR = Reflexos do Céu/Névoa
|
||||||
|
option.Refraction = Refração na Água/Vidro
|
||||||
|
option.Dirt_Amount = Quantidade de Sujeira
|
||||||
|
option.Water_Top_Layer = Coordenada Y do Oceano
|
||||||
|
|
||||||
|
screen.Water_fog_color = Ajustes da Névoa na Água
|
||||||
|
option.Dirt_Scatter_R = Disperção Vermelho (Sujeira)
|
||||||
|
option.Dirt_Scatter_G = Disperção Verde (Sujeira)
|
||||||
|
option.Dirt_Scatter_B = Disperção Azul (Sujeira)
|
||||||
|
option.Dirt_Absorb_R = Absorção Vermelho (Sujeira)
|
||||||
|
option.Dirt_Absorb_G = Absorção Verde (Sujeira)
|
||||||
|
option.Dirt_Absorb_B = Absorção Azul (Sujeira)
|
||||||
|
option.Water_Absorb_R = Absorção Vermelha (Água)
|
||||||
|
option.Water_Absorb_G = Absorção Verde (Água)
|
||||||
|
option.Water_Absorb_B = Absorção Azul (Água)
|
||||||
|
|
||||||
|
|
||||||
|
screen.Post_Processing = Pós-processamento
|
||||||
|
screen.Tonemapping = Mapeamento de Tons/Ajustes de Cor
|
||||||
|
option.TONEMAP = Mapeamento de Tons
|
||||||
|
option.USE_ACES_COLORSPACE_APPROXIMATION = Usar Aproximação de Espaço de Cores ACES
|
||||||
|
option.SATURATION = Saturação
|
||||||
|
option.CROSSTALK = Crosstalk
|
||||||
|
option.CONTRAST = Contraste
|
||||||
|
screen.Exposure = Ajustes de Exposição
|
||||||
|
option.AUTO_EXPOSURE = Exposição Automática
|
||||||
|
option.EXPOSURE_MULTIPLIER = Multiplicador de Exposição
|
||||||
|
option.Exposure_Speed = Velocidade de Ajuste de Exposição
|
||||||
|
option.Manual_exposure_value = Valor Manual de Exposição
|
||||||
|
screen.DepthOfField = Ajustes de Profundidade de Campo
|
||||||
|
screen.Purkinje_effect = Ajustes da Mudança de Purkinje
|
||||||
|
option.Purkinje_strength = Intensidade do Purkinje
|
||||||
|
option.Purkinje_R = Purkinje Vermelho
|
||||||
|
option.Purkinje_G = Purkinje Verde
|
||||||
|
option.Purkinje_B = Purkinje Azul
|
||||||
|
option.Purkinje_Multiplier = Multiplicador de Purkinje
|
||||||
|
option.SHARPENING = Quantidade de Nitidez CAS
|
||||||
|
option.BLOOM_STRENGTH = Quantidade de Bloom
|
||||||
|
screen.TAA_OPTIONS = Ajustes do Antisserrilhamento
|
||||||
|
option.SCREENSHOT_MODE = Modo Screenshot
|
||||||
|
option.TAA = TAA
|
||||||
|
option.BLEND_FACTOR = Determinante de Mistura
|
||||||
|
option.TAA_UPSCALING = Upscaling Temporal
|
||||||
|
option.SCALE_FACTOR = Determinante de Tamanho
|
||||||
|
|
||||||
|
|
||||||
|
screen.LabPBR = LabPBR
|
||||||
|
screen.Reflections = Reflexos Especulares
|
||||||
|
option.Specular_Reflections = Reflexos Especulares
|
||||||
|
option.Screen_Space_Reflections = Reflexos no Espaço da Tela / SSR
|
||||||
|
option.Rough_reflections = Rugosidade Detalhada
|
||||||
|
option.Sky_reflection = Reflexos do Céu/Névoa
|
||||||
|
option.Dynamic_SSR_quality = Qualidade Dinâmica do SSR
|
||||||
|
option.Roughness_Threshold = Nível do Reflexo
|
||||||
|
option.Sun_specular_Strength = Intensidade do Reflexo do Sol
|
||||||
|
option.reflection_quality = Qualidade do SSR
|
||||||
|
|
||||||
|
screen.Emissives = Emissivos
|
||||||
|
option.Emissive_Brightness = Quantidade de Emissão
|
||||||
|
option.Emissive_Curve = Curva da Emissão
|
||||||
|
option.EMISSIVE_TYPE = Modo
|
||||||
|
value.EMISSIVE_TYPE.0 = Nenhuma Emissão
|
||||||
|
value.EMISSIVE_TYPE.1 = Somente Embutido
|
||||||
|
value.EMISSIVE_TYPE.2 = Embutido + Emissão Lab
|
||||||
|
value.EMISSIVE_TYPE.3 = Somente Emissão Lab
|
||||||
|
|
||||||
|
|
||||||
|
screen.POM = Mapameamento de Oclusão Paralaxe / POM
|
||||||
|
option.POM = Mapameamento de Oclusão Paralaxe
|
||||||
|
option.MAX_ITERATIONS = Qualidade
|
||||||
|
option.POM_DEPTH = Profundidade
|
||||||
|
option.MAX_DIST = Distância Máxima
|
||||||
|
option.Adaptive_Step_length = Qualidade Dinâmica
|
||||||
|
option.Horrible_slope_normals = Inclinação de Relevo Ruim
|
||||||
|
|
||||||
|
|
||||||
|
screen.Porosity = Porosidade / Poças
|
||||||
|
option.Porosity = Porosidade
|
||||||
|
option.Puddles = Poças
|
||||||
|
option.Puddle_Size = Ajuste do Tamanho das Poças
|
||||||
|
|
||||||
|
|
||||||
|
option.DOF_QUALITY=Profundidade de Campo
|
||||||
|
value.DOF_QUALITY.-1=Desligado
|
||||||
|
value.DOF_QUALITY.0=Hexagonal
|
||||||
|
value.DOF_QUALITY.1=Baixo
|
||||||
|
value.DOF_QUALITY.2=Médio
|
||||||
|
value.DOF_QUALITY.3=Alto
|
||||||
|
value.DOF_QUALITY.4=Ultra
|
||||||
|
value.DOF_QUALITY.5=Variação
|
||||||
|
screen.JITTER_DOF= Profundidade de Campo por Variação
|
||||||
|
option.focal=Distância Focal
|
||||||
|
option.aperture=Abertura
|
||||||
|
option.MANUAL_FOCUS=Foco
|
||||||
|
option.DOF_ANAMORPHIC_RATIO=Altura Anamórfica
|
||||||
|
value.MANUAL_FOCUS.-2=Autofoco
|
||||||
|
value.MANUAL_FOCUS.-1=Controle de Brilho
|
||||||
|
option.DoF_Adaptation_Speed=Velocidade de Adaptação da Profundidade de Campo
|
||||||
|
option.FAR_BLUR_ONLY=Apenas Desfoque Distante
|
||||||
|
option.JITTER_STRENGTH= Intensidade da Variação
|
||||||
|
option.FOCUS_LASER_COLOR=Cor de Foco do Laser
|
||||||
|
value.FOCUS_LASER_COLOR.0=Vermnelho
|
||||||
|
value.FOCUS_LASER_COLOR.1=Verde
|
||||||
|
value.FOCUS_LASER_COLOR.2=Azul
|
||||||
|
value.FOCUS_LASER_COLOR.3=Rosa
|
||||||
|
value.FOCUS_LASER_COLOR.4=Amarelo
|
||||||
|
value.FOCUS_LASER_COLOR.5=Branco
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE=Modo Aerochrome
|
||||||
|
option.AEROCHROME_PINKNESS=Aerochrome Proporção Vermelho:Rosa
|
||||||
|
option.AEROCHROME_WOOL_ENABLED=Lã Aerochrome
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE.comment = Filme Infravermelho. Da uma pesquisada "Aerochrome" pra tu ter uma ideia do que isso faz.
|
||||||
|
option.AEROCHROME_PINKNESS.comment = Maior = Rosa. Menor = Vermelho
|
||||||
|
option.AEROCHROME_WOOL_ENABLED.comment = A lã também deveria ser afetada, mas não fica muito legal em construções. Habilite se você quiser ser mais tecnicamente correto.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
screen.Misc_Settings.comment = Várias configurações para DEBUGGING ou outras coisas divertidas.
|
||||||
|
screen.Sun_and_Moon_Colors.comment = Ajuste as Cores do Sol/Lua
|
||||||
|
option.sunPathRotation.comment = Ajuste o Ângulo do Sol/Lua
|
||||||
|
option.sun_illuminance.comment = Ajuste o Brilho do Sol
|
||||||
|
option.moon_illuminance.comment = Ajuste o Brilho da Lua
|
||||||
|
option.OLD_LIGHTLEAK_FIX.comment = Utiliza um método antigo para prevenir o vazamento de luz dentro de cavernas.
|
||||||
|
|
||||||
|
screen.Direct_Light.comment = Ajustes para o sol e as sombras.
|
||||||
|
|
||||||
|
screen.Shadows.comment = Ajuste as sombras do sol ao seu gosto.
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS.comment = Sombras de contato. §bO Que é Isso?§r São pequenas sombras usadas para coisas distantes e também para pequenos detalhes próximos. §aCUSTO DE PERFORMANCE:§r Baixo para Médio; será mais pesado em uma resolução maior.
|
||||||
|
option.RENDER_ENTITY_SHADOWS.comment = §bO Que é Isso?§r São sombras em todos os tipos de entidades como: criaturas, baús, banners e placas. §aCUSTO DE DESEMPENHO:§r Baixo para Alto; pode ser mais pesado dependendo de quantas entidades estão por perto.
|
||||||
|
option.shadowMapResolution.comment = Qualidade das sombras do sol projeta por coisas e objetos. §aCUSTO DE PERFORMANCE:§r Médio para Muito Alto; Renderizar as sombras requer renderizar o mundo uma outra vez, mas da perspectiva do sol, por isso elas reduzem a performance pela metade.
|
||||||
|
option.shadowDistance.comment = Distância máxima que as sombras renderizam. Essa distância não é medida de forma linear em chunks quando colocada em Não Otimizado. §aCUSTO DE PERFORMANCE:§r Médio para Muito Alto; If the chunk render distance is high, the shadows will become more expensive Vai ser mais pesado se a distância de renderização dos chunks for alta.
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE.comment = Renderiza as sombras somente em uma esféra em volta de você, limitada à uma distância máxima de chunks. Se usado Não Otimizado ela não vai renderizar em uma esféra e também não vai ter limite por chunks; pode cobrir uma área muito maior com a mesma configuração de distância. A distância não é medida em chunks se usado Não Otimizado. §aCUSTO DE PERFORMANCE:§r Baixo para Médio. Otimizado é mais rápido e Não Otimizado é mais lento.
|
||||||
|
screen.Filtering.comment = Ajuste o efeito de filtragem aplicado as sombras.
|
||||||
|
option.BASIC_SHADOW_FILTER.comment = Filtro básico que suaviza as sombras.
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT.comment = Qualidade do filtro básico das sombras. Esse filtro apenas suaviza as sombras. §aCUSTO DE PERFORMANCE:§r Baixo para Alto; Aumentar isso reduz um pouco do ruído presente nas bordas das sombras.
|
||||||
|
option.Min_Shadow_Filter_Radius.comment = A suavidade máxima do filtro básico das sombras.
|
||||||
|
option.Variable_Penumbra_Shadows.comment = Esse efeito deixa a sombra mais suave, de acordo com o quão longe ela está do que a projetou. Esse efeito cria sombras de alta qualidade e também o espalhamento de subsuperfície. §aCUSTO DE PERFORMANCE:§r Baixo para Alto;
|
||||||
|
option.VPS_Search_Samples.comment = A qualidade do filtro das sombras de penumbra variável. §aCUSTO DE PERFORMANCE:§r Baixo para Alto; Aumentar isso reduz um pouco do ruído presente no espalhamento de subsuperfície e em sombras muito suavez.
|
||||||
|
option.Max_Shadow_Filter_Radius.comment = A suavidade máxima que a sombra consegue alcançar quando está longe do que a projetou.
|
||||||
|
option.Max_Filter_Depth.comment = Ajusta o tamanho do Sol. Se o sol for maior as sombras ficam mais suaves, de acordo com a distância do que as projetou.
|
||||||
|
|
||||||
|
screen.Ambient_light.comment = Ajustes relacionados a luz em lugares sombreados
|
||||||
|
option.AO_Strength.comment = Ajuste à força da oclusão ambiental gerada pelo SSAO, GTAO, RTAO, e SSGI. §bO Que é Isso?§r Oclusão ambiental é uma pequena sombra suave no canto das coisas.
|
||||||
|
option.GI_Strength.comment = Ajuste à força da iluminação global gerada pelo SSGI. §bO Que é Isso?§r Nesse caso, é a luz quicando de uma superfície para outra área.
|
||||||
|
option.HQ_SSGI.comment = Habilite uma iluminação global de longo alcance. §aCUSTO DE PERFORMANCE:§r Muito Alto
|
||||||
|
option.Hand_Held_lights.comment = Habilite uma luz portátil do próprio shaders. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.ambientOcclusionLevel.comment = Ajuste à força da oclusão de ambiente vanilla do Minecraft. §bO Que é Isso?§r Essa é a oclusão de ambiente vanilla do Minecraft, mesmo sem shaders.
|
||||||
|
option.ambient_brightness.comment = Ajuste o brilho da luz em locais sombreados.
|
||||||
|
option.MIN_LIGHT_AMOUNT.comment = Ajuste a quantidade mínima de luz presente em locais sombreados.
|
||||||
|
option.indirect_effect.comment = Habilite diferentes tipos de efeitos para criar uma iluminação de alta qualidade em locais sombreados. §aCUSTO DE PERFORMANCE:§r. Vanilla AO: Muito Baixo. SSAO: Baixo para Médio. GTAO: Médio para Alto. RTAO or SSGI: Alto para Muito Alto.
|
||||||
|
|
||||||
|
screen.Ambient_Colors.comment = Ajuste a cor da luz em lugares sombreados.
|
||||||
|
screen.Torch_Colors.comment = Ajuste a cor da luz da tocha ou outras fontes de luz.
|
||||||
|
|
||||||
|
screen.LabPBR.comment = Um punhado de efeitos que usam informações de um pacote de textura que usa o formato LabPBR.
|
||||||
|
screen.Reflections.comment = Ajuste os reflexos que utilizam informações de um pacote de textura LabPBR.
|
||||||
|
option.Specular_Reflections.comment = Habilita todos os reflexos para pacotes LabPBR. Isso permite o reflexo do sol, além de várias outras configurações abaixo. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Screen_Space_Reflections.comment = Habilita reflexos no espaço de tela. §aCUSTO DE PERFORMANCE:§r Médio
|
||||||
|
option.Rough_reflections.comment = Habilita uma rugosidade mais detalhada para criar reflexos de qualidade mais alta. Isso causa uma quantidade vísivel de ruído. §aCUSTO DE PERFORMANCE:§r Médio para Alto
|
||||||
|
option.Sky_reflection.comment = Habilita os reflexos do céu e da névoa. §aCUSTO DA PERFORMANCE:§r Baixo para Médio.
|
||||||
|
option.Dynamic_SSR_quality.comment = Isso diminui a qualidade dos reflexos baseado na sua visibilidade. Pode aumentar a performance, mas diminui a qualidade.
|
||||||
|
option.Roughness_Threshold.comment = Se a rugosidade atingir seu limite, todos os reflexos, por excessão do sol, não vão renderizar. Pode aumentar a performance.
|
||||||
|
option.Sun_specular_Strength.comment = Ajuste o quão brilhante o reflexo do sol é.
|
||||||
|
option.reflection_quality.comment = Ajuste a qualidade dos reflexos no espaço de tela.
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering.comment = §bO Que é Isso?§r O espalhamento de subsuperfície é aquele efeito quando você coloca uma luz no seu dedo e ele começa a brilhar. O sol causa esse efeito em várias coisas, como: plantas, tecido, pele e outras coisas.
|
||||||
|
option.SSS_TYPE.comment = Ajuste como o espalhamento de subsuperfície é aplicado ao mundo. §bEmbutido:§r O shaders decide o que recebe. §bLabSSS:§r O pacote de textura decide o que recebe. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.MOB_SSS.comment = Habilita espalhamento de subsuperfície para criaturas. Jogadores são incluídos. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.MISC_BLOCK_SSS.comment = Habilita espalhamento de subsuperfície para blocos diversos que talvez não sejam adequados. Isso é sobre tudo para ao bloco de grama e areia. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.Ambient_SSS.comment = §bO Que é Isso?§r espalhamento de subsuperfície da luz vinda do céu em vez do sol. §aCUSTO DE PERFORMANCE:§r Muito Baixo para Médio; se o SSAO estiver habilitado o custo é baixo, mas se o SSAO estiver desabilitado o custo é maior.
|
||||||
|
option.ambientsss_brightness.comment = Ajusta o brilho do espalhamento de subsuperfície vindo da luz do céu.
|
||||||
|
|
||||||
|
screen.Emissives.comment = §bO Que é Isso?§r Emissividade é quanta luz algo está liberando ou o quão brilhante algo é.
|
||||||
|
option.Emissive_Brightness.comment = Ajuste o quão brilhante a textura emissiva deve ser.
|
||||||
|
option.EMISSIVE_TYPE.comment = Ajuste como a textura emissiva é aplicada ao mundo. §bEmbutido:§r O shaders decide o que recebe. §bLabSSS:§r O pacote de textura decide o que recebe. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.Emissive_Curve.comment = Isso determina a velocidade que a textura emissiva chega no seu ponto mais brilhante. 1.0 é linear.
|
||||||
|
|
||||||
|
screen.POM.comment = Ajustes relacionados ao Mapameamento de Oclusão Paralaxe que usa informações de um pacote de textura.
|
||||||
|
option.POM.comment = §bO Que é Isso?§r Esse efeito tenta criar um efeito 3D onde não existe um, usando uma imagem especial de um pacote de textura. Esse efeito basicamente puxa para dentro, então pode existir artefátos se visto de alguns ângulos. §aCUSTO DE PERFORMANCE:§r Médio para Alto
|
||||||
|
option.MAX_ITERATIONS.comment = Ajuste a qualidade do efeito POM. Se você enxergar camadas individuais de perto, aumentar isso criara mais camadas para dificultar a visualização delas. §aCUSTO DE PERFORMANCE:§r Alto
|
||||||
|
option.POM_DEPTH.comment = A profundidade do efeito POM na superfície. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.MAX_DIST.comment = A distância máxima da câmera que o efeito POM pode renderizar. §aCUSTO DE PERFORMANCE:§r Alto
|
||||||
|
option.Adaptive_Step_length.comment = Isso vai aumentar a qualidade visual sem realmente aumentar a qualidade. Isso causa alguns artefátos se você olhar bem de perto ou se tiver um mapa de terreno com váriações de altura.
|
||||||
|
option.Horrible_slope_normals.comment = Isso é uma implementação mal feita para dar uma superfície nos lados do POM. Não é recomendado usar isso. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
|
||||||
|
screen.Porosity.comment = Ajustes relacionados à umidade e poças
|
||||||
|
option.Porosity.comment = §bO Que é Isso?§r Porosidade é o quão poroso um material é ou quanta água tem dentro dele. Por exemplo, uma esponja é muito porosa; a aguá é segurada dentro dela e escurece a esponja. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Puddles.comment = Habilita poças quando estiver chovendo. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Puddle_Size.comment = Ajusta o tamanho das poças.
|
||||||
|
|
||||||
|
screen.Fog.comment = Ajustes relacionados à névoa volumétrica ou névoa distante.
|
||||||
|
option.VL_RENDER_RESOLUTION.comment = Ajuste a resolução da névoa volumétrica. §aCUSTO DE PERFORMANCE:§r Alto
|
||||||
|
option.VL_SAMPLES.comment = Ajuste a qualidade da névoa volumétrica. §aCUSTO DE PERFORMANCE:§r Alto
|
||||||
|
option.BLOOMY_FOG.comment = Ajuste à força do bloom que é aplicada a névoa. §bO Que é Isso?§r Esse efeito faz a névoa ter um aspecto suave, isso ajuda a diminuir o ruído. Pode causar flick em bordas detalhadas. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.Haze_amount.comment = Ajuste a densidade da atmosféra ao seu redor. §bO Que é Isso?§r É aquela névoa azul que você vê na distância.
|
||||||
|
option.RainFog_amount.comment = Ajuste a densidade da névoa quando chove.
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG.comment = Habilita uma névoa detalhada quando você vai dentro ou do lado de uma nuvem. §aCUSTO DE PERFORMANCE:§r Baixo para Médio
|
||||||
|
option.BorderFog.comment = Habilita uma névoa que esconde chunks não carregados.
|
||||||
|
|
||||||
|
screen.TOD_fog.comment = Ajusta a densidade da névoa que aparece em horários especifícos do dia.
|
||||||
|
option.TOD_Fog_mult.comment = Ajusta quantidade total de névoa que aparece em horários especifícos do dia. Isso não afeta a névoa atmosférica.
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT.comment = Habilita uma névoa que apenas aparece em biomas especifícos. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
|
||||||
|
screen.Cave_Fog.comment = Ajustes para a névoa que aparece em lugares escuros, como cavernas.
|
||||||
|
option.Cave_Fog = Névoa de Caverna
|
||||||
|
option.Cave_Fog.comment = Habilita uma névoa que aparece em lugares escuros. Não tem como dizer com precisão se você está em uma caverna, então a névoa pode aparecer em lugares que não são cavernas. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.CaveFogFallOff.comment = Ajuste a velocidade que a gradiante da névoa chega no seu ponto mais brilhante.
|
||||||
|
|
||||||
|
screen.Clouds.comment = Ajustes relacionados a nuvens volumétricas.
|
||||||
|
option.VOLUMETRIC_CLOUDS.comment = Habilita as nuvens. §aCUSTO DE PERFORMANCE:§r Médio para Alto
|
||||||
|
option.CLOUDS_QUALITY.comment = Ajuste a resolução das nuvens volumétricas. §aCUSTO DE PERFORMANCE:§r Alto
|
||||||
|
option.CLOUDS_SHADOWS.comment = Habilita sombras que são prjetadas pelas sombras no chão e a névoa em baixo. §aCUSTO DE PERFORMANCE:§r Baixo para Médio
|
||||||
|
option.Daily_Weather.comment = Habilita o clima diário. O shaders alterna entre 8 perfis. Você não pode mudar nenhuma configuração de cobertura quando isso estiver habilitado. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Cloud_Speed.comment = Ajuste a velocidade que as nuvens se movem ao decorrer do dia.
|
||||||
|
option.Rain_coverage.comment = Ajuste a cobertura das nuvens durante a chuva.
|
||||||
|
|
||||||
|
option.Cumulus.comment = Habilite camada inferior de nuvens. §aCUSTO DE PERFORMANCE:§r Médio
|
||||||
|
option.Cumulus_coverage.comment = Ajuste a cobertura das das camadas inferiores de nuvens. Essa configuração não funciona se o clima diário estiver habilitado.
|
||||||
|
option.Cumulus_density.comment = Ajuste a densidade das camadas inferiores de nuvens.
|
||||||
|
option.Cumulus_height.comment = Ajuste a altura das camadas inferiores.
|
||||||
|
|
||||||
|
option.Altostratus.comment = Habilite camada superior de nuvens. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Alto_coverage.comment = Ajuste a cobertura das das camadas superiores de nuvens. Essa configuração não funciona se o clima diário estiver habilitado.
|
||||||
|
option.Alto_density.comment = Ajuste a densidade das camadas superiores de nuvens.
|
||||||
|
|
||||||
|
screen.World.comment = Ajuste configurações para váriadas coisas que acontecem no mundo, o balançar das plantas e a água.
|
||||||
|
screen.Water.comment = Ajustes relacionados a água.
|
||||||
|
option.WATER_REFLECTIONS.comments = Habilite todos os reflexos para coisas translúcidas. Isso permite outras configurações abaixo. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.SCREENSPACE_REFLECTIONS.comment = Habilita reflexos no espaço de tela em coisas translúcidas. §aCUSTO DE PERFORMANCE:§r Médio
|
||||||
|
option.SSR_STEPS.comment = Ajuste a qualiade dos reflexos em coisas translúcidas. §aCUSTO DE PERFORMANCE:§r Médio pra Alto
|
||||||
|
option.WATER_SUN_SPECULAR.comment = Habilita reflexos da lua e do sol em coisas translúcidas. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.WATER_BACKGROUND_SPECULAR.comment = Habilita reflexos do céu e névoa em coisas translúcidas. §aCUSTO DE PERFORMANCE:§r Baixo para Médio
|
||||||
|
option.Refraction.comment = Habilita refração em coisas translúcidas. §bO Que é Isso?§r Olhe para a água e você vai perceber a refração da luz distorcendo as coisas dentro dela. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Dirt_Amount.comment = Ajusta quanta sujeira tem na água. Isso controla quanta névoa tem dentro da água.
|
||||||
|
option.Water_Top_Layer.comment = Ajusta a coordenada Y que oceano deve estar no mundo.
|
||||||
|
|
||||||
|
screen.Water_fog_color.comment = Ajusta as cores da névoa na água.
|
||||||
|
|
||||||
|
screen.Climate.comment = Ajustes relacionados ao clima, como: cores sazonais, clima diário e névoa especifíca de bioma.
|
||||||
|
screen.Seasons = Estações
|
||||||
|
screen.Seasons.comment = Cores sazonais que se alternam, verão, outono, inverno e primavera.
|
||||||
|
option.Seasons.comment = Cores sazonais que se alternam, verão, outono, inverno e primavera. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.Season_Length.comment = Controla por quanto tempo uma única estação dura, em dias do Minecraft.
|
||||||
|
option.Snowy_Winter.comment = Habilita neve durante o inverno. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
screen.Summer_colors.comment = Ajuste as cores da vegetação durante o verão.
|
||||||
|
screen.Fall_colors.comment = Ajuste as cores da vegetação durante o outono.
|
||||||
|
screen.Winter_colors.comment = Ajuste as cores da vegetação durante o inverno.
|
||||||
|
screen.Spring_colors.comment = Ajuste as cores da vegetação durante a primavera.
|
||||||
|
|
||||||
|
screen.Waving_Stuff.comment = Ajustes relacionados ao balançar das plantas.
|
||||||
|
option.WAVY_PLANTS.comment = Habilite o balançar das plantas. §aCUSTO DE PERFORMANCE:§r Muito Baixo
|
||||||
|
option.WAVY_STRENGTH.comment = Ajuste a intensidade com que as plantas balançam.
|
||||||
|
option.WAVY_SPEED.comment = Ajuste a velocidade com que as plantas balançam.
|
||||||
|
|
||||||
|
screen.Post_Processing.comment = Ajustes relacionados a todos os efeitos de pós-processamento, do antisserrilhamento ao mapeamentos de tonsC.
|
||||||
|
screen.Tonemapping.comment = Ajustes relacionados ao mapeamento de tons.
|
||||||
|
screen.Exposure.comment = Ajustes relacionados a exposição.
|
||||||
|
screen.DepthOfField.comment = Ajustes relacionados a profundidade de campo.
|
||||||
|
screen.Purkinje_effect.comment = Ajustes relacionados a mudança purkinje.
|
||||||
|
option.SHARPENING.comment = Ajuste a quantidade de nitidez CAS que é aplicada à imagem. Isso traz devolta os detalhes perdidos do antisserrilhamento ou upscaling.
|
||||||
|
option.BLOOM_STRENGTH.comment = Ajuste a quantidade de bloom que é aplicada à imagem. §bO Que é Isso?§r Bloom é o brilho suave em tudo, para descrever se algo é brilhante ou não.
|
||||||
|
screen.TAA_OPTIONS.comment = Ajustes relacionados ao antisserrilhamento.
|
||||||
|
option.SCREENSHOT_MODE.comment = Habilite a acumulação de frames para conseguir uma imagem de alta qualidade sem ruídos. §bO Que é Isso?§r Isso junta quadros que já aconteceram no próximo quadro gerado, essencialmente é como se fosse uma foto de longa exposição.
|
||||||
|
option.TAA.comment = Habilite o antisserrilhamento temporal. Isso remove as bordas irregulares nas coisas, deixa ela mais suave e ajuda a remover o rúido de vários efeitos. Isso vai causar um efeito de rastro, pois isso usa quadros passados para conseguir a informação extra. §aCUSTO DE PERFORMANCE:§r Baixo
|
||||||
|
option.BLEND_FACTOR.comment = Ajuste a dependência de quadros passados. Valores maiores dependem menos em quadros passados, causando uma imagem com rúido. Valores menores dependem mais em quadros passados, causando uma imagem mais borrada.
|
||||||
|
option.TAA_UPSCALING.comment = Habilita um upscaling temporal. Isso deixa você ajustar a porcentagem da tela, permitindo que seu jogo mantenha um equilíbrio entre o desempenho e a qualidade de imagem.
|
||||||
|
option.SCALE_FACTOR.comment = Ajuste de qual fração da sua resolução é feito o upscale. Abaixo de 0.5 não é nem um pouco recomendado e só existe porque é engraçado:P
|
|
@ -0,0 +1,750 @@
|
||||||
|
option.BLISS_SHADERS = Шейдер Bliss
|
||||||
|
value.BLISS_SHADERS.0 = Редакция Chocapic13
|
||||||
|
value.BLISS_SHADERS.1 = Автор Xonk
|
||||||
|
value.BLISS_SHADERS.2 = Версия GIT-HEAD
|
||||||
|
option.BLISS_SHADERS.comment = Информация о шейдере
|
||||||
|
|
||||||
|
profile.QUALITY = Качество
|
||||||
|
profile.PERFORMANCE = Представление
|
||||||
|
|
||||||
|
screen.Sun_and_Moon_Colors = Цвет солнца/луны
|
||||||
|
option.sunColorR = Солнечный свет R
|
||||||
|
option.sunColorG = Солнечный свет G
|
||||||
|
option.sunColorB = Солнечный свет B
|
||||||
|
option.moonColorR = Лунный свет R
|
||||||
|
option.moonColorG = Лунный свет G
|
||||||
|
option.moonColorB = Лунный свет B
|
||||||
|
option.colortype = Цветовой тип
|
||||||
|
option.Sun_temp = Температура солнца
|
||||||
|
option.Moon_temp = Температура луны
|
||||||
|
|
||||||
|
option.colortype.comment = 1 = RGB для цвета солнца/луны; 2 = черное тело
|
||||||
|
|
||||||
|
screen.Misc_Settings = Разные настройки
|
||||||
|
option.sunPathRotation = Угол наклона солнца/луны
|
||||||
|
option.sun_illuminance = Свет Солнца
|
||||||
|
option.moon_illuminance = Свет Луны
|
||||||
|
option.MOONPHASE_BASED_MOONLIGHT = Уровень яркости фаз луны
|
||||||
|
option.TRANSLUCENT_COLORED_SHADOWS = Полупрозрачные цветные тени
|
||||||
|
option.OLD_LIGHTLEAK_FIX = Исправление утечки света
|
||||||
|
|
||||||
|
option.RESOURCEPACK_SKY = Небо текстурпака
|
||||||
|
value.RESOURCEPACK_SKY.0 = Выкл.
|
||||||
|
value.RESOURCEPACK_SKY.1 = Небо + Шейдер солнца/луны
|
||||||
|
value.RESOURCEPACK_SKY.2 = Все небо
|
||||||
|
|
||||||
|
screen.Waving_Stuff = Колыхание растительности
|
||||||
|
option.WAVY_PLANTS = Колыхание растительности
|
||||||
|
option.WAVY_STRENGTH = Интенсивность колыхания
|
||||||
|
option.WAVY_SPEED = Скорость колыхания
|
||||||
|
|
||||||
|
screen.Direct_Light = Прямой свет
|
||||||
|
screen.Shadows = Тени
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS = Тени от объектов
|
||||||
|
option.RENDER_ENTITY_SHADOWS = Тени от сущностей
|
||||||
|
option.shadowMapResolution = Разрешение теней
|
||||||
|
option.shadowDistance = Дистанция теней
|
||||||
|
value.shadowDistance.64.0 = 4 Чанков
|
||||||
|
value.shadowDistance.80.0 = 5 Чанков
|
||||||
|
value.shadowDistance.96.0 = 6 Чанков
|
||||||
|
value.shadowDistance.112.0 = 7 Чанков
|
||||||
|
value.shadowDistance.128.0 = 8 Чанков
|
||||||
|
value.shadowDistance.144.0 = 9 Чанков
|
||||||
|
value.shadowDistance.160.0 = 10 Чанков
|
||||||
|
value.shadowDistance.176.0 = 11 Чанков
|
||||||
|
value.shadowDistance.192.0 = 12 Чанков
|
||||||
|
value.shadowDistance.208.0 = 13 Чанков
|
||||||
|
value.shadowDistance.224.0 = 14 Чанков
|
||||||
|
value.shadowDistance.240.0 = 15 Чанков
|
||||||
|
value.shadowDistance.256.0 = 16 Чанков
|
||||||
|
value.shadowDistance.272.0 = 17 Чанков
|
||||||
|
value.shadowDistance.288.0 = 18 Чанков
|
||||||
|
value.shadowDistance.304.0 = 19 Чанков
|
||||||
|
value.shadowDistance.320.0 = 20 Чанков
|
||||||
|
value.shadowDistance.336.0 = 21 Чанков
|
||||||
|
value.shadowDistance.352.0 = 22 Чанков
|
||||||
|
value.shadowDistance.368.0 = 23 Чанков
|
||||||
|
value.shadowDistance.384.0 = 24 Чанков
|
||||||
|
value.shadowDistance.400.0 = 25 Чанков
|
||||||
|
value.shadowDistance.416.0 = 26 Чанков
|
||||||
|
value.shadowDistance.432.0 = 27 Чанков
|
||||||
|
value.shadowDistance.448.0 = 28 Чанков
|
||||||
|
value.shadowDistance.464.0 = 29 Чанков
|
||||||
|
value.shadowDistance.480.0 = 30 Чанков
|
||||||
|
value.shadowDistance.496.0 = 31 Чанков
|
||||||
|
value.shadowDistance.512.0 = 32 Чанков
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE = Границы теней
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.-1.0 = Неоптимизированный
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.1.0 = Оптимизированный
|
||||||
|
option.entityShadowDistanceMul = Расстояние до тени объекта
|
||||||
|
|
||||||
|
screen.Filtering = Параметры теневой фильтрации
|
||||||
|
option.BASIC_SHADOW_FILTER = Теневой фильтр
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT = Качество теневого фильтра
|
||||||
|
option.Min_Shadow_Filter_Radius = Мини. радиус фильтра теней
|
||||||
|
option.Variable_Penumbra_Shadows = Переменные тени/полутени
|
||||||
|
option.VPS_Search_Samples = Качество фильтра VPS
|
||||||
|
option.Max_Shadow_Filter_Radius = Макс. радиус фильтра теней
|
||||||
|
option.Max_Filter_Depth = Коэффициент "размера солнца"
|
||||||
|
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering = Поверхностное рассеивание
|
||||||
|
option.LabSSS_Curve = Интенсивность LabSSS
|
||||||
|
option.MISC_BLOCK_SSS = SSS для случайных блоков
|
||||||
|
option.MOB_SSS = SSS для мобов
|
||||||
|
option.Ambient_SSS = SSS для неба
|
||||||
|
option.ambientsss_brightness = SSS для неба
|
||||||
|
option.SSS_TYPE = Режим
|
||||||
|
value.SSS_TYPE.0 = Выкл.
|
||||||
|
value.SSS_TYPE.1 = Hardcoded only
|
||||||
|
value.SSS_TYPE.2 = Hardcoded + LabSSS
|
||||||
|
value.SSS_TYPE.3 = LabSSS only
|
||||||
|
|
||||||
|
|
||||||
|
screen.Ambient_light = Окружающий свет
|
||||||
|
option.AO_Strength = Интенсивность AO
|
||||||
|
option.GI_Strength = Интенсивность GI
|
||||||
|
option.HQ_SSGI = SSGI дальнего радиуса
|
||||||
|
option.Hand_Held_lights = Ручной свет
|
||||||
|
option.SKY_CONTRIBUTION_IN_SSRT = Высокое качество света
|
||||||
|
option.ambientOcclusionLevel = Интенсивность Vanilla AO
|
||||||
|
option.ambient_brightness = Яркость окружающего света
|
||||||
|
option.MIN_LIGHT_AMOUNT = Минимальная яркость света
|
||||||
|
option.indirect_effect = Качество освещения
|
||||||
|
value.indirect_effect.0 = Vanilla AO
|
||||||
|
value.indirect_effect.1 = SSAO
|
||||||
|
value.indirect_effect.2 = GTAO
|
||||||
|
value.indirect_effect.3 = RTAO
|
||||||
|
value.indirect_effect.4 = SSGI
|
||||||
|
|
||||||
|
screen.Ambient_Colors = Цвет окружающего света
|
||||||
|
option.AmbientLight_R = Количество красного
|
||||||
|
option.AmbientLight_G = Количество зеленого
|
||||||
|
option.AmbientLight_B = Количество синего
|
||||||
|
option.ambient_colortype = Тип окраса
|
||||||
|
value.ambient_colortype.0 = Температура
|
||||||
|
value.ambient_colortype.1 = RGB
|
||||||
|
|
||||||
|
screen.Torch_Colors = Цвет факела
|
||||||
|
option.TORCH_AMOUNT = Интенсивность освещения факела
|
||||||
|
option.TORCH_R = Количество красного
|
||||||
|
option.TORCH_G = Количество зеленого
|
||||||
|
option.TORCH_B = Количество синего
|
||||||
|
|
||||||
|
option.HANDHELD_LIGHT_RANGE = Диапазон портативного освещения
|
||||||
|
option.UseQuarterResDepth = Используйте четверть глубины разрешения
|
||||||
|
|
||||||
|
screen.Fog = Туман
|
||||||
|
option.VL_RENDER_RESOLUTION = Разрешение объемного тумана
|
||||||
|
option.VL_SAMPLES = Качество объемного тумана
|
||||||
|
option.BLOOMY_FOG = Количество рассеянного тумана
|
||||||
|
option.Haze_amount = Плотность атмосферной дымки
|
||||||
|
option.RainFog_amount = Количество дождевого тумана
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG = Рендер Облака в виде Тумана
|
||||||
|
option.BorderFog = Граница тумана
|
||||||
|
|
||||||
|
screen.TOD_fog = Дневной туман
|
||||||
|
option.TOD_Fog_mult = Плотности тумана
|
||||||
|
option.Morning_Uniform_Fog = Плотность утреннего тумана
|
||||||
|
option.Noon_Uniform_Fog = Плотность полудневного тумана
|
||||||
|
option.Evening_Uniform_Fog = Плотность вечернего тумана
|
||||||
|
option.Night_Uniform_Fog = Плотность ночного тумана
|
||||||
|
option.Morning_Cloudy_Fog = Плотность утреннего облачного тумана
|
||||||
|
option.Noon_Cloudy_Fog = Плотность полудневного облачного тумана
|
||||||
|
option.Evening_Cloudy_Fog = Плотность вечернего облачного тумана
|
||||||
|
option.Night_Cloudy_Fog = Плотность ночного облачного тумана
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT = Специфичная среда биомов
|
||||||
|
|
||||||
|
screen.Cave_Fog = Пещерный туман
|
||||||
|
option.CAVE_FOG = Пещерный туман
|
||||||
|
option.CaveFogFallOff = Яркость тумана
|
||||||
|
option.CaveFogColor_R = Количество красного
|
||||||
|
option.CaveFogColor_G = Количество зеленого
|
||||||
|
option.CaveFogColor_B = Количество синего
|
||||||
|
option.FOG_START_HEIGHT = Высота начала тумана
|
||||||
|
|
||||||
|
screen.END_AND_NETHER_FOG = Туман в Незере/Энде
|
||||||
|
option.END_STORM_DENSTIY = Плотность шторма в энде
|
||||||
|
option.NETHER_PLUME_DENSITY = Плотность дыма в незере
|
||||||
|
option.CLOUD_SHADOW_STRENGTH = Сила тени от облаков
|
||||||
|
|
||||||
|
screen.Clouds = Облака
|
||||||
|
option.VOLUMETRIC_CLOUDS = Объемные облака
|
||||||
|
option.CLOUDS_QUALITY = Разрешение облаков
|
||||||
|
option.CLOUDS_SHADOWS = Тень от облаков
|
||||||
|
option.Cloud_Speed = Скорость облаков
|
||||||
|
option.Rain_coverage = Покрытие во время дождя
|
||||||
|
option.Daily_Weather = Ежедневная погода
|
||||||
|
|
||||||
|
option.CloudLayer0 = Малые кучевые облака
|
||||||
|
option.CloudLayer0_coverage = Покрытие
|
||||||
|
option.CloudLayer0_density = Плотность
|
||||||
|
option.CloudLayer0_height = Высота
|
||||||
|
|
||||||
|
option.CloudLayer1 = Большие кучевые облака
|
||||||
|
option.CloudLayer1_coverage = Покрытие
|
||||||
|
option.CloudLayer1_density = Плотность
|
||||||
|
option.CloudLayer1_height = Высота
|
||||||
|
|
||||||
|
option.CloudLayer2 = Высокослойные кучевые облака
|
||||||
|
option.CloudLayer2_coverage = Покрытие
|
||||||
|
option.CloudLayer2_density = Плотность
|
||||||
|
option.CloudLayer2_height = Высота
|
||||||
|
|
||||||
|
screen.DAILY_WEATHER = Дневная погода
|
||||||
|
screen.DAY0_WEATHER = День 0 Погода
|
||||||
|
option.DAY0_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY0_l0_density = Плотность малых облаков
|
||||||
|
option.DAY0_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY0_l1_density = Плотность больших облаков
|
||||||
|
option.DAY0_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY0_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY0_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY0_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY1_WEATHER = День 1 Погода
|
||||||
|
option.DAY1_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY1_l0_density = Плотность малых облаков
|
||||||
|
option.DAY1_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY1_l1_density = Плотность больших облаков
|
||||||
|
option.DAY1_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY1_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY1_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY1_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY2_WEATHER = День 2 Погода
|
||||||
|
option.DAY2_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY2_l0_density = Плотность малых облаков
|
||||||
|
option.DAY2_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY2_l1_density = Плотность больших облаков
|
||||||
|
option.DAY2_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY2_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY2_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY2_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY3_WEATHER = День 3 Погода
|
||||||
|
option.DAY3_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY3_l0_density = Плотность малых облаков
|
||||||
|
option.DAY3_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY3_l1_density = Плотность больших облаков
|
||||||
|
option.DAY3_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY3_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY3_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY3_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY4_WEATHER = День 4 Погода
|
||||||
|
option.DAY4_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY4_l0_density = Плотность малых облаков
|
||||||
|
option.DAY4_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY4_l1_density = Плотность больших облаков
|
||||||
|
option.DAY4_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY4_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY4_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY4_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY5_WEATHER = День 5 Погода
|
||||||
|
option.DAY5_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY5_l0_density = Плотность малых облаков
|
||||||
|
option.DAY5_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY5_l1_density = Плотность больших облаков
|
||||||
|
option.DAY5_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY5_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY5_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY5_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY6_WEATHER = День 6 Погода
|
||||||
|
option.DAY6_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY6_l0_density = Плотность малых облаков
|
||||||
|
option.DAY6_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY6_l1_density = Плотность больших облаков
|
||||||
|
option.DAY6_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY6_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY6_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY6_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY7_WEATHER = День 7 Погода
|
||||||
|
option.DAY7_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY7_l0_density = Плотность малых облаков
|
||||||
|
option.DAY7_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY7_l1_density = Плотность больших облаков
|
||||||
|
option.DAY7_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY7_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY7_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY7_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY8_WEATHER = День 8 Погода
|
||||||
|
option.DAY8_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY8_l0_density = Плотность малых облаков
|
||||||
|
option.DAY8_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY8_l1_density = Плотность больших облаков
|
||||||
|
option.DAY8_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY8_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY8_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY8_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
screen.DAY9_WEATHER = День 9 Погода
|
||||||
|
option.DAY9_l0_coverage = Покрытие малых облаков
|
||||||
|
option.DAY9_l0_density = Плотность малых облаков
|
||||||
|
option.DAY9_l1_coverage = Покрытие больших облаков
|
||||||
|
option.DAY9_l1_density = Плотность больших облаков
|
||||||
|
option.DAY9_l2_coverage = Покрытие высокослоистых облаков
|
||||||
|
option.DAY9_l2_density = Плотность высокослоистых облаков
|
||||||
|
option.DAY9_ufog_density = Покрытие плотности тумана
|
||||||
|
option.DAY9_cfog_density = Облачная плотность тумана
|
||||||
|
|
||||||
|
|
||||||
|
screen.Climate = Климат
|
||||||
|
screen.Seasons = Сезонные цвета
|
||||||
|
option.Seasons = Сезонные цвета
|
||||||
|
option.Season_Length = Продолжительность сезона (в днях)
|
||||||
|
option.Start_Season = Начало сезона
|
||||||
|
value.Start_Season.0 = Лето (по умолчанию)
|
||||||
|
value.Start_Season.1 = Осень
|
||||||
|
value.Start_Season.2 = Зима
|
||||||
|
value.Start_Season.3 = Весна
|
||||||
|
option.Snowy_Winter = Снег зимой
|
||||||
|
screen.Summer_colors = Летние цвета
|
||||||
|
option.Summer_R = Количество красного
|
||||||
|
option.Summer_G = Количество зеленого
|
||||||
|
option.Summer_B = Количество синего
|
||||||
|
option.Summer_Leaf_R = Количество красного (листва)
|
||||||
|
option.Summer_Leaf_G = Количество зеленого (листва)
|
||||||
|
option.Summer_Leaf_B = Количество синего (листва)
|
||||||
|
|
||||||
|
screen.Fall_colors = Осенние цвета
|
||||||
|
option.Fall_R = Количество красного
|
||||||
|
option.Fall_G = Количество зеленого
|
||||||
|
option.Fall_B = Количество синего
|
||||||
|
option.Fall_Leaf_R = Количество красного (листва)
|
||||||
|
option.Fall_Leaf_G = Количество зеленого (листва)
|
||||||
|
option.Fall_Leaf_B = Количество синего (листва)
|
||||||
|
|
||||||
|
screen.Winter_colors = Зимние цвета
|
||||||
|
option.Winter_R = Количество красного
|
||||||
|
option.Winter_G = Количество зеленого
|
||||||
|
option.Winter_B = Количество синего
|
||||||
|
option.Winter_Leaf_R = Количество красного (листва)
|
||||||
|
option.Winter_Leaf_G = Количество зеленого (листва)
|
||||||
|
option.Winter_Leaf_B = Количество синего (листва)
|
||||||
|
|
||||||
|
screen.Spring_colors = Весенние цвета
|
||||||
|
option.Spring_R = Количество красного
|
||||||
|
option.Spring_G = Количество зеленого
|
||||||
|
option.Spring_B = Количество синего
|
||||||
|
option.Spring_Leaf_R = Количество красного (листва)
|
||||||
|
option.Spring_Leaf_G = Количество зеленого (листва)
|
||||||
|
option.Spring_Leaf_B = Количество синего (листва)
|
||||||
|
|
||||||
|
screen.SWAMP = Болото
|
||||||
|
option.SWAMP_ENV = Окружающая среда болот
|
||||||
|
option.SWAMP_UNIFORM_DENSITY = Равномерная плотность тумана
|
||||||
|
option.SWAMP_CLOUDY_DENSITY = Облачная плотность тумана
|
||||||
|
option.SWAMP_R = Количество красного
|
||||||
|
option.SWAMP_G = Количество зеленого
|
||||||
|
option.SWAMP_B = Количество синего
|
||||||
|
|
||||||
|
screen.JUNGLE = Джунгли
|
||||||
|
option.JUNGLE_ENV = Окружающая среда джунглей
|
||||||
|
option.JUNGLE_UNIFORM_DENSITY = Равномерная плотность тумана
|
||||||
|
option.JUNGLE_CLOUDY_DENSITY = Облачная плотность тумана
|
||||||
|
option.JUNGLE_R = Количество красного
|
||||||
|
option.JUNGLE_G = Количество зеленого
|
||||||
|
option.JUNGLE_B = Количество синего
|
||||||
|
|
||||||
|
screen.DARKFOREST = Темный лес
|
||||||
|
option.DARKFOREST_ENV = Окружающая среда темного леса
|
||||||
|
option.DARKFOREST_UNIFORM_DENSITY = Равномерная плотность тумана
|
||||||
|
option.DARKFOREST_CLOUDY_DENSITY = Облачная плотность тумана
|
||||||
|
option.DARKFOREST_R = Количество красного
|
||||||
|
option.DARKFOREST_G = Количество зеленого
|
||||||
|
option.DARKFOREST_B = Количество синего
|
||||||
|
|
||||||
|
screen.World = Мир
|
||||||
|
screen.Water = Вода
|
||||||
|
option.WATER_REFLECTIONS = Зеркальные отражения от воды
|
||||||
|
option.SCREENSPACE_REFLECTIONS = Отражения объектов
|
||||||
|
option.SSR_STEPS = Качество SSR
|
||||||
|
option.WATER_SUN_SPECULAR = Отражения солнца/луны
|
||||||
|
option.WATER_BACKGROUND_SPECULAR = Отражения неба/тумана
|
||||||
|
option.Refraction = Преломление в воде/стекле
|
||||||
|
option.Dirt_Amount = Количество грязи
|
||||||
|
option.Water_Top_Layer = Координата океана Y
|
||||||
|
option.WATER_WAVE_STRENGTH = Сила волны
|
||||||
|
option.SNELLS_WINDOW = Вид из подводы
|
||||||
|
option.WATER_WAVE_SPEED = Скорость волн
|
||||||
|
|
||||||
|
screen.Water_fog_color = Настройка водяного тумана
|
||||||
|
option.Dirt_Scatter_R = Рассеяный красный (грязь)
|
||||||
|
option.Dirt_Scatter_G = Рассеяный зеленый (грязь)
|
||||||
|
option.Dirt_Scatter_B = Рассеяный синий (грязь)
|
||||||
|
option.Dirt_Absorb_R = Поглощ. красный (грязь)
|
||||||
|
option.Dirt_Absorb_G = Поглощ. зеленый (грязь)
|
||||||
|
option.Dirt_Absorb_B = Поглощ. синий (грязь)
|
||||||
|
option.Water_Absorb_R = Поглощ. красный (вода)
|
||||||
|
option.Water_Absorb_G = Поглощ. зеленый (вода)
|
||||||
|
option.Water_Absorb_B = Поглощ. синий (вода)
|
||||||
|
|
||||||
|
option.Vanilla_like_water = Ванильная вода
|
||||||
|
option.Vanilla_like_water.comment = Влючите ваниильную текстуру воды
|
||||||
|
|
||||||
|
|
||||||
|
screen.Post_Processing = Постобработка
|
||||||
|
screen.Tonemapping = Настройки тональной карты/цвета
|
||||||
|
screen.Exposure = Настройки экспозиции
|
||||||
|
screen.DepthOfField = Настройки глубины резкости
|
||||||
|
screen.Purkinje_effect = Настройки эффекта Пуркинье
|
||||||
|
option.SHARPENING = Степень контрастной адаптации
|
||||||
|
option.BLOOM_STRENGTH = Степень размытия
|
||||||
|
screen.TAA_OPTIONS = Настройки сглаживания
|
||||||
|
option.SCREENSHOT_MODE = Режим скриншота
|
||||||
|
option.TAA = TAA
|
||||||
|
option.BLEND_FACTOR = Коэффициент смешивания
|
||||||
|
option.TAA_UPSCALING = Увеличение масштаба
|
||||||
|
option.SCALE_FACTOR = Коэффициент масштаба
|
||||||
|
option.AUTO_EXPOSURE = Авто. экспозиция
|
||||||
|
option.EXPOSURE_MULTIPLIER = Коэффициент экспозиции
|
||||||
|
option.Exposure_Speed = Скорость экспозиции
|
||||||
|
option.Manual_exposure_value = Значение ручной экспозиции
|
||||||
|
option.Purkinje_strength = Интенсивность Пуркинье
|
||||||
|
option.Purkinje_R = Пуркинье красный
|
||||||
|
option.Purkinje_G = Пуркинье зеленый
|
||||||
|
option.Purkinje_B = Пуркинье синий
|
||||||
|
option.Purkinje_Multiplier = Коэффициент Пуркинье
|
||||||
|
option.TONEMAP = Тональная карта
|
||||||
|
option.USE_ACES_COLORSPACE_APPROXIMATION = Аппроксимация цветового пространства
|
||||||
|
option.SATURATION = Насыщенность
|
||||||
|
option.CROSSTALK = Перекрестные помехи
|
||||||
|
option.CONTRAST = Контраст
|
||||||
|
option.focal = Фокусный
|
||||||
|
option.aperture = Апертура
|
||||||
|
option.DoF_Adaptation_Speed = Скорость адаптации DoF
|
||||||
|
option.FAR_BLUR_ONLY = Только дальнее размытие
|
||||||
|
screen.COLOR_GRADING = Расширенная цветокоррекция
|
||||||
|
option.TONE_CURVE = Кривая тона
|
||||||
|
option.LOWER_CURVE = Нижняя кривая
|
||||||
|
option.UPPER_CURVE = Верхняя кривая
|
||||||
|
option.COLOR_GRADING_ENABLED = Расширенная цветокоррекция
|
||||||
|
option.SHADOWS_GRADE_R = Тень §cКоличество красного
|
||||||
|
option.SHADOWS_GRADE_G = Тень §aКоличество зеленого
|
||||||
|
option.SHADOWS_GRADE_B = Тень §9Количество синего
|
||||||
|
option.SHADOWS_GRADE_MUL = Яркость теней
|
||||||
|
option.MIDS_GRADE_R = Полутона §cКоличество красного
|
||||||
|
option.MIDS_GRADE_G = Полутона §aКоличество зеленого
|
||||||
|
option.MIDS_GRADE_B = Полутона §9Количество синего
|
||||||
|
option.MIDS_GRADE_MUL = Яркость полутонов
|
||||||
|
option.HIGHLIGHTS_GRADE_R = Основное освещение §cКоличество красного
|
||||||
|
option.HIGHLIGHTS_GRADE_G = Основное освещение §aКоличество зеленого
|
||||||
|
option.HIGHLIGHTS_GRADE_B = Основное освещение §9Количество синего
|
||||||
|
option.HIGHLIGHTS_GRADE_MUL = Яркость основного освещения
|
||||||
|
|
||||||
|
|
||||||
|
screen.LabPBR = Эффекты LabPBR
|
||||||
|
screen.Reflections = Зеркальные отражения
|
||||||
|
option.Specular_Reflections = Зеркальные отражения
|
||||||
|
option.Screen_Space_Reflections = Отражения в пространстве экрана
|
||||||
|
option.Rough_reflections = Детализированный объем
|
||||||
|
option.Sky_reflection = Отражения Неба/Тумана
|
||||||
|
option.Dynamic_SSR_quality = Динамическое качество SSR
|
||||||
|
option.Roughness_Threshold = Порог отражений
|
||||||
|
option.Sun_specular_Strength = Яркость отражений от солнца
|
||||||
|
option.reflection_quality = Качество SSR
|
||||||
|
|
||||||
|
screen.Emissives = Излучаемый свет
|
||||||
|
option.Emissive_Brightness = Яркость излучения
|
||||||
|
option.Emissive_Curve = Скорость излучения
|
||||||
|
option.EMISSIVE_TYPE = Режим
|
||||||
|
value.EMISSIVE_TYPE.0 = Выкл.
|
||||||
|
value.EMISSIVE_TYPE.1 = Hardcoded only
|
||||||
|
value.EMISSIVE_TYPE.2 = Hardcoded + Lab Emission
|
||||||
|
value.EMISSIVE_TYPE.3 = Lab Emission only
|
||||||
|
|
||||||
|
|
||||||
|
screen.POM = Параллаксная окклюзия/POM
|
||||||
|
option.HEIGTHMAP_DEPTH_OFFSET = Heightmap in Depth
|
||||||
|
option.POM = Параллаксная окклюзия
|
||||||
|
option.MAX_ITERATIONS = Качество
|
||||||
|
option.POM_DEPTH = Глубина
|
||||||
|
option.MAX_DIST = Максимальное расстояние
|
||||||
|
option.Adaptive_Step_length = Динамическое качество
|
||||||
|
option.Horrible_slope_normals = Ужастные нормали наклона
|
||||||
|
|
||||||
|
|
||||||
|
screen.Porosity = Объем/лужи
|
||||||
|
option.Porosity = Объем
|
||||||
|
option.Puddles = Лужи
|
||||||
|
option.Puddle_Size = Размера луж
|
||||||
|
|
||||||
|
option.MATERIAL_AO = Материальная окружающая окклюзия
|
||||||
|
|
||||||
|
option.DOF_QUALITY = Глубина резкости
|
||||||
|
value.DOF_QUALITY.-1 = Выкл.
|
||||||
|
value.DOF_QUALITY.0 = Шестиугольный
|
||||||
|
value.DOF_QUALITY.1 = Низкая
|
||||||
|
value.DOF_QUALITY.2 = Средняя
|
||||||
|
value.DOF_QUALITY.3 = Высокая
|
||||||
|
value.DOF_QUALITY.4 = Ультра
|
||||||
|
value.DOF_QUALITY.5 = Дрожание
|
||||||
|
option.MANUAL_FOCUS = Фокусировка
|
||||||
|
option.DOF_ANAMORPHIC_RATIO = Анаморфическое соотношение
|
||||||
|
value.MANUAL_FOCUS.-2 = Автофокус
|
||||||
|
value.MANUAL_FOCUS.-1 = Ползунок яркости
|
||||||
|
|
||||||
|
screen.JITTER_DOF = Коэффициента дрожания
|
||||||
|
option.JITTER_STRENGTH = Сила дрожания
|
||||||
|
option.JITTER_STRENGTH.comment = Извините
|
||||||
|
option.FOCUS_LASER_COLOR = Цвет фокусировки
|
||||||
|
option.FOCUS_LASER_COLOR.comment = Красный, зеленый, синий, розовый, желтый, белый
|
||||||
|
value.FOCUS_LASER_COLOR.0 = Красный
|
||||||
|
value.FOCUS_LASER_COLOR.1 = Зеленый
|
||||||
|
value.FOCUS_LASER_COLOR.2 = Синий
|
||||||
|
value.FOCUS_LASER_COLOR.3 = Розовый
|
||||||
|
value.FOCUS_LASER_COLOR.4 = Желтый
|
||||||
|
value.FOCUS_LASER_COLOR.5 = Белый
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE = Режим аэрохрома
|
||||||
|
option.AEROCHROME_PINKNESS = Соотношение аэрохромного красного и розового
|
||||||
|
option.AEROCHROME_WOOL_ENABLED = Аэрохромная шерсть
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE.comment = Инфракрасная пленка. Погуглите "Аэрохром", чтобы получить представление о том, что он делает
|
||||||
|
option.AEROCHROME_PINKNESS.comment = Больше = Розовый. Меньше = Красный
|
||||||
|
option.AEROCHROME_WOOL_ENABLED.comment = Технически шерстяные вещи должны быть затронуты, но это разрушает многие сборки. Позвольте быть более технически корректным
|
||||||
|
|
||||||
|
|
||||||
|
option.DEBUG_VIEW = Вид отладки
|
||||||
|
value.debug_off = вылк.
|
||||||
|
value.debug_SHADOWMAP = Теневая карта
|
||||||
|
value.debug_NORMALS = Нормали
|
||||||
|
value.debug_SPECULAR = Зеркальное
|
||||||
|
value.debug_INDIRECT = Косвенный
|
||||||
|
value.debug_DIRECT = Прямой
|
||||||
|
value.debug_VIEW_POSITION = Позиция просмотра
|
||||||
|
value.debug_DH_WATER_BLENDING = Смешивание воды DH
|
||||||
|
value.debug_FILTERED_STUFF = Фильтрованный материал
|
||||||
|
|
||||||
|
option.display_LUT = дисплей LUT
|
||||||
|
option.SSS_view = Вид SSS
|
||||||
|
option.LIGHTNING_FLASH = Вспышка молнии
|
||||||
|
option.LIGHTNING_FLASH.comment = ДЛЯ ПОЛЬЗОВАТЕЛЕЙ OPTIFINE. некоторые моды изменяют цвет неба, что может привести к обнаружению вспышки молнии
|
||||||
|
option.LIT_PARTICLE_BRIGHTNESS = Яркость освещенных частиц
|
||||||
|
option.BLOOMY_PARTICLES = Цветущие частицы
|
||||||
|
option.BIOME_TINT_WATER = Биом подкрашивает воду
|
||||||
|
option.SELECT_BOX = Устанавливать флажок
|
||||||
|
option.WATER_CAUSTICS_BRIGHTNESS = Водная каустика воды
|
||||||
|
|
||||||
|
screen.the_orb = Сфера
|
||||||
|
option.THE_ORB = Сфера
|
||||||
|
option.ORB_X = Сфера X
|
||||||
|
option.ORB_Y = Сфера Y
|
||||||
|
option.ORB_Z = Сфера Z
|
||||||
|
option.ORB_ColMult = Сфера ColMult
|
||||||
|
option.ORB_R = Сфера красного
|
||||||
|
option.ORB_G = Сфера зеленого
|
||||||
|
option.ORB_B = Сфера синего
|
||||||
|
option.WhiteWorld = Белый мир
|
||||||
|
option.WhiteWorld.comment = ЭТО ОТЛАДОЧНЫЙ РЕЖИМ. используется для упрощения просмотра AO. используется для лучшего просмотра поддельного GI (зеленый свет)
|
||||||
|
option.ambientLight_only = Только рассеянный свет
|
||||||
|
option.ambientLight_only.comment = ЭТО ОТЛАДОЧНЫЙ РЕЖИМ. выключите солнечный свет. Производительность не увеличивается, тени по-прежнему работают в фоновом режиме
|
||||||
|
option.HURT_AND_DEATH_EFFECT = Эффект боли и смерти
|
||||||
|
option.PLANET_GROUND_BRIGHTNESS = Яркость поверхности планеты
|
||||||
|
option.ORIGINAL_CHOCAPIC_SKY = Оригинальное Chocapic небо
|
||||||
|
option.CLOUDS_INFRONT_OF_WORLD = Облака перед миром
|
||||||
|
option.DENOISE_SSS_AND_SSAO = Удаление шумов SSS и SSAO
|
||||||
|
option.HYPER_DETAILED_WAVES = Сверхподобные
|
||||||
|
|
||||||
|
|
||||||
|
screen.Misc_Settings.comment = Случайные настройки для ОТЛАДКИ или других забавных вещей
|
||||||
|
screen.Sun_and_Moon_Colors.comment = Настройте цвет солнца или луны
|
||||||
|
option.sunPathRotation.comment = Настройте угол наклона солнца или луны
|
||||||
|
option.sun_illuminance.comment = Настройте яркость солнца
|
||||||
|
option.moon_illuminance.comment = Настройте яркость луны
|
||||||
|
|
||||||
|
screen.Direct_Light.comment = Настройте параметры, связанные с солнцем/луной и тенями
|
||||||
|
|
||||||
|
screen.Shadows.comment = Настройте тени от солнца по своему вкусу
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS.comment = §bЧто это?§r Это небольшие тени от объектов, которые находятся далеко или поблизости. §aНАГРУЗКА:§r от низкой до средней; при более высоком разрешении это приводит к большей нагрузке
|
||||||
|
option.RENDER_ENTITY_SHADOWS.comment = §bЧто это?§r Тени от всех типов сущностей, таких как мобы, сундуки, баннеры или таблички. §aНАГРУЗКА:§r от низкой до высокой; это очень нагружающе, когда поблизости много сущностей
|
||||||
|
option.shadowMapResolution.comment = Качество теней от солнца, вызванное объектами в мире. §aНАГРУЗКА:§r от средней до очень высокой; Тени должны повторно отображать 3D мир с точки зрения солнца, вот почему это снижает производительность вдвое
|
||||||
|
option.shadowDistance.comment = Максимальное расстояние, которое может отобразить теневая карта. Расстояние не измеряется линейно чанками, если установлено значение §b"неоптимизировано". §aНАГРУЗКА:§r от средней до очень высокой; Если расстояние
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE.comment = §b"Оптимизированный"§r тени только в сфере вокруг вас, ограничиваясь максимальным расстоянием в чанках. §b"Неоптимизированный"§r не отображает тени в сфере и не привязан к чанкам; он может охватывать гораздо большую площадь при тех же настройках дистанции. §aНАГРУЗКА:§r от низкой до средней; §b"Оптимизированный"§r работает быстрее, а §b"неоптимизированный"§r медленнее
|
||||||
|
screen.Filtering.comment = Настройте эффекты фильтрации, применяемые к теням
|
||||||
|
option.BASIC_SHADOW_FILTER.comment = Включает/Выключает теневой фильтр
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT.comment = Этот фильтр просто смягчает тени. §aНАГРУЗКА:§r от низкой до средней; увеличение этого значения должно уменьшить некоторый шум на границе теней
|
||||||
|
option.Min_Shadow_Filter_Radius.comment = Максимальная мягкость базового теневого фильтра
|
||||||
|
option.Variable_Penumbra_Shadows.comment = Этот эффект смягчает тени тем больше, чем дальше тень от того, что ее отбрасывает. Этот эффект используется для создания теней более высокого качества и рассеивания на поверхности. §aНАГРУЗКА:§r от низкой к высокой
|
||||||
|
option.VPS_Search_Samples.comment = Качество фильтра с переменной полутенью и тенью. §aНАГРУЗКА:§r от низкой до высокой; увеличение этого значения должно уменьшить некоторый шум при поверхностном рассеивании и очень мягких тенях
|
||||||
|
option.Max_Shadow_Filter_Radius.comment = Максимальная мягкость, которую могут получить тени, когда они находятся далеко от того, что их отбрасывает
|
||||||
|
option.Max_Filter_Depth.comment = Если солнце больше, тени становятся мягче ближе к тому, что их отбрасывает
|
||||||
|
|
||||||
|
screen.Ambient_light.comment = Настройте параметры, связанные с освещением в затененных местах
|
||||||
|
option.AO_Strength.comment = Настройте силу внешней окклюзии, создаваемой SSAO, GTAO, RTAO, и SSGI. §bЧто это?§r окружающая окклюзия - это небольшие мягкие тени в углах и тому подобное
|
||||||
|
option.GI_Strength.comment = Настройте интенсивность глобального освещения, создаваемого SSGI. §bЧто это?§r глобальное освещение в данном раскладе конкретно представляет собой свет, отражающийся от поверхности и попадающий в какую-либо другую область
|
||||||
|
option.HQ_SSGI.comment = Переключить глобальное освещение экранного пространства на большие расстояния. §aНАГРУЗКА:§r очень высокая
|
||||||
|
option.Hand_Held_lights.comment = Переключайте ручные источники света на стороне шейдера. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.SKY_CONTRIBUTION_IN_SSRT.comment = Разрешите RTAO или SSGI учитывать все небо и туман, чтобы создать высококачественное освещение для затененных областей. Это может привести к увеличению шума. §aНАГРУЗКА:§r средняя
|
||||||
|
|
||||||
|
option.ambientOcclusionLevel.comment = Настройте силу внешней окклюзии в vanilla minecraft. §bЧто это?§r Эта окружающая окклюзия присутствует в minecraft даже без включенных шейдеров
|
||||||
|
option.ambient_brightness.comment = Настройте яркость освещения в затененных местах
|
||||||
|
option.MIN_LIGHT_AMOUNT.comment = Настройте минимальное количество света, которое может быть в затененных местах
|
||||||
|
option.indirect_effect.comment = Переключайте различные типы эффектов, чтобы повысить качество освещения в затененных местах. §aНАГРУЗКА:§r. Vanilla AO: очень низкая. SSAO: от низкой до средней. GTAO: от средней до высокой. RTAO or SSGI: от высокой до очень высокой
|
||||||
|
|
||||||
|
screen.Ambient_Colors.comment = Настройте цвет освещения в затененных областях
|
||||||
|
screen.Torch_Colors.comment = Настройте цвет света от факелов или других размещенных источников света
|
||||||
|
|
||||||
|
screen.LabPBR.comment = Множество эффектов, использующих информацию, предоставляемую любым пакетом ресурсов, который соответствует формату LabPBR
|
||||||
|
screen.Reflections.comment = Настройте отражения, использующие информацию, предоставленную пакетом ресурсов LabPBR
|
||||||
|
option.Specular_Reflections.comment = Переключите все отражения для пакетов LabPBR. Это включает отражение солнца и позволяет включить другие настройки, указанные ниже. §aНАГРУЗКА:§r низкая
|
||||||
|
option.Screen_Space_Reflections.comment = Переключение отражений в пространстве экрана. §aНАГРУЗКА:§r средняя
|
||||||
|
option.Rough_reflections.comment = Переключите более детализированный объем для более качественного отражения. Это вызовет значительное количество видимых шумов. §aНАГРУЗКА:§r от средней до высокой
|
||||||
|
option.Sky_reflection.comment = Переключайте отражения неба и тумана. §aНАГРУЗКА:§r от низкой до средней
|
||||||
|
option.Dynamic_SSR_quality.comment = Это снижает качество отражений в пространстве экрана в зависимости от того, насколько они заметны. это может повысить производительность, но снизить качество
|
||||||
|
option.Roughness_Threshold.comment = Если объем достигает этого порога, все отражения, кроме солнечных, не отображаются. это может повысить производительность
|
||||||
|
option.Sun_specular_Strength.comment = Настройте, насколько ярким будет отражение солнца
|
||||||
|
option.reflection_quality.comment = Настройте качество отражений в пространстве экрана
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering.comment = §bЧто это?§r Поверхностное рассеивание - это то, что происходит, когда вы направляете яркий свет на свою руку, и она начинает светиться. На самом деле солнце делает то же самое с растениями, тканью, кожей и другими вещами
|
||||||
|
option.SSS_TYPE.comment = Настройте, как поверхностное рассеивание применяется к окружающему миру. §bHardcoded:§r Управляет шейдер. §bLabSSS:§r Управляет пакет ресурсов. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.MOB_SSS.comment = Переключите поверхностное рассеивание для мобов; Игроки тоже включены. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.MISC_BLOCK_SSS.comment = Переключите поверхностное рассеяние для случайных блоков; в основном это для травы и песка. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.Ambient_SSS.comment = §bЧто это?§r поверхностное рассеивание от света, исходящего с неба, а не от солнца. §aНАГРУЗКА:§r от очень низкой до средней; если SSAO включен, маленькая нагрузка, но если SSAO выключен, большая нагрузка
|
||||||
|
option.ambientsss_brightness.comment = Настройте яркость поверхностного рассеивания света с неба
|
||||||
|
|
||||||
|
screen.Emissives.comment = §bЧто это?§r Излучательная способность - это просто количество света, которое что-то испускает, или насколько сильно что-то светится
|
||||||
|
option.Emissive_Brightness.comment = Настройте, насколько ярким должно быть излучение текстур
|
||||||
|
option.EMISSIVE_TYPE.comment = Настройте способ применения излучения текстур к окружающему миру. §bHardcoded:§r Шейдер решает, что ему достанется. §bLabSSS:§r Пакет ресурсов решает, что ему достанется. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.Emissive_Curve.comment = Это определяет, как быстро излучение текстур достигнет своей самой яркой точки. 1.0 является линейным
|
||||||
|
|
||||||
|
screen.POM.comment = Настройте параметры, связанные с отображением параллаксной окклюзии, в котором используется информация, предоставляемая пакетом ресурсов
|
||||||
|
option.HEIGTHMAP_DEPTH_OFFSET.comment = §bЧто это?§r Это приводит к тому, что предоставляемая пакетом ресурсов "карта высот" компенсирует глубину, используемую многими эффектами. Это позволяет видеть более мелкие детали поблизости и может работать как "бюджетный POM". §aНАГРУЗКА:§r от низкой до средней - используйте этот параметр, если POM слишком сложно запускать
|
||||||
|
option.POM.comment = §bЧто это?§r Этот эффект пытается создать трехмерную геометрию там, где ее раньше не было, используя специальное изображение из пакета ресурсов. Этот эффект в основном направлен только внутрь, поэтому при взгляде под крутыми углами могут наблюдаться некоторые артефакты. §aНАГРУЗКА:§r от средней до высокой
|
||||||
|
option.MAX_ITERATIONS.comment = Настройте качество отображения эффекта параллаксной окклюзии. если вы видите отдельные слои при близком рассмотрении, при увеличении этого параметра слоев становится больше, поэтому их будет труднее разглядеть. §aНАГРУЗКА:§r высокая
|
||||||
|
option.POM_DEPTH.comment = Насколько глубоко эффект отображения параллаксной окклюзии может проникнуть в поверхность. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.MAX_DIST.comment = Максимальное расстояние от камеры, которое может отобразить эффект отображения параллаксной окклюзии. §aНАГРУЗКА:§r высокая
|
||||||
|
option.Adaptive_Step_length.comment = Это повысит визуальное качество без необходимости повышать фактическое. Это приводит к появлению некоторых артефактов, если вы смотрите очень внимательно или у вас очень насыщенная карта высот с резкими перепадами высот
|
||||||
|
option.Horrible_slope_normals.comment = Это плохо выполненная реализация для придания поверхности отображения параллаксной окклюзии. Я не рекомендую это!. §aНАГРУЗКА:§r низкая
|
||||||
|
|
||||||
|
screen.Porosity.comment = Настройка параметров, связанных с объемом и лужами
|
||||||
|
option.Porosity.comment = §bЧто это?§r Объем - это описание того, насколько пористым является какой-либо материал, или, по сути, сколько воды может удерживаться внутри него. например, губки очень пористые; вода содержится внутри и в результате темнеет. §aНАГРУЗКА:§r низкая
|
||||||
|
option.Puddles.comment = Переключайте лужи на время дождя. §aНАГРУЗКА:§r низкая
|
||||||
|
option.Puddle_Size.comment = Настройте размер лужиц
|
||||||
|
|
||||||
|
screen.Fog.comment = Настройте параметры, связанные с объемным туманом, нанесенным с помощью raymarched, или туманом, основанным на расстоянии
|
||||||
|
option.VL_RENDER_RESOLUTION.comment = Настройте разрешение объемного тумана. §aНАГРУЗКА:§r высокая
|
||||||
|
option.VL_SAMPLES.comment = Настройте качество объемного тумана. §aНАГРУЗКА:§r высокая
|
||||||
|
option.BLOOMY_FOG.comment = Настройте мягкость, применяемую к туману. §bЧто это?§r Этот эффект делает туман более мягким, а также помогает скрыть небольшие шумы; может вызвать некоторое видимое мерцание на детализированных краях. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.Haze_amount.comment = Настройте, насколько плотной является атмосфера вокруг вас. §bЧто это?§r Это голубая дымка, которую вы видите вдалеке
|
||||||
|
option.RainFog_amount.comment = Настройте, насколько плотным становится туман во время дождя
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG.comment = Переключайте детализацию тумана, когда вы находитесь внутри облака или вокруг него. §aНАГРУЗКА:§r от средней до высокой
|
||||||
|
option.BorderFog.comment = §bЧто это?§r Включите туман, который пытается скрыть загружаемые фрагменты; Но из-за того, что небо повсюду, это трудно сделать хорошо. §aНАГРУЗКА:§r очень, очень низкая
|
||||||
|
|
||||||
|
screen.TOD_fog.comment = Настройте плотность тумана, которая появляется в определенное время суток
|
||||||
|
option.TOD_Fog_mult.comment = Настройте общее количество тумана, появляющегося в определенное время в течение дня. это не влияет на атмосферную дымку
|
||||||
|
|
||||||
|
screen.Cave_Fog.comment = Настройте параметры для тумана, который появляется, когда вы находитесь в очень темных местах, таких как пещеры
|
||||||
|
option.Cave_Fog.comment = Отключите туман, который появляется в темных местах. Невозможно точно определить, когда вы находитесь в пещере с помощью шейдера, поэтому этот туман может появляться в местах, которые пещерой не являются. §aНАГРУЗКА:§r низкая
|
||||||
|
option.CaveFogFallOff.comment = Настройте, как быстро градиент тумана достигает своей самой яркой части
|
||||||
|
|
||||||
|
screen.Clouds.comment = Настройте параметры, относящиеся к размерным объемным облакам
|
||||||
|
option.VOLUMETRIC_CLOUDS.comment = Переключи облака. §aНАГРУЗКА:§r от средней до высокой
|
||||||
|
option.CLOUDS_QUALITY.comment = Настройте разрешение объемных облаков. §aНАГРУЗКА:§r высокая
|
||||||
|
option.CLOUDS_SHADOWS.comment = Переключайте тени, отбрасываемые облаками на землю, и туман под ними. §aНАГРУЗКА:§r от низкой до средней
|
||||||
|
option.Daily_Weather.comment = Переключите ежедневную погоду. Я установил 8 погодных профилей, которые шейдер циклически просматривает каждый день. Вы не можете изменить какие-либо настройки облачного покрытия, когда это включено. §aНАГРУЗКА:§r низкая
|
||||||
|
option.Cloud_Speed.comment = Настройте, с какой скоростью движутся облака в течение дня
|
||||||
|
option.Rain_coverage.comment = Настройте, какую долю неба закрывают облака во время дождя
|
||||||
|
|
||||||
|
screen.World.comment = Настраивайте параметры для различных событий, происходящих в мире, от колышущихся растений до настроек, связанных с водой
|
||||||
|
screen.Water.comment = Настройте параметры, связанные с водой
|
||||||
|
option.WATER_REFLECTIONS.comment = Переключите все отражения для полупрозрачных объектов; Это позволяет включить другие настройки, указанные ниже. §aНАГРУЗКА:§r от низкой до высокой
|
||||||
|
option.SCREENSPACE_REFLECTIONS.comment = Переключать отражения в пространстве экрана на полупрозрачных объектах. §aНАГРУЗКА:§r средняя
|
||||||
|
option.SSR_STEPS.comment = Настройте качество отражения в пространстве экрана на полупрозрачных объектах. §aНАГРУЗКА:§r от средней до высокой
|
||||||
|
option.WATER_SUN_SPECULAR.comment = Переключайте отражения солнца и луны на полупрозрачных объектах. §aНАГРУЗКА:§r низкая
|
||||||
|
option.WATER_BACKGROUND_SPECULAR.comment = Переключайте отражения неба и тумана на полупрозрачных объектах. §aНАГРУЗКА:§r от низкой до средней
|
||||||
|
option.Refraction.comment = Переключите преломление на полупрозрачных объектах. §bЧто это?§r Если вы посмотрите на воду, то увидите, что преломление света искажает то, что в ней находится. §aНАГРУЗКА:§r низкая
|
||||||
|
option.Dirt_Amount.comment = Настройте количество грязи в воде. Это определяет количество тумана в воде
|
||||||
|
option.Water_Top_Layer.comment = Настройте координату Y, в которой должен находиться океан в мире
|
||||||
|
|
||||||
|
screen.Water_fog_color.comment = Настройте цвет водного тумана
|
||||||
|
|
||||||
|
screen.Climate.comment = Настройте параметры, связанные с климатом, такие как сезонные цвета, ежедневная погода и туман, специфичный для биома
|
||||||
|
screen.Seasons.comment = Сезонные цвета, которые сменяют друг друга: лето, осень, зима и весна
|
||||||
|
option.Seasons.comment = Сезонные цвета, которые сменяют друг друга: лето, осень, зима и весна. §aНАГРУЗКА:§r низкая
|
||||||
|
option.Season_Length.comment = Контролируйте, как долго длится один сезон в игровых днях
|
||||||
|
option.Snowy_Winter.comment = Снег в зимнее время. §aНАГРУЗКА:§r низкая
|
||||||
|
screen.Summer_colors.comment = Настраивайте цвета растительности летом
|
||||||
|
screen.Fall_colors.comment = Настраивайте цвета растительности осенью
|
||||||
|
screen.Winter_colors.comment = Настраивайте цвета растительности зимний
|
||||||
|
screen.Spring_colors.comment = Настраивайте цвета растительности весной
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT.comment = Переключите все специальные окружающие среды, которые появляются только в некоторых биомах. §aНАГРУЗКА:§r низкая
|
||||||
|
|
||||||
|
screen.SWAMP.comment = Настройте окружающая среду в этом типе биома
|
||||||
|
option.SWAMP_ENV.comment = Переключайте окружающую среду только для этого типа биома. Другие среды биома остаются активными, даже если эта отключена
|
||||||
|
|
||||||
|
screen.JUNGLE.comment = Настройте окружающая среду в этом типе биома.
|
||||||
|
option.JUNGLE_ENV.comment = Переключайте окружающую среду только для этого типа биома. Другие среды биома остаются активными, даже если эта отключена
|
||||||
|
|
||||||
|
screen.DARKFOREST.comment = Настройте окружающая среду в этом типе биома
|
||||||
|
option.DARKFOREST_ENV.comment = Переключайте окружающую среду только для этого типа биома. Другие среды биома остаются активными, даже если эта отключена
|
||||||
|
|
||||||
|
|
||||||
|
screen.Waving_Stuff.comment = Настройте параметры, связанные с движением растительности
|
||||||
|
option.WAVY_PLANTS.comment = Переключайте раскачивание растений. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.WAVY_STRENGTH.comment = Настройте силу, с которой растения раскачиваются
|
||||||
|
option.WAVY_SPEED.comment = Настройте скорость, с которой растения раскачиваются
|
||||||
|
|
||||||
|
screen.Post_Processing.comment = Настройте параметры для всех эффектов постобработки, от сглаживания до отображения тонов
|
||||||
|
screen.Tonemapping.comment = Настройте параметры, связанные с отображением цвета и тона
|
||||||
|
screen.Exposure.comment = Настройте параметры, связанные с экспозицией
|
||||||
|
screen.DepthOfField.comment = Настройте параметры, связанные с глубиной резкости
|
||||||
|
screen.Purkinje_effect.comment = Настройте параметры, связанные с эффектом Пуркинье. §bЧто это?§r Это изменения цветового восприятия человеческим глазом при понижении освещённости объектов
|
||||||
|
option.SHARPENING.comment = Настройте степень контрастной адаптивной резкости, применяемой к изображению. Это действительно может выявить детали, утраченные в результате сглаживания или увеличения масштаба
|
||||||
|
option.BLOOM_STRENGTH.comment = Настройте степень размытия, которая будет применена к изображению. §bЧто это?§r Свечение - это мягкое свечение на всем, чтобы можно описать, является чем-то ярким или нет
|
||||||
|
screen.TAA_OPTIONS.comment = Настройте параметры, связанные со сглаживанием
|
||||||
|
option.SCREENSHOT_MODE.comment = Переключайте накопление кадров, чтобы получить изображение с низким уровнем шума и высоким качеством. §bЧто это?§r Он складывает кадры, которые произошли, в следующий сгенерированный кадр, так что это похоже на фотографию с длительной экспозицией
|
||||||
|
option.TAA.comment = Включите временное сглаживание. Это уберет все неровные края объектов, смягчит изображение и поможет убрать шум для многих эффектов. Это приведет к появлению ghosting или trailing, поскольку для получения дополнительной информации о мире используются прошлые кадры. §aНАГРУЗКА:§r низкая
|
||||||
|
option.BLEND_FACTOR.comment = Настройте, какой объем истории кадров используется. большое число означает, что оно в меньшей степени зависит от истории кадров, поэтому оно может выглядеть мерцающим и шумным. низкие числа больше зависят от истории кадров, поэтому оно может выглядеть смазанным и вызывать отставание
|
||||||
|
option.TAA_UPSCALING.comment = Переключите временное масштабирование. Это позволяет сохранить хорошее качество изображения с более низким разрешением при увеличении масштаба. таким образом, вы все равно можете получить высокое разрешение по сравнению с обычным увеличением и при этом получить лучшую производительность
|
||||||
|
option.SCALE_FACTOR.comment = Настройте, с какой доли вашего разрешения увеличивать масштаб. Ниже 0,5 вообще не рекомендуется, я использую это только как опцию, потому что это забавно :P
|
||||||
|
screen.COLOR_GRADING.comment = Расширенные возможности цветокоррекции
|
||||||
|
option.TONE_CURVE.comment = Включите кривую тона. Это не зависит от цветокоррекции и применяется в первую очередь
|
||||||
|
option.COLOR_GRADING_ENABLED.comment = Включите цветовую градацию. Ползунки RGB не будут влиять на яркость. Это применяется после кривой тона
|
||||||
|
|
||||||
|
option.RESOURCEPACK_SKY.comment = Включите поддержку неба пакета ресурсов. Настройте параметры так, чтобы использовать все небо пакета ресурсов или сохранить солнце и луну шейдера. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.SKY_GROUND = Атмосфера грунта
|
||||||
|
|
||||||
|
option.MATERIAL_AO.comment = Переключайте использование внешней окклюзии в зависимости от того, что предоставляет пакет ресурсов. §aНАГРУЗКА:§r очень низкая
|
||||||
|
option.WATER_WAVE_STRENGTH.comment = Настройте, насколько сильными будут казаться волны
|
||||||
|
option.MOONPHASE_BASED_MOONLIGHT.comment = §bЧто это?§r каждую ночь луна освещается по-разному. Этот параметр регулирует яркость лунного света в зависимости от того, насколько сильно светит Луна. §aНАГРУЗКА:§r незначительная
|
||||||
|
|
||||||
|
option.END_STORM_DENSTIY.comment = §bЧто это?§r Это темный облачный туман в конце. Настройте плотность конечной бури (та, что в эндер мире)
|
||||||
|
option.NETHER_PLUME_DENSITY.comment = §bЧто это?§r Это густые, светящиеся дымовые башни в преисподней. Настройте плотность дыма в преисподней
|
||||||
|
|
||||||
|
option.CloudLayer0.comment = Переключите слой облаков, которые являются маленькими. §aНАГРУЗКА:§r средняя
|
||||||
|
option.CloudLayer0_coverage.comment = Настройте, какую часть неба закрывают эти облака
|
||||||
|
option.CloudLayer0_density.comment = Настройте, насколько плотными являются эти облака
|
||||||
|
option.CloudLayer0_height.comment = Настройте высоту, на которой летят эти облака
|
||||||
|
|
||||||
|
option.CloudLayer1.comment = Переключите слой облаков, которые являются большими. §aНАГРУЗКА:§r средняя
|
||||||
|
option.CloudLayer1_coverage.comment = Настройте, какую часть неба закрывают эти облака
|
||||||
|
option.CloudLayer1_density.comment = Настройте, насколько плотными являются эти облака
|
||||||
|
option.CloudLayer1_height.comment = Настройте высоту, на которой летят эти облака. §cОНИ НЕ МОГУТ БЫТЬ НИЖЕ МАЛЕНЬКИХ ОБЛАКОВ§r
|
||||||
|
|
||||||
|
option.CloudLayer2.comment = Переключите слой облаков, который является очень высоким и тонким. §aНАГРУЗКА:§r низкая
|
||||||
|
option.CloudLayer2_coverage.comment = Настройте, какую часть неба закрывают эти облака
|
||||||
|
option.CloudLayer2_density.comment = Настройте, насколько плотными являются эти облака
|
||||||
|
option.CloudLayer2_height.comment = Настройте высоту, на которой летят эти облака. §cОНИ НЕ МОГУТ БЫТЬ НИЖЕ БОЛЬШИХ ОБЛАКОВ§r
|
||||||
|
|
||||||
|
option.SKY_GROUND.comment = §bЧто это?§r Это темная нижняя половина неба, которая была бы землей, если бы в minecraft было бесконечное расстояние рендеринга. §aНАГРУЗКА:§r очень, очень низкая. §cотключение этого происходит совсем немного медленнее, чем включение из-за дополнительной математики.§r
|
||||||
|
option.SNELLS_WINDOW.comment = §bЧто это?§r это темный отражающий круг, который вы видите под водой. Это приблизительное изображение того, что происходит в реальности, известное как "полное внутреннее отражение". §aНАГРУЗКА:§r очень, очень, очень маленькая.
|
||||||
|
option.entityShadowDistanceMul.comment = §bЧто это?§r Настройте, насколько далеко должны работать тени для объектов. Это полезно, если вы хотите сохранить тени объектов и повысить производительность в областях с большим количеством объектов.
|
||||||
|
|
||||||
|
screen.DISTANT_HORIZONS_SETTINGS = §2Мод Distant Horizons §fнастройки
|
||||||
|
|
||||||
|
option.DH_KNOWN_ISSUES =
|
||||||
|
value.DH_KNOWN_ISSUES.0 = §c ЩЕЛКНИТЕ ПО ЭТОМУ ТЕКСТУ, ЧТОБЫ ПРОСМОТРЕТЬ СПИСОК ИЗВЕСТНЫХ ПРОБЛЕМ
|
||||||
|
value.DH_KNOWN_ISSUES.1 = §a GTAO, RTAO, и SSGI прерываются на LODs - поддержка DH не реализована
|
||||||
|
|
||||||
|
option.DISTANT_HORIZONS_SHADOWMAP = §c(НЕ ИСПОЛЬЗУЙТЕ, ЕСЛИ ВЫ НЕ ЗНАЕТЕ, ЧТО ЭТО ТАКОЕ)§r Поддержка карты теней DH
|
||||||
|
option.DISTANT_HORIZONS_SHADOWMAP.comment = §cЭТОТ ПАРАМЕТР СНИЗИТ ПРОИЗВОДИТЕЛЬНОСТЬ, ИЗ-ЗА ЧЕГО ТЕНИ БУДУТ ВЫГЛЯДЕТЬ БЛОЧНЫМИ, МЕРЦАЮЩИМИ И С НИЗКОЙ ДЕТАЛИЗАЦИЕЙ§r. установите дистанцию теней равную 32 фрагментам (или больше). установите разрешение теней равную 4096 (или больше)
|
||||||
|
option.TOGGLE_VL_FOG = Объемный туман
|
||||||
|
option.TOGGLE_VL_FOG.comment = одна большая кнопка, чтобы просто отключить весь туман
|
|
@ -0,0 +1,834 @@
|
||||||
|
option.BLISS_SHADERS=Bliss
|
||||||
|
value.BLISS_SHADERS.0=A Chocapic13 Edit
|
||||||
|
value.BLISS_SHADERS.1=作者: Xonk
|
||||||
|
value.BLISS_SHADERS.2=版本: GIT-HEAD
|
||||||
|
|
||||||
|
# if you're here to translate, this is a joke, these don't do what they say
|
||||||
|
profile.QUALITY=质量
|
||||||
|
profile.PERFORMANCE=性能
|
||||||
|
|
||||||
|
screen.Misc_Settings = 杂项
|
||||||
|
screen.Sun_and_Moon_Colors = 日月颜色
|
||||||
|
option.sunPathRotation = 太阳角度
|
||||||
|
option.sun_illuminance = 阳光照度
|
||||||
|
option.moon_illuminance = 月光照度
|
||||||
|
option.MOONPHASE_BASED_MOONLIGHT = 月相亮度水平
|
||||||
|
|
||||||
|
option.RESOURCEPACK_SKY = 资源包天空
|
||||||
|
value.RESOURCEPACK_SKY.0 = 别用这个
|
||||||
|
value.RESOURCEPACK_SKY.1 = 天空 + 光影日月
|
||||||
|
value.RESOURCEPACK_SKY.2 = 完整天空
|
||||||
|
|
||||||
|
screen.Waving_Stuff = 摇晃相关
|
||||||
|
option.WAVY_PLANTS = 植物摇晃
|
||||||
|
option.WAVY_STRENGTH = 摇晃强度
|
||||||
|
option.WAVY_SPEED = 摇晃速度
|
||||||
|
|
||||||
|
screen.Direct_Light = 直接照明
|
||||||
|
screen.Shadows = 阴影
|
||||||
|
option.TRANSLUCENT_COLORED_SHADOWS = 半透明彩色阴影
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS = 屏幕空间阴影
|
||||||
|
option.RENDER_ENTITY_SHADOWS = 实体阴影
|
||||||
|
option.shadowMapResolution = 阴影分辨率
|
||||||
|
option.shadowDistance = 阴影距离
|
||||||
|
value.shadowDistance.32.0 = 2 区块
|
||||||
|
value.shadowDistance.48.0 = 3 区块
|
||||||
|
value.shadowDistance.64.0 = 4 区块
|
||||||
|
value.shadowDistance.80.0 = 5 区块
|
||||||
|
value.shadowDistance.96.0 = 6 区块
|
||||||
|
value.shadowDistance.112.0 = 7 区块
|
||||||
|
value.shadowDistance.128.0 = 8 区块
|
||||||
|
value.shadowDistance.144.0 = 9 区块
|
||||||
|
value.shadowDistance.160.0 = 10 区块
|
||||||
|
value.shadowDistance.176.0 = 11 区块
|
||||||
|
value.shadowDistance.192.0 = 12 区块
|
||||||
|
value.shadowDistance.208.0 = 13 区块
|
||||||
|
value.shadowDistance.224.0 = 14 区块
|
||||||
|
value.shadowDistance.240.0 = 15 区块
|
||||||
|
value.shadowDistance.256.0 = 16 区块
|
||||||
|
value.shadowDistance.272.0 = 17 区块
|
||||||
|
value.shadowDistance.288.0 = 18 区块
|
||||||
|
value.shadowDistance.304.0 = 19 区块
|
||||||
|
value.shadowDistance.320.0 = 20 区块
|
||||||
|
value.shadowDistance.336.0 = 21 区块
|
||||||
|
value.shadowDistance.352.0 = 22 区块
|
||||||
|
value.shadowDistance.368.0 = 23 区块
|
||||||
|
value.shadowDistance.384.0 = 24 区块
|
||||||
|
value.shadowDistance.512.0 = 32 区块
|
||||||
|
value.shadowDistance.768.0 = 48 区块
|
||||||
|
value.shadowDistance.1024.0 = 64 区块
|
||||||
|
value.shadowDistance.1536.0 = 96 区块
|
||||||
|
value.shadowDistance.2048.0 = 128 区块
|
||||||
|
value.shadowDistance.4096.0 = 256 区块
|
||||||
|
value.shadowDistance.8192.0 = 512 区块
|
||||||
|
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE = 最大阴影边界
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.-1.0 = 无优化
|
||||||
|
value.OPTIMIZED_SHADOW_DISTANCE.1.0 = 优化
|
||||||
|
option.entityShadowDistanceMul = 实体阴影距离
|
||||||
|
value.entityShadowDistanceMul.0.01 = 阴影距离的 1%
|
||||||
|
value.entityShadowDistanceMul.0.02 = 阴影距离的 2%
|
||||||
|
value.entityShadowDistanceMul.0.03 = 阴影距离的 3%
|
||||||
|
value.entityShadowDistanceMul.0.04 = 阴影距离的 4%
|
||||||
|
value.entityShadowDistanceMul.0.05 = 阴影距离的 5%
|
||||||
|
value.entityShadowDistanceMul.0.10 = 阴影距离的 10%
|
||||||
|
value.entityShadowDistanceMul.0.15 = 阴影距离的 15%
|
||||||
|
value.entityShadowDistanceMul.0.20 = 阴影距离的 20%
|
||||||
|
value.entityShadowDistanceMul.0.25 = 阴影距离的 25%
|
||||||
|
value.entityShadowDistanceMul.0.30 = 阴影距离的 30%
|
||||||
|
value.entityShadowDistanceMul.0.35 = 阴影距离的 35%
|
||||||
|
value.entityShadowDistanceMul.0.40 = 阴影距离的 40%
|
||||||
|
value.entityShadowDistanceMul.0.45 = 阴影距离的 45%
|
||||||
|
value.entityShadowDistanceMul.0.50 = 阴影距离的 50%
|
||||||
|
value.entityShadowDistanceMul.0.75 = 阴影距离的 75%
|
||||||
|
value.entityShadowDistanceMul.1.00 = 阴影距离的 100%
|
||||||
|
|
||||||
|
screen.Filtering = 阴影过滤设置
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT = 阴影过滤采样数
|
||||||
|
option.Min_Shadow_Filter_Radius = 最小阴影过滤半径
|
||||||
|
option.Variable_Penumbra_Shadows = 可变半阴影 (VPS)
|
||||||
|
option.VPS_Search_Samples = VPS 检索采样数
|
||||||
|
option.Max_Shadow_Filter_Radius = 最大阴影过滤半径
|
||||||
|
option.Max_Filter_Depth = 最大过滤深度
|
||||||
|
|
||||||
|
screen.LPV = FloodFill
|
||||||
|
option.LPV_ENABLED = FloodFill
|
||||||
|
option.LPV_SIZE = LPV 规模
|
||||||
|
value.LPV_SIZE.6 = 小 [64]
|
||||||
|
value.LPV_SIZE.7 = 中 [128]
|
||||||
|
value.LPV_SIZE.8 = 大 [256]
|
||||||
|
option.LPV_NORMAL_OFFSET = 法线偏移 (Normal-Offset)
|
||||||
|
option.LPV_ENTITY_LIGHTS = 实体光源
|
||||||
|
option.LPV_REDSTONE_LIGHTS = 红石光源
|
||||||
|
option.LPV_COLORED_CANDLES = 彩色蜡烛
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering = 次表面散射 (SSS)
|
||||||
|
option.LabSSS_Curve = LabSSS 曲线
|
||||||
|
option.MISC_BLOCK_SSS = 随机方块次表面散射
|
||||||
|
option.MOB_SSS = 怪物次表面散射
|
||||||
|
option.Ambient_SSS = 天空光次表面散射
|
||||||
|
option.ambientsss_brightness = 天空光次表面散射亮度
|
||||||
|
option.SSS_TYPE = 次表面散射模式
|
||||||
|
value.SSS_TYPE.0 = 无
|
||||||
|
value.SSS_TYPE.1 = 仅硬编码
|
||||||
|
value.SSS_TYPE.2 = 硬编码 + LabSSS
|
||||||
|
value.SSS_TYPE.3 = 仅 LabSSS
|
||||||
|
|
||||||
|
|
||||||
|
screen.Ambient_light = 环境光
|
||||||
|
option.AO_Strength = 环境光遮蔽强度
|
||||||
|
option.GI_Strength = 全局照明强度
|
||||||
|
option.HQ_SSGI = 远距 SSGI
|
||||||
|
option.Hand_Held_lights = 手持光源
|
||||||
|
option.SKY_CONTRIBUTION_IN_SSRT = 高质量环境光
|
||||||
|
option.ambientOcclusionLevel = 原版 AO 强度
|
||||||
|
option.ambient_brightness = 环境光照明亮度
|
||||||
|
option.MIN_LIGHT_AMOUNT = 最小照明强度
|
||||||
|
option.indirect_effect = 间接照明模式
|
||||||
|
value.indirect_effect.0 = 原版 AO
|
||||||
|
value.indirect_effect.1 = SSAO
|
||||||
|
value.indirect_effect.2 = GTAO
|
||||||
|
value.indirect_effect.3 = RTAO
|
||||||
|
value.indirect_effect.4 = SSGI
|
||||||
|
|
||||||
|
screen.Ambient_Colors = 环境光颜色
|
||||||
|
option.AmbientLight_R = 环境光红色比重
|
||||||
|
option.AmbientLight_G = 环境光绿色比重
|
||||||
|
option.AmbientLight_B = 环境光蓝色比重
|
||||||
|
option.ambient_colortype = 环境光颜色类型
|
||||||
|
value.ambient_colortype.0 = 色温模式
|
||||||
|
value.ambient_colortype.1 = RGB 滑块模式
|
||||||
|
|
||||||
|
screen.Torch_Colors = 照明颜色
|
||||||
|
option.TORCH_AMOUNT = 照明强度
|
||||||
|
option.TORCH_R = 照明红色比重
|
||||||
|
option.TORCH_G = 照明绿色比重
|
||||||
|
option.TORCH_B = 照明蓝色比重
|
||||||
|
|
||||||
|
|
||||||
|
screen.Fog = 雾气设置
|
||||||
|
option.VL_RENDER_RESOLUTION = 体积雾渲染分辨率
|
||||||
|
option.VL_SAMPLES = 体积雾采样值
|
||||||
|
option.BLOOMY_FOG = 雾气泛化值
|
||||||
|
option.Haze_amount = 大气雾霾密度
|
||||||
|
option.RainFog_amount = 雨雾密度
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG = 将云作为雾气渲染
|
||||||
|
option.BorderFog = 边界雾
|
||||||
|
|
||||||
|
screen.TOD_fog = 全天雾气
|
||||||
|
option.TOD_Fog_mult = 雾气密度倍率
|
||||||
|
option.Morning_Uniform_Fog = 清晨 - 雾气密度
|
||||||
|
option.Noon_Uniform_Fog = 正午 - 雾气密度
|
||||||
|
option.Evening_Uniform_Fog = 傍晚 - 雾气密度
|
||||||
|
option.Night_Uniform_Fog = 夜晚 - 雾气密度
|
||||||
|
option.Morning_Cloudy_Fog = 清晨 - 云雾密度
|
||||||
|
option.Noon_Cloudy_Fog = 正午 - 云雾密度
|
||||||
|
option.Evening_Cloudy_Fog = 傍晚 - 云雾密度
|
||||||
|
option.Night_Cloudy_Fog =夜 晚 - 云雾密度
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT = 群系特色环境
|
||||||
|
|
||||||
|
screen.Cave_Fog = 洞穴雾气
|
||||||
|
option.Cave_fog = 洞穴雾气
|
||||||
|
option.CaveFogFallOff = 洞穴雾气渐消曲线
|
||||||
|
option.CaveFogColor_R = 洞穴雾气红色比重
|
||||||
|
option.CaveFogColor_G = 洞穴雾气绿色比重
|
||||||
|
option.CaveFogColor_B = 洞穴雾气蓝色比重
|
||||||
|
|
||||||
|
screen.END_AND_NETHER_FOG = 下界/末地雾气
|
||||||
|
option.END_STORM_DENSTIY = 末地风暴强度
|
||||||
|
option.NETHER_PLUME_DENSITY = 下界烟柱密度
|
||||||
|
|
||||||
|
screen.Clouds = 云层设置
|
||||||
|
option.VOLUMETRIC_CLOUDS = 体积云
|
||||||
|
option.CLOUDS_QUALITY = 云层分辨率倍数
|
||||||
|
option.CLOUDS_SHADOWS = 云影
|
||||||
|
option.Cloud_Speed = 云层速度
|
||||||
|
option.Rain_coverage = 雨云覆盖率
|
||||||
|
option.Daily_Weather = 周期循环的天气
|
||||||
|
|
||||||
|
option.CloudLayer0 = 小积云
|
||||||
|
option.CloudLayer0_coverage = 覆盖率
|
||||||
|
option.CloudLayer0_density = 密度
|
||||||
|
option.CloudLayer0_height = 高度
|
||||||
|
|
||||||
|
option.CloudLayer1 = 大积云
|
||||||
|
option.CloudLayer1_coverage = 覆盖率
|
||||||
|
option.CloudLayer1_density = 密度
|
||||||
|
option.CloudLayer1_height = 高度
|
||||||
|
|
||||||
|
option.CloudLayer2 = 高层云
|
||||||
|
option.CloudLayer2_coverage = 覆盖率
|
||||||
|
option.CloudLayer2_density = 密度
|
||||||
|
option.CloudLayer2_height = 高度
|
||||||
|
|
||||||
|
screen.DAILY_WEATHER = 周期循环的天气设置
|
||||||
|
screen.DAY0_WEATHER = 第 0 天的天气
|
||||||
|
option.DAY0_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY0_l0_density = 小积云密度
|
||||||
|
option.DAY0_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY0_l1_density = 大积云密度
|
||||||
|
option.DAY0_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY0_l2_density = 高层云密度
|
||||||
|
option.DAY0_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY0_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY1_WEATHER = 第 1 天的天气
|
||||||
|
option.DAY1_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY1_l0_density = 小积云密度
|
||||||
|
option.DAY1_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY1_l1_density = 大积云密度
|
||||||
|
option.DAY1_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY1_l2_density = 高层云密度
|
||||||
|
option.DAY1_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY1_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY2_WEATHER = 第 2 天的天气
|
||||||
|
option.DAY2_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY2_l0_density = 小积云密度
|
||||||
|
option.DAY2_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY2_l1_density = 大积云密度
|
||||||
|
option.DAY2_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY2_l2_density = 高层云密度
|
||||||
|
option.DAY2_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY2_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY3_WEATHER = 第 3 天的天气
|
||||||
|
option.DAY3_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY3_l0_density = 小积云密度
|
||||||
|
option.DAY3_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY3_l1_density = 大积云密度
|
||||||
|
option.DAY3_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY3_l2_density = 高层云密度
|
||||||
|
option.DAY3_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY3_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY4_WEATHER = 第 4 天的天气
|
||||||
|
option.DAY4_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY4_l0_density = 小积云密度
|
||||||
|
option.DAY4_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY4_l1_density = 大积云密度
|
||||||
|
option.DAY4_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY4_l2_density = 高层云密度
|
||||||
|
option.DAY4_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY4_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY5_WEATHER = 第 5 天的天气
|
||||||
|
option.DAY5_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY5_l0_density = 小积云密度
|
||||||
|
option.DAY5_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY5_l1_density = 大积云密度
|
||||||
|
option.DAY5_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY5_l2_density = 高层云密度
|
||||||
|
option.DAY5_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY5_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY6_WEATHER = 第 6 天的天气
|
||||||
|
option.DAY6_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY6_l0_density = 小积云密度
|
||||||
|
option.DAY6_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY6_l1_density = 大积云密度
|
||||||
|
option.DAY6_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY6_l2_density = 高层云密度
|
||||||
|
option.DAY6_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY6_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY7_WEATHER = 第 7 天的天气
|
||||||
|
option.DAY7_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY7_l0_density = 小积云密度
|
||||||
|
option.DAY7_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY7_l1_density = 大积云密度
|
||||||
|
option.DAY7_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY7_l2_density = 高层云密度
|
||||||
|
option.DAY7_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY7_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY8_WEATHER = 第 8 天的天气
|
||||||
|
option.DAY8_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY8_l0_density = 小积云密度
|
||||||
|
option.DAY8_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY8_l1_density = 大积云密度
|
||||||
|
option.DAY8_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY8_l2_density = 高层云密度
|
||||||
|
option.DAY8_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY8_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
screen.DAY9_WEATHER = 第 9 天的天气
|
||||||
|
option.DAY9_l0_coverage = 小积云覆盖率
|
||||||
|
option.DAY9_l0_density = 小积云密度
|
||||||
|
option.DAY9_l1_coverage = 大积云覆盖率
|
||||||
|
option.DAY9_l1_density = 大积云密度
|
||||||
|
option.DAY9_l2_coverage = 高层云覆盖率
|
||||||
|
option.DAY9_l2_density = 高层云密度
|
||||||
|
option.DAY9_ufog_density = 均匀雾气密度
|
||||||
|
option.DAY9_cfog_density = 云雾密度
|
||||||
|
|
||||||
|
|
||||||
|
screen.Climate = 气候
|
||||||
|
option.Seasons = 四季颜色
|
||||||
|
option.Season_Length = 季节长度 (以 MC 日为单位)
|
||||||
|
option.Start_Season = 起始季节
|
||||||
|
value.Start_Season.0 = 夏季 (默认)
|
||||||
|
value.Start_Season.1 = 秋季
|
||||||
|
value.Start_Season.2 = 冬季
|
||||||
|
value.Start_Season.3 = 春季
|
||||||
|
option.Snowy_Winter = 雪冬
|
||||||
|
screen.Summer_colors = 夏季颜色
|
||||||
|
option.Summer_R = 植被 - 红
|
||||||
|
option.Summer_G = 植被 - 绿
|
||||||
|
option.Summer_B = 植被 - 蓝
|
||||||
|
option.Summer_Leaf_R = 树叶 - 红
|
||||||
|
option.Summer_Leaf_G = 树叶 - 绿
|
||||||
|
option.Summer_Leaf_B = 树叶 - 蓝
|
||||||
|
|
||||||
|
screen.Fall_colors = 秋季颜色
|
||||||
|
option.Fall_R = 植被 - 红
|
||||||
|
option.Fall_G = 植被 - 绿
|
||||||
|
option.Fall_B = 植被 - 蓝
|
||||||
|
option.Fall_Leaf_R = 树叶 - 红
|
||||||
|
option.Fall_Leaf_G = 树叶 - 绿
|
||||||
|
option.Fall_Leaf_B = 树叶 - 蓝
|
||||||
|
|
||||||
|
screen.Winter_colors = 冬季颜色
|
||||||
|
option.Winter_R = 植被 - 红
|
||||||
|
option.Winter_G = 植被 - 绿
|
||||||
|
option.Winter_B = 植被 - 蓝
|
||||||
|
option.Winter_Leaf_R = 树叶 - 红
|
||||||
|
option.Winter_Leaf_G = 树叶 - 绿
|
||||||
|
option.Winter_Leaf_B = 树叶 - 蓝
|
||||||
|
|
||||||
|
screen.Spring_colors = 春季颜色
|
||||||
|
option.Spring_R = 植被 - 红
|
||||||
|
option.Spring_G = 植被 - 绿
|
||||||
|
option.Spring_B = 植被 - 蓝
|
||||||
|
option.Spring_Leaf_R = 树叶 - 红
|
||||||
|
option.Spring_Leaf_G = 树叶 - 绿
|
||||||
|
option.Spring_Leaf_B = 树叶 - 蓝
|
||||||
|
|
||||||
|
screen.SWAMP = 沼泽
|
||||||
|
option.SWAMP_ENV = 沼泽环境
|
||||||
|
option.SWAMP_UNIFORM_DENSITY = 均匀雾气密度
|
||||||
|
option.SWAMP_CLOUDY_DENSITY = 云雾密度
|
||||||
|
option.SWAMP_R = 红色比重
|
||||||
|
option.SWAMP_G = 绿色比重
|
||||||
|
option.SWAMP_B = 蓝色比重
|
||||||
|
|
||||||
|
screen.JUNGLE = 丛林
|
||||||
|
option.JUNGLE_ENV = 丛林环境
|
||||||
|
option.JUNGLE_UNIFORM_DENSITY = 均匀雾气密度
|
||||||
|
option.JUNGLE_CLOUDY_DENSITY = 云雾密度
|
||||||
|
option.JUNGLE_R = 红色比重
|
||||||
|
option.JUNGLE_G = 绿色比重
|
||||||
|
option.JUNGLE_B = 蓝色比重
|
||||||
|
|
||||||
|
screen.DARKFOREST = 黑森林
|
||||||
|
option.DARKFOREST_ENV = 黑森林环境
|
||||||
|
option.DARKFOREST_UNIFORM_DENSITY = 均匀雾气密度
|
||||||
|
option.DARKFOREST_CLOUDY_DENSITY = 均匀雾气密度
|
||||||
|
option.DARKFOREST_R = 红色比重
|
||||||
|
option.DARKFOREST_G = 绿色比重
|
||||||
|
option.DARKFOREST_B = 蓝色比重
|
||||||
|
|
||||||
|
screen.World = 世界
|
||||||
|
screen.Water = 水体设置
|
||||||
|
option.WATER_REFLECTIONS = 水面高光反射
|
||||||
|
option.SCREENSPACE_REFLECTIONS = 屏幕空间反射 (SSR)
|
||||||
|
option.SSR_STEPS = SSR 采样值
|
||||||
|
option.WATER_SUN_SPECULAR = 日月反射
|
||||||
|
option.WATER_BACKGROUND_SPECULAR = 天空/雾气反射
|
||||||
|
option.Refraction = 折射 (水体/玻璃)
|
||||||
|
option.Dirt_Amount = 水体浑浊程度
|
||||||
|
option.Water_Top_Layer = 海平面 Y 轴坐标
|
||||||
|
option.WATER_WAVE_STRENGTH = 水波强度
|
||||||
|
option.SNELLS_WINDOW = 斯涅尔窗 (Snell's Window)
|
||||||
|
|
||||||
|
screen.Water_fog_color = 水雾设置
|
||||||
|
option.Dirt_Scatter_R = 红色扩散 (污物)
|
||||||
|
option.Dirt_Scatter_G = 绿色扩散 (污物)
|
||||||
|
option.Dirt_Scatter_B = 蓝色扩散 (污物)
|
||||||
|
option.Dirt_Absorb_R = 红色吸收 (污物)
|
||||||
|
option.Dirt_Absorb_G = 绿色吸收 (污物)
|
||||||
|
option.Dirt_Absorb_B = 蓝色吸收 (污物)
|
||||||
|
option.Water_Absorb_R = 红色吸收 (水体)
|
||||||
|
option.Water_Absorb_G = 绿色吸收 (水体)
|
||||||
|
option.Water_Absorb_B = 蓝色吸收 (水体)
|
||||||
|
|
||||||
|
|
||||||
|
screen.Post_Processing = 后期处理
|
||||||
|
screen.Tonemapping = 色调映射
|
||||||
|
screen.Exposure = 曝光
|
||||||
|
screen.DepthOfField = 景深 (DOF)
|
||||||
|
screen.Purkinje_effect = 柏金赫现象设置
|
||||||
|
option.SHARPENING = 锐化强度
|
||||||
|
option.BLOOM_STRENGTH = 泛光强度
|
||||||
|
screen.TAA_OPTIONS = 抗锯齿设置
|
||||||
|
option.SCREENSHOT_MODE = 截图模式
|
||||||
|
option.TAA = 时间性抗锯齿 (TAA)
|
||||||
|
option.BLEND_FACTOR = 混合比重
|
||||||
|
option.TAA_UPSCALING = TAA 升采样
|
||||||
|
option.SCALE_FACTOR = 放大倍率
|
||||||
|
screen.COLOR_GRADING = 颜色分级
|
||||||
|
option.TONE_CURVE = 色调曲线
|
||||||
|
option.LOWER_CURVE = 下部曲线
|
||||||
|
option.UPPER_CURVE = 上部曲线
|
||||||
|
option.COLOR_GRADING_ENABLED = 颜色分级
|
||||||
|
option.SHADOWS_GRADE_R = 暗部 - §c红色
|
||||||
|
option.SHADOWS_GRADE_G = 暗部 - §a绿色
|
||||||
|
option.SHADOWS_GRADE_B = 暗部 - §9蓝色
|
||||||
|
option.SHADOWS_GRADE_MUL = 暗部 - 亮度
|
||||||
|
option.MIDS_GRADE_R = 中性色 - §c红色
|
||||||
|
option.MIDS_GRADE_G = 中性色 - §a绿色
|
||||||
|
option.MIDS_GRADE_B = 中性色 - §9蓝色
|
||||||
|
option.MIDS_GRADE_MUL = 中性色 - 亮度
|
||||||
|
option.HIGHLIGHTS_GRADE_R = 亮部 - §c红色
|
||||||
|
option.HIGHLIGHTS_GRADE_G = 亮部 - §a绿色
|
||||||
|
option.HIGHLIGHTS_GRADE_B = 亮部 - §9蓝色
|
||||||
|
option.HIGHLIGHTS_GRADE_MUL = 亮部 - 亮度
|
||||||
|
|
||||||
|
|
||||||
|
screen.LabPBR = Lab PBR
|
||||||
|
screen.Reflections = 高光反射
|
||||||
|
option.Specular_Reflections = 高光反射
|
||||||
|
option.Screen_Space_Reflections = 屏幕空间反射 (SSR)
|
||||||
|
option.Rough_reflections = 粗糙反射
|
||||||
|
option.Sky_reflection = 天空/雾气反射
|
||||||
|
option.Dynamic_SSR_quality = 动态 SSR 质量
|
||||||
|
option.Roughness_Threshold = 粗糙反射阀值
|
||||||
|
option.Sun_specular_Strength = 太阳反射强度
|
||||||
|
option.reflection_quality = SSR 质量
|
||||||
|
|
||||||
|
screen.Emissives = 发光效果
|
||||||
|
option.Emissive_Brightness = 发光亮度
|
||||||
|
option.Emissive_Curve = 发光曲线
|
||||||
|
option.EMISSIVE_TYPE = 发光模式
|
||||||
|
value.EMISSIVE_TYPE.0 = 不发光
|
||||||
|
value.EMISSIVE_TYPE.1 = 仅硬编码
|
||||||
|
value.EMISSIVE_TYPE.2 = 硬编码 + LabPBR 自发光
|
||||||
|
value.EMISSIVE_TYPE.3 = 仅 LabPBR 自发光
|
||||||
|
|
||||||
|
|
||||||
|
screen.POM = 视差遮蔽映射 (POM)
|
||||||
|
option.HEIGTHMAP_DEPTH_OFFSET = 基于高度图的深度偏移
|
||||||
|
option.POM = 视差 (POM)
|
||||||
|
option.MAX_ITERATIONS = 视差质量
|
||||||
|
option.POM_DEPTH = 视差深度
|
||||||
|
option.MAX_DIST = 视差最大距离
|
||||||
|
option.Adaptive_Step_length = 动态质量
|
||||||
|
option.Horrible_slope_normals = 恐怖的斜坡法线
|
||||||
|
|
||||||
|
|
||||||
|
screen.Porosity = 孔隙率/水坑
|
||||||
|
option.Porosity = 孔隙率
|
||||||
|
option.Puddles = 水坑
|
||||||
|
option.Puddle_Size = 水坑大小
|
||||||
|
|
||||||
|
option.MATERIAL_AO = 材质环境光遮蔽
|
||||||
|
|
||||||
|
option.DOF_QUALITY=景深 (DOF)
|
||||||
|
value.DOF_QUALITY.-1=关闭
|
||||||
|
value.DOF_QUALITY.0=六边形景深虚化效果
|
||||||
|
value.DOF_QUALITY.1=低质量
|
||||||
|
value.DOF_QUALITY.2=中质量
|
||||||
|
value.DOF_QUALITY.3=高质量
|
||||||
|
value.DOF_QUALITY.4=极高质量
|
||||||
|
value.DOF_QUALITY.5=抖动
|
||||||
|
option.MANUAL_FOCUS=对焦距离
|
||||||
|
option.DOF_ANAMORPHIC_RATIO=景深变形比
|
||||||
|
value.MANUAL_FOCUS.-2=自动对焦
|
||||||
|
value.MANUAL_FOCUS.-1=亮度滑块
|
||||||
|
|
||||||
|
screen.JITTER_DOF=抖动景深设置
|
||||||
|
option.JITTER_STRENGTH=抖动强度
|
||||||
|
option.FOCUS_LASER_COLOR=聚焦点
|
||||||
|
value.FOCUS_LASER_COLOR.0=红
|
||||||
|
value.FOCUS_LASER_COLOR.1=绿
|
||||||
|
value.FOCUS_LASER_COLOR.2=蓝
|
||||||
|
value.FOCUS_LASER_COLOR.3=粉
|
||||||
|
value.FOCUS_LASER_COLOR.4=黄
|
||||||
|
value.FOCUS_LASER_COLOR.5=白
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE=Aerochrome 模式
|
||||||
|
option.AEROCHROME_PINKNESS=Aerochrome 模式 红色: 粉色 比例
|
||||||
|
option.AEROCHROME_WOOL_ENABLED=Aerochrome 模式作用于羊毛
|
||||||
|
|
||||||
|
option.AEROCHROME_MODE.comment=影响画面. 从谷歌浏览器的功能实现方式得到了灵感.
|
||||||
|
option.AEROCHROME_PINKNESS.comment=选项数值越高 = 越接近粉色. 选项数值越低 = 越接近红色.
|
||||||
|
option.AEROCHROME_WOOL_ENABLED.comment=技术上,与羊毛相关的方块都会受到影响,但会破坏了大量的建筑外观. 启用后可能会导致更多的技术性错误.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
screen.Misc_Settings.comment = 用于调试的一些随机选项和有趣的功能.
|
||||||
|
screen.Sun_and_Moon_Colors.comment = 配置太阳和月亮的颜色.
|
||||||
|
option.sunPathRotation.comment = 配置太阳和月亮的角度.
|
||||||
|
option.sun_illuminance.comment = 配置太阳的亮度.
|
||||||
|
option.moon_illuminance.comment = 配置月亮的亮度.
|
||||||
|
|
||||||
|
screen.Direct_Light.comment = 配置和阳光或阴影相关的设置.
|
||||||
|
|
||||||
|
screen.Shadows.comment = 根据喜好配置阳光的阴影.
|
||||||
|
option.SCREENSPACE_CONTACT_SHADOWS.comment = §b这啥?§r 这是给远处事物的小部分阴影区域补充, 以及对近处小部分阴影区域添加细节. §a性能消耗水平:§r 低偏中; 在更高分辨率下会消耗更多性能.
|
||||||
|
option.RENDER_ENTITY_SHADOWS.comment = §b这啥?§r 所有类型实体的阴影, 例如怪物, 箱子, 旗帜, 或者告示牌. §a性能消耗水平:§r 低偏中; 在近处有特别多实体的时候消耗的性能会非常的恐怖.
|
||||||
|
option.shadowMapResolution.comment = 在太阳照射下从世界上的事物投射出来阴影的质量. §a性能消耗水平:§r 中或更高; 阴影需要从太阳的角度进行第二次 3D 世界的渲染, 这就是为什么它会使性能减半.
|
||||||
|
option.shadowDistance.comment = 阴影可渲染的最大距离 (这不是线性距离). 推荐保持默认, 因为接触阴影能解决远处阴影的渲染需求. §a性能消耗水平:§r 中或更高; 如果渲染距离非常大, 阴影的性能开销会很恐怖.
|
||||||
|
option.OPTIMIZED_SHADOW_DISTANCE.comment = 仅在围绕以玩家为中心的球体中渲染的阴影, 最大渲染区块由渲染距离进行限制. 无优化选项不会以球体渲染阴影, 且不会被区块限制; 这意味着同样的渲染距离下阴影能覆盖更大的区域. 同样的, 设置为 无优化 时阴影距离不受区块限制. §a性能消耗水平:§r 低偏中. 优化选项更快, 无优化选项更慢.
|
||||||
|
screen.Filtering.comment = 配置作用于阴影的过滤效果.
|
||||||
|
option.SHADOW_FILTER_SAMPLE_COUNT.comment = 基础阴影过滤器质量. 过滤器仅用于软化阴影. §a性能消耗水平:§r 低偏中; 拉高本选项数值可以减少阴影边缘的噪点.
|
||||||
|
option.Min_Shadow_Filter_Radius.comment = 基础阴影过滤器的最大软化程度.
|
||||||
|
option.Variable_Penumbra_Shadows.comment = 该效果使阴影离投射它的地方距离越远越柔和. 用于渲染更高质量的阴影和次表面散射. §a性能消耗水平:§r 低或高.
|
||||||
|
option.VPS_Search_Samples.comment = 可变半阴影过滤器质量. §a性能消耗水平:§r 低或高; 拉高本选项数值可以减少次表面散射和其它非常柔和地阴影的噪点.
|
||||||
|
option.Max_Shadow_Filter_Radius.comment = 离投射它的地方最大半径时阴影柔和程度达到最大.
|
||||||
|
option.Max_Filter_Depth.comment = 配置太阳大小. 若太阳更大, 阴影越靠近投射它的地方越柔和.
|
||||||
|
|
||||||
|
screen.Ambient_light.comment = 配置和遮蔽处的照明相关的设置.
|
||||||
|
option.AO_Strength.comment = 配置由 SSAO, GTAO, RTAO, 和 SSGI 渲染的环境光遮蔽强度. §b这啥?§r 环境光遮蔽是指在角落区域的小块柔和阴影.
|
||||||
|
option.GI_Strength.comment = 配置由 SSGI 渲染的全局照明强度. §b这啥?§r 在该情况下, 全局照明是指光线从一个表面反弹到其他区域的现象.
|
||||||
|
option.HQ_SSGI.comment = 远距屏幕空间全局照明开关. §a性能消耗水平:§r 非常高.
|
||||||
|
option.Hand_Held_lights.comment = 动态手持光源 (光影实现) 开关. §a性能消耗水平:§r 非常低.
|
||||||
|
option.SKY_CONTRIBUTION_IN_SSRT.comment = 允许 RTAO 或 SSGI 计算考虑整个天空和雾气来在遮蔽处创建高质量照明. 但会带来更多噪点. §a性能消耗水平:§r 中
|
||||||
|
|
||||||
|
option.ambientOcclusionLevel.comment = 配置原版 Minecraft 的环境光遮蔽强度. §b这啥?§r 原版下该环境光遮蔽默认开启, 无关光影是否开启.
|
||||||
|
option.ambient_brightness.comment = 配置阴影区域的其他光源照明的亮度.
|
||||||
|
option.MIN_LIGHT_AMOUNT.comment = 配置阴影区域的最小照明水平.
|
||||||
|
option.indirect_effect.comment = 切换不同类型的间接照明效果使阴影区域渲染质量更好. §a性能消耗水平:§r. 原版 AO: 非常低. SSAO: 低偏中. GTAO: 中偏高. RTAO or SSGI: 高或更高.
|
||||||
|
|
||||||
|
screen.Ambient_Colors.comment = 配置阴影区域的照明颜色.
|
||||||
|
screen.Torch_Colors.comment = 配置火把或其它可放置光源的颜色.
|
||||||
|
|
||||||
|
screen.LabPBR.comment = 由遵循 LabPBR 格式的资源包提供部分信息的小部分效果.
|
||||||
|
screen.Reflections.comment = 配置由 LabPBR 格式的资源包所提供信息的反射.
|
||||||
|
option.Specular_Reflections.comment = LabPBR 资源包所有反射的开关. 本选项同时启用太阳反射, 同时允许以下其它设置启用. §a性能消耗水平:§r 低.
|
||||||
|
option.Screen_Space_Reflections.comment = 屏幕空间反射开关. §a性能消耗水平:§r 中.
|
||||||
|
option.Rough_reflections.comment = 开启更精细的粗糙反射以获得更高的反射质量. 开启会导致出现大量可见噪点. §a性能消耗水平:§r 中偏高.
|
||||||
|
option.Sky_reflection.comment = 反射天空和雾气的开关. §a性能消耗水平:§r 低偏中.
|
||||||
|
option.Dynamic_SSR_quality.comment = 会基于它们的可见程度降低屏幕空间反射质量. 以降低质量为代价提升性能.
|
||||||
|
option.Roughness_Threshold.comment = 粗糙度达到阈值后除了太阳反射外所有反射都不渲染. 可提升性能.
|
||||||
|
option.Sun_specular_Strength.comment = 配置太阳反射亮度.
|
||||||
|
option.reflection_quality.comment = 配置屏幕空间反射质量.
|
||||||
|
|
||||||
|
screen.Subsurface_Scattering.comment = §b这啥?§r 打个比方, 次表面散射类似于你把你的手盖住一个很亮的光源, 手掌呈现的那种从内部透光的感觉. 阳光实际上对植物, 衣服, 皮肤或者其它事物照耀都可以产生相同的效果.
|
||||||
|
option.SSS_TYPE.comment = 配置次表面散射如何在世界应用. §b硬编码:§r 由光影决定. §bLabSSS:§r 由资源包决定. §a性能消耗水平:§r 非常低.
|
||||||
|
option.MOB_SSS.comment = 怪物次表面散射开关. 也包含玩家. §a性能消耗水平:§r 非常低.
|
||||||
|
option.MISC_BLOCK_SSS.comment = 随机方块的次表面散射开关. 这个一般是指草和沙子. §a性能消耗水平:§r 非常低
|
||||||
|
option.Ambient_SSS.comment = §b这啥?§r 天空光的次表面散射开关, 而不是太阳光. §a性能消耗水平:§r 低偏中; 如果启用了 SSAO , 本选项的性能消耗会很小, 反之如果关闭了会消耗得大.
|
||||||
|
option.ambientsss_brightness.comment = 配置天空光次表面散射亮度.
|
||||||
|
|
||||||
|
screen.Emissives.comment = §b这啥?§r 自发光亮度是指某方块发光量或自发光强度.
|
||||||
|
option.Emissive_Brightness.comment = 配置自发光纹理发光亮度.
|
||||||
|
option.EMISSIVE_TYPE.comment = 配置自发光纹理如何在世界应用. §b硬编码:§r 由光影决定. §bLabPBR:§r 由资源包决定. §a性能消耗水平:§r 非常低.
|
||||||
|
option.Emissive_Curve.comment = 调整自发光纹理达到最高亮度的容易程度/速度. 1.0 是线性.
|
||||||
|
|
||||||
|
screen.POM.comment = 配置由资源包提供信息的视差遮蔽映射的相关设置.
|
||||||
|
option.HEIGTHMAP_DEPTH_OFFSET.comment = §b这啥?§r 使用资源包提供的 “高度图” 的偏移抵消许多效果所需的深度. 允许近处有更多细节, 同时作为 “POM 的性能预算” 而生效. §a性能消耗水平:§r 低偏中 - 如果设备负担不起了 POM 的性能消耗, 可使用本选项.
|
||||||
|
option.POM.comment = §b这啥?§r 通过使用资源包中的特殊图像, 在实际没有的区域渲染出 3D 几何图形. 这种效果基本上只向内凹, 所以大角度观察时, 会存在一些伪影. §a性能消耗水平:§r 中偏高.
|
||||||
|
option.MAX_ITERATIONS.comment = 配置视差效果的质量. 如果近距离仅看到了部分层, 则需要提高本项数值, 不然很难看到. §a性能消耗水平:§r 高.
|
||||||
|
option.POM_DEPTH.comment = 视差效果表面凹陷程度. §a性能消耗水平:§r 非常低.
|
||||||
|
option.MAX_DIST.comment = 视差效果以镜头为起点开始渲染的最远距离. §a性能消耗水平:§r 高.
|
||||||
|
option.Adaptive_Step_length.comment = 本选项可在不实际意义上提高质量的情况下提高视觉质量. 如果在非常近距离观察, 或者读取了陡峭的高度图, 会导致产生一些伪影.
|
||||||
|
option.Horrible_slope_normals.comment = 糟糕的实现, 给视差贴图的两侧提供表面. §a性能消耗水平:§r 低.
|
||||||
|
|
||||||
|
screen.Porosity.comment = 配置和湿度, 水坑相关的设置.
|
||||||
|
option.Porosity.comment = §b这啥?§r 孔隙率是对某种材料的多孔性的描述, 也可以说是它容纳水的能力. 例如, 海绵是非常多孔的; 大量吸附水时, 会使它变黑. §a性能消耗水平:§r 低.
|
||||||
|
option.Puddles.comment = 雨天时水坑的开关. §a性能消耗水平:§r 低.
|
||||||
|
option.Puddle_Size.comment = 配置水坑大小.
|
||||||
|
|
||||||
|
screen.Fog.comment = 配置和光线行进体积雾, 基于距离的雾气相关的设置.
|
||||||
|
option.VL_RENDER_RESOLUTION.comment = 配置体积雾分辨率. §a性能消耗水平:§r 高.
|
||||||
|
option.VL_SAMPLES.comment = 配置体积雾质量. §a性能消耗水平:§r 高
|
||||||
|
option.BLOOMY_FOG.comment = 配置作用于雾气的泛化强度. §b这啥?§r 本选项的效果使雾气看起来更柔和, 同时有助于隐藏部分噪点. 但可能会导致在细节边缘出现一些明显的闪烁. §a性能消耗水平:§r 非常低.
|
||||||
|
option.Haze_amount.comment = 配置周遭的大气密度. §b这啥?§r 在远处看到的蓝色雾霾.
|
||||||
|
option.RainFog_amount.comment = 配置雨天时的雾气密度.
|
||||||
|
option.RAYMARCH_CLOUDS_WITH_FOG.comment = 进入云层内或靠近云层周围时, 更细致的雾气的开关. §a性能消耗水平:§r 中偏高.
|
||||||
|
option.BorderFog.comment = §b这啥?§r 雾气开关, 目的是尝试隐藏区块边界. 但因为四周都是天空, 所以很难做好. §a性能消耗水平:§r 非常非常低.
|
||||||
|
|
||||||
|
screen.TOD_fog.comment = 配置一天中特定时间出现的雾气的密度.
|
||||||
|
option.TOD_Fog_mult.comment = 配置一天中特定时间出现的总体雾气量. 本选项不影响大气雾霾密度.
|
||||||
|
|
||||||
|
screen.Cave_Fog.comment = 配置仅出现在黑暗区域的雾气设置, 例如洞穴.
|
||||||
|
option.Cave_Fog.comment = 仅出现在黑暗区域的雾气. 因为光影不可能准确地判断出你是否在一个洞穴里, 所以这种雾气可能会出现在不是洞穴的地方. §a性能消耗水平:§r 低.
|
||||||
|
option.CaveFogFallOff.comment = 配置雾化淡出梯度达到最亮部分的容易程度/速度.
|
||||||
|
|
||||||
|
screen.Clouds.comment = 配置和光线步进体积云相关的设置.
|
||||||
|
option.VOLUMETRIC_CLOUDS.comment = 云层开关. §a性能消耗水平:§r 中偏高.
|
||||||
|
option.CLOUDS_QUALITY.comment = 配置体积云分辨率. §a性能消耗水平:§r 高.
|
||||||
|
option.CLOUDS_SHADOWS.comment = 从云层或雾气投射到地面的阴影的开关. §a性能消耗水平:§r 低偏中.
|
||||||
|
option.Daily_Weather.comment = 按周期循环的天气功能开关. 有八种天气预设, 每天光影会循环启用它们. 启用本选项后, 不能改变任何云层覆盖率设置. §a性能消耗水平:§r 低.
|
||||||
|
option.Cloud_Speed.comment = 配置日常时间云层的移动速度.
|
||||||
|
option.Rain_coverage.comment = 配置雨天时云层的覆盖率.
|
||||||
|
|
||||||
|
screen.World.comment = 配置多种会在主世界发生的效果, 从摇摆植物到水体相关的设置等.
|
||||||
|
screen.Water.comment = 配置和水体相关的设置.
|
||||||
|
option.WATER_REFLECTIONS.comment = 所有半透明方块反射的开关. 本选项允许以下其它设置启用. §a性能消耗水平:§r 低.
|
||||||
|
option.SCREENSPACE_REFLECTIONS.comment = 半透明方块的屏幕空间反射开关. §a性能消耗水平:§r 中.
|
||||||
|
option.SSR_STEPS.comment = 配置半透明方块的屏幕空间反射质量. §a性能消耗水平:§r 中偏高.
|
||||||
|
option.WATER_SUN_SPECULAR.comment = 半透明方块的日月反射开关. §a性能消耗水平:§r 低.
|
||||||
|
option.WATER_BACKGROUND_SPECULAR.comment = 半透明方块的天空和雾气反射开关. §a性能消耗水平:§r 低偏中.
|
||||||
|
option.Refraction.comment = 半透明折射开关. §b这啥?§r 如果你观察水体, 可以看到光的折射会扭曲了水中的内容. §a性能消耗水平:§r 低.
|
||||||
|
option.Dirt_Amount.comment = 配置水中污物含量. 这可以控制水雾量.
|
||||||
|
option.Water_Top_Layer.comment = 配置海平面在世界中的 Y 坐标.
|
||||||
|
|
||||||
|
screen.Water_fog_color.comment = 配置水雾颜色.
|
||||||
|
|
||||||
|
screen.Climate.comment = 配置和气候相关的设置, 例如四季颜色, 周期循环的天气, 以及群系特定雾气.
|
||||||
|
screen.Seasons.comment = 循环往复的四季颜色, 夏秋冬春.
|
||||||
|
option.Seasons.comment = 循环往复的四季颜色, 夏秋冬春. §a性能消耗水平:§r 低.
|
||||||
|
option.Season_Length.comment = 控制单个季节的持续时间, 单位: MC 日.
|
||||||
|
option.Snowy_Winter.comment = 冬季积雪开关. §a性能消耗水平:§r 低.
|
||||||
|
screen.Summer_colors.comment = 配置夏季植被的颜色.
|
||||||
|
screen.Fall_colors.comment = 配置秋季植被的颜色.
|
||||||
|
screen.Winter_colors.comment = 配置冬季植被的颜色.
|
||||||
|
screen.Spring_colors.comment = 配置春季植被的颜色.
|
||||||
|
|
||||||
|
option.PER_BIOME_ENVIRONMENT.comment = 开关仅出现在特定群系的所有特色环境效果. §a性能消耗水平:§r 低.
|
||||||
|
|
||||||
|
screen.SWAMP.comment = 配置此群系类型的环境效果.
|
||||||
|
option.SWAMP_ENV.comment = 开关此群系类型的环境效果. 即使此项禁用, 其他群系的环境效果仍保持激活状态..
|
||||||
|
|
||||||
|
screen.JUNGLE.comment = 配置此群系类型的环境效果.
|
||||||
|
option.JUNGLE_ENV.comment = 开关此群系类型的环境效果. 即使此项禁用, 其他群系的环境效果仍保持激活状态..
|
||||||
|
|
||||||
|
screen.DARKFOREST.comment = 配置此群系类型的环境效果.
|
||||||
|
option.DARKFOREST_ENV.comment = 开关此群系类型的环境效果. 即使此项禁用, 其他群系的环境效果仍保持激活状态..
|
||||||
|
|
||||||
|
|
||||||
|
screen.Waving_Stuff.comment = 配置和摇摆相关的设置.
|
||||||
|
option.WAVY_PLANTS.comment = 植物摇摆开关. §a性能消耗水平:§r 非常低.
|
||||||
|
option.WAVY_STRENGTH.comment = 配置摇摆效果强度.
|
||||||
|
option.WAVY_SPEED.comment = 配置植物摇摆速度.
|
||||||
|
|
||||||
|
screen.Post_Processing.comment = 配置所有后处理效果设置, 从抗锯齿到色调映射等.
|
||||||
|
screen.Tonemapping.comment = 配置和颜色或色调相关的设置.
|
||||||
|
screen.Exposure.comment = 配置和曝光相关的设置.
|
||||||
|
screen.DepthOfField.comment = 配置和景深相关的设置.
|
||||||
|
screen.Purkinje_effect.comment = 配置和柏金赫现象相关的设置. 柏金赫现象: 人类眼睛对高度照明灵敏,而在低照明水平时,往光谱高频蓝端迁移的现象 (来源于百度百科).
|
||||||
|
option.SHARPENING.comment = 配置对比度自适应锐化作用于图像的强度. 本选项可以有效带出因抗锯齿和升分辨率产生的细节损失.
|
||||||
|
option.BLOOM_STRENGTH.comment = 配置作用于图像的泛光强度. §b这啥?§r 泛光是指柔和所有发光事物的效果, 用来描述某物是否明亮.
|
||||||
|
screen.TAA_OPTIONS.comment = 配置和抗锯齿相关的设置.
|
||||||
|
option.SCREENSHOT_MODE.comment = 开启帧数积累以获得少噪点高质量的图像. §b这啥?§r 将已发生的帧叠加到生成的下一帧上, 类似于长曝光图像.
|
||||||
|
option.TAA.comment = 时间性抗锯齿 (TAA) 开关. 这可以去除大部分内容的锯齿状边缘, 软化图像, 并有助于去除许多效果产生的噪点. 但会导致拖影, 因为它使用过去的帧来获取世界额外信息. §a性能消耗水平:§r 低.
|
||||||
|
option.BLEND_FACTOR.comment = 配置历史帧使用比重. 更高的数值意味着依赖更少的历史帧, 所以可能会看起来很闪烁和多噪点. 较低的数值意味着以来更多的历史帧, 所以可能会看起来更少噪点但是更多拖影和显得有点脏.
|
||||||
|
option.TAA_UPSCALING.comment = 时间性升分辨率. 升分辨率时, 可以从低分辨率的图像中保留大多数质量. 因此与常规升分辨率相比, 可以开启一个看起来很高的分辨率的同时也能有更好的性能.
|
||||||
|
option.SCALE_FACTOR.comment = 配置以原有分辨率的多大一部分来开始升分辨率. 不推荐低于0.5, 只把它作为一个选项, 因为它很有趣. :P
|
||||||
|
screen.COLOR_GRADING.comment = 高级调色选项.
|
||||||
|
option.TONE_CURVE.comment = 启用色调曲线. 独立于颜色分级且首先应用.
|
||||||
|
option.COLOR_GRADING_ENABLED.comment = 启用颜色分级. RGB 滑块不会影响亮度. 在色调曲线之后应用.
|
||||||
|
|
||||||
|
option.RESOURCEPACK_SKY.comment = 开关资源包天空支持. 配置设置来使用完整的资源包天空, 或保持光影的日月. §a性能消耗水平:§r 非常低.
|
||||||
|
option.SKY_GROUND = 地天
|
||||||
|
|
||||||
|
option.MATERIAL_AO.comment = 开关基于资源包提供的内容应用环境光遮蔽的功能. §a性能消耗水平:§r 非常低.
|
||||||
|
option.WATER_WAVE_STRENGTH.comment = 配置出现的水波强度.
|
||||||
|
option.MOONPHASE_BASED_MOONLIGHT.comment = §b这啥?§r 每晚月亮有不同的照度. 此选项根据月相来调整发出的月光亮度. §a性能消耗水平:§r 近乎于无.
|
||||||
|
|
||||||
|
option.END_STORM_DENSTIY.comment = §b这啥?§r 这是末地的一层暗色云雾. 配置末地风暴的密度.
|
||||||
|
option.NETHER_PLUME_DENSITY.comment = §b这啥?§r 这是下界中那些浓密的发光烟柱. 配置下界烟柱的密度.
|
||||||
|
|
||||||
|
option.CloudLayer0.comment = 较小积云层的开关. §a性能消耗水平:§r 中.
|
||||||
|
option.CloudLayer0_coverage.comment = 配置云覆盖天空的程度.
|
||||||
|
option.CloudLayer0_density.comment = 配置云层的密度或者说厚度.
|
||||||
|
option.CloudLayer0_height.comment = 配置云层飘浮处的高度.
|
||||||
|
|
||||||
|
option.CloudLayer1.comment = 较大积云层的开关. §a性能消耗水平:§r 中.
|
||||||
|
option.CloudLayer1_coverage.comment = 配置云覆盖天空的程度.
|
||||||
|
option.CloudLayer1_density.comment = 配置云层的密度或者说厚度.
|
||||||
|
option.CloudLayer1_height.comment = 配置云层飘浮处的高度. §c不能低于小积云层§r
|
||||||
|
|
||||||
|
option.CloudLayer2.comment = 较高且薄的云层的开关. §a性能消耗水平:§r 低.
|
||||||
|
option.CloudLayer2_coverage.comment = 配置云覆盖天空的程度.
|
||||||
|
option.CloudLayer2_density.comment = 配置云层的密度或者说厚度.
|
||||||
|
option.CloudLayer2_height.comment = 配置云层飘浮处的高度. §c不能低于大积云层§r
|
||||||
|
|
||||||
|
option.SKY_GROUND.comment = §b这啥?§r 天空的暗色下半部分, 若 Minecraft 有无限渲染距离, 则这是地面. §a性能消耗水平:§r 非常非常低. §c由于额外的函数计算, 禁用本选项会比启用消耗消耗更多性能.§r
|
||||||
|
option.SNELLS_WINDOW.comment = §b这啥?§r 这是在水下看到的黑色反射圆圈. 这是对现实水下会发生的情况的模拟, 称为 "全内反射". §a性能消耗水平:§r 非常非常非常低.
|
||||||
|
option.entityShadowDistanceMul.comment = §b这啥?§r 配置实体阴影的生效距离. 如果想保留实体阴影开启又想提高有巨量实体的区域的性能, 本选项会十分有用.
|
||||||
|
|
||||||
|
screen.DISTANT_HORIZONS_SETTINGS = §2Distant Horizons §f设置
|
||||||
|
|
||||||
|
option.DH_KNOWN_ISSUES =DH 支持已知问题
|
||||||
|
value.DH_KNOWN_ISSUES.0 = §c 点击此处文本循环查看已知问题列表
|
||||||
|
value.DH_KNOWN_ISSUES.1 = §a LOD 区域的 GTAO, RTAO, 和 SSGI 不生效 - 未能实现对 DH 的支持
|
||||||
|
|
||||||
|
option.DISTANT_HORIZONS_SHADOWMAP = §c(如果不知道本选项作用, 请不要开启)§r DH 阴影图支持
|
||||||
|
option.DISTANT_HORIZONS_SHADOWMAP.comment = §c此选项会降低性能, 会使阴影看起来呈块状, 闪烁且会降低阴影细节§r. 将阴影距离设置为 32 区块 (或更多). 设置阴影分辨率为 4096 (或更大)
|
||||||
|
option.TOGGLE_VL_FOG = 体积雾
|
||||||
|
option.TOGGLE_VL_FOG.comment = 一个快速关闭所有雾气的开关.
|
||||||
|
|
||||||
|
option.TRANSLUCENT_COLORED_SHADOWS.comment = §b这啥?§r 本选项的效果可以使像染色玻璃这样的半透明方块对穿过的光线染色. §a性能消耗水平:§r 中.
|
||||||
|
|
||||||
|
#Additional Options / 附加选项
|
||||||
|
#Direct Light
|
||||||
|
option.BASIC_SHADOW_FILTER=基础阴影过滤
|
||||||
|
|
||||||
|
option.sunColorR=太阳 - 红色比重
|
||||||
|
option.sunColorG=太阳 - 绿色比重
|
||||||
|
option.sunColorB=太阳 - 蓝色比重
|
||||||
|
option.moonColorR=月亮 - 红色比重
|
||||||
|
option.moonColorG=月亮 - 绿色比重
|
||||||
|
option.moonColorB=月亮 - 蓝色比重
|
||||||
|
option.colortype=颜色模式
|
||||||
|
option.colortype.comment=1 = RGB 模式滑块. 2 = 黑体模式.
|
||||||
|
value.colortype.1= RGB 模式滑块
|
||||||
|
value.colortype.2= 黑体模式
|
||||||
|
option.Sun_temp=阳光色温
|
||||||
|
suffix.Sun_temp=K
|
||||||
|
option.Moon_temp=月光色温
|
||||||
|
suffix.Moon_temp=K
|
||||||
|
|
||||||
|
suffix.sunPathRotation=°
|
||||||
|
suffix.sun_illuminance=LX
|
||||||
|
suffix.moon_illuminance=LX
|
||||||
|
option.OLD_LIGHTLEAK_FIX=旧版阳光泄露修复
|
||||||
|
|
||||||
|
|
||||||
|
#World
|
||||||
|
option.Vanilla_like_water=原版水体样式
|
||||||
|
option.WATER_WAVE_SPEED=水体摇晃速度
|
||||||
|
|
||||||
|
#Ambient_light
|
||||||
|
option.HANDHELD_LIGHT_RANGE=手持光源范围
|
||||||
|
|
||||||
|
|
||||||
|
#Fog
|
||||||
|
option.FOG_START_HEIGHT=雾气起始高度
|
||||||
|
|
||||||
|
option.CAVE_FOG=洞穴雾气
|
||||||
|
|
||||||
|
|
||||||
|
#Post_Processing
|
||||||
|
option.TONEMAP=色调映射方法
|
||||||
|
option.USE_ACES_COLORSPACE_APPROXIMATION=启用 ACES 色彩空间的近似值拟合
|
||||||
|
option.SATURATION=饱和度
|
||||||
|
option.CROSSTALK=去饱和度
|
||||||
|
option.CONTRAST=对比度
|
||||||
|
|
||||||
|
option.AUTO_EXPOSURE=自动曝光
|
||||||
|
option.EXPOSURE_MULTIPLIER=曝光强度
|
||||||
|
option.Exposure_Speed=曝光速度
|
||||||
|
option.Manual_exposure_value=手动曝光值
|
||||||
|
|
||||||
|
option.AUTOFOCUS=自动对焦
|
||||||
|
option.focal=焦距
|
||||||
|
option.aperture=光圈
|
||||||
|
option.DoF_Adaptation_Speed=景深虚化自适应速度
|
||||||
|
option.FAR_BLUR_ONLY=仅虚化远处
|
||||||
|
|
||||||
|
option.Purkinje_strength=柏金赫现象强度
|
||||||
|
option.Purkinje_R=柏金赫 - 红色
|
||||||
|
option.Purkinje_G=柏金赫 - 绿色
|
||||||
|
option.Purkinje_B=柏金赫 - 蓝色
|
||||||
|
option.Purkinje_Multiplier=柏金赫现象倍率
|
||||||
|
|
||||||
|
screen.GAMEPLAY_EFFECTS=游玩效果设置
|
||||||
|
option.MOTION_AMOUNT=Motion Amount
|
||||||
|
option.DAMAGE_TAKEN_EFFECT=受伤效果
|
||||||
|
option.LOW_HEALTH_EFFECT=低生命值效果
|
||||||
|
|
||||||
|
#Clouds
|
||||||
|
option.CLOUD_SHADOW_STRENGTH=云影强度
|
||||||
|
|
||||||
|
|
||||||
|
#LabPBR
|
||||||
|
|
||||||
|
option.sss_density_multiplier=次表面散射强度倍率
|
||||||
|
option.sss_absorbance_multiplier=次表面散射吸光倍率
|
||||||
|
|
||||||
|
|
||||||
|
#Climate Settings
|
||||||
|
|
||||||
|
|
||||||
|
#Misc Settings
|
||||||
|
screen.the_orb=末地球形天体
|
||||||
|
option.THE_ORB=球形天体
|
||||||
|
option.THE_ORB.comment=§c实测请保持关闭该选项, 以下配置选项暂不能调节该天体效果.
|
||||||
|
option.ORB_X=天体位置 - X轴坐标
|
||||||
|
option.ORB_Y=天体位置 - Y轴坐标
|
||||||
|
option.ORB_Z=天体位置 - Z轴坐标
|
||||||
|
option.ORB_ColMult=天体颜色倍率
|
||||||
|
option.ORB_R=天体颜色 - 红色
|
||||||
|
option.ORB_G=天体颜色 - 绿色
|
||||||
|
option.ORB_B=天体颜色 - 蓝色
|
||||||
|
|
||||||
|
screen.lightning_color=闪电颜色
|
||||||
|
option.Lightning_R=闪电 - 红色
|
||||||
|
option.Lightning_G=闪电 - 绿色
|
||||||
|
option.Lightning_B=闪电 - 蓝色
|
||||||
|
|
||||||
|
option.DEBUG_VIEW=调试视图
|
||||||
|
value.DEBUG_VIEW.debug_OFF=关闭
|
||||||
|
value.DEBUG_VIEW.debug_SHADOWMAP=阴影图
|
||||||
|
value.DEBUG_VIEW.debug_NORMALS=法线
|
||||||
|
value.DEBUG_VIEW.debug_SPECULAR=高光
|
||||||
|
value.DEBUG_VIEW.debug_INDIRECT=间接照明
|
||||||
|
value.DEBUG_VIEW.debug_DIRECT=直接照明
|
||||||
|
value.DEBUG_VIEW.debug_VIEW_POSITION=View Position
|
||||||
|
value.DEBUG_VIEW.debug_DH_WATER_BLENDING=DH 水体混合
|
||||||
|
option.display_LUT=显示 LUT
|
||||||
|
option.WhiteWorld=全白世界
|
||||||
|
option.WhiteWorld.comment=用于调试的视图. 易于观察环境光遮蔽的效果. 易于观察模拟全局光照 (绿光) 的效果.
|
||||||
|
option.SSS_view=次表面散射视图
|
||||||
|
option.ambientLight_only=仅启用环境光
|
||||||
|
option.ambientLight_only.comment=用于调试的视图. 关闭太阳光. 此选项不会影响性能,阴影依旧会在后台工作.
|
||||||
|
option.Glass_Tint=玻璃色调
|
||||||
|
option.Glass_Tint.comment=背景通过混合玻璃本身的颜色获得强烈的色调.
|
||||||
|
option.LIGHTNING_FLASH=闪电闪烁
|
||||||
|
option.HURT_AND_DEATH_EFFECT=死伤效果
|
||||||
|
option.LIT_PARTICLE_BRIGHTNESS=提高粒子亮度
|
||||||
|
option.PLANET_GROUND_BRIGHTNESS=行星地表亮度
|
||||||
|
option.BLOOMY_PARTICLES=泛光粒子
|
||||||
|
option.ORIGINAL_CHOCAPIC_SKY=原始 Chocapic 天空
|
||||||
|
option.BIOME_TINT_WATER=群系色调水体
|
||||||
|
option.CLOUDS_INFRONT_OF_WORLD=云层在世界前渲染
|
||||||
|
option.SELECT_BOX=选择框
|
||||||
|
option.DENOISE_SSS_AND_SSAO=对 SSS和 SSAOO 降噪
|
||||||
|
option.WATER_CAUSTICS_BRIGHTNESS=水体焦散线亮度
|
||||||
|
option.HYPER_DETAILED_WAVES=超细节水波
|
||||||
|
option.OLD_BLOOM=旧版泛光
|
||||||
|
|
||||||
|
|
||||||
|
#Climate
|
||||||
|
screen.Seasons=季节
|
||||||
|
suffix.Season_Length=MC日
|
||||||
|
|
||||||
|
#DH settings
|
||||||
|
option.DH_OVERDRAW_PREVENTION=防止过度绘制
|
|
@ -0,0 +1,63 @@
|
||||||
|
/////// ALL OF THIS IS BASED OFF OF THE DISTANT HORIZONS EXAMPLE PACK BY NULL
|
||||||
|
|
||||||
|
uniform mat4 dhPreviousProjection;
|
||||||
|
uniform mat4 dhProjectionInverse;
|
||||||
|
uniform mat4 dhProjection;
|
||||||
|
|
||||||
|
vec3 toScreenSpace_DH( vec2 texcoord, float depth, float DHdepth ) {
|
||||||
|
|
||||||
|
vec4 viewPos = vec4(0.0);
|
||||||
|
vec3 feetPlayerPos = vec3(0.0);
|
||||||
|
vec4 iProjDiag = vec4(0.0);
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
if (depth < 1.0) {
|
||||||
|
#endif
|
||||||
|
iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
|
||||||
|
feetPlayerPos = vec3(texcoord, depth) * 2.0 - 1.0;
|
||||||
|
viewPos = iProjDiag * feetPlayerPos.xyzz + gbufferProjectionInverse[3];
|
||||||
|
viewPos.xyz /= viewPos.w;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
} else {
|
||||||
|
iProjDiag = vec4(dhProjectionInverse[0].x, dhProjectionInverse[1].y, dhProjectionInverse[2].zw);
|
||||||
|
|
||||||
|
feetPlayerPos = vec3(texcoord, DHdepth) * 2.0 - 1.0;
|
||||||
|
viewPos = iProjDiag * feetPlayerPos.xyzz + dhProjectionInverse[3];
|
||||||
|
viewPos.xyz /= viewPos.w;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return viewPos.xyz;
|
||||||
|
}
|
||||||
|
vec3 toClipSpace3_DH( vec3 viewSpacePosition, bool depthCheck ) {
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
mat4 projectionMatrix = depthCheck ? dhProjection : gbufferProjection;
|
||||||
|
return projMAD(projectionMatrix, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
#else
|
||||||
|
return projMAD(gbufferProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
mat4 DH_shadowProjectionTweak( in mat4 projection){
|
||||||
|
|
||||||
|
#ifdef DH_SHADOWPROJECTIONTWEAK
|
||||||
|
|
||||||
|
float _far = (3.0 * far);
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
_far = 2.0 * dhFarPlane;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
mat4 newProjection = projection;
|
||||||
|
newProjection[2][2] = -2.0 / _far;
|
||||||
|
newProjection[3][2] = 0.0;
|
||||||
|
|
||||||
|
return newProjection;
|
||||||
|
#else
|
||||||
|
return projection;
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,183 @@
|
||||||
|
|
||||||
|
// Common constants
|
||||||
|
|
||||||
|
const float eps = 1e-6;
|
||||||
|
const float e = exp(1.0);
|
||||||
|
const float tau = 2.0 * pi;
|
||||||
|
const float half_pi = 0.5 * pi;
|
||||||
|
const float rcp_pi = 1.0 / pi;
|
||||||
|
const float degree = tau / 360.0; // Size of one degree in radians, useful because radians() is not a constant expression on all platforms
|
||||||
|
const float golden_ratio = 0.5 + 0.5 * sqrt(5.0);
|
||||||
|
const float golden_angle = tau / golden_ratio / golden_ratio;
|
||||||
|
const float hand_depth = 0.56;
|
||||||
|
|
||||||
|
#if defined TAA && defined TAA_UPSCALING
|
||||||
|
const float taau_render_scale = RENDER_SCALE.x;
|
||||||
|
#else
|
||||||
|
const float taau_render_scale = 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// Helper functions
|
||||||
|
|
||||||
|
#define rcp(x) (1.0 / (x))
|
||||||
|
#define clamp01(x) clamp(x, 0.0, 1.0) // free on operation output
|
||||||
|
#define max0(x) max(x, 0.0)
|
||||||
|
#define min1(x) min(x, 1.0)
|
||||||
|
|
||||||
|
float sqr(float x) { return x * x; }
|
||||||
|
vec2 sqr(vec2 v) { return v * v; }
|
||||||
|
vec3 sqr(vec3 v) { return v * v; }
|
||||||
|
vec4 sqr(vec4 v) { return v * v; }
|
||||||
|
|
||||||
|
float cube(float x) { return x * x * x; }
|
||||||
|
|
||||||
|
float max_of(vec2 v) { return max(v.x, v.y); }
|
||||||
|
float max_of(vec3 v) { return max(v.x, max(v.y, v.z)); }
|
||||||
|
float max_of(vec4 v) { return max(v.x, max(v.y, max(v.z, v.w))); }
|
||||||
|
float min_of(vec2 v) { return min(v.x, v.y); }
|
||||||
|
float min_of(vec3 v) { return min(v.x, min(v.y, v.z)); }
|
||||||
|
float min_of(vec4 v) { return min(v.x, min(v.y, min(v.z, v.w))); }
|
||||||
|
|
||||||
|
float length_squared(vec2 v) { return dot(v, v); }
|
||||||
|
float length_squared(vec3 v) { return dot(v, v); }
|
||||||
|
|
||||||
|
vec2 normalize_safe(vec2 v) { return v == vec2(0.0) ? v : normalize(v); }
|
||||||
|
vec3 normalize_safe(vec3 v) { return v == vec3(0.0) ? v : normalize(v); }
|
||||||
|
|
||||||
|
float rcp_length(vec2 v) { return inversesqrt(dot(v, v)); }
|
||||||
|
float rcp_length(vec3 v) { return inversesqrt(dot(v, v)); }
|
||||||
|
|
||||||
|
float fast_acos(float x) {
|
||||||
|
const float C0 = 1.57018;
|
||||||
|
const float C1 = -0.201877;
|
||||||
|
const float C2 = 0.0464619;
|
||||||
|
|
||||||
|
float res = (C2 * abs(x) + C1) * abs(x) + C0; // p(x)
|
||||||
|
res *= sqrt(1.0 - abs(x));
|
||||||
|
|
||||||
|
return x >= 0 ? res : pi - res; // Undo range reduction
|
||||||
|
}
|
||||||
|
vec2 fast_acos(vec2 v) { return vec2(fast_acos(v.x), fast_acos(v.y)); }
|
||||||
|
|
||||||
|
uniform vec2 view_res;
|
||||||
|
uniform vec2 view_pixel_size;
|
||||||
|
|
||||||
|
float linear_step(float edge0, float edge1, float x) {
|
||||||
|
return clamp01((x - edge0) / (edge1 - edge0));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 linear_step(vec2 edge0, vec2 edge1, vec2 x) {
|
||||||
|
return clamp01((x - edge0) / (edge1 - edge0));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 project(mat4 m, vec3 pos) {
|
||||||
|
return vec4(m[0].x, m[1].y, m[2].zw) * pos.xyzz + m[3];
|
||||||
|
}
|
||||||
|
vec3 project_and_divide(mat4 m, vec3 pos) {
|
||||||
|
vec4 homogenous = project(m, pos);
|
||||||
|
return homogenous.xyz / homogenous.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 screen_to_view_space(vec3 screen_pos, bool handle_jitter) {
|
||||||
|
vec3 ndc_pos = 2.0 * screen_pos - 1.0;
|
||||||
|
|
||||||
|
return project_and_divide(gbufferProjectionInverse, ndc_pos);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 view_to_screen_space(vec3 view_pos, bool handle_jitter) {
|
||||||
|
vec3 ndc_pos = project_and_divide(gbufferProjection, view_pos);
|
||||||
|
|
||||||
|
|
||||||
|
return ndc_pos * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ---------------------
|
||||||
|
// ambient occlusion
|
||||||
|
// ---------------------
|
||||||
|
|
||||||
|
#define GTAO_SLICES 2
|
||||||
|
#define GTAO_HORIZON_STEPS 3
|
||||||
|
#define GTAO_RADIUS 2.0
|
||||||
|
#define GTAO_FALLOFF_START 0.75
|
||||||
|
|
||||||
|
float integrate_arc(vec2 h, float n, float cos_n) {
|
||||||
|
vec2 tmp = cos_n + 2.0 * h * sin(n) - cos(2.0 * h - n);
|
||||||
|
return 0.25 * (tmp.x + tmp.y);
|
||||||
|
}
|
||||||
|
|
||||||
|
float calculate_maximum_horizon_angle(
|
||||||
|
vec3 view_slice_dir,
|
||||||
|
vec3 viewer_dir,
|
||||||
|
vec3 screen_pos,
|
||||||
|
vec3 view_pos,
|
||||||
|
float dither
|
||||||
|
) {
|
||||||
|
const float step_size = GTAO_RADIUS * rcp(float(GTAO_HORIZON_STEPS));
|
||||||
|
|
||||||
|
float max_cos_theta = -1.0;
|
||||||
|
|
||||||
|
vec2 ray_step = (view_to_screen_space(view_pos + view_slice_dir * step_size, true) - screen_pos).xy;
|
||||||
|
vec2 ray_pos = screen_pos.xy + ray_step * (dither + max_of(view_pixel_size) * rcp_length(ray_step));
|
||||||
|
|
||||||
|
|
||||||
|
for (int i = 0; i < GTAO_HORIZON_STEPS; ++i, ray_pos += ray_step) {
|
||||||
|
float depth = texelFetch2D(depthtex1, ivec2(clamp(ray_pos,0.0,1.0) * view_res * taau_render_scale - 0.5), 0).x;
|
||||||
|
|
||||||
|
if (depth == 1.0 || depth < hand_depth || depth == screen_pos.z) continue;
|
||||||
|
|
||||||
|
vec3 offset = screen_to_view_space(vec3(ray_pos, depth), true) - view_pos;
|
||||||
|
|
||||||
|
float len_sq = length_squared(offset);
|
||||||
|
float norm = inversesqrt(len_sq);
|
||||||
|
|
||||||
|
float distance_falloff = linear_step(GTAO_FALLOFF_START * GTAO_RADIUS, GTAO_RADIUS, len_sq * norm);
|
||||||
|
|
||||||
|
float cos_theta = dot(viewer_dir, offset) * norm;
|
||||||
|
cos_theta = mix(cos_theta, -1.0, distance_falloff);
|
||||||
|
|
||||||
|
max_cos_theta = max(cos_theta, max_cos_theta);
|
||||||
|
}
|
||||||
|
|
||||||
|
return fast_acos(clamp(max_cos_theta, -1.0, 1.0));
|
||||||
|
}
|
||||||
|
|
||||||
|
float ambient_occlusion(vec3 screen_pos, vec3 view_pos, vec3 view_normal, vec2 dither) {
|
||||||
|
float ao = 0.0;
|
||||||
|
|
||||||
|
// Construct local working space
|
||||||
|
vec3 viewer_dir = normalize(-view_pos);
|
||||||
|
vec3 viewer_right = normalize(cross(vec3(0.0, 1.0, 0.0), viewer_dir));
|
||||||
|
vec3 viewer_up = cross(viewer_dir, viewer_right);
|
||||||
|
mat3 local_to_view = mat3(viewer_right, viewer_up, viewer_dir);
|
||||||
|
|
||||||
|
for (int i = 0; i < GTAO_SLICES; ++i) {
|
||||||
|
float slice_angle = (i + dither.x) * (pi / float(GTAO_SLICES));
|
||||||
|
|
||||||
|
vec3 slice_dir = vec3(cos(slice_angle), sin(slice_angle), 0.0);
|
||||||
|
vec3 view_slice_dir = local_to_view * slice_dir;
|
||||||
|
|
||||||
|
vec3 ortho_dir = slice_dir - dot(slice_dir, viewer_dir) * viewer_dir;
|
||||||
|
vec3 axis = cross(slice_dir, viewer_dir);
|
||||||
|
|
||||||
|
vec3 projected_normal = view_normal - axis * dot(view_normal, axis);
|
||||||
|
|
||||||
|
float len_sq = dot(projected_normal, projected_normal);
|
||||||
|
float norm = inversesqrt(len_sq);
|
||||||
|
|
||||||
|
float sgn_gamma = sign(dot(ortho_dir, projected_normal));
|
||||||
|
float cos_gamma = clamp01(dot(projected_normal, viewer_dir) * norm);
|
||||||
|
float gamma = sgn_gamma * fast_acos(cos_gamma);
|
||||||
|
|
||||||
|
vec2 max_horizon_angles;
|
||||||
|
max_horizon_angles.x = calculate_maximum_horizon_angle(-view_slice_dir, viewer_dir, screen_pos, view_pos, dither.y);
|
||||||
|
max_horizon_angles.y = calculate_maximum_horizon_angle( view_slice_dir, viewer_dir, screen_pos, view_pos, dither.y);
|
||||||
|
|
||||||
|
max_horizon_angles = gamma + clamp(vec2(-1.0, 1.0) * max_horizon_angles - gamma, -half_pi, half_pi) ;
|
||||||
|
|
||||||
|
|
||||||
|
ao += integrate_arc(max_horizon_angles, gamma, cos_gamma) * len_sq * norm ;
|
||||||
|
}
|
||||||
|
ao *= rcp(float(GTAO_SLICES));
|
||||||
|
return ao*(ao*0.5+0.5);
|
||||||
|
}
|
|
@ -0,0 +1,165 @@
|
||||||
|
// uniform float LowCoverage;
|
||||||
|
|
||||||
|
// uniform float isDeserts;
|
||||||
|
const float sunAngularSize = 0.533333;
|
||||||
|
const float moonAngularSize = 0.516667;
|
||||||
|
|
||||||
|
//Sky coefficients and heights
|
||||||
|
|
||||||
|
#define airNumberDensity 2.5035422e25
|
||||||
|
#define ozoneConcentrationPeak 8e-6
|
||||||
|
const float ozoneNumberDensity = airNumberDensity * ozoneConcentrationPeak;
|
||||||
|
#define ozoneCrossSection vec3(4.51103766177301e-21, 3.2854797958699e-21, 1.96774621921165e-22)
|
||||||
|
|
||||||
|
#define sky_planetRadius 6731e3
|
||||||
|
|
||||||
|
#define sky_atmosphereHeight 110e3
|
||||||
|
#define sky_scaleHeights vec2(8.0e3, 1.2e3)
|
||||||
|
|
||||||
|
|
||||||
|
#define sky_coefficientRayleigh vec3(sky_coefficientRayleighR*1e-6, sky_coefficientRayleighG*1e-5, sky_coefficientRayleighB*1e-5)
|
||||||
|
|
||||||
|
|
||||||
|
#define sky_coefficientMie vec3(sky_coefficientMieR*1e-6, sky_coefficientMieG*1e-6, sky_coefficientMieB*1e-6) // Should be >= 2e-6
|
||||||
|
const vec3 sky_coefficientOzone = (ozoneCrossSection * (ozoneNumberDensity * 0.2e-6)); // ozone cross section * (ozone number density * (cm ^ 3))
|
||||||
|
|
||||||
|
const vec2 sky_inverseScaleHeights = 1.0 / sky_scaleHeights;
|
||||||
|
const vec2 sky_scaledPlanetRadius = sky_planetRadius * sky_inverseScaleHeights;
|
||||||
|
const float sky_atmosphereRadius = sky_planetRadius + sky_atmosphereHeight;
|
||||||
|
const float sky_atmosphereRadiusSquared = sky_atmosphereRadius * sky_atmosphereRadius;
|
||||||
|
|
||||||
|
#define sky_coefficientsScattering mat2x3(sky_coefficientRayleigh, sky_coefficientMie)
|
||||||
|
const mat3 sky_coefficientsAttenuation = mat3(sky_coefficientRayleigh , sky_coefficientMie, sky_coefficientOzone ); // commonly called the extinction coefficient
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
float sky_rayleighPhase(float cosTheta) {
|
||||||
|
const vec2 mul_add = vec2(0.1, 0.28) * rPI;
|
||||||
|
return cosTheta * mul_add.x + mul_add.y; // optimized version from [Elek09], divided by 4 pi for energy conservation
|
||||||
|
}
|
||||||
|
|
||||||
|
float sky_miePhase(float cosTheta, const float g) {
|
||||||
|
float gg = g * g;
|
||||||
|
return (gg * -0.25 + 0.25) * rPI * pow(-(2.0 * g) * cosTheta + (gg + 1.0), -1.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 sky_phase(float cosTheta, const float g) {
|
||||||
|
return vec2(sky_rayleighPhase(cosTheta), sky_miePhase(cosTheta, g));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 sky_density(float centerDistance) {
|
||||||
|
vec2 rayleighMie = exp(centerDistance * -sky_inverseScaleHeights + sky_scaledPlanetRadius);
|
||||||
|
|
||||||
|
// Ozone distribution curve by Sergeant Sarcasm - https://www.desmos.com/calculator/j0wozszdwa
|
||||||
|
float ozone = exp(-max(0.0, (35000.0 - centerDistance) - sky_planetRadius) * (1.0 / 5000.0))
|
||||||
|
* exp(-max(0.0, (centerDistance - 35000.0) - sky_planetRadius) * (1.0 / 15000.0));
|
||||||
|
return vec3(rayleighMie, ozone);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 sky_airmass(vec3 position, vec3 direction, float rayLength, const float steps) {
|
||||||
|
float stepSize = rayLength * (1.0 / steps);
|
||||||
|
vec3 increment = direction * stepSize;
|
||||||
|
position += increment * 0.5;
|
||||||
|
|
||||||
|
vec3 airmass = vec3(0.0);
|
||||||
|
for (int i = 0; i < steps; ++i, position += increment) {
|
||||||
|
airmass += sky_density(length(position));
|
||||||
|
}
|
||||||
|
|
||||||
|
return airmass * stepSize;
|
||||||
|
}
|
||||||
|
vec3 sky_airmass(vec3 position, vec3 direction, const float steps) {
|
||||||
|
float rayLength = dot(position, direction);
|
||||||
|
rayLength = rayLength * rayLength + sky_atmosphereRadiusSquared - dot(position, position);
|
||||||
|
if (rayLength < 0.0) return vec3(0.0);
|
||||||
|
rayLength = sqrt(rayLength) - dot(position, direction);
|
||||||
|
|
||||||
|
return sky_airmass(position, direction, rayLength, steps);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 sky_opticalDepth(vec3 position, vec3 direction, float rayLength, const float steps) {
|
||||||
|
return sky_coefficientsAttenuation * sky_airmass(position, direction, rayLength, steps);
|
||||||
|
}
|
||||||
|
vec3 sky_opticalDepth(vec3 position, vec3 direction, const float steps) {
|
||||||
|
return sky_coefficientsAttenuation * sky_airmass(position, direction, steps);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 sky_transmittance(vec3 position, vec3 direction, const float steps) {
|
||||||
|
return exp(-sky_opticalDepth(position, direction, steps) * rLOG2);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
vec3 calculateAtmosphere(vec3 background, vec3 viewVector, vec3 upVector, vec3 sunVector, vec3 moonVector, out vec2 pid, out vec3 transmittance, const int iSteps, float noise) {
|
||||||
|
const int jSteps = 4;
|
||||||
|
|
||||||
|
#ifdef SKY_GROUND
|
||||||
|
float planetGround = exp(-100 * pow(max(-viewVector.y*5 + 0.1,0.0),2)); // darken the ground in the sky.
|
||||||
|
#else
|
||||||
|
float planetGround = pow(clamp(viewVector.y+1.0,0.0,1.0),2); // darken the ground in the sky.
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float GroundDarkening = max(planetGround * 0.7+0.3,clamp(sunVector.y*2.0,0.0,1.0));
|
||||||
|
|
||||||
|
vec3 viewPos = (sky_planetRadius + eyeAltitude) * upVector;
|
||||||
|
|
||||||
|
vec2 aid = rsi(viewPos, viewVector, sky_atmosphereRadius);
|
||||||
|
if (aid.y < 0.0) {transmittance = vec3(1.0); return vec3(0.0);}
|
||||||
|
|
||||||
|
pid = rsi(viewPos, viewVector, sky_planetRadius * 0.998);
|
||||||
|
bool planetIntersected = pid.y >= 0.0;
|
||||||
|
|
||||||
|
vec2 sd = vec2((planetIntersected && pid.x < 0.0) ? pid.y : max(aid.x, 0.0), (planetIntersected && pid.x > 0.0) ? pid.x : aid.y);
|
||||||
|
|
||||||
|
float stepSize = (sd.y - sd.x) * (1.0 / iSteps);
|
||||||
|
vec3 increment = viewVector * stepSize;
|
||||||
|
vec3 position = viewVector * sd.x + viewPos;
|
||||||
|
position += increment * (0.34*noise);
|
||||||
|
|
||||||
|
vec2 phaseSun = sky_phase(dot(viewVector, sunVector), 0.8);
|
||||||
|
vec2 phaseMoon = sky_phase(dot(viewVector, moonVector), 0.8);
|
||||||
|
|
||||||
|
vec3 scatteringSun = vec3(0.0);
|
||||||
|
vec3 scatteringMoon = vec3(0.0);
|
||||||
|
vec3 scatteringAmbient = vec3(0.0);
|
||||||
|
|
||||||
|
transmittance = vec3(1.0);
|
||||||
|
|
||||||
|
float high_sun = clamp(pow(sunVector.y+0.6,5),0.0,1.0) * 3.0; // make sunrise less blue, and allow sunset to be bluer
|
||||||
|
float low_sun = clamp(((1.0-abs(sunVector.y))*3.) - high_sun,1.0,2.0) ;
|
||||||
|
|
||||||
|
|
||||||
|
for (int i = 0; i < iSteps; ++i, position += increment) {
|
||||||
|
vec3 density = sky_density(length(position));
|
||||||
|
if (density.y > 1e35) break;
|
||||||
|
vec3 stepAirmass = density * stepSize ;
|
||||||
|
vec3 stepOpticalDepth = sky_coefficientsAttenuation * stepAirmass ;
|
||||||
|
|
||||||
|
vec3 stepTransmittance = exp2(-stepOpticalDepth * rLOG2);
|
||||||
|
vec3 stepTransmittedFraction = clamp01((stepTransmittance - 1.0) / -stepOpticalDepth) ;
|
||||||
|
vec3 stepScatteringVisible = transmittance * stepTransmittedFraction * GroundDarkening ;
|
||||||
|
|
||||||
|
#ifdef ORIGINAL_CHOCAPIC_SKY
|
||||||
|
scatteringSun += sky_coefficientsScattering * (stepAirmass.xy * phaseSun) * stepScatteringVisible * sky_transmittance(position, sunVector, jSteps) * planetGround;
|
||||||
|
#else
|
||||||
|
scatteringSun += sky_coefficientsScattering * (stepAirmass.xy * phaseSun) * stepScatteringVisible * sky_transmittance(position, sunVector*0.5+0.1, jSteps) * planetGround;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
scatteringMoon += sky_coefficientsScattering * (stepAirmass.xy * phaseMoon) * stepScatteringVisible * sky_transmittance(position, moonVector, jSteps) * planetGround;
|
||||||
|
|
||||||
|
// Nice way to fake multiple scattering.
|
||||||
|
#ifdef ORIGINAL_CHOCAPIC_SKY
|
||||||
|
scatteringAmbient += sky_coefficientsScattering * stepAirmass.xy * stepScatteringVisible;
|
||||||
|
#else
|
||||||
|
scatteringAmbient += sky_coefficientsScattering * stepAirmass.xy * stepScatteringVisible * low_sun;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
transmittance *= stepTransmittance;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 scattering = scatteringSun * sunColorBase + scatteringAmbient * background + scatteringMoon*moonColorBase ;
|
||||||
|
|
||||||
|
return scattering;
|
||||||
|
}
|
|
@ -0,0 +1,79 @@
|
||||||
|
const float k = 1.8;
|
||||||
|
const float d0 = 0.04 + max(64.0 - shadowDistance, 0.0)/64.0 * 0.26;
|
||||||
|
const float d1 = 0.61;
|
||||||
|
float a = exp(d0);
|
||||||
|
float b = (exp(d1)-a)*150./128.0;
|
||||||
|
|
||||||
|
vec4 BiasShadowProjection(in vec4 projectedShadowSpacePosition) {
|
||||||
|
|
||||||
|
float distortFactor = log(length(projectedShadowSpacePosition.xy)*b+a)*k;
|
||||||
|
projectedShadowSpacePosition.xy /= distortFactor;
|
||||||
|
return projectedShadowSpacePosition;
|
||||||
|
}
|
||||||
|
|
||||||
|
float calcDistort(vec2 worldpos){
|
||||||
|
return 1.0/(log(length(worldpos)*b+a)*k);
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform float far;
|
||||||
|
|
||||||
|
/*
|
||||||
|
mat4 BuildOrthoProjectionMatrix(const in float width, const in float height, const in float zNear, const in float zFar) {
|
||||||
|
return mat4(
|
||||||
|
vec4(2.0 / width, 0.0, 0.0, 0.0),
|
||||||
|
vec4(0.0, 2.0 / height, 0.0, 0.0),
|
||||||
|
vec4(0.0, 0.0, -2.0 / (zFar - zNear), 0.0),
|
||||||
|
vec4(0.0, 0.0, -(zFar + zNear)/(zFar - zNear), 1.0));
|
||||||
|
}
|
||||||
|
|
||||||
|
mat4 BuildTranslationMatrix(const in vec3 delta) {
|
||||||
|
return mat4(
|
||||||
|
vec4(1.0, 0.0, 0.0, 0.0),
|
||||||
|
vec4(0.0, 1.0, 0.0, 0.0),
|
||||||
|
vec4(0.0, 0.0, 1.0, 0.0),
|
||||||
|
vec4(delta, 1.0));
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform vec3 CamPos;
|
||||||
|
|
||||||
|
// vec3 LightDir = vec3(1.0, 0.5, 1.0);
|
||||||
|
|
||||||
|
float rate = frameTimeCounter;
|
||||||
|
vec3 LightDir = vec3(sin(rate), 0.3, cos(rate));
|
||||||
|
// vec3 LightDir = vec3(cos(rate),sin(rate),cos(rate));
|
||||||
|
|
||||||
|
const float shadowIntervalSize = 2.0f;
|
||||||
|
vec3 GetShadowIntervalOffset() {
|
||||||
|
return fract(CamPos / shadowIntervalSize) * shadowIntervalSize - vec3(3,0,1);
|
||||||
|
}
|
||||||
|
|
||||||
|
mat4 BuildShadowViewMatrix(const in vec3 localLightDir) {
|
||||||
|
const vec3 worldUp = vec3(1, 0, 0);
|
||||||
|
|
||||||
|
vec3 zaxis = localLightDir;
|
||||||
|
|
||||||
|
// float check = localLightDir.y;
|
||||||
|
// if(check < 0.0) zaxis.y = -zaxis.y;
|
||||||
|
|
||||||
|
vec3 xaxis = normalize(cross(worldUp, zaxis));
|
||||||
|
vec3 yaxis = normalize(cross(zaxis, xaxis));
|
||||||
|
|
||||||
|
mat4 shadowModelViewEx = mat4(1.0);
|
||||||
|
shadowModelViewEx[0].xyz = vec3(xaxis.x, yaxis.x, zaxis.x);
|
||||||
|
shadowModelViewEx[1].xyz = vec3(xaxis.y, yaxis.y, zaxis.y);
|
||||||
|
shadowModelViewEx[2].xyz = vec3(xaxis.z, yaxis.z, zaxis.z);
|
||||||
|
|
||||||
|
vec3 intervalOffset = GetShadowIntervalOffset();
|
||||||
|
mat4 translation = BuildTranslationMatrix(intervalOffset);
|
||||||
|
|
||||||
|
return shadowModelViewEx * translation;
|
||||||
|
}
|
||||||
|
|
||||||
|
mat4 BuildShadowProjectionMatrix() {
|
||||||
|
float maxDist = min(shadowDistance, far);
|
||||||
|
return BuildOrthoProjectionMatrix(maxDist, maxDist, -far, far);
|
||||||
|
}
|
||||||
|
|
||||||
|
// mat4 Custom_ViewMatrix = BuildShadowViewMatrix(LightDir);
|
||||||
|
// mat4 Custom_ProjectionMatrix = BuildShadowProjectionMatrix();
|
||||||
|
*/
|
|
@ -0,0 +1,34 @@
|
||||||
|
// Emin's and Gri's combined ideas to stop peter panning and light leaking, also has little shadowacne so thats nice
|
||||||
|
// https://www.complementary.dev/reimagined
|
||||||
|
// https://github.com/gri573
|
||||||
|
void GriAndEminShadowFix(
|
||||||
|
inout vec3 WorldPos,
|
||||||
|
vec3 FlatNormal,
|
||||||
|
float VanillaAO,
|
||||||
|
float SkyLightmap
|
||||||
|
){
|
||||||
|
|
||||||
|
float minvalue = 0.007;
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS_SHADOWMAP
|
||||||
|
minvalue = 0.035;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// float DistanceOffset = clamp(0.17 + length(WorldPos) / (shadowMapResolution*0.20), 0.0,1.0) ;
|
||||||
|
// float DistanceOffset = clamp(0.17 + length(WorldPos) / (shadowMapResolution*0.20), 0.0,1.0) ;
|
||||||
|
float shadowResScale = (2048.0/shadowMapResolution) / 4.0;
|
||||||
|
float DistanceOffset = (length(WorldPos)+4.0) * (minvalue + shadowResScale*0.015);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
vec3 Bias = FlatNormal * DistanceOffset; // adjust the bias thingy's strength as it gets farther away.
|
||||||
|
|
||||||
|
vec3 finalBias = Bias;
|
||||||
|
|
||||||
|
// stop lightleaking by zooming up, centered on blocks
|
||||||
|
vec2 scale = vec2(0.5); scale.y *= 0.5;
|
||||||
|
vec3 zoomShadow = scale.y - scale.x * fract(WorldPos + cameraPosition + Bias*scale.y);
|
||||||
|
if(SkyLightmap < 0.1) finalBias = mix(Bias, zoomShadow, clamp(VanillaAO*5,0,1));
|
||||||
|
|
||||||
|
WorldPos += finalBias;
|
||||||
|
}
|
|
@ -0,0 +1,201 @@
|
||||||
|
#define BLOCK_WATER 8
|
||||||
|
#define BLOCK_BAMBOO 11
|
||||||
|
#define BLOCK_GRASS_SHORT 12
|
||||||
|
#define BLOCK_GRASS_TALL_LOWER 13
|
||||||
|
#define BLOCK_GRASS_TALL_UPPER 14
|
||||||
|
#define BLOCK_SAPLING 15
|
||||||
|
#define BLOCK_VINE 16
|
||||||
|
#define BLOCK_GROUND_WAVING 60
|
||||||
|
#define BLOCK_GROUND_WAVING_VERTICAL 61
|
||||||
|
#define BLOCK_AIR_WAVING 62
|
||||||
|
#define BLOCK_SSS_STRONG 80
|
||||||
|
#define BLOCK_SSS_WEAK 81
|
||||||
|
#define BLOCK_SSS_WEAK_2 82
|
||||||
|
#define BLOCK_SSS_WEAK_3 83
|
||||||
|
#define BLOCK_SSS_WEIRD 84
|
||||||
|
#define BLOCK_GRASS 85
|
||||||
|
#define BLOCK_AMETHYST_BUD_LARGE 101
|
||||||
|
#define BLOCK_AMETHYST_BUD_MEDIUM 102
|
||||||
|
#define BLOCK_AMETHYST_CLUSTER 103
|
||||||
|
#define BLOCK_BEACON 104
|
||||||
|
#define BLOCK_BREWING_STAND 105
|
||||||
|
#define BLOCK_CANDLES_PLAIN_LIT_1 106
|
||||||
|
#define BLOCK_CANDLES_PLAIN_LIT_2 107
|
||||||
|
#define BLOCK_CANDLES_PLAIN_LIT_3 108
|
||||||
|
#define BLOCK_CANDLES_PLAIN_LIT_4 109
|
||||||
|
#define BLOCK_CANDLES_BLACK_LIT_1 110
|
||||||
|
#define BLOCK_CANDLES_BLACK_LIT_2 111
|
||||||
|
#define BLOCK_CANDLES_BLACK_LIT_3 112
|
||||||
|
#define BLOCK_CANDLES_BLACK_LIT_4 113
|
||||||
|
#define BLOCK_CANDLES_BLUE_LIT_1 114
|
||||||
|
#define BLOCK_CANDLES_BLUE_LIT_2 115
|
||||||
|
#define BLOCK_CANDLES_BLUE_LIT_3 116
|
||||||
|
#define BLOCK_CANDLES_BLUE_LIT_4 117
|
||||||
|
#define BLOCK_CANDLES_BROWN_LIT_1 118
|
||||||
|
#define BLOCK_CANDLES_BROWN_LIT_2 119
|
||||||
|
#define BLOCK_CANDLES_BROWN_LIT_3 120
|
||||||
|
#define BLOCK_CANDLES_BROWN_LIT_4 121
|
||||||
|
#define BLOCK_CANDLES_CYAN_LIT_1 122
|
||||||
|
#define BLOCK_CANDLES_CYAN_LIT_2 123
|
||||||
|
#define BLOCK_CANDLES_CYAN_LIT_3 124
|
||||||
|
#define BLOCK_CANDLES_CYAN_LIT_4 125
|
||||||
|
#define BLOCK_CANDLES_GRAY_LIT_1 126
|
||||||
|
#define BLOCK_CANDLES_GRAY_LIT_2 127
|
||||||
|
#define BLOCK_CANDLES_GRAY_LIT_3 128
|
||||||
|
#define BLOCK_CANDLES_GRAY_LIT_4 129
|
||||||
|
#define BLOCK_CANDLES_GREEN_LIT_1 130
|
||||||
|
#define BLOCK_CANDLES_GREEN_LIT_2 131
|
||||||
|
#define BLOCK_CANDLES_GREEN_LIT_3 132
|
||||||
|
#define BLOCK_CANDLES_GREEN_LIT_4 133
|
||||||
|
#define BLOCK_CANDLES_LIGHT_BLUE_LIT_1 134
|
||||||
|
#define BLOCK_CANDLES_LIGHT_BLUE_LIT_2 135
|
||||||
|
#define BLOCK_CANDLES_LIGHT_BLUE_LIT_3 136
|
||||||
|
#define BLOCK_CANDLES_LIGHT_BLUE_LIT_4 137
|
||||||
|
#define BLOCK_CANDLES_LIGHT_GRAY_LIT_1 138
|
||||||
|
#define BLOCK_CANDLES_LIGHT_GRAY_LIT_2 139
|
||||||
|
#define BLOCK_CANDLES_LIGHT_GRAY_LIT_3 140
|
||||||
|
#define BLOCK_CANDLES_LIGHT_GRAY_LIT_4 141
|
||||||
|
#define BLOCK_CANDLES_LIME_LIT_1 142
|
||||||
|
#define BLOCK_CANDLES_LIME_LIT_2 143
|
||||||
|
#define BLOCK_CANDLES_LIME_LIT_3 144
|
||||||
|
#define BLOCK_CANDLES_LIME_LIT_4 145
|
||||||
|
#define BLOCK_CANDLES_MAGENTA_LIT_1 146
|
||||||
|
#define BLOCK_CANDLES_MAGENTA_LIT_2 147
|
||||||
|
#define BLOCK_CANDLES_MAGENTA_LIT_3 148
|
||||||
|
#define BLOCK_CANDLES_MAGENTA_LIT_4 149
|
||||||
|
#define BLOCK_CANDLES_ORANGE_LIT_1 150
|
||||||
|
#define BLOCK_CANDLES_ORANGE_LIT_2 151
|
||||||
|
#define BLOCK_CANDLES_ORANGE_LIT_3 152
|
||||||
|
#define BLOCK_CANDLES_ORANGE_LIT_4 153
|
||||||
|
#define BLOCK_CANDLES_PINK_LIT_1 154
|
||||||
|
#define BLOCK_CANDLES_PINK_LIT_2 155
|
||||||
|
#define BLOCK_CANDLES_PINK_LIT_3 156
|
||||||
|
#define BLOCK_CANDLES_PINK_LIT_4 157
|
||||||
|
#define BLOCK_CANDLES_PURPLE_LIT_1 158
|
||||||
|
#define BLOCK_CANDLES_PURPLE_LIT_2 159
|
||||||
|
#define BLOCK_CANDLES_PURPLE_LIT_3 160
|
||||||
|
#define BLOCK_CANDLES_PURPLE_LIT_4 161
|
||||||
|
#define BLOCK_CANDLES_RED_LIT_1 162
|
||||||
|
#define BLOCK_CANDLES_RED_LIT_2 163
|
||||||
|
#define BLOCK_CANDLES_RED_LIT_3 164
|
||||||
|
#define BLOCK_CANDLES_RED_LIT_4 165
|
||||||
|
#define BLOCK_CANDLES_WHITE_LIT_1 166
|
||||||
|
#define BLOCK_CANDLES_WHITE_LIT_2 167
|
||||||
|
#define BLOCK_CANDLES_WHITE_LIT_3 168
|
||||||
|
#define BLOCK_CANDLES_WHITE_LIT_4 169
|
||||||
|
#define BLOCK_CANDLES_YELLOW_LIT_1 170
|
||||||
|
#define BLOCK_CANDLES_YELLOW_LIT_2 171
|
||||||
|
#define BLOCK_CANDLES_YELLOW_LIT_3 172
|
||||||
|
#define BLOCK_CANDLES_YELLOW_LIT_4 173
|
||||||
|
#define BLOCK_CANDLES_LIT_1 174
|
||||||
|
#define BLOCK_CANDLES_LIT_2 175
|
||||||
|
#define BLOCK_CANDLES_LIT_3 176
|
||||||
|
#define BLOCK_CANDLES_LIT_4 177
|
||||||
|
#define BLOCK_CAVE_VINE_BERRIES 178
|
||||||
|
#define BLOCK_COMPARATOR_LIT 179
|
||||||
|
#define BLOCK_COPPER_BULB_LIT 180
|
||||||
|
#define BLOCK_COPPER_BULB_EXPOSED_LIT 181
|
||||||
|
#define BLOCK_COPPER_BULB_OXIDIZED_LIT 182
|
||||||
|
#define BLOCK_COPPER_BULB_WEATHERED_LIT 183
|
||||||
|
#define BLOCK_CONDUIT 184
|
||||||
|
#define BLOCK_CRYING_OBSIDIAN 185
|
||||||
|
#define BLOCK_END_GATEWAY 186
|
||||||
|
#define BLOCK_END_ROD 187
|
||||||
|
#define BLOCK_FIRE 188
|
||||||
|
#define BLOCK_FROGLIGHT_OCHRE 189
|
||||||
|
#define BLOCK_FROGLIGHT_PEARLESCENT 190
|
||||||
|
#define BLOCK_FROGLIGHT_VERDANT 191
|
||||||
|
#define BLOCK_FURNACE_LIT 192
|
||||||
|
#define BLOCK_GLOW_LICHEN 193
|
||||||
|
#define BLOCK_GLOWSTONE 194
|
||||||
|
#define BLOCK_JACK_O_LANTERN 195
|
||||||
|
#define BLOCK_LANTERN 196
|
||||||
|
#define BLOCK_LAVA 197
|
||||||
|
#define BLOCK_LIGHT_1 198
|
||||||
|
#define BLOCK_LIGHT_2 199
|
||||||
|
#define BLOCK_LIGHT_3 200
|
||||||
|
#define BLOCK_LIGHT_4 201
|
||||||
|
#define BLOCK_LIGHT_5 202
|
||||||
|
#define BLOCK_LIGHT_6 203
|
||||||
|
#define BLOCK_LIGHT_7 204
|
||||||
|
#define BLOCK_LIGHT_8 205
|
||||||
|
#define BLOCK_LIGHT_9 206
|
||||||
|
#define BLOCK_LIGHT_10 207
|
||||||
|
#define BLOCK_LIGHT_11 208
|
||||||
|
#define BLOCK_LIGHT_12 209
|
||||||
|
#define BLOCK_LIGHT_13 210
|
||||||
|
#define BLOCK_LIGHT_14 211
|
||||||
|
#define BLOCK_LIGHT_15 212
|
||||||
|
#define BLOCK_MAGMA 213
|
||||||
|
#define BLOCK_REDSTONE_LAMP_LIT 214
|
||||||
|
#define BLOCK_REDSTONE_TORCH_LIT 215
|
||||||
|
#define BLOCK_REDSTONE_WIRE_1 216
|
||||||
|
#define BLOCK_REDSTONE_WIRE_2 217
|
||||||
|
#define BLOCK_REDSTONE_WIRE_3 218
|
||||||
|
#define BLOCK_REDSTONE_WIRE_4 219
|
||||||
|
#define BLOCK_REDSTONE_WIRE_5 220
|
||||||
|
#define BLOCK_REDSTONE_WIRE_6 221
|
||||||
|
#define BLOCK_REDSTONE_WIRE_7 222
|
||||||
|
#define BLOCK_REDSTONE_WIRE_8 223
|
||||||
|
#define BLOCK_REDSTONE_WIRE_9 224
|
||||||
|
#define BLOCK_REDSTONE_WIRE_10 225
|
||||||
|
#define BLOCK_REDSTONE_WIRE_11 226
|
||||||
|
#define BLOCK_REDSTONE_WIRE_12 227
|
||||||
|
#define BLOCK_REDSTONE_WIRE_13 228
|
||||||
|
#define BLOCK_REDSTONE_WIRE_14 229
|
||||||
|
#define BLOCK_REDSTONE_WIRE_15 230
|
||||||
|
#define BLOCK_REPEATER_LIT 231
|
||||||
|
#define BLOCK_RESPAWN_ANCHOR_4 232
|
||||||
|
#define BLOCK_SCULK_SENSOR_ACTIVE 233
|
||||||
|
#define BLOCK_SEA_PICKLE_WET_1 234
|
||||||
|
#define BLOCK_SEA_PICKLE_WET_2 235
|
||||||
|
#define BLOCK_SEA_PICKLE_WET_3 236
|
||||||
|
#define BLOCK_SEA_PICKLE_WET_4 237
|
||||||
|
#define BLOCK_SEA_LANTERN 238
|
||||||
|
#define BLOCK_SHROOMLIGHT 239
|
||||||
|
#define BLOCK_SOUL_FIRE 240
|
||||||
|
#define BLOCK_SOUL_LANTERN 241
|
||||||
|
#define BLOCK_SOUL_TORCH 242
|
||||||
|
#define BLOCK_TORCH 243
|
||||||
|
#define BLOCK_GLASS 301
|
||||||
|
#define BLOCK_HONEY 302
|
||||||
|
#define BLOCK_ICE 303
|
||||||
|
#define BLOCK_NETHER_PORTAL 304
|
||||||
|
#define BLOCK_SLIME 305
|
||||||
|
#define BLOCK_GLASS_BLACK 306
|
||||||
|
#define BLOCK_GLASS_BLUE 307
|
||||||
|
#define BLOCK_GLASS_BROWN 308
|
||||||
|
#define BLOCK_GLASS_CYAN 309
|
||||||
|
#define BLOCK_GLASS_GRAY 310
|
||||||
|
#define BLOCK_GLASS_GREEN 311
|
||||||
|
#define BLOCK_GLASS_LIGHT_BLUE 312
|
||||||
|
#define BLOCK_GLASS_LIGHT_GRAY 313
|
||||||
|
#define BLOCK_GLASS_LIME 314
|
||||||
|
#define BLOCK_GLASS_MAGENTA 315
|
||||||
|
#define BLOCK_GLASS_ORANGE 316
|
||||||
|
#define BLOCK_GLASS_PINK 317
|
||||||
|
#define BLOCK_GLASS_PURPLE 318
|
||||||
|
#define BLOCK_GLASS_RED 319
|
||||||
|
#define BLOCK_GLASS_WHITE 320
|
||||||
|
#define BLOCK_GLASS_YELLOW 321
|
||||||
|
#define BLOCK_LPV_IGNORE 401
|
||||||
|
#define BLOCK_CARPET 402
|
||||||
|
#define BLOCK_DOOR_N 403
|
||||||
|
#define BLOCK_DOOR_E 404
|
||||||
|
#define BLOCK_DOOR_S 405
|
||||||
|
#define BLOCK_DOOR_W 406
|
||||||
|
#define BLOCK_FENCE 407
|
||||||
|
#define BLOCK_FENCE_GATE 408
|
||||||
|
#define BLOCK_FLOWER_POT 409
|
||||||
|
#define BLOCK_IRON_BARS 410
|
||||||
|
#define BLOCK_PRESSURE_PLATE 411
|
||||||
|
#define BLOCK_SLAB_TOP 412
|
||||||
|
#define BLOCK_SLAB_BOTTOM 413
|
||||||
|
#define BLOCK_TRAPDOOR_BOTTOM 414
|
||||||
|
#define BLOCK_TRAPDOOR_TOP 415
|
||||||
|
#define BLOCK_TRAPDOOR_N 416
|
||||||
|
#define BLOCK_TRAPDOOR_E 417
|
||||||
|
#define BLOCK_TRAPDOOR_S 418
|
||||||
|
#define BLOCK_TRAPDOOR_W 419
|
||||||
|
#define BLOCK_END_PORTAL 500
|
||||||
|
#define BLOCK_SIGN 501
|
|
@ -0,0 +1,474 @@
|
||||||
|
#if DOF_QUALITY == 0 // Original choc hex bokeh
|
||||||
|
#define BOKEH_SAMPLES 60
|
||||||
|
#define HEXAGONAL_BOKEH
|
||||||
|
const vec2 bokeh_offsets[60] = vec2[60] (
|
||||||
|
vec2( 0.2165, 0.1250 ),
|
||||||
|
vec2( 0.0000, 0.2500 ),
|
||||||
|
vec2( -0.2165, 0.1250 ),
|
||||||
|
vec2( -0.2165, -0.1250 ),
|
||||||
|
vec2( -0.0000, -0.2500 ),
|
||||||
|
vec2( 0.2165, -0.1250 ),
|
||||||
|
vec2( 0.4330, 0.2500 ),
|
||||||
|
vec2( 0.0000, 0.5000 ),
|
||||||
|
vec2( -0.4330, 0.2500 ),
|
||||||
|
vec2( -0.4330, -0.2500 ),
|
||||||
|
vec2( -0.0000, -0.5000 ),
|
||||||
|
vec2( 0.4330, -0.2500 ),
|
||||||
|
vec2( 0.6495, 0.3750 ),
|
||||||
|
vec2( 0.0000, 0.7500 ),
|
||||||
|
vec2( -0.6495, 0.3750 ),
|
||||||
|
vec2( -0.6495, -0.3750 ),
|
||||||
|
vec2( -0.0000, -0.7500 ),
|
||||||
|
vec2( 0.6495, -0.3750 ),
|
||||||
|
vec2( 0.8660, 0.5000 ),
|
||||||
|
vec2( 0.0000, 1.0000 ),
|
||||||
|
vec2( -0.8660, 0.5000 ),
|
||||||
|
vec2( -0.8660, -0.5000 ),
|
||||||
|
vec2( -0.0000, -1.0000 ),
|
||||||
|
vec2( 0.8660, -0.5000 ),
|
||||||
|
vec2( 0.2163, 0.3754 ),
|
||||||
|
vec2( -0.2170, 0.3750 ),
|
||||||
|
vec2( -0.4333, -0.0004 ),
|
||||||
|
vec2( -0.2163, -0.3754 ),
|
||||||
|
vec2( 0.2170, -0.3750 ),
|
||||||
|
vec2( 0.4333, 0.0004 ),
|
||||||
|
vec2( 0.4328, 0.5004 ),
|
||||||
|
vec2( -0.2170, 0.6250 ),
|
||||||
|
vec2( -0.6498, 0.1246 ),
|
||||||
|
vec2( -0.4328, -0.5004 ),
|
||||||
|
vec2( 0.2170, -0.6250 ),
|
||||||
|
vec2( 0.6498, -0.1246 ),
|
||||||
|
vec2( 0.6493, 0.6254 ),
|
||||||
|
vec2( -0.2170, 0.8750 ),
|
||||||
|
vec2( -0.8663, 0.2496 ),
|
||||||
|
vec2( -0.6493, -0.6254 ),
|
||||||
|
vec2( 0.2170, -0.8750 ),
|
||||||
|
vec2( 0.8663, -0.2496 ),
|
||||||
|
vec2( 0.2160, 0.6259 ),
|
||||||
|
vec2( -0.4340, 0.5000 ),
|
||||||
|
vec2( -0.6500, -0.1259 ),
|
||||||
|
vec2( -0.2160, -0.6259 ),
|
||||||
|
vec2( 0.4340, -0.5000 ),
|
||||||
|
vec2( 0.6500, 0.1259 ),
|
||||||
|
vec2( 0.4325, 0.7509 ),
|
||||||
|
vec2( -0.4340, 0.7500 ),
|
||||||
|
vec2( -0.8665, -0.0009 ),
|
||||||
|
vec2( -0.4325, -0.7509 ),
|
||||||
|
vec2( 0.4340, -0.7500 ),
|
||||||
|
vec2( 0.8665, 0.0009 ),
|
||||||
|
vec2( 0.2158, 0.8763 ),
|
||||||
|
vec2( -0.6510, 0.6250 ),
|
||||||
|
vec2( -0.8668, -0.2513 ),
|
||||||
|
vec2( -0.2158, -0.8763 ),
|
||||||
|
vec2( 0.6510, -0.6250 ),
|
||||||
|
vec2( 0.8668, 0.2513 ));
|
||||||
|
|
||||||
|
#elif DOF_QUALITY == 1 // Low quality bokeh
|
||||||
|
#define BOKEH_SAMPLES 32
|
||||||
|
const vec2 bokeh_offsets[32] = vec2[32](
|
||||||
|
vec2(0.12064426510477419, 0.015554431411765697),
|
||||||
|
vec2(-0.16400077998918963, 0.16180237012184204),
|
||||||
|
vec2(0.020080498035937415, -0.2628838391620438),
|
||||||
|
vec2(0.19686650437195816, 0.27801320993574674),
|
||||||
|
vec2(-0.37362329188851157, -0.049763799980476156),
|
||||||
|
vec2(0.34544673107582735, -0.20696126421568928),
|
||||||
|
vec2(-0.12135781397691386, 0.4507963336805642),
|
||||||
|
vec2(-0.22749138875333694, -0.41407969197383454),
|
||||||
|
vec2(0.4797593802468298, 0.19235249500691445),
|
||||||
|
vec2(-0.5079968434096749, 0.22345015963708734),
|
||||||
|
vec2(0.23843255951864029, -0.5032700515259672),
|
||||||
|
vec2(0.17505863904522073, 0.587555727235086),
|
||||||
|
vec2(-0.5451127409909945, -0.29782530685850084),
|
||||||
|
vec2(0.6300137885218894, -0.12390992876509886),
|
||||||
|
vec2(-0.391501580064061, 0.5662295575692019),
|
||||||
|
vec2(-0.09379538975841809, -0.6746452122696498),
|
||||||
|
vec2(0.5447160222309757, 0.47831268960533435),
|
||||||
|
vec2(-0.7432342062047558, 0.04610937594275518),
|
||||||
|
vec2(0.5345993903170301, -0.520777903066999),
|
||||||
|
vec2(-0.0404139208253129, 0.7953459466435174),
|
||||||
|
vec2(-0.517173266802963, -0.5989723613060595),
|
||||||
|
vec2(0.8080038585189984, 0.12485626574164435),
|
||||||
|
vec2(-0.6926663754026566, 0.494463047083117),
|
||||||
|
vec2(0.183730322451809, -0.8205069509230769),
|
||||||
|
vec2(0.43067753069940745, 0.7747454863024757),
|
||||||
|
vec2(-0.8548041452377114, -0.25576180722119723),
|
||||||
|
vec2(0.8217466662308877, -0.3661258311820314),
|
||||||
|
vec2(-0.36224393661662146, 0.87070999332353),
|
||||||
|
vec2(-0.32376306917956177, -0.8724793262829371),
|
||||||
|
vec2(0.8455529005007657, 0.46224259051084376),
|
||||||
|
vec2(-0.9483903811252437, 0.2643989345002705),
|
||||||
|
vec2(0.5322400733549763, -0.818975339518135)
|
||||||
|
);
|
||||||
|
#elif DOF_QUALITY == 2 // Medium quality bokeh
|
||||||
|
#define BOKEH_SAMPLES 64
|
||||||
|
const vec2 bokeh_offsets[64] = vec2[64](
|
||||||
|
vec2(0.07966914016126773, -0.0005732549414365655),
|
||||||
|
vec2(-0.12160530145582471, 0.10283965425501301),
|
||||||
|
vec2(0.008559818525228833, -0.197458844206032),
|
||||||
|
vec2(0.13356640242431705, 0.18501312713480866),
|
||||||
|
vec2(-0.269830801109193, -0.04676021929400281),
|
||||||
|
vec2(0.23862848827685754, -0.15791561224005177),
|
||||||
|
vec2(-0.09145217101863704, 0.3071892456093635),
|
||||||
|
vec2(-0.16649994145461533, -0.30437045701653237),
|
||||||
|
vec2(0.33360187330480306, 0.12444185472734362),
|
||||||
|
vec2(-0.3648472506019276, 0.14643122426640393),
|
||||||
|
vec2(0.16295804188571, -0.36743756507231173),
|
||||||
|
vec2(0.11814591296857804, 0.40389274018272564),
|
||||||
|
vec2(-0.39109215347150406, -0.22216619295880746),
|
||||||
|
vec2(0.43984778429926974, -0.0991894497563406),
|
||||||
|
vec2(-0.2824726599141313, 0.38881286099524415),
|
||||||
|
vec2(-0.07196259394779835, -0.48861810336110434),
|
||||||
|
vec2(0.3795331553348995, 0.3266462474773111),
|
||||||
|
vec2(-0.5311851850227693, 0.021032353535204915),
|
||||||
|
vec2(0.3723796163057802, -0.3798174856209827),
|
||||||
|
vec2(-0.03421619527550065, 0.5508226133906681),
|
||||||
|
vec2(-0.37133596181036055, -0.43510931729303065),
|
||||||
|
vec2(0.5657057697780938, 0.07671481330934922),
|
||||||
|
vec2(-0.49542832895271105, 0.33806627476843804),
|
||||||
|
vec2(0.12427771910967947, -0.5917579278786026),
|
||||||
|
vec2(0.2988957646566429, 0.536255888187953),
|
||||||
|
vec2(-0.6100770454895419, -0.19242280712483223),
|
||||||
|
vec2(0.5754234023037136, -0.27046195686657265),
|
||||||
|
vec2(-0.2617843818309086, 0.6041130418557645),
|
||||||
|
vec2(-0.2345742995202231, -0.6285079469299325),
|
||||||
|
vec2(0.59225695199046, 0.315282971433257),
|
||||||
|
vec2(-0.6762525075113398, 0.17538638065344198),
|
||||||
|
vec2(0.37071132728294354, -0.5906749150680255),
|
||||||
|
vec2(0.1119798859418661, 0.7017402283731283),
|
||||||
|
vec2(-0.5807270152810202, -0.4435682524557845),
|
||||||
|
vec2(0.7229827225912143, -0.06119326417718071),
|
||||||
|
vec2(-0.5144794788954391, 0.5461387788248901),
|
||||||
|
vec2(-0.005035179534685496, -0.7557546423829214),
|
||||||
|
vec2(0.5055857377426614, 0.5663728829872585),
|
||||||
|
vec2(-0.7810140733390272, -0.07214936952359105),
|
||||||
|
vec2(0.6170681003447506, -0.47552351060683423),
|
||||||
|
vec2(-0.15109977600025168, 0.7820762666899624),
|
||||||
|
vec2(-0.43760314844428994, -0.6821127366950525),
|
||||||
|
vec2(0.7772009255491943, 0.21481487028437787),
|
||||||
|
vec2(-0.742204728724318, 0.3758394044302885),
|
||||||
|
vec2(0.28114246867378123, -0.7824253564882913),
|
||||||
|
vec2(0.3091922614465049, 0.7803683548608),
|
||||||
|
vec2(-0.7789831306606206, -0.36561570268862775),
|
||||||
|
vec2(0.8145440939773348, -0.2543941296975529),
|
||||||
|
vec2(-0.4488757377357506, 0.7504758305912105),
|
||||||
|
vec2(-0.1933624476019976, -0.8604246222601459),
|
||||||
|
vec2(0.7154581485450054, 0.513848417434855),
|
||||||
|
vec2(-0.8988765686147268, 0.11036534262592021),
|
||||||
|
vec2(0.5783350546530844, -0.6902686901177914),
|
||||||
|
vec2(0.024600692161986272, 0.9131155784626814),
|
||||||
|
vec2(-0.6564461645240188, -0.657849672537283),
|
||||||
|
vec2(0.9212949234450745, 0.04697899281368057),
|
||||||
|
vec2(-0.7330423210662792, 0.5978985715758123),
|
||||||
|
vec2(0.12225611512756368, -0.9393399804201348),
|
||||||
|
vec2(0.5334856827883492, 0.7868760176859764),
|
||||||
|
vec2(-0.948368229388031, -0.21678429915641398),
|
||||||
|
vec2(0.8372175428305082, -0.4798472000523386),
|
||||||
|
vec2(-0.31121110469716806, 0.9318623471900049),
|
||||||
|
vec2(-0.41881630178513873, -0.899674402337137),
|
||||||
|
vec2(0.9082566602526256, 0.38845471061254216)
|
||||||
|
);
|
||||||
|
#elif DOF_QUALITY == 3 // High quality bokeh
|
||||||
|
#define BOKEH_SAMPLES 96
|
||||||
|
const vec2 bokeh_offsets[96] = vec2[96](
|
||||||
|
vec2(0.07121012932580298, -0.005700790092752472),
|
||||||
|
vec2(-0.09312976408269022, 0.07873549668993801),
|
||||||
|
vec2(0.013149611337887245, -0.16645720056123525),
|
||||||
|
vec2(0.1152170596849477, 0.14582985633924836),
|
||||||
|
vec2(-0.21415537775596927, -0.043412288570053574),
|
||||||
|
vec2(0.20099989356868228, -0.13417028686218047),
|
||||||
|
vec2(-0.06850983617645874, 0.24558623934474322),
|
||||||
|
vec2(-0.1297860841436839, -0.25375016688247776),
|
||||||
|
vec2(0.2785453377231323, 0.09637361951611127),
|
||||||
|
vec2(-0.29173598389867905, 0.1143278645615103),
|
||||||
|
vec2(0.1392152328130355, -0.30524424497902103),
|
||||||
|
vec2(0.10262628276810476, 0.3245443120276563),
|
||||||
|
vec2(-0.3131648573584685, -0.1866306663416654),
|
||||||
|
vec2(0.3652947607876658, -0.08622057598322416),
|
||||||
|
vec2(-0.22447741224677245, 0.3122316422302745),
|
||||||
|
vec2(-0.052596663134391534, -0.4041877401668016),
|
||||||
|
vec2(0.3160480724583331, 0.2614728148450268),
|
||||||
|
vec2(-0.42755033863187675, 0.011940115357288394),
|
||||||
|
vec2(0.3102072322995241, -0.31535240777916773),
|
||||||
|
vec2(-0.021776857676125607, 0.4445120511380856),
|
||||||
|
vec2(-0.29703399441499195, -0.36049799929262627),
|
||||||
|
vec2(0.4680573756135771, 0.05740465338052286),
|
||||||
|
vec2(-0.3983549879059493, 0.27079722808233325),
|
||||||
|
vec2(0.1076328815172257, -0.4884010542428246),
|
||||||
|
vec2(0.25020791867460324, 0.432618369814755),
|
||||||
|
vec2(-0.4919652729660237, -0.1623452935030104),
|
||||||
|
vec2(0.47599178934545766, -0.22606399244564834),
|
||||||
|
vec2(-0.20758550392653913, 0.4880235037760105),
|
||||||
|
vec2(-0.1853685647531024, -0.5184073191472642),
|
||||||
|
vec2(0.48973632510956305, 0.2521947388069187),
|
||||||
|
vec2(-0.5459973114481342, 0.13796965075175446),
|
||||||
|
vec2(0.3088450800163787, -0.48751677798588744),
|
||||||
|
vec2(0.0975917427828865, 0.5677357677730314),
|
||||||
|
vec2(-0.46800107365064036, -0.3674046909313041),
|
||||||
|
vec2(0.5964734698442213, -0.05519682036954475),
|
||||||
|
vec2(-0.4139101866969282, 0.4406877162294968),
|
||||||
|
vec2(0.002049341904248123, -0.6223038109189813),
|
||||||
|
vec2(0.41896957501138105, 0.45720879309620605),
|
||||||
|
vec2(-0.6315347717590759, -0.06414244292517278),
|
||||||
|
vec2(0.5099945429097319, -0.39349604995429904),
|
||||||
|
vec2(-0.11721190170447472, 0.6333298683840053),
|
||||||
|
vec2(-0.3511409257292949, -0.5621754467118343),
|
||||||
|
vec2(0.6407424471834575, 0.17016287772655794),
|
||||||
|
vec2(-0.59984707457312, 0.3016388593021738),
|
||||||
|
vec2(0.23571241320439879, -0.6440803577969166),
|
||||||
|
vec2(0.25861497309905895, 0.6319353642149682),
|
||||||
|
vec2(-0.6298765140060968, -0.3037567005718222),
|
||||||
|
vec2(0.6712330165260425, -0.21294466649920604),
|
||||||
|
vec2(-0.36034495634397506, 0.6075282203535491),
|
||||||
|
vec2(-0.15171922856817155, -0.707766491614509),
|
||||||
|
vec2(0.5903296808625542, 0.4143227465576124),
|
||||||
|
vec2(-0.7277690961712949, 0.08488019551391128),
|
||||||
|
vec2(0.4783691435335692, -0.5688347547957064),
|
||||||
|
vec2(0.02624692981739339, 0.7403230184135525),
|
||||||
|
vec2(-0.529825500118305, -0.5423647377841855),
|
||||||
|
vec2(0.7583947037976506, 0.033125457614728814),
|
||||||
|
vec2(-0.5923660000472654, 0.48294941004015257),
|
||||||
|
vec2(0.1059822487778383, -0.772200611734827),
|
||||||
|
vec2(0.44174978474925664, 0.6372488486615551),
|
||||||
|
vec2(-0.7681788679771326, -0.18223636845309496),
|
||||||
|
vec2(0.6897458099924982, -0.3970263276035467),
|
||||||
|
vec2(-0.2479422541533022, 0.755629690982855),
|
||||||
|
vec2(-0.33580152966568444, -0.7398138028495373),
|
||||||
|
vec2(0.7477490064797803, 0.31193921366734034),
|
||||||
|
vec2(-0.7736080489368817, 0.26795577022080547),
|
||||||
|
vec2(0.3868886663966537, -0.7349923110069412),
|
||||||
|
vec2(0.2072555967697858, 0.8001249720762448),
|
||||||
|
vec2(-0.7040443194892538, -0.4626423043345493),
|
||||||
|
vec2(0.8322384822401724, -0.1447122942561253),
|
||||||
|
vec2(-0.5252166762643815, 0.664457295558192),
|
||||||
|
vec2(-0.06754632697534207, -0.8600666846898691),
|
||||||
|
vec2(0.6296824993369153, 0.5834370562363421),
|
||||||
|
vec2(-0.869944526760866, -0.014179400625216068),
|
||||||
|
vec2(0.6499749876116837, -0.590431834076035),
|
||||||
|
vec2(-0.08653298327805949, 0.8710652567467342),
|
||||||
|
vec2(-0.5336452473653825, -0.7147165352819029),
|
||||||
|
vec2(0.8765151038515352, 0.15835652829089225),
|
||||||
|
vec2(-0.7637367481190092, 0.46912680629507475),
|
||||||
|
vec2(0.24230314452308632, -0.8766382336302021),
|
||||||
|
vec2(0.41057390183400766, 0.8059431929582904),
|
||||||
|
vec2(-0.8580075067207172, -0.32820494707410347),
|
||||||
|
vec2(0.8541129534247509, -0.3489366841323772),
|
||||||
|
vec2(-0.4020475845121665, 0.8300639316319863),
|
||||||
|
vec2(-0.271383304434805, -0.8982601300128057),
|
||||||
|
vec2(0.806149237823113, 0.4726141519370287),
|
||||||
|
vec2(-0.9246093490373926, 0.18793390244305297),
|
||||||
|
vec2(0.5525228823894455, -0.7768686415915086),
|
||||||
|
vec2(0.11248781322457736, 0.9422381490453825),
|
||||||
|
vec2(-0.7290593513744651, -0.6315956494365766),
|
||||||
|
vec2(0.9641126469581356, -0.03618111342429133),
|
||||||
|
vec2(-0.6958327822205611, 0.6724277225888768),
|
||||||
|
vec2(0.05364990040181975, -0.9804535309203316),
|
||||||
|
vec2(0.6205795080163646, 0.7540570525272473),
|
||||||
|
vec2(-0.9777078995622647, -0.14683634641243257),
|
||||||
|
vec2(0.8189512244871316, -0.564380296276503),
|
||||||
|
vec2(-0.22935101607289898, 0.965189829782074)
|
||||||
|
);
|
||||||
|
#elif DOF_QUALITY == 4 // Ultra quality bokeh
|
||||||
|
#define BOKEH_SAMPLES 128
|
||||||
|
const vec2 bokeh_offsets[128] = vec2[128](
|
||||||
|
vec2(0.0663717288408725, -0.0013834293391071473),
|
||||||
|
vec2(-0.07595079370610941, 0.07174054001593103),
|
||||||
|
vec2(0.016089845306454117, -0.1406025646260119),
|
||||||
|
vec2(0.10448284847446448, 0.12984595992288336),
|
||||||
|
vec2(-0.18076204965577036, -0.03404254503522808),
|
||||||
|
vec2(0.1787729618263991, -0.11264127715283463),
|
||||||
|
vec2(-0.05462931069997152, 0.2162375217952921),
|
||||||
|
vec2(-0.10769609808818306, -0.21620049103190728),
|
||||||
|
vec2(0.24592928641190032, 0.08701560245846723),
|
||||||
|
vec2(-0.24794882541635205, 0.10256443477355368),
|
||||||
|
vec2(0.12526587604780554, -0.26079567080797356),
|
||||||
|
vec2(0.09357891581109577, 0.284617218572553),
|
||||||
|
vec2(-0.26650677420701185, -0.15807329847424043),
|
||||||
|
vec2(0.3210564905494301, -0.07111560942753943),
|
||||||
|
vec2(-0.18970119374354508, 0.27395413373961097),
|
||||||
|
vec2(-0.040848098590723636, -0.3464832511798149),
|
||||||
|
vec2(0.27840760740397325, 0.22999569975767717),
|
||||||
|
vec2(-0.3655675068138925, 0.013894042926387594),
|
||||||
|
vec2(0.27334929144700043, -0.2695495965784895),
|
||||||
|
vec2(-0.014157364124171042, 0.38851232827676874),
|
||||||
|
vec2(-0.25253703711299613, -0.3086468256980197),
|
||||||
|
vec2(0.4100515255479846, 0.053267487825832176),
|
||||||
|
vec2(-0.3402835914128429, 0.2380708784965685),
|
||||||
|
vec2(0.09791475751438991, -0.41941412050652843),
|
||||||
|
vec2(0.22138836163818915, 0.3782120981062479),
|
||||||
|
vec2(-0.4213524763303703, -0.13704154865558862),
|
||||||
|
vec2(0.4169229294039292, -0.1922235606360057),
|
||||||
|
vec2(-0.1750723720198253, 0.42619435161677505),
|
||||||
|
vec2(-0.15583193830129546, -0.44540030818645854),
|
||||||
|
vec2(0.42882604653886824, 0.22196065021043188),
|
||||||
|
vec2(-0.46814559427413643, 0.12303882220514525),
|
||||||
|
vec2(0.2721696329659735, -0.41864831480405745),
|
||||||
|
vec2(0.08921887628752824, 0.4952271972313669),
|
||||||
|
vec2(-0.4005988709418946, -0.3146281961132203),
|
||||||
|
vec2(0.5212631254064987, -0.04424824894529297),
|
||||||
|
vec2(-0.35375478872674765, 0.3852003570933512),
|
||||||
|
vec2(0.006476729988070734, -0.5353773094248466),
|
||||||
|
vec2(0.36754024321057777, 0.3995080293577968),
|
||||||
|
vec2(-0.542223207878615, -0.0519953853311339),
|
||||||
|
vec2(0.44637017778921256, -0.33722397584639424),
|
||||||
|
vec2(-0.09680653666400772, 0.5520333546988624),
|
||||||
|
vec2(-0.29939501415200226, -0.4833046185334542),
|
||||||
|
vec2(0.5596011843818348, 0.1509189745951235),
|
||||||
|
vec2(-0.5147808571281486, 0.26478051462710167),
|
||||||
|
vec2(0.20883488566029573, -0.5542363522278412),
|
||||||
|
vec2(0.22866908434076613, 0.5508256786627931),
|
||||||
|
vec2(-0.5407871145385126, -0.2595074195620819),
|
||||||
|
vec2(0.5860067920083645, -0.18086189108585835),
|
||||||
|
vec2(-0.30736593848152494, 0.5296884720449828),
|
||||||
|
vec2(-0.1266907583446624, -0.6093901619826914),
|
||||||
|
vec2(0.5159424480728841, 0.3623676235874931),
|
||||||
|
vec2(-0.6255645775356298, 0.07706200529609625),
|
||||||
|
vec2(0.41898177852462715, -0.4890717485057145),
|
||||||
|
vec2(0.027432455831161814, 0.6446921406553703),
|
||||||
|
vec2(-0.4541403948372952, -0.46614804133513105),
|
||||||
|
vec2(0.6614910274222918, 0.032241087509198955),
|
||||||
|
vec2(-0.5083020565411538, 0.42180005754033856),
|
||||||
|
vec2(0.0964852676297621, -0.6651917468773848),
|
||||||
|
vec2(0.3872684835471157, 0.5554272911761509),
|
||||||
|
vec2(-0.6605604664806174, -0.15426772487094212),
|
||||||
|
vec2(0.6020393414453297, -0.34028128597305507),
|
||||||
|
vec2(-0.21002234293038552, 0.6579481079477967),
|
||||||
|
vec2(-0.2861107074822046, -0.6371439476352124),
|
||||||
|
vec2(0.6522715831040163, 0.2737008831753178),
|
||||||
|
vec2(-0.6652622751135028, 0.2356101038047024),
|
||||||
|
vec2(0.3397573613737368, -0.6329684132153847),
|
||||||
|
vec2(0.1841905597170904, 0.6964821517232016),
|
||||||
|
vec2(-0.6050183182298694, -0.39710638871623194),
|
||||||
|
vec2(0.7254416154649453, -0.12177092336287425),
|
||||||
|
vec2(-0.45014903629822983, 0.5789904973861583),
|
||||||
|
vec2(-0.05379488725502444, -0.7412859981872281),
|
||||||
|
vec2(0.5500229885821982, 0.5088249119127414),
|
||||||
|
vec2(-0.7486921122201893, -0.008726121449014926),
|
||||||
|
vec2(0.5675967989341455, -0.5077753678100256),
|
||||||
|
vec2(-0.07023781394610165, 0.7579182403995453),
|
||||||
|
vec2(-0.45744839298930007, -0.6154090763560658),
|
||||||
|
vec2(0.7637862945741366, 0.14069437605788096),
|
||||||
|
vec2(-0.656713477836827, 0.4098293315506553),
|
||||||
|
vec2(0.21454262641179686, -0.7556373805496136),
|
||||||
|
vec2(0.36026937695710076, 0.7015208788118822),
|
||||||
|
vec2(-0.7383543496199366, -0.28068022211104154),
|
||||||
|
vec2(0.7443854632051411, -0.29863443306808585),
|
||||||
|
vec2(-0.34348147387975525, 0.7224100512613486),
|
||||||
|
vec2(-0.23032288796555528, -0.7743624920949431),
|
||||||
|
vec2(0.7028476670342306, 0.4128494614683644),
|
||||||
|
vec2(-0.7960332370050228, 0.16630913345088935),
|
||||||
|
vec2(0.48320080015941314, -0.6692343793188953),
|
||||||
|
vec2(0.10211925170659499, 0.8195557731909884),
|
||||||
|
vec2(-0.6266819713189401, -0.5434242776289469),
|
||||||
|
vec2(0.839647992213555, -0.027780163659783332),
|
||||||
|
vec2(-0.5979069183510588, 0.5858930896737415),
|
||||||
|
vec2(0.05116412449643274, -0.8455440653042995),
|
||||||
|
vec2(0.5421395668481722, 0.656586163094272),
|
||||||
|
vec2(-0.8420179306636936, -0.12361040648919945),
|
||||||
|
vec2(0.7139345127041803, -0.4852140742679803),
|
||||||
|
vec2(-0.19392185846495172, 0.8394325117685132),
|
||||||
|
vec2(-0.4204487200571126, -0.7589178553865392),
|
||||||
|
vec2(0.8327210388300782, 0.27198001249322223),
|
||||||
|
vec2(-0.7960210362439597, 0.35875934008010707),
|
||||||
|
vec2(0.3521694740750743, -0.8113417187989848),
|
||||||
|
vec2(0.2956218966152538, 0.8352993597773058),
|
||||||
|
vec2(-0.7802993418734316, -0.4233366042943169),
|
||||||
|
vec2(0.8713623792816834, -0.22102227243790618),
|
||||||
|
vec2(-0.4898157243847507, 0.7501925472112333),
|
||||||
|
vec2(-0.1404730904953662, -0.8933311986231547),
|
||||||
|
vec2(0.7161931362879647, 0.5614815300362244),
|
||||||
|
vec2(-0.9058628529093994, 0.06505632357778653),
|
||||||
|
vec2(0.6327340635903044, -0.6679986961411009),
|
||||||
|
vec2(-0.009601876744475778, 0.9192004679524599),
|
||||||
|
vec2(-0.6108521377052276, -0.6924574614793783),
|
||||||
|
vec2(0.9281555629938579, 0.09338283007560376),
|
||||||
|
vec2(-0.7450460329935668, 0.555586889447176),
|
||||||
|
vec2(0.18065981280216364, -0.9220637339884982),
|
||||||
|
vec2(0.4976041523666884, 0.8004563576254236),
|
||||||
|
vec2(-0.9058072969449353, -0.26025660300795816),
|
||||||
|
vec2(0.8531917506909307, -0.4268234961929668),
|
||||||
|
vec2(-0.33647364470405444, 0.8898636052739477),
|
||||||
|
vec2(-0.3487004193922513, -0.8922603177419213),
|
||||||
|
vec2(0.8692854206244577, 0.4191405201257309),
|
||||||
|
vec2(-0.922200158608347, 0.27426963027794127),
|
||||||
|
vec2(0.5026010788472942, -0.8336545903450451),
|
||||||
|
vec2(0.19912047190109702, 0.953130414632473),
|
||||||
|
vec2(-0.7881026276127884, -0.575672440830542),
|
||||||
|
vec2(0.9797345166178452, -0.1133457865497118),
|
||||||
|
vec2(-0.6426714284056454, 0.743356925293099),
|
||||||
|
vec2(-0.022557857722768027, -0.9912168632834627),
|
||||||
|
vec2(0.694719000547024, 0.7134671125059463),
|
||||||
|
vec2(-0.992326501717018, -0.062069798758671524)
|
||||||
|
);
|
||||||
|
#endif
|
||||||
|
#if DOF_QUALITY == 5 || defined(DOF_JITTER_SHADOW) // DOF_QUALITY == 5 && defined(SCREENSHOT_MODE)
|
||||||
|
const vec2 jitter_offsets[64] = vec2[](
|
||||||
|
vec2(0.08838834764831845, 0),
|
||||||
|
vec2(-0.1846432401149469, -0.8598513673187094),
|
||||||
|
vec2(0.017279026012279545, -0.19688558926459543),
|
||||||
|
vec2(-0.3024918972101173, 0.9324356021314415),
|
||||||
|
vec2(-0.9396490219009803, -0.21621104421497742),
|
||||||
|
vec2(0.24734769576390825, -0.1573423572986152),
|
||||||
|
vec2(-0.41009709429808805, -0.8991011473957005),
|
||||||
|
vec2(0.5744249772651445, 0.07728806825078578),
|
||||||
|
vec2(0.3423210807918538, 0.12501510966878018),
|
||||||
|
vec2(-0.44015653024869994, 0.751049085532647),
|
||||||
|
vec2(0.17167724937276072, -0.36686431013087517),
|
||||||
|
vec2(0.12686512045562875, 0.4044659951241622),
|
||||||
|
vec2(-0.42888394095723925, -0.6815394817536159),
|
||||||
|
vec2(0.4485669917863205, -0.09861619481490404),
|
||||||
|
vec2(-0.27375345242708055, 0.3893861159366807),
|
||||||
|
vec2(-0.06324338646074763, -0.4880448484196678),
|
||||||
|
vec2(0.3882523628219502, 0.32721950241874764),
|
||||||
|
vec2(-0.14238056851320097, 0.782649521631399),
|
||||||
|
vec2(0.3810988237928309, -0.37924423067954616),
|
||||||
|
vec2(-0.025496987788449936, 0.5513958683321046),
|
||||||
|
vec2(-0.3626167543233098, -0.4345360623515941),
|
||||||
|
vec2(0.9169758677396763, 0.3890279655539787),
|
||||||
|
vec2(-0.48670912146566037, 0.3386395297098746),
|
||||||
|
vec2(0.13299692659673018, -0.591184672937166),
|
||||||
|
vec2(-0.2530651743438579, 0.6046862967972011),
|
||||||
|
vec2(-0.6013578380024912, -0.19184955218339567),
|
||||||
|
vec2(0.9300141309321251, 0.047552247755117134),
|
||||||
|
vec2(-0.35612804311487684, 0.1470044792078405),
|
||||||
|
vec2(-0.2258550920331724, -0.6279346919884959),
|
||||||
|
vec2(0.6257873078318013, -0.47495025566539767),
|
||||||
|
vec2(-0.6675333000242891, 0.17595963559487854),
|
||||||
|
vec2(0.3794305347699942, -0.5901016601265889),
|
||||||
|
vec2(0.12069909342891681, 0.7023134833145649),
|
||||||
|
vec2(-0.5720078077939695, -0.44299499751434795),
|
||||||
|
vec2(0.731701930078265, -0.06062000923574415),
|
||||||
|
vec2(-0.5057602714083884, 0.5467120337663267),
|
||||||
|
vec2(0.2898616761608319, -0.7818521015468547),
|
||||||
|
vec2(0.514304945229712, 0.5669461379286951),
|
||||||
|
vec2(-0.7722948658519765, -0.07157611458215449),
|
||||||
|
vec2(0.6009761594775107, 0.31585622637469357),
|
||||||
|
vec2(-0.5224659775357187, 0.02160560847664148),
|
||||||
|
vec2(-0.3823729459844533, -0.2215929380173709),
|
||||||
|
vec2(0.785920133036245, 0.21538812522581444),
|
||||||
|
vec2(-0.7334855212372673, 0.3764126593717251),
|
||||||
|
vec2(0.1309753226146144, -0.9387667254786982),
|
||||||
|
vec2(0.31791146893355565, 0.7809416098022366),
|
||||||
|
vec2(0.3076149721436936, 0.5368291431293896),
|
||||||
|
vec2(0.8232633014643855, -0.2538208747561163),
|
||||||
|
vec2(-0.77026392317357, -0.3650424477471912),
|
||||||
|
vec2(-0.112886093968774, 0.10341290919644958),
|
||||||
|
vec2(0.7241773560320561, 0.5144216723762915),
|
||||||
|
vec2(-0.8901573611276761, 0.11093859756735677),
|
||||||
|
vec2(0.5870542621401351, -0.6896954351763548),
|
||||||
|
vec2(0.033319899649036984, 0.913688833404118),
|
||||||
|
vec2(-0.6477269570369681, -0.6572764175958464),
|
||||||
|
vec2(0.5841426097907643, -0.2698887019251361),
|
||||||
|
vec2(-0.7243231135792285, 0.5984718265172488),
|
||||||
|
vec2(0.003684027952365215, -0.7551813874414849),
|
||||||
|
vec2(0.5422048902753999, 0.7874492726274129),
|
||||||
|
vec2(-0.15778073396756462, -0.3037972020750958),
|
||||||
|
vec2(0.8459367503175589, -0.47927394511090204),
|
||||||
|
vec2(0.14228560991136777, 0.18558638207624523),
|
||||||
|
vec2(-0.08273296353158632, 0.30776250055080007),
|
||||||
|
vec2(-0.26111159362214226, -0.046186964352566244)
|
||||||
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
mat2 rotate(float angle){
|
||||||
|
return mat2(cos(angle), -sin(angle), sin(angle), cos(angle));
|
||||||
|
}
|
|
@ -0,0 +1,303 @@
|
||||||
|
// this file contains all things for seasons, weather, and biome specific settings.
|
||||||
|
// i gotta start centralizing shit someday.
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////////// SEASONS /////////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////////////////////////////////// VERTEX SHADER
|
||||||
|
#ifdef Seasons
|
||||||
|
#ifdef SEASONS_VSH
|
||||||
|
|
||||||
|
uniform int worldDay;
|
||||||
|
uniform float noPuddleAreas;
|
||||||
|
|
||||||
|
void YearCycleColor (
|
||||||
|
inout vec3 FinalColor,
|
||||||
|
vec3 glcolor,
|
||||||
|
|
||||||
|
bool isLeaves,
|
||||||
|
bool isPlants
|
||||||
|
){
|
||||||
|
// colors for things that arent leaves and using the tint index.
|
||||||
|
vec3 SummerCol = vec3(Summer_R, Summer_G, Summer_B);
|
||||||
|
vec3 AutumnCol = vec3(Fall_R, Fall_G, Fall_B);
|
||||||
|
vec3 WinterCol = vec3(Winter_R, Winter_G, Winter_B) ;
|
||||||
|
vec3 SpringCol = vec3(Spring_R, Spring_G, Spring_B);
|
||||||
|
|
||||||
|
|
||||||
|
// decide if you want to replace biome colors or tint them.
|
||||||
|
|
||||||
|
SummerCol *= glcolor;
|
||||||
|
AutumnCol *= glcolor;
|
||||||
|
WinterCol *= glcolor;
|
||||||
|
SpringCol *= glcolor;
|
||||||
|
|
||||||
|
// do leaf colors different because thats cool and i like it
|
||||||
|
if(isLeaves){
|
||||||
|
SummerCol = vec3(Summer_Leaf_R, Summer_Leaf_G, Summer_Leaf_B);
|
||||||
|
AutumnCol = vec3(Fall_Leaf_R, Fall_Leaf_G, Fall_Leaf_B);
|
||||||
|
WinterCol = vec3(Winter_Leaf_R, Winter_Leaf_G, Winter_Leaf_B);
|
||||||
|
SpringCol = vec3(Spring_Leaf_R, Spring_Leaf_G, Spring_Leaf_B);
|
||||||
|
|
||||||
|
SummerCol *= glcolor;
|
||||||
|
AutumnCol *= glcolor;
|
||||||
|
WinterCol *= glcolor;
|
||||||
|
SpringCol *= glcolor;
|
||||||
|
}
|
||||||
|
|
||||||
|
// length of each season in minecraft days
|
||||||
|
int SeasonLength = Season_Length;
|
||||||
|
|
||||||
|
// loop the year. multiply the season length by the 4 seasons to create a years time.
|
||||||
|
float YearLoop = mod(worldDay + Start_Season * SeasonLength, SeasonLength * 4);
|
||||||
|
|
||||||
|
// the time schedule for each season
|
||||||
|
float SummerTime = clamp(YearLoop ,0, SeasonLength) / SeasonLength;
|
||||||
|
float AutumnTime = clamp(YearLoop - SeasonLength ,0, SeasonLength) / SeasonLength;
|
||||||
|
float WinterTime = clamp(YearLoop - SeasonLength*2 ,0, SeasonLength) / SeasonLength;
|
||||||
|
float SpringTime = clamp(YearLoop - SeasonLength*3 ,0, SeasonLength) / SeasonLength;
|
||||||
|
|
||||||
|
// lerp all season colors together
|
||||||
|
vec3 SummerToFall = mix(SummerCol, AutumnCol, SummerTime);
|
||||||
|
vec3 FallToWinter = mix(SummerToFall, WinterCol, AutumnTime);
|
||||||
|
vec3 WinterToSpring = mix(FallToWinter, SpringCol, WinterTime);
|
||||||
|
vec3 SpringToSummer = mix(WinterToSpring, SummerCol, SpringTime);
|
||||||
|
|
||||||
|
// make it so that you only have access to parts of the texture that use the tint index
|
||||||
|
#ifdef DH_SEASONS
|
||||||
|
bool IsTintIndex = isPlants || isLeaves;
|
||||||
|
#else
|
||||||
|
bool IsTintIndex = floor(dot(glcolor,vec3(0.5))) < 1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// multiply final color by the final lerped color, because it contains all the other colors.
|
||||||
|
if(IsTintIndex) FinalColor = SpringToSummer;
|
||||||
|
|
||||||
|
// #ifdef Snowy_Winter
|
||||||
|
// // this is to make snow only exist in winter
|
||||||
|
// float FallToWinter_snowfall = mix(0.0, 1.0, AutumnTime);
|
||||||
|
// float WinterToSpring_snowfall = mix(FallToWinter_snowfall, 0.0, WinterTime);
|
||||||
|
// // SnowySeason = clamp(pow(sin(WinterToSpring_snowfall*SeasonLength)*0.5+0.5,5),0,1) * WinterToSpring_snowfall * noPuddleAreas;
|
||||||
|
// #else
|
||||||
|
// // SnowySeason = 0.0;
|
||||||
|
// #endif
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 getSeasonColor( int worldDay ){
|
||||||
|
|
||||||
|
// length of each season in minecraft days
|
||||||
|
// for example, at 1, a season is 1 day long
|
||||||
|
int SeasonLength = 1;
|
||||||
|
|
||||||
|
// loop the year. multiply the season length by the 4 seasons to create a years time.
|
||||||
|
float YearLoop = mod(worldDay + SeasonLength, SeasonLength * 4);
|
||||||
|
|
||||||
|
// the time schedule for each season
|
||||||
|
float SummerTime = clamp(YearLoop ,0, SeasonLength) / SeasonLength;
|
||||||
|
float AutumnTime = clamp(YearLoop - SeasonLength ,0, SeasonLength) / SeasonLength;
|
||||||
|
float WinterTime = clamp(YearLoop - SeasonLength*2 ,0, SeasonLength) / SeasonLength;
|
||||||
|
float SpringTime = clamp(YearLoop - SeasonLength*3 ,0, SeasonLength) / SeasonLength;
|
||||||
|
|
||||||
|
// colors for things
|
||||||
|
vec3 SummerCol = vec3(Summer_R, Summer_G, Summer_B);
|
||||||
|
vec3 AutumnCol = vec3(Fall_R, Fall_G, Fall_B);
|
||||||
|
vec3 WinterCol = vec3(Winter_R, Winter_G, Winter_B);
|
||||||
|
vec3 SpringCol = vec3(Spring_R, Spring_G, Spring_B);
|
||||||
|
|
||||||
|
// lerp all season colors together
|
||||||
|
vec3 SummerToFall = mix(SummerCol, AutumnCol, SummerTime);
|
||||||
|
vec3 FallToWinter = mix(SummerToFall, WinterCol, AutumnTime);
|
||||||
|
vec3 WinterToSpring = mix(FallToWinter, SpringCol, WinterTime);
|
||||||
|
vec3 SpringToSummer = mix(WinterToSpring, SummerCol, SpringTime);
|
||||||
|
|
||||||
|
// return the final color of the year, because it contains all the other colors, at some point.
|
||||||
|
return SpringToSummer;
|
||||||
|
}
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
////////////////////////////// DAILY WEATHER //////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef WEATHERCLOUDS
|
||||||
|
|
||||||
|
uniform float Cumulus_Cov;
|
||||||
|
|
||||||
|
float DailyWeather_Cumulus(
|
||||||
|
float Coverage
|
||||||
|
){
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
Coverage += mix(Cumulus_Cov, Rain_coverage, rainStrength);
|
||||||
|
#else
|
||||||
|
Coverage += mix(CloudLayer0_coverage, Rain_coverage, rainStrength);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return Coverage;
|
||||||
|
}
|
||||||
|
|
||||||
|
uniform float Alto_Cov;
|
||||||
|
uniform float Alto_Den;
|
||||||
|
|
||||||
|
void DailyWeather_Alto(
|
||||||
|
inout float Coverage,
|
||||||
|
inout float Density
|
||||||
|
){
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
Coverage = Alto_Cov;
|
||||||
|
Density = Alto_Den;
|
||||||
|
#else
|
||||||
|
Coverage = CloudLayer2_coverage;
|
||||||
|
Density = CloudLayer2_density;
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
uniform float Uniform_Den;
|
||||||
|
uniform float Cloudy_Den;
|
||||||
|
|
||||||
|
void DailyWeather_FogDensity(
|
||||||
|
inout vec4 UniformDensity,
|
||||||
|
inout vec4 CloudyDensity
|
||||||
|
){
|
||||||
|
|
||||||
|
// set fog Profiles for each of the 8 days in the cycle.
|
||||||
|
// U = uniform fog || C = cloudy fog
|
||||||
|
// vec4( morning, noon, evening, night )
|
||||||
|
|
||||||
|
UniformDensity.rgb += vec3(Uniform_Den);
|
||||||
|
CloudyDensity.rgb += vec3(Cloudy_Den);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////// BIOME SPECIFICS /////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
uniform float nightVision;
|
||||||
|
|
||||||
|
uniform float isJungles;
|
||||||
|
uniform float isSwamps;
|
||||||
|
uniform float isDarkForests;
|
||||||
|
uniform float sandStorm;
|
||||||
|
uniform float snowStorm;
|
||||||
|
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
|
||||||
|
void BiomeFogColor(
|
||||||
|
inout vec3 FinalFogColor
|
||||||
|
){
|
||||||
|
|
||||||
|
|
||||||
|
// this is a little complicated? lmao
|
||||||
|
vec3 BiomeColors = vec3(0.0);
|
||||||
|
BiomeColors.r = isSwamps*SWAMP_R + isJungles*JUNGLE_R + isDarkForests*DARKFOREST_R + sandStorm*1.0 + snowStorm*0.6;
|
||||||
|
BiomeColors.g = isSwamps*SWAMP_G + isJungles*JUNGLE_G + isDarkForests*DARKFOREST_G + sandStorm*0.5 + snowStorm*0.8;
|
||||||
|
BiomeColors.b = isSwamps*SWAMP_B + isJungles*JUNGLE_B + isDarkForests*DARKFOREST_B + sandStorm*0.3 + snowStorm*1.0;
|
||||||
|
|
||||||
|
// insure the biome colors are locked to the fog shape and lighting, but not its orignal color.
|
||||||
|
BiomeColors *= max(dot(FinalFogColor,vec3(0.33333)), MIN_LIGHT_AMOUNT*0.025 + nightVision*0.2);
|
||||||
|
|
||||||
|
// these range 0.0-1.0. they will never overlap.
|
||||||
|
float Inbiome = isJungles+isSwamps+isDarkForests+sandStorm+snowStorm;
|
||||||
|
|
||||||
|
// interpoloate between normal fog colors and biome colors. the transition speeds are conrolled by the biome uniforms.
|
||||||
|
FinalFogColor = mix(FinalFogColor, BiomeColors, Inbiome);
|
||||||
|
}
|
||||||
|
|
||||||
|
// void BiomeSunlightColor(
|
||||||
|
// inout vec3 FinalSunlightColor
|
||||||
|
// ){
|
||||||
|
// // this is a little complicated? lmao
|
||||||
|
// vec3 BiomeColors = vec3(0.0);
|
||||||
|
// BiomeColors.r = isSwamps*SWAMP_R + isJungles*JUNGLE_R + isDarkForests*DARKFOREST_R + sandStorm*1.0 + snowStorm*0.6;
|
||||||
|
// BiomeColors.g = isSwamps*SWAMP_G + isJungles*JUNGLE_G + isDarkForests*DARKFOREST_G + sandStorm*0.5 + snowStorm*0.8;
|
||||||
|
// BiomeColors.b = isSwamps*SWAMP_B + isJungles*JUNGLE_B + isDarkForests*DARKFOREST_B + sandStorm*0.3 + snowStorm*1.0;
|
||||||
|
|
||||||
|
// // these range 0.0-1.0. they will never overlap.
|
||||||
|
// float Inbiome = isJungles+isSwamps+isDarkForests+sandStorm+snowStorm;
|
||||||
|
|
||||||
|
// // interpoloate between normal fog colors and biome colors. the transition speeds are conrolled by the biome uniforms.
|
||||||
|
// FinalSunlightColor = mix(FinalSunlightColor, FinalSunlightColor * (BiomeColors*0.8+0.2), Inbiome);
|
||||||
|
// }
|
||||||
|
|
||||||
|
void BiomeFogDensity(
|
||||||
|
inout vec4 UniformDensity,
|
||||||
|
inout vec4 CloudyDensity,
|
||||||
|
float maxDistance
|
||||||
|
){
|
||||||
|
// these range 0.0-1.0. they will never overlap.
|
||||||
|
float Inbiome = isJungles+isSwamps+isDarkForests+sandStorm+snowStorm;
|
||||||
|
|
||||||
|
vec2 BiomeFogDensity = vec2(0.0); // x = uniform || y = cloudy
|
||||||
|
BiomeFogDensity.x = isSwamps*SWAMP_UNIFORM_DENSITY + isJungles*JUNGLE_UNIFORM_DENSITY + isDarkForests*DARKFOREST_UNIFORM_DENSITY + sandStorm*15 + snowStorm*150;
|
||||||
|
BiomeFogDensity.y = isSwamps*SWAMP_CLOUDY_DENSITY + isJungles*JUNGLE_CLOUDY_DENSITY + isDarkForests*DARKFOREST_CLOUDY_DENSITY + sandStorm*255 + snowStorm*255;
|
||||||
|
|
||||||
|
UniformDensity = mix(UniformDensity, vec4(BiomeFogDensity.x), Inbiome*maxDistance);
|
||||||
|
CloudyDensity = mix(CloudyDensity, vec4(BiomeFogDensity.y), Inbiome*maxDistance);
|
||||||
|
}
|
||||||
|
|
||||||
|
float BiomeVLFogColors(inout vec3 DirectLightCol, inout vec3 IndirectLightCol){
|
||||||
|
|
||||||
|
// this is a little complicated? lmao
|
||||||
|
vec3 BiomeColors = vec3(0.0);
|
||||||
|
BiomeColors.r = isSwamps*SWAMP_R + isJungles*JUNGLE_R + isDarkForests*DARKFOREST_R + sandStorm*1.0 + snowStorm*0.6;
|
||||||
|
BiomeColors.g = isSwamps*SWAMP_G + isJungles*JUNGLE_G + isDarkForests*DARKFOREST_G + sandStorm*0.5 + snowStorm*0.8;
|
||||||
|
BiomeColors.b = isSwamps*SWAMP_B + isJungles*JUNGLE_B + isDarkForests*DARKFOREST_B + sandStorm*0.3 + snowStorm*1.0;
|
||||||
|
|
||||||
|
// insure the biome colors are locked to the fog shape and lighting, but not its orignal color.
|
||||||
|
DirectLightCol = BiomeColors * max(dot(DirectLightCol,vec3(0.33333)), MIN_LIGHT_AMOUNT*0.025 + nightVision*0.2);
|
||||||
|
|
||||||
|
IndirectLightCol = BiomeColors * max(dot(IndirectLightCol,vec3(0.33333)), MIN_LIGHT_AMOUNT*0.025 + nightVision*0.2);
|
||||||
|
|
||||||
|
// these range 0.0-1.0. they will never overlap.
|
||||||
|
float Inbiome = isJungles+isSwamps+isDarkForests+sandStorm+snowStorm;
|
||||||
|
|
||||||
|
return Inbiome;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
////////////////////////////// FOG CONTROLLER /////////////////////////////////
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#ifdef TIMEOFDAYFOG
|
||||||
|
// uniform int worldTime;
|
||||||
|
void TimeOfDayFog(
|
||||||
|
inout float Uniform, inout float Cloudy, float maxDistance
|
||||||
|
) {
|
||||||
|
|
||||||
|
float Time = worldTime%24000;
|
||||||
|
|
||||||
|
// set schedules for fog to appear at specific ranges of time in the day.
|
||||||
|
float Morning = clamp((Time-22000)/2000,0,1) + clamp((2000-Time)/2000,0,1);
|
||||||
|
float Noon = clamp(Time/2000,0,1) * clamp((12000-Time)/2000,0,1);
|
||||||
|
float Evening = clamp((Time-10000)/2000,0,1) * clamp((14000-Time)/2000,0,1) ;
|
||||||
|
float Night = clamp((Time-13000)/2000,0,1) * clamp((23000-Time)/2000,0,1) ;
|
||||||
|
|
||||||
|
// set densities. morn, noon, even, night
|
||||||
|
vec4 UniformDensity = TOD_Fog_mult * vec4(Morning_Uniform_Fog, Noon_Uniform_Fog, Evening_Uniform_Fog, Night_Uniform_Fog);
|
||||||
|
vec4 CloudyDensity = TOD_Fog_mult * vec4(Morning_Cloudy_Fog, Noon_Cloudy_Fog, Evening_Cloudy_Fog, Night_Cloudy_Fog);
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef Daily_Weather
|
||||||
|
DailyWeather_FogDensity(UniformDensity, CloudyDensity); // let daily weather influence fog densities.
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
BiomeFogDensity(UniformDensity, CloudyDensity, maxDistance); // let biome fog hijack to control densities, and overrride any other density controller...
|
||||||
|
#endif
|
||||||
|
|
||||||
|
Uniform *= Morning*UniformDensity.r + Noon*UniformDensity.g + Evening*UniformDensity.b + Night*UniformDensity.a;
|
||||||
|
Cloudy *= Morning*CloudyDensity.r + Noon*CloudyDensity.g + Evening*CloudyDensity.b + Night*CloudyDensity.a;
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -0,0 +1,46 @@
|
||||||
|
//using white noise for color dithering : gives a somewhat more "filmic" look when noise is visible
|
||||||
|
float nrand( vec2 n )
|
||||||
|
{
|
||||||
|
return fract(sin(dot(n.xy, vec2(12.9898, 78.233)))* 43758.5453);
|
||||||
|
}
|
||||||
|
|
||||||
|
float triangWhiteNoise( vec2 n )
|
||||||
|
{
|
||||||
|
|
||||||
|
float t = fract( frameTimeCounter );
|
||||||
|
float rnd = nrand( n + 0.07*t );
|
||||||
|
|
||||||
|
float center = rnd*2.0-1.0;
|
||||||
|
rnd = center*inversesqrt(abs(center));
|
||||||
|
rnd = max(-1.0,rnd);
|
||||||
|
return rnd-sign(center);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 fp10Dither(vec3 color,vec2 tc01){
|
||||||
|
float dither = triangWhiteNoise(tc01);
|
||||||
|
const vec3 mantissaBits = vec3(6.,6.,5.);
|
||||||
|
vec3 exponent = floor(log2(color));
|
||||||
|
return color + dither*exp2(-mantissaBits)*exp2(exponent);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 fp16Dither(vec3 color,vec2 tc01){
|
||||||
|
float dither = triangWhiteNoise(tc01);
|
||||||
|
const vec3 mantissaBits = vec3(10.);
|
||||||
|
vec3 exponent = floor(log2(color));
|
||||||
|
return color + dither*exp2(-mantissaBits)*exp2(exponent);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 int8Dither(vec3 color,vec2 tc01){
|
||||||
|
float dither = triangWhiteNoise(tc01);
|
||||||
|
return color + dither*exp2(-8.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 int10Dither(vec3 color,vec2 tc01){
|
||||||
|
float dither = triangWhiteNoise(tc01);
|
||||||
|
return color + dither*exp2(-10.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 int16Dither(vec3 color,vec2 tc01){
|
||||||
|
float dither = triangWhiteNoise(tc01);
|
||||||
|
return color + dither*exp2(-16.0);
|
||||||
|
}
|
|
@ -0,0 +1,330 @@
|
||||||
|
//faster and actually more precise than pow 2.2
|
||||||
|
vec3 toLinear(vec3 sRGB){
|
||||||
|
return sRGB * (sRGB * (sRGB * 0.305306011 + 0.682171111) + 0.012522878);
|
||||||
|
}
|
||||||
|
|
||||||
|
float luma(vec3 color) {
|
||||||
|
return dot(color,vec3(0.299, 0.587, 0.114));
|
||||||
|
}
|
||||||
|
|
||||||
|
const mat3 ACESInputMat =
|
||||||
|
mat3(0.59719, 0.35458, 0.04823,
|
||||||
|
0.07600, 0.90834, 0.01566,
|
||||||
|
0.02840, 0.13383, 0.83777
|
||||||
|
);
|
||||||
|
|
||||||
|
// ODT_SAT => XYZ => D60_2_D65 => sRGB
|
||||||
|
const mat3 ACESOutputMat =
|
||||||
|
mat3( 1.60475, -0.53108, -0.07367,
|
||||||
|
-0.10208, 1.10813, -0.00605,
|
||||||
|
-0.00327, -0.07276, 1.07602
|
||||||
|
);
|
||||||
|
vec3 LinearTosRGB(in vec3 color)
|
||||||
|
{
|
||||||
|
vec3 x = color * 12.92f;
|
||||||
|
vec3 y = 1.055f * pow(clamp(color,0.0,1.0), vec3(1.0f / 2.4f)) - 0.055f;
|
||||||
|
|
||||||
|
vec3 clr = color;
|
||||||
|
clr.r = color.r < 0.0031308f ? x.r : y.r;
|
||||||
|
clr.g = color.g < 0.0031308f ? x.g : y.g;
|
||||||
|
clr.b = color.b < 0.0031308f ? x.b : y.b;
|
||||||
|
|
||||||
|
return clr;
|
||||||
|
}
|
||||||
|
vec3 ToneMap_Hejl2015(in vec3 hdr)
|
||||||
|
{
|
||||||
|
vec4 vh = vec4(hdr*0.85, 3.0); //0
|
||||||
|
vec4 va = (1.75 * vh) + 0.05; //0.05
|
||||||
|
vec4 vf = ((vh * va + 0.004f) / ((vh * (va + 0.55f) + 0.0491f))) - 0.0821f+0.000633604888; //((0+0.004)/((0*(0.05+0.55)+0.0491)))-0.0821
|
||||||
|
return vf.xyz / vf.www;
|
||||||
|
}
|
||||||
|
vec3 HableTonemap(vec3 linearColor) {
|
||||||
|
// A = shoulder strength
|
||||||
|
const float A = 0.6;
|
||||||
|
// B = linear strength
|
||||||
|
const float B = 0.5;
|
||||||
|
// C = linear angle
|
||||||
|
const float C = 0.1;
|
||||||
|
// D = toe strength
|
||||||
|
const float D = 0.5;
|
||||||
|
// E = toe numerator
|
||||||
|
const float E = 0.01;
|
||||||
|
// F = toe denominator
|
||||||
|
const float F = 0.3;
|
||||||
|
// Note: E / F = toe angle
|
||||||
|
// linearWhite = linear white point value
|
||||||
|
|
||||||
|
vec3 x = linearColor*2.0;
|
||||||
|
vec3 color = ((x * (A * x + C * B) + D * E) / (x * (A * x + B) + D * F)) - E / F;
|
||||||
|
|
||||||
|
const float W = 11.0;
|
||||||
|
const float white = ((W * (A * W + C * B) + D * E) / (W * (A * W + B) + D * F)) - E / F;
|
||||||
|
|
||||||
|
return color / white;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 reinhard(vec3 x){
|
||||||
|
x *= 1.66;
|
||||||
|
return x/(1.0+x);
|
||||||
|
}
|
||||||
|
vec3 ACESFilm( vec3 x )
|
||||||
|
{
|
||||||
|
x*=0.9;
|
||||||
|
float a = 2.51f;
|
||||||
|
float b = 0.03f;
|
||||||
|
float c = 2.43f;
|
||||||
|
float d = 0.59f;
|
||||||
|
float e = 0.14f;
|
||||||
|
return (x*(a*x+b))/(x*(c*x+d)+e);
|
||||||
|
}
|
||||||
|
|
||||||
|
// From https://www.shadertoy.com/view/WdjSW3
|
||||||
|
vec3 Tonemap_Lottes(vec3 x) {
|
||||||
|
// Lottes 2016, "Advanced Techniques and Optimization of HDR Color Pipelines"
|
||||||
|
const float a = 1.6;
|
||||||
|
const float d = 0.977;
|
||||||
|
const float hdrMax = 8.0;
|
||||||
|
const float midIn = 0.23;
|
||||||
|
const float midOut = 0.267;
|
||||||
|
|
||||||
|
// Can be precomputed
|
||||||
|
const float b =
|
||||||
|
(-pow(midIn, a) + pow(hdrMax, a) * midOut) /
|
||||||
|
((pow(hdrMax, a * d) - pow(midIn, a * d)) * midOut);
|
||||||
|
const float c =
|
||||||
|
(pow(hdrMax, a * d) * pow(midIn, a) - pow(hdrMax, a) * pow(midIn, a * d) * midOut) /
|
||||||
|
((pow(hdrMax, a * d) - pow(midIn, a * d)) * midOut);
|
||||||
|
|
||||||
|
return pow(x,vec3(a)) / (pow(x, vec3(a * d)) * b + c);
|
||||||
|
}
|
||||||
|
vec3 curve(vec3 x){
|
||||||
|
return 1.0 - x/(1.0+x);
|
||||||
|
}
|
||||||
|
vec3 Tonemap_Uchimura_Modified(vec3 x, float P, float a, float m, float l, float c, float b) {
|
||||||
|
// Uchimura 2017, "HDR theory and practice"
|
||||||
|
// Math: https://www.desmos.com/calculator/gslcdxvipg
|
||||||
|
// Source: https://www.slideshare.net/nikuque/hdr-theory-and-practicce-jp
|
||||||
|
float l0 = ((P - m) * l) / a;
|
||||||
|
float L0 = m - m / a;
|
||||||
|
float L1 = m + (1.0 - m) / a;
|
||||||
|
float S0 = m + l0;
|
||||||
|
float S1 = m + a * l0;
|
||||||
|
float C2 = (a * P) / (P - S1);
|
||||||
|
float CP = C2 / P;
|
||||||
|
|
||||||
|
vec3 w0 = 1.0 - smoothstep(x, vec3(0.0), vec3(m));
|
||||||
|
vec3 w2 = step(m + l0, x);
|
||||||
|
vec3 w1 = 1.0 - w0 - w2;
|
||||||
|
|
||||||
|
vec3 T = m * pow(x / m, vec3(c)) + b;
|
||||||
|
vec3 S = P - (P - S1) * curve(CP * (x - S0));
|
||||||
|
vec3 L = m + a * (x - m);
|
||||||
|
|
||||||
|
return clamp(T * w0 + L * w1 + S * w2,0.0,1.0);
|
||||||
|
}
|
||||||
|
// From https://www.shadertoy.com/view/WdjSW3
|
||||||
|
vec3 Tonemap_Uchimura(vec3 x, float P, float a, float m, float l, float c, float b) {
|
||||||
|
// Uchimura 2017, "HDR theory and practice"
|
||||||
|
// Math: https://www.desmos.com/calculator/gslcdxvipg
|
||||||
|
// Source: https://www.slideshare.net/nikuque/hdr-theory-and-practicce-jp
|
||||||
|
float l0 = ((P - m) * l) / a;
|
||||||
|
float L0 = m - m / a;
|
||||||
|
float L1 = m + (1.0 - m) / a;
|
||||||
|
float S0 = m + l0;
|
||||||
|
float S1 = m + a * l0;
|
||||||
|
float C2 = (a * P) / (P - S1);
|
||||||
|
float CP = -C2 / P;
|
||||||
|
|
||||||
|
vec3 w0 = 1.0 - smoothstep(x, vec3(0.0), vec3(m));
|
||||||
|
vec3 w2 = step(m + l0, x);
|
||||||
|
vec3 w1 = 1.0 - w0 - w2;
|
||||||
|
|
||||||
|
vec3 T = m * pow(x / m, vec3(c)) + b;
|
||||||
|
vec3 S = P - (P - S1) * exp(CP * (x - S0));
|
||||||
|
vec3 L = m + a * (x - m);
|
||||||
|
|
||||||
|
return clamp(T * w0 + L * w1 + S * w2,0.0,1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 Tonemap_Uchimura(vec3 x) {
|
||||||
|
const float P = 1.0; // max display brightness 1.0
|
||||||
|
const float a = 1.0; // contrast 1.0
|
||||||
|
const float m = 0.12; // linear section start 0.22
|
||||||
|
const float l = 0.22; // linear section length 0.4
|
||||||
|
const float c = 1.0; // black 1.33
|
||||||
|
const float b = 0.0; // pedestal 0.0
|
||||||
|
return Tonemap_Uchimura_Modified(x, P, a, m, l, c, b);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
vec3 Tonemap_Xonk(vec3 Color){
|
||||||
|
|
||||||
|
Color = pow(Color,vec3(1.3));
|
||||||
|
|
||||||
|
return Color / (0.333 + Color);
|
||||||
|
// return pow(Color / (0.333 + Color), vec3(1.1));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 Tonemap_Full_Reinhard(vec3 C){
|
||||||
|
|
||||||
|
float whitepoint = 10.0;
|
||||||
|
float lighten = 0.5;
|
||||||
|
|
||||||
|
return (C * (1.0 + C / (whitepoint*whitepoint))) / (lighten + C);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 Full_Reinhard_Edit(vec3 C){
|
||||||
|
|
||||||
|
C = pow(C,vec3(1.2));
|
||||||
|
float whitepoint = 10.0;
|
||||||
|
float lighten = 0.333;
|
||||||
|
|
||||||
|
return (C * (1.0 + C / (whitepoint*whitepoint))) / (lighten + C);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// from https://iolite-engine.com/blog_posts/minimal_agx_implementation
|
||||||
|
// MIT License
|
||||||
|
//
|
||||||
|
// Copyright (c) 2024 Missing Deadlines (Benjamin Wrensch)
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
// of this software and associated documentation files (the "Software"), to deal
|
||||||
|
// in the Software without restriction, including without limitation the rights
|
||||||
|
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
// copies of the Software, and to permit persons to whom the Software is
|
||||||
|
// furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
// SOFTWARE.
|
||||||
|
|
||||||
|
// All values used to derive this implementation are sourced from Troy’s initial AgX implementation/OCIO config file available here:
|
||||||
|
// https://github.com/sobotka/AgX
|
||||||
|
|
||||||
|
// AND
|
||||||
|
|
||||||
|
/// from https://github.com/donmccurdy/three.js/blob/dev/src/renderers/shaders/ShaderChunk/tonemapping_pars_fragment.glsl.js
|
||||||
|
// AgX Tone Mapping implementation based on Filament, which in turn is based
|
||||||
|
// on Blender's implementation using rec 2020 primaries
|
||||||
|
// https://github.com/google/filament/pull/7236
|
||||||
|
|
||||||
|
// Inputs and outputs are encoded as Linear-sRGB.
|
||||||
|
// https://iolite-engine.com/blog_posts/minimal_agx_implementation
|
||||||
|
// Mean error^2: 3.6705141e-06
|
||||||
|
vec3 agxDefaultContrastApprox( vec3 x ) {
|
||||||
|
vec3 x2 = x * x;
|
||||||
|
vec3 x4 = x2 * x2;
|
||||||
|
|
||||||
|
return + 15.5 * x4 * x2
|
||||||
|
- 40.14 * x4 * x
|
||||||
|
+ 31.96 * x4
|
||||||
|
- 6.868 * x2 * x
|
||||||
|
+ 0.4298 * x2
|
||||||
|
+ 0.1191 * x
|
||||||
|
- 0.00232;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 agxLook(vec3 val) {
|
||||||
|
const vec3 lw = vec3(0.2126, 0.7152, 0.0722);
|
||||||
|
float luma = dot(val, lw);
|
||||||
|
|
||||||
|
// Default
|
||||||
|
vec3 offset = vec3(0.0);
|
||||||
|
vec3 slope = vec3(1.0);
|
||||||
|
vec3 power = vec3(1.0);
|
||||||
|
float sat = 1.25;
|
||||||
|
|
||||||
|
// ASC CDL
|
||||||
|
val = pow(val * slope + offset, power);
|
||||||
|
return luma + sat * (val - luma);
|
||||||
|
}
|
||||||
|
vec3 ToneMap_AgX( vec3 color ) {
|
||||||
|
// AgX constants
|
||||||
|
const mat3 AgXInsetMatrix = mat3(
|
||||||
|
vec3( 0.856627153315983, 0.137318972929847, 0.11189821299995 ),
|
||||||
|
vec3( 0.0951212405381588, 0.761241990602591, 0.0767994186031903 ),
|
||||||
|
vec3( 0.0482516061458583, 0.101439036467562, 0.811302368396859 )
|
||||||
|
);
|
||||||
|
// explicit AgXOutsetMatrix generated from Filaments AgXOutsetMatrixInv
|
||||||
|
const mat3 AgXOutsetMatrix = mat3(
|
||||||
|
vec3( 1.1271005818144368, - 0.1413297634984383, - 0.14132976349843826 ),
|
||||||
|
vec3( - 0.11060664309660323, 1.157823702216272, - 0.11060664309660294 ),
|
||||||
|
vec3( - 0.016493938717834573, - 0.016493938717834257, 1.2519364065950405 )
|
||||||
|
);
|
||||||
|
|
||||||
|
// LOG2_MIN = -10.0
|
||||||
|
// LOG2_MAX = +6.5
|
||||||
|
// MIDDLE_GRAY = 0.18
|
||||||
|
const float AgxMinEv = - 12.47393; // log2( pow( 2, LOG2_MIN ) * MIDDLE_GRAY )
|
||||||
|
const float AgxMaxEv = 4.026069; // log2( pow( 2, LOG2_MAX ) * MIDDLE_GRAY )
|
||||||
|
|
||||||
|
color = AgXInsetMatrix * color;
|
||||||
|
|
||||||
|
// Log2 encoding
|
||||||
|
color = clamp(log2(color), AgxMinEv, AgxMaxEv);
|
||||||
|
color = (color - AgxMinEv) / (AgxMaxEv - AgxMinEv);
|
||||||
|
|
||||||
|
// Apply sigmoid
|
||||||
|
color = agxDefaultContrastApprox( color );
|
||||||
|
|
||||||
|
// Apply AgX look
|
||||||
|
color = agxLook(color);
|
||||||
|
|
||||||
|
color = AgXOutsetMatrix * color;
|
||||||
|
|
||||||
|
// Linearize
|
||||||
|
color = pow( max( vec3( 0.0 ), color ), vec3( 2.2 ) );
|
||||||
|
|
||||||
|
// Gamut mapping. Simple clamp for now.
|
||||||
|
color = clamp( color, 0.0, 1.0 );
|
||||||
|
|
||||||
|
return color;
|
||||||
|
}
|
||||||
|
vec3 ToneMap_AgX_minimal( vec3 color ) {
|
||||||
|
// AgX constants from Benjamin Wrensch ( I HATE THE BRIGHTS GOING TO WHITE )
|
||||||
|
const mat3 AgXInsetMatrix = mat3(
|
||||||
|
0.842479062253094, 0.0423282422610123, 0.0423756549057051,
|
||||||
|
0.0784335999999992, 0.878468636469772, 0.0784336,
|
||||||
|
0.0792237451477643, 0.0791661274605434, 0.879142973793104);
|
||||||
|
|
||||||
|
const mat3 AgXOutsetMatrix = mat3(
|
||||||
|
1.19687900512017, -0.0528968517574562, -0.0529716355144438,
|
||||||
|
-0.0980208811401368, 1.15190312990417, -0.0980434501171241,
|
||||||
|
-0.0990297440797205, -0.0989611768448433, 1.15107367264116);
|
||||||
|
|
||||||
|
// LOG2_MIN = -10.0
|
||||||
|
// LOG2_MAX = +6.5
|
||||||
|
// MIDDLE_GRAY = 0.18
|
||||||
|
const float AgxMinEv = - 12.47393; // log2( pow( 2, LOG2_MIN ) * MIDDLE_GRAY )
|
||||||
|
const float AgxMaxEv = 4.026069; // log2( pow( 2, LOG2_MAX ) * MIDDLE_GRAY )
|
||||||
|
|
||||||
|
color = AgXInsetMatrix * color;
|
||||||
|
|
||||||
|
// Log2 encoding
|
||||||
|
color = clamp(log2(color), AgxMinEv, AgxMaxEv);
|
||||||
|
color = (color - AgxMinEv) / (AgxMaxEv - AgxMinEv);
|
||||||
|
|
||||||
|
// Apply sigmoid
|
||||||
|
color = agxDefaultContrastApprox( color );
|
||||||
|
|
||||||
|
// Apply AgX look
|
||||||
|
color = agxLook(color);
|
||||||
|
|
||||||
|
color = AgXOutsetMatrix * color;
|
||||||
|
|
||||||
|
// Linearize
|
||||||
|
color = pow(color, vec3(2.2));
|
||||||
|
|
||||||
|
// Gamut mapping. Simple clamp for now.
|
||||||
|
color = clamp( color, 0.0, 1.0 );
|
||||||
|
|
||||||
|
return color;
|
||||||
|
}
|
|
@ -0,0 +1,112 @@
|
||||||
|
#ifdef IS_LPV_ENABLED
|
||||||
|
vec3 GetHandLight(const in int itemId, const in vec3 playerPos, const in vec3 normal) {
|
||||||
|
vec3 lightFinal = vec3(0.0);
|
||||||
|
vec3 lightColor = vec3(0.0);
|
||||||
|
float lightRange = 0.0;
|
||||||
|
|
||||||
|
uvec2 blockData = texelFetch(texBlockData, itemId, 0).rg;
|
||||||
|
vec4 lightColorRange = unpackUnorm4x8(blockData.r);
|
||||||
|
lightColor = srgbToLinear(lightColorRange.rgb);
|
||||||
|
lightRange = lightColorRange.a * 255.0;
|
||||||
|
|
||||||
|
if (lightRange > 0.0) {
|
||||||
|
float lightDist = length(playerPos);
|
||||||
|
vec3 lightDir = playerPos / lightDist;
|
||||||
|
float NoL = 1.0;//max(dot(normal, lightDir), 0.0);
|
||||||
|
float falloff = pow(1.0 - lightDist / lightRange, 3.0);
|
||||||
|
lightFinal = lightColor * NoL * max(falloff, 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
return lightFinal;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 DoAmbientLightColor(
|
||||||
|
vec3 playerPos,
|
||||||
|
vec3 lpvPos,
|
||||||
|
vec3 SkyColor,
|
||||||
|
vec3 MinimumColor,
|
||||||
|
vec3 TorchColor,
|
||||||
|
vec2 Lightmap,
|
||||||
|
float Exposure
|
||||||
|
){
|
||||||
|
// Lightmap = vec2(0.0,1.0);
|
||||||
|
|
||||||
|
float LightLevelZero = clamp(pow(eyeBrightnessSmooth.y/240. + Lightmap.y,2.0) ,0.0,1.0);
|
||||||
|
|
||||||
|
// do sky lighting.
|
||||||
|
float skyLM = (pow(Lightmap.y,15.0)*2.0 + pow(Lightmap.y,2.5))*0.5;
|
||||||
|
vec3 MinimumLight = MinimumColor * (MIN_LIGHT_AMOUNT*0.01 + nightVision);
|
||||||
|
vec3 IndirectLight = max(SkyColor * ambient_brightness * skyLM * 0.7, MinimumLight);
|
||||||
|
|
||||||
|
// do torch lighting
|
||||||
|
float TorchLM = pow(1.0-sqrt(1.0-clamp(Lightmap.x,0.0,1.0)),2.0) * 2.0;
|
||||||
|
float TorchBrightness_autoAdjust = mix(1.0, 30.0, clamp(exp(-10.0*Exposure),0.0,1.0)) ;
|
||||||
|
vec3 TorchLight = TorchColor * TorchLM * TORCH_AMOUNT ;
|
||||||
|
|
||||||
|
#if defined IS_LPV_ENABLED && defined MC_GL_EXT_shader_image_load_store
|
||||||
|
vec4 lpvSample = SampleLpvLinear(lpvPos);
|
||||||
|
vec3 LpvTorchLight = GetLpvBlockLight(lpvSample);
|
||||||
|
|
||||||
|
// i gotchu
|
||||||
|
float fadeLength = 10.0; // in blocks
|
||||||
|
vec3 cubicRadius = clamp( min(((LpvSize3-1.0) - lpvPos)/fadeLength, lpvPos/fadeLength) ,0.0,1.0);
|
||||||
|
float LpvFadeF = cubicRadius.x*cubicRadius.y*cubicRadius.z;
|
||||||
|
|
||||||
|
LpvFadeF = 1.0 - pow(1.0-pow(LpvFadeF,1.5),3.0); // make it nice and soft :)
|
||||||
|
|
||||||
|
TorchLight = mix(TorchLight,LpvTorchLight/5.0, LpvFadeF);
|
||||||
|
|
||||||
|
const vec3 normal = vec3(0.0); // TODO
|
||||||
|
|
||||||
|
if (heldItemId > 0)
|
||||||
|
TorchLight += GetHandLight(heldItemId, playerPos, normal);
|
||||||
|
|
||||||
|
if (heldItemId2 > 0)
|
||||||
|
TorchLight += GetHandLight(heldItemId2, playerPos, normal);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return IndirectLight + TorchLight * TorchBrightness_autoAdjust;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// this is dumb, and i plan to remove it eventually...
|
||||||
|
vec4 RT_AmbientLight(
|
||||||
|
vec3 playerPos,
|
||||||
|
vec3 lpvPos,
|
||||||
|
float Exposure,
|
||||||
|
vec2 Lightmap,
|
||||||
|
vec3 TorchColor
|
||||||
|
){
|
||||||
|
float skyLM = (pow(Lightmap.y,15.0)*2.0 + pow(Lightmap.y,2.5))*0.5;
|
||||||
|
|
||||||
|
|
||||||
|
// do torch lighting
|
||||||
|
float TorchLM = pow(1.0-sqrt(1.0-clamp(Lightmap.x,0.0,1.0)),2.0) * 2.0;
|
||||||
|
float TorchBrightness_autoAdjust = mix(1.0, 30.0, clamp(exp(-10.0*Exposure),0.0,1.0)) ;
|
||||||
|
vec3 TorchLight = TorchColor * TorchLM * TORCH_AMOUNT ;
|
||||||
|
|
||||||
|
#if defined IS_LPV_ENABLED && defined MC_GL_EXT_shader_image_load_store
|
||||||
|
vec4 lpvSample = SampleLpvLinear(lpvPos);
|
||||||
|
vec3 LpvTorchLight = GetLpvBlockLight(lpvSample);
|
||||||
|
|
||||||
|
// i gotchu
|
||||||
|
float fadeLength = 10.0; // in blocks
|
||||||
|
vec3 cubicRadius = clamp( min(((LpvSize3-1.0) - lpvPos)/fadeLength, lpvPos/fadeLength) ,0.0,1.0);
|
||||||
|
float LpvFadeF = cubicRadius.x*cubicRadius.y*cubicRadius.z;
|
||||||
|
|
||||||
|
LpvFadeF = 1.0 - pow(1.0-pow(LpvFadeF,1.5),3.0); // make it nice and soft :)
|
||||||
|
|
||||||
|
TorchLight = mix(TorchLight,LpvTorchLight/5.0, LpvFadeF);
|
||||||
|
|
||||||
|
const vec3 normal = vec3(0.0); // TODO
|
||||||
|
|
||||||
|
if (heldItemId > 0)
|
||||||
|
TorchLight += GetHandLight(heldItemId, playerPos, normal);
|
||||||
|
|
||||||
|
if (heldItemId2 > 0)
|
||||||
|
TorchLight += GetHandLight(heldItemId2, playerPos, normal);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return vec4(TorchLight, skyLM);
|
||||||
|
}
|
|
@ -0,0 +1,309 @@
|
||||||
|
// Hash without Sine
|
||||||
|
// MIT License...
|
||||||
|
/* Copyright (c)2014 David Hoskins.
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.*/
|
||||||
|
//----------------------------------------------------------------------------------------
|
||||||
|
vec3 hash31(float p)
|
||||||
|
{
|
||||||
|
vec3 p3 = fract(vec3(p) * vec3(.1031, .1030, .0973));
|
||||||
|
p3 += dot(p3, p3.yzx+33.33);
|
||||||
|
return fract((p3.xxy+p3.yzz)*p3.zyx);
|
||||||
|
}
|
||||||
|
|
||||||
|
float hash11(float p)
|
||||||
|
{
|
||||||
|
p = fract(p * .1031);
|
||||||
|
p *= p + 33.33;
|
||||||
|
p *= p + p;
|
||||||
|
return fract(p);
|
||||||
|
}
|
||||||
|
|
||||||
|
//----------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
// Integer Hash - II
|
||||||
|
// - Inigo Quilez, Integer Hash - II, 2017
|
||||||
|
// https://www.shadertoy.com/view/XlXcW4
|
||||||
|
//----------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
uvec3 iqint2(uvec3 x)
|
||||||
|
{
|
||||||
|
const uint k = 1103515245u;
|
||||||
|
|
||||||
|
x = ((x>>8U)^x.yzx)*k;
|
||||||
|
x = ((x>>8U)^x.yzx)*k;
|
||||||
|
x = ((x>>8U)^x.yzx)*k;
|
||||||
|
|
||||||
|
return x;
|
||||||
|
}
|
||||||
|
|
||||||
|
uvec3 hash(vec2 s)
|
||||||
|
{
|
||||||
|
uvec4 u = uvec4(s, uint(s.x) ^ uint(s.y), uint(s.x) + uint(s.y)); // Play with different values for 3rd and 4th params. Some hashes are okay with constants, most aren't.
|
||||||
|
|
||||||
|
return iqint2(u.xyz);
|
||||||
|
}
|
||||||
|
|
||||||
|
//----------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
// vec3 RandomPosition = hash31(frameTimeCounter);
|
||||||
|
float vortexBoundRange = 300.0;
|
||||||
|
vec3 ManualLightPos = vec3(ORB_X, ORB_Y, ORB_Z);
|
||||||
|
|
||||||
|
vec3 LightSourcePosition(vec3 worldPos, vec3 cameraPos, float vortexBounds){
|
||||||
|
|
||||||
|
// this is static so it can just sit in one place
|
||||||
|
vec3 vortexPos = worldPos - vec3(0.0,200.0,0.0);
|
||||||
|
|
||||||
|
vec3 lightningPos = worldPos - cameraPos - ManualLightPos;
|
||||||
|
|
||||||
|
// snap-to coordinates in worldspace.
|
||||||
|
float cellSize = 200.0;
|
||||||
|
lightningPos += fract(cameraPos/cellSize)*cellSize - cellSize*0.5;
|
||||||
|
|
||||||
|
// make the position offset to random places (RNG.xyz from non-clearing buffer).
|
||||||
|
vec3 randomOffset = (texelFetch2D(colortex4,ivec2(2,1),0).xyz / 150.0) * 2.0 - 1.0;
|
||||||
|
lightningPos -= randomOffset * 2.5;
|
||||||
|
|
||||||
|
#ifdef THE_ORB
|
||||||
|
cellSize = 200.0;
|
||||||
|
vec3 orbpos = worldPos - cameraPos - ManualLightPos;// - vec3(sin(frameTimeCounter), cos(frameTimeCounter), cos(frameTimeCounter))*100;
|
||||||
|
orbpos += fract(cameraPos/cellSize)*cellSize - cellSize*0.5;
|
||||||
|
|
||||||
|
return orbpos;
|
||||||
|
#else
|
||||||
|
return mix(lightningPos, vortexPos, vortexBounds);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
float densityAtPosFog(in vec3 pos){
|
||||||
|
pos /= 18.;
|
||||||
|
pos.xz *= 0.5;
|
||||||
|
|
||||||
|
vec3 p = floor(pos);
|
||||||
|
vec3 f = fract(pos);
|
||||||
|
|
||||||
|
f = (f*f) * (3.-2.*f);
|
||||||
|
vec2 uv = p.xz + f.xz + p.y * vec2(0.0,193.0);
|
||||||
|
vec2 coord = uv / 512.0;
|
||||||
|
vec2 xy = texture2D(noisetex, coord).yx;
|
||||||
|
return mix(xy.r,xy.g, f.y);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Create a rising swirl centered around some origin.
|
||||||
|
void SwirlAroundOrigin(inout vec3 alteredOrigin, vec3 origin){
|
||||||
|
|
||||||
|
float radiance = 2.39996 + alteredOrigin.y/1.5 + frameTimeCounter/50;
|
||||||
|
mat2 rotationMatrix = mat2(vec2(cos(radiance), -sin(radiance)), vec2(sin(radiance), cos(radiance)));
|
||||||
|
|
||||||
|
// make the swirl only happen within a radius
|
||||||
|
float SwirlBounds = clamp(sqrt(length(vec3(origin.x, origin.y-100,origin.z)) / 200.0 - 1.0) ,0.0,1.0);
|
||||||
|
|
||||||
|
alteredOrigin.xz = mix(alteredOrigin.xz * rotationMatrix, alteredOrigin.xz, SwirlBounds);
|
||||||
|
}
|
||||||
|
|
||||||
|
// control where the fog volume should and should not be using a sphere.
|
||||||
|
void VolumeBounds(inout float Volume, vec3 Origin){
|
||||||
|
|
||||||
|
vec3 Origin2 = (Origin - vec3(0,100,0));
|
||||||
|
Origin2.y *= 0.8;
|
||||||
|
float Center1 = length(Origin2);
|
||||||
|
|
||||||
|
float Bounds = max(1.0 - Center1 / 75.0, 0.0) * 5.0;
|
||||||
|
|
||||||
|
|
||||||
|
float radius = 150.0;
|
||||||
|
float thickness = 50.0 * radius;
|
||||||
|
float Torus = (thickness - clamp( pow( length( vec2(length(Origin.xz) - radius, Origin2.y) ),2.0) - radius, 0.0, thickness) ) / thickness;
|
||||||
|
|
||||||
|
Origin2.xz *= 0.5;
|
||||||
|
Origin2.y -= 100;
|
||||||
|
|
||||||
|
float orb = clamp((1.0 - length(Origin2) / 15.0) * 1.0,0.0,1.0);
|
||||||
|
Volume = max(Volume - Bounds - Torus, 0);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// create the volume shape
|
||||||
|
float fogShape(in vec3 pos){
|
||||||
|
float vortexBounds = clamp(vortexBoundRange - length(pos), 0.0,1.0);
|
||||||
|
vec3 samplePos = pos*vec3(1.0,1.0/48.0,1.0);
|
||||||
|
float fogYstart = -60;
|
||||||
|
|
||||||
|
|
||||||
|
// this is below down where you fall to your death.
|
||||||
|
float voidZone = max(exp2(-1.0 * sqrt(max(pos.y - -60,0.0))) ,0.0) ;
|
||||||
|
|
||||||
|
// swirly swirly :DDDDDDDDDDD
|
||||||
|
SwirlAroundOrigin(samplePos, pos);
|
||||||
|
|
||||||
|
float noise = densityAtPosFog(samplePos * 12.0);
|
||||||
|
float erosion = 1.0-densityAtPosFog((samplePos - frameTimeCounter/20) * (124 + (1-noise)*7));
|
||||||
|
|
||||||
|
|
||||||
|
float clumpyFog = max(exp(noise * -mix(10,4,vortexBounds))*mix(2,1,vortexBounds) - erosion*0.3, 0.0);
|
||||||
|
|
||||||
|
// apply limts
|
||||||
|
VolumeBounds(clumpyFog, pos);
|
||||||
|
|
||||||
|
|
||||||
|
return clumpyFog + voidZone;
|
||||||
|
}
|
||||||
|
|
||||||
|
float endFogPhase(vec3 LightPos){
|
||||||
|
|
||||||
|
float mie = exp(length(LightPos) / -150);
|
||||||
|
mie *= mie;
|
||||||
|
mie *= mie;
|
||||||
|
mie *= 100;
|
||||||
|
|
||||||
|
return mie;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 LightSourceColors(float vortexBounds, float lightningflash){
|
||||||
|
|
||||||
|
// vec3 vortexColor = vec3(0.7,0.88,1.0);
|
||||||
|
// vec3 lightningColor = vec3(ORB_R,ORB_G,ORB_B);
|
||||||
|
|
||||||
|
vec3 vortexColor = vec3(0.5,0.68,1.0);
|
||||||
|
vec3 lightningColor = vec3(1.0,0.3,0.2) * lightningflash;
|
||||||
|
|
||||||
|
#ifdef THE_ORB
|
||||||
|
return vec3(ORB_R, ORB_G, ORB_B) * ORB_ColMult;
|
||||||
|
#else
|
||||||
|
return mix(lightningColor, vortexColor, vortexBounds);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 LightSourceLighting(vec3 startPos, vec3 lightPos, float noise, float density, vec3 lightColor, float vortexBound){
|
||||||
|
|
||||||
|
float phase = endFogPhase(lightPos);
|
||||||
|
float shadow = 0.0;
|
||||||
|
|
||||||
|
for (int j = 0; j < 3; j++){
|
||||||
|
vec3 shadowSamplePos = startPos - lightPos * (0.05 + j * (0.25 + noise*0.15));
|
||||||
|
shadow += fogShape(shadowSamplePos);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 finalLighting = lightColor * phase * exp(shadow * -10.0);
|
||||||
|
|
||||||
|
finalLighting += lightColor * phase*phase * (1.0-exp((shadow*shadow*shadow) * vec3(0.6,2.0,2) * -1)) * (1.0 - exp(-density*density));
|
||||||
|
|
||||||
|
return finalLighting;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 GetVolumetricFog(
|
||||||
|
vec3 viewPosition,
|
||||||
|
float dither,
|
||||||
|
float dither2
|
||||||
|
){
|
||||||
|
#ifndef TOGGLE_VL_FOG
|
||||||
|
return vec4(0.0,0.0,0.0,1.0);
|
||||||
|
#endif
|
||||||
|
/// ------------- RAYMARCHING STUFF ------------- \\\
|
||||||
|
|
||||||
|
int SAMPLES = 16;
|
||||||
|
|
||||||
|
//project pixel position into projected shadowmap space
|
||||||
|
vec3 wpos = mat3(gbufferModelViewInverse) * viewPosition + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 fragposition = mat3(shadowModelView) * wpos + shadowModelView[3].xyz;
|
||||||
|
fragposition = diagonal3(shadowProjection) * fragposition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
//project view origin into projected shadowmap space
|
||||||
|
vec3 start = vec3(0.0);
|
||||||
|
|
||||||
|
//rayvector into projected shadow map space
|
||||||
|
//we can use a projected vector because its orthographic projection
|
||||||
|
//however we still have to send it to curved shadow map space every step
|
||||||
|
vec3 dV = fragposition - start;
|
||||||
|
vec3 dVWorld = (wpos-gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
float maxLength = min(length(dVWorld),32.0 * 12.0)/length(dVWorld);
|
||||||
|
dV *= maxLength;
|
||||||
|
dVWorld *= maxLength;
|
||||||
|
float dL = length(dVWorld);
|
||||||
|
|
||||||
|
vec3 progressW = gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
|
||||||
|
/// ------------- COLOR/LIGHTING STUFF ------------- \\\
|
||||||
|
|
||||||
|
vec3 color = vec3(0.0);
|
||||||
|
vec3 absorbance = vec3(1.0);
|
||||||
|
|
||||||
|
vec3 fogcolor = (gl_Fog.color.rgb / max(dot(gl_Fog.color.rgb,vec3(0.3333)),0.05)) ;
|
||||||
|
|
||||||
|
float lightningflash = texelFetch2D(colortex4,ivec2(1,1),0).x/150.0;
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<SAMPLES;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither)/float(SAMPLES))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
float dd = pow(expFactor, float(i+dither)/float(SAMPLES)) * log(expFactor) / float(SAMPLES)/(expFactor-1.0);
|
||||||
|
|
||||||
|
vec3 progressW = gbufferModelViewInverse[3].xyz+cameraPosition + d*dVWorld;
|
||||||
|
|
||||||
|
// determine where the vortex area ends and chaotic lightning area begins.
|
||||||
|
float vortexBounds = clamp(vortexBoundRange - length(progressW), 0.0,1.0);
|
||||||
|
|
||||||
|
vec3 lightPosition = LightSourcePosition(progressW, cameraPosition, vortexBounds);
|
||||||
|
vec3 lightColors = LightSourceColors(vortexBounds, lightningflash);
|
||||||
|
|
||||||
|
float volumeDensity = fogShape(progressW);
|
||||||
|
// volumeDensity += max(1.0 - length(vec3(lightPosition.x,lightPosition.y*2,lightPosition.z))/50,0.0) * vortexBounds;
|
||||||
|
|
||||||
|
float clearArea = 1.0-min(max(1.0 - length(progressW - cameraPosition) / 100,0.0),1.0);
|
||||||
|
float density = min(volumeDensity * clearArea, END_STORM_DENSTIY);
|
||||||
|
|
||||||
|
///// ----- air lighting, the haze
|
||||||
|
float distanceFog = max(1.0 - length(progressW - cameraPosition) / max(far, 32.0 * 13.0),0.0);
|
||||||
|
float hazeDensity = min(exp2(distanceFog * -25)+0.0005,1.0);
|
||||||
|
vec3 hazeColor = vec3(0.3,0.75,1.0) * 0.3;
|
||||||
|
color += (hazeColor - hazeColor*exp(-hazeDensity*dd*dL)) * absorbance;
|
||||||
|
|
||||||
|
///// ----- main lighting
|
||||||
|
vec3 voidLighting = vec3(1.0,0.0,0.8) * 0.1 * (1-exp(volumeDensity * -25)) * max(exp2(-1 * sqrt(max(progressW.y - -60,0.0))),0.0) ;
|
||||||
|
|
||||||
|
vec3 ambient = vec3(0.5,0.75,1.0) * 0.2 * (exp((volumeDensity*volumeDensity) * -50) * 0.9 + 0.1);
|
||||||
|
float shadows = 0;
|
||||||
|
vec3 lightsources = LightSourceLighting(progressW, lightPosition, dither2, volumeDensity, lightColors, vortexBounds);
|
||||||
|
vec3 lighting = lightsources + ambient + voidLighting;
|
||||||
|
|
||||||
|
#ifdef THE_ORB
|
||||||
|
density += min(50.0*max(1.0 - length(lightPosition)/10,0.0),1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
///// ----- blend
|
||||||
|
color += (lighting - lighting*exp(-(density)*dd*dL)) * absorbance;
|
||||||
|
absorbance *= exp(-max(density,hazeDensity)*dd*dL);
|
||||||
|
}
|
||||||
|
// return vec4(0.0,0.0,0.0,1.0);
|
||||||
|
return vec4(color, absorbance);
|
||||||
|
}
|
||||||
|
|
||||||
|
float GetCloudShadow(vec3 WorldPos, vec3 LightPos){
|
||||||
|
float Shadow = 0.0;
|
||||||
|
|
||||||
|
for (int i=0; i < 3; i++){
|
||||||
|
|
||||||
|
// vec3 shadowSamplePos = WorldPos - LightPos * (pow(i,0.75)*0.25);
|
||||||
|
vec3 shadowSamplePos = WorldPos - LightPos * (0.01 + pow(i,0.75)*0.25);
|
||||||
|
Shadow += fogShape(shadowSamplePos)*END_STORM_DENSTIY;
|
||||||
|
}
|
||||||
|
|
||||||
|
return clamp(exp2(Shadow * -5.0),0.0,1.0);
|
||||||
|
}
|
|
@ -0,0 +1,13 @@
|
||||||
|
#define ENTITY_PLAYER 1601
|
||||||
|
#define ENTITY_LIGHTNING 1602
|
||||||
|
#define ENTITY_BLAZE 1603
|
||||||
|
#define ENTITY_DRAGON_WITHER 1604
|
||||||
|
#define ENTITY_END_CRYSTAL 1605
|
||||||
|
#define ENTITY_ITEM_FRAME 1606
|
||||||
|
#define ENTITY_MAGMA_CUBE 1607
|
||||||
|
#define ENTITY_TNT 1608
|
||||||
|
#define ENTITY_FIREBALL_SMALL 1609
|
||||||
|
#define ENTITY_SPECTRAL_ARROW 1610
|
||||||
|
#define ENTITY_SSS_MEDIUM 1801
|
||||||
|
#define ENTITY_SSS_WEAK 1802
|
||||||
|
#define ENTITY_SLIME 1803
|
|
@ -0,0 +1,70 @@
|
||||||
|
#ifdef IS_IRIS
|
||||||
|
uniform float currentPlayerHealth;
|
||||||
|
uniform float maxPlayerHealth;
|
||||||
|
uniform float oneHeart;
|
||||||
|
uniform float threeHeart;
|
||||||
|
#else
|
||||||
|
uniform bool isDead;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
uniform float hurt;
|
||||||
|
|
||||||
|
// uniform float currentPlayerHunger;
|
||||||
|
// uniform float maxPlayerHunger;
|
||||||
|
|
||||||
|
// uniform float currentPlayerArmor;
|
||||||
|
// uniform float maxPlayerArmor;
|
||||||
|
|
||||||
|
// uniform float currentPlayerAir;
|
||||||
|
// uniform float maxPlayerAir;
|
||||||
|
|
||||||
|
// uniform bool is_sneaking;
|
||||||
|
// uniform bool is_sprinting;
|
||||||
|
// uniform bool is_hurt;
|
||||||
|
// uniform bool is_invisible;
|
||||||
|
// uniform bool is_burning;
|
||||||
|
|
||||||
|
// uniform bool is_on_ground;
|
||||||
|
// uniform bool isSpectator;
|
||||||
|
|
||||||
|
|
||||||
|
void applyGameplayEffects_FRAGMENT(inout vec3 color, in vec2 texcoord, float noise){
|
||||||
|
|
||||||
|
#if defined LOW_HEALTH_EFFECT || defined DAMAGE_TAKEN_EFFECT
|
||||||
|
// detect when health is zero
|
||||||
|
#ifdef IS_IRIS
|
||||||
|
bool isDead = currentPlayerHealth * maxPlayerHealth <= 0.0 && currentPlayerHealth > -1;
|
||||||
|
#else
|
||||||
|
float oneHeart = 0.0;
|
||||||
|
float threeHeart = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float vignette = sqrt(clamp(dot(texcoord*2.0 - 1.0, texcoord*2.0 - 1.0) * 0.5, 0.0, 1.0));
|
||||||
|
|
||||||
|
// heart beat effect to scale stuff with, make it more intense. theres a multiplier "MOTION_AMOUNT" for accessiblity
|
||||||
|
float beatingRate = isDead ? 0.0 : (oneHeart > 0.0 ? 15.0 : 7.5);
|
||||||
|
float heartBeat = (pow(sin(frameTimeCounter * beatingRate)*0.5+0.5,2.0)*0.2 + 0.1);
|
||||||
|
|
||||||
|
// scale UV to be more and more lower frequency towards the edges of the screen, to create a tunnel vision effect,
|
||||||
|
vec2 zoomUV = 0.5 + (texcoord - 0.5) * (1.0 - vignette * (isDead ? noise*0.7 : noise * heartBeat * MOTION_AMOUNT));
|
||||||
|
vec3 distortedScreen = vec3(1.0, 0.0, 0.0) * dot(texture2D(colortex7, zoomUV).rgb, vec3(0.21, 0.72, 0.07));
|
||||||
|
|
||||||
|
#ifdef LOW_HEALTH_EFFECT
|
||||||
|
// at 1 heart or 3 hearts, create 2 levels of a strain / tunnel vision effect.
|
||||||
|
|
||||||
|
// black and white version of the scene color.
|
||||||
|
vec3 colorLuma = vec3(1.0, 1.0, 1.0) * dot(color,vec3(0.21, 0.72, 0.07));
|
||||||
|
|
||||||
|
// I LOVE LINEAR INTERPOLATION
|
||||||
|
color = mix(color, mix(colorLuma, distortedScreen, vignette), mix(vignette * threeHeart, oneHeart, oneHeart));
|
||||||
|
|
||||||
|
if(isDead) color = distortedScreen*0.3;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef DAMAGE_TAKEN_EFFECT
|
||||||
|
// when damage is taken, flash the above effect. because it uses the stuff above, it seamlessly blends to them.
|
||||||
|
color = mix(color, distortedScreen, (vignette*vignette) * sqrt(hurt));
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
}
|
|
@ -0,0 +1,17 @@
|
||||||
|
vec3 RgbToHsv(const in vec3 c) {
|
||||||
|
const vec4 K = vec4(0.0, -1.0, 2.0, -3.0) / 3.0;
|
||||||
|
const float e = 1.0e-10;
|
||||||
|
|
||||||
|
vec4 p = mix(vec4(c.bg, K.wz), vec4(c.gb, K.xy), step(c.b, c.g));
|
||||||
|
vec4 q = mix(vec4(p.xyw, c.r), vec4(c.r, p.yzx), step(p.x, c.r));
|
||||||
|
|
||||||
|
float d = q.x - min(q.w, q.y);
|
||||||
|
return vec3(abs(q.z + (q.w - q.y) / (6.0 * d + e)), d / (q.x + e), q.x);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 HsvToRgb(const in vec3 c) {
|
||||||
|
const vec4 K = vec4(3.0, 2.0, 1.0, 9.0) / 3.0;
|
||||||
|
|
||||||
|
vec3 p = abs(fract(c.xxx + K.xyz) * 6.0 - K.www);
|
||||||
|
return c.z * mix(K.xxx, saturate(p - K.xxx), c.y);
|
||||||
|
}
|
|
@ -0,0 +1,398 @@
|
||||||
|
vec2 R2_samples(int n){
|
||||||
|
vec2 alpha = vec2(0.75487765, 0.56984026);
|
||||||
|
return fract(alpha * n);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 cosineHemisphereSample(vec2 Xi){
|
||||||
|
float theta = 2.0 * 3.14159265359 * Xi.y;
|
||||||
|
|
||||||
|
float r = sqrt(Xi.x);
|
||||||
|
float x = r * cos(theta);
|
||||||
|
float y = r * sin(theta);
|
||||||
|
|
||||||
|
return vec3(x, y, sqrt(clamp(1.0 - Xi.x,0.,1.)));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 TangentToWorld(vec3 N, vec3 H, float roughness){
|
||||||
|
vec3 UpVector = abs(N.z) < 0.999 ? vec3(0.0, 0.0, 1.0) : vec3(1.0, 0.0, 0.0);
|
||||||
|
vec3 T = normalize(cross(UpVector, N));
|
||||||
|
vec3 B = cross(N, T);
|
||||||
|
|
||||||
|
return vec3((T * H.x) + (B * H.y) + (N * H.z));
|
||||||
|
}
|
||||||
|
vec2 SpiralSample(
|
||||||
|
int samples, int totalSamples, float rotation, float Xi
|
||||||
|
){
|
||||||
|
Xi = max(Xi,0.0015);
|
||||||
|
|
||||||
|
float alpha = float(samples + Xi) * (1.0 / float(totalSamples));
|
||||||
|
|
||||||
|
float theta = (2.0 *3.14159265359) * alpha * rotation;
|
||||||
|
|
||||||
|
float r = sqrt(Xi);
|
||||||
|
float x = r * sin(theta);
|
||||||
|
float y = r * cos(theta);
|
||||||
|
|
||||||
|
return vec2(x, y);
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////// SSAO ////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
vec4 BilateralUpscale_SSAO(sampler2D tex, sampler2D depth, vec2 coord, float referenceDepth){
|
||||||
|
ivec2 scaling = ivec2(1.0);
|
||||||
|
ivec2 posDepth = ivec2(coord) * scaling;
|
||||||
|
ivec2 posColor = ivec2(coord);
|
||||||
|
ivec2 pos = ivec2(gl_FragCoord.xy*texelSize + 1);
|
||||||
|
|
||||||
|
ivec2 getRadius[4] = ivec2[](
|
||||||
|
ivec2(-2,-2),
|
||||||
|
ivec2(-2, 0),
|
||||||
|
ivec2( 0, 0),
|
||||||
|
ivec2( 0,-2)
|
||||||
|
);
|
||||||
|
// ivec2 getRadius3x3[8] = ivec2[](
|
||||||
|
// ivec2(-2,-2),
|
||||||
|
// ivec2(-2, 0),
|
||||||
|
// ivec2( 0, 0),
|
||||||
|
// ivec2( 0,-2),
|
||||||
|
// ivec2(-2,-1),
|
||||||
|
// ivec2(-1,-2),
|
||||||
|
// ivec2(0,-1),
|
||||||
|
// ivec2(-1,0)
|
||||||
|
// );
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float diffThreshold = 0.0005 ;
|
||||||
|
#else
|
||||||
|
float diffThreshold = 0.005;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec4 RESULT = vec4(0.0);
|
||||||
|
float SUM = 0.0;
|
||||||
|
|
||||||
|
for (int i = 0; i < 4; i++) {
|
||||||
|
|
||||||
|
ivec2 radius = getRadius[i];
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float offsetDepth = sqrt(texelFetch2D(depth, posDepth + radius * scaling + pos * scaling,0).a/65000.0);
|
||||||
|
#else
|
||||||
|
float offsetDepth = ld(texelFetch2D(depth, posDepth + radius * scaling + pos * scaling, 0).r);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float EDGES = abs(offsetDepth - referenceDepth) < diffThreshold ? 1.0 : 1e-5;
|
||||||
|
|
||||||
|
RESULT += texelFetch2D(tex, posColor + radius + pos, 0) * EDGES;
|
||||||
|
|
||||||
|
SUM += EDGES;
|
||||||
|
}
|
||||||
|
|
||||||
|
// return vec4(1,1,1,1) * SUM/4;
|
||||||
|
|
||||||
|
return RESULT / SUM;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 SSAO(
|
||||||
|
vec3 viewPos, vec3 normal, bool hand, bool leaves, float noise
|
||||||
|
){
|
||||||
|
if(hand) return vec2(1.0,0.0);
|
||||||
|
int samples = 7;
|
||||||
|
float occlusion = 0.0;
|
||||||
|
float sss = 0.0;
|
||||||
|
|
||||||
|
|
||||||
|
float dist = 1.0 + clamp(viewPos.z*viewPos.z/50.0,0,5); // shrink sample size as distance increases
|
||||||
|
float mulfov2 = gbufferProjection[1][1]/(3 * dist);
|
||||||
|
float maxR2 = viewPos.z*viewPos.z*mulfov2*2.*5/50.0;
|
||||||
|
|
||||||
|
#ifdef Ambient_SSS
|
||||||
|
float maxR2_2 = viewPos.z*viewPos.z*mulfov2*2.*2./50.0;
|
||||||
|
|
||||||
|
float dist3 = clamp(1-exp( viewPos.z*viewPos.z / -50),0,1);
|
||||||
|
if(leaves) maxR2_2 = mix(10, maxR2_2, dist3);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec2 acc = -(TAA_Offset*(texelSize/2))*RENDER_SCALE ;
|
||||||
|
|
||||||
|
int n = 0;
|
||||||
|
for (int i = 0; i < samples; i++) {
|
||||||
|
|
||||||
|
// vec2 sampleOffset = SpiralSample(i, 7, 8, noise) * 0.2 * mulfov2;
|
||||||
|
|
||||||
|
vec2 sampleOffset = SpiralSample(i, 7, 8, noise) * clamp(0.05 + i*0.095, 0.0,0.3) * mulfov2;
|
||||||
|
|
||||||
|
ivec2 offset = ivec2(gl_FragCoord.xy + sampleOffset*vec2(viewWidth,viewHeight*aspectRatio)*RENDER_SCALE);
|
||||||
|
|
||||||
|
if (offset.x >= 0 && offset.y >= 0 && offset.x < viewWidth*RENDER_SCALE.x && offset.y < viewHeight*RENDER_SCALE.y ) {
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float dhdepth = texelFetch2D(dhDepthTex1, offset,0).x;
|
||||||
|
#else
|
||||||
|
float dhdepth = 0.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 t0 = toScreenSpace_DH((offset*texelSize+acc+0.5*texelSize) * (1.0/RENDER_SCALE), texelFetch2D(depthtex1, offset,0).x, dhdepth);
|
||||||
|
vec3 vec = (t0.xyz - viewPos);
|
||||||
|
float dsquared = dot(vec, vec);
|
||||||
|
|
||||||
|
if (dsquared > 1e-5){
|
||||||
|
if (dsquared < maxR2){
|
||||||
|
float NdotV = clamp(dot(vec*inversesqrt(dsquared), normalize(normal)),0.,1.);
|
||||||
|
occlusion += NdotV * clamp(1.0-dsquared/maxR2,0.0,1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef Ambient_SSS
|
||||||
|
if(dsquared > maxR2_2){
|
||||||
|
float NdotV = 1.0 - clamp(dot(vec*dsquared, normalize(normal)),0.,1.);
|
||||||
|
sss += max((NdotV - (1.0-NdotV)) * clamp(1.0-maxR2_2/dsquared,0.0,1.0) ,0.0);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
n += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return max(1.0 - vec2(occlusion, sss)/n, 0.0);
|
||||||
|
}
|
||||||
|
float ScreenSpace_SSS(
|
||||||
|
vec3 viewPos, vec3 normal, bool hand, bool leaves, float noise
|
||||||
|
){
|
||||||
|
if(hand) return 0.0;
|
||||||
|
int samples = 7;
|
||||||
|
float occlusion = 0.0;
|
||||||
|
float sss = 0.0;
|
||||||
|
|
||||||
|
|
||||||
|
float dist = 1.0 + clamp(viewPos.z*viewPos.z/50.0,0,5); // shrink sample size as distance increases
|
||||||
|
float mulfov2 = gbufferProjection[1][1]/(3 * dist);
|
||||||
|
|
||||||
|
float maxR2_2 = viewPos.z*viewPos.z*mulfov2*2.*2./50.0;
|
||||||
|
|
||||||
|
float dist3 = clamp(1-exp( viewPos.z*viewPos.z / -50),0,1);
|
||||||
|
if(leaves) maxR2_2 = mix(10, maxR2_2, dist3);
|
||||||
|
|
||||||
|
|
||||||
|
vec2 acc = -(TAA_Offset*(texelSize/2))*RENDER_SCALE ;
|
||||||
|
|
||||||
|
int n = 0;
|
||||||
|
for (int i = 0; i < samples; i++) {
|
||||||
|
|
||||||
|
vec2 sampleOffset = SpiralSample(i, 7, 8, noise) * 0.2 * mulfov2;
|
||||||
|
|
||||||
|
ivec2 offset = ivec2(gl_FragCoord.xy + sampleOffset*vec2(viewWidth,viewHeight*aspectRatio)*RENDER_SCALE);
|
||||||
|
|
||||||
|
if (offset.x >= 0 && offset.y >= 0 && offset.x < viewWidth*RENDER_SCALE.x && offset.y < viewHeight*RENDER_SCALE.y ) {
|
||||||
|
vec3 t0 = toScreenSpace(vec3(offset*texelSize+acc+0.5*texelSize, texelFetch2D(depthtex1, offset,0).x) * vec3(1.0/RENDER_SCALE, 1.0) );
|
||||||
|
vec3 vec = (t0.xyz - viewPos);
|
||||||
|
float dsquared = dot(vec, vec);
|
||||||
|
|
||||||
|
if (dsquared > 1e-5){
|
||||||
|
if(dsquared > maxR2_2){
|
||||||
|
float NdotV = 1.0 - clamp(dot(vec*dsquared, normalize(normal)),0.,1.);
|
||||||
|
sss += max((NdotV - (1.0-NdotV)) * clamp(1.0-maxR2_2/dsquared,0.0,1.0) ,0.0);
|
||||||
|
}
|
||||||
|
n += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return max(1.0 - sss/n, 0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////////////
|
||||||
|
///////////////////////////// RTAO/SSGI ////////////////////////
|
||||||
|
////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
vec3 rayTrace_GI(vec3 dir,vec3 position,float dither, float quality){
|
||||||
|
|
||||||
|
vec3 clipPosition = toClipSpace3(position);
|
||||||
|
float rayLength = ((position.z + dir.z * far*sqrt(3.)) > -near) ?
|
||||||
|
(-near -position.z) / dir.z : far*sqrt(3.);
|
||||||
|
vec3 direction = normalize(toClipSpace3(position+dir*rayLength)-clipPosition); //convert to clip space
|
||||||
|
direction.xy = normalize(direction.xy);
|
||||||
|
|
||||||
|
//get at which length the ray intersects with the edge of the screen
|
||||||
|
vec3 maxLengths = (step(0.,direction)-clipPosition) / direction;
|
||||||
|
float mult = maxLengths.y;
|
||||||
|
|
||||||
|
vec3 stepv = direction * mult / quality*vec3(RENDER_SCALE,1.0) * dither;
|
||||||
|
vec3 spos = clipPosition*vec3(RENDER_SCALE,1.0) ;
|
||||||
|
|
||||||
|
spos.xy += TAA_Offset*texelSize*0.5/RENDER_SCALE;
|
||||||
|
|
||||||
|
float biasdist = clamp(position.z*position.z/50.0,1,2); // shrink sample size as distance increases
|
||||||
|
|
||||||
|
for(int i = 0; i < int(quality); i++){
|
||||||
|
spos += stepv;
|
||||||
|
#ifdef UseQuarterResDepth
|
||||||
|
float sp = sqrt(texelFetch2D(colortex4,ivec2(spos.xy/texelSize/4),0).w/65000.0);
|
||||||
|
#else
|
||||||
|
float sp = linZ(texelFetch2D(depthtex1,ivec2(spos.xy/ texelSize),0).r);
|
||||||
|
#endif
|
||||||
|
float currZ = linZ(spos.z);
|
||||||
|
|
||||||
|
if( sp < currZ) {
|
||||||
|
float dist = abs(sp-currZ)/currZ;
|
||||||
|
if (abs(dist) < biasdist*0.05) return vec3(spos.xy, invLinZ(sp))/vec3(RENDER_SCALE,1.0);
|
||||||
|
}
|
||||||
|
spos += stepv;
|
||||||
|
}
|
||||||
|
return vec3(1.1);
|
||||||
|
}
|
||||||
|
float convertHandDepth_3(in float depth, bool hand) {
|
||||||
|
if(!hand) return depth;
|
||||||
|
|
||||||
|
float ndcDepth = depth * 2.0 - 1.0;
|
||||||
|
ndcDepth /= MC_HAND_DEPTH;
|
||||||
|
return ndcDepth * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
vec3 RT(vec3 dir, vec3 position, float noise, float stepsizes, bool hand){
|
||||||
|
float dist = 1.0 + clamp(position.z*position.z,0,2); // shrink sample size as distance increases
|
||||||
|
|
||||||
|
float stepSize = stepsizes / dist;
|
||||||
|
int maxSteps = STEPS;
|
||||||
|
vec3 clipPosition = toClipSpace3(position);
|
||||||
|
float rayLength = ((position.z + dir.z * sqrt(3.0)*far) > -sqrt(3.0)*near) ?
|
||||||
|
(-sqrt(3.0)*near -position.z) / dir.z : sqrt(3.0)*far;
|
||||||
|
vec3 end = toClipSpace3(position+dir*rayLength) ;
|
||||||
|
vec3 direction = end-clipPosition ; //convert to clip space
|
||||||
|
|
||||||
|
float len = max(abs(direction.x)/texelSize.x,abs(direction.y)/texelSize.y)/stepSize;
|
||||||
|
//get at which length the ray intersects with the edge of the screen
|
||||||
|
vec3 maxLengths = (step(0.,direction)-clipPosition) / direction;
|
||||||
|
|
||||||
|
float mult = min(min(maxLengths.x,maxLengths.y),maxLengths.z)*2000.0;
|
||||||
|
|
||||||
|
vec3 stepv = direction/len;
|
||||||
|
|
||||||
|
|
||||||
|
int iterations = min(int(min(len, mult*len)-2), maxSteps);
|
||||||
|
|
||||||
|
//Do one iteration for closest texel (good contact shadows)
|
||||||
|
vec3 spos = clipPosition*vec3(RENDER_SCALE,1.0) ;
|
||||||
|
spos.xy += TAA_Offset*texelSize*0.5*RENDER_SCALE;
|
||||||
|
spos += stepv/(stepSize/2);
|
||||||
|
|
||||||
|
float distancered = 1.0 + clamp(position.z*position.z/50.0,0,2); // shrink sample size as distance increases
|
||||||
|
|
||||||
|
for(int i = 0; i < iterations; i++){
|
||||||
|
if (spos.x < 0.0 || spos.y < 0.0 || spos.z < 0.0 || spos.x > 1.0 || spos.y > 1.0 || spos.z > 1.0) return vec3(1.1);
|
||||||
|
spos += stepv*noise;
|
||||||
|
#ifdef UseQuarterResDepth
|
||||||
|
float sp = sqrt(texelFetch2D(colortex4,ivec2(spos.xy/ texelSize/4),0).w/65000.0);
|
||||||
|
#else
|
||||||
|
float sp = linZ(texelFetch2D(depthtex1,ivec2(spos.xy/ texelSize),0).r);
|
||||||
|
#endif
|
||||||
|
float currZ = linZ(spos.z);
|
||||||
|
|
||||||
|
if( sp < currZ) {
|
||||||
|
float dist = abs(sp-currZ)/currZ;
|
||||||
|
if (dist <= mix(0.5, 0.1, clamp(position.z*position.z - 0.1,0,1))) return vec3(spos.xy, invLinZ(sp))/vec3(RENDER_SCALE,1.0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return vec3(1.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
void ApplySSRT(
|
||||||
|
inout vec3 lighting,
|
||||||
|
vec3 viewPos,
|
||||||
|
vec3 normal,
|
||||||
|
vec3 noise,
|
||||||
|
|
||||||
|
vec3 playerPos,
|
||||||
|
vec3 lpvPos,
|
||||||
|
float Exposure,
|
||||||
|
vec2 lightmaps,
|
||||||
|
|
||||||
|
vec3 skylightcolor,
|
||||||
|
vec3 torchcolor,
|
||||||
|
|
||||||
|
bool isGrass,
|
||||||
|
bool hand
|
||||||
|
){
|
||||||
|
int nrays = RAY_COUNT;
|
||||||
|
|
||||||
|
vec3 radiance = vec3(0.0);
|
||||||
|
|
||||||
|
vec3 occlusion = vec3(0.0);
|
||||||
|
vec3 skycontribution = vec3(0.0);
|
||||||
|
|
||||||
|
vec3 occlusion2 = vec3(0.0);
|
||||||
|
vec3 skycontribution2 = vec3(0.0);
|
||||||
|
|
||||||
|
// rgb = torch color * lightmap. a = sky lightmap.
|
||||||
|
vec4 Lighting = RT_AmbientLight(playerPos, lpvPos, Exposure, lightmaps, torchcolor);
|
||||||
|
skylightcolor = skylightcolor * ambient_brightness * Lighting.a;
|
||||||
|
|
||||||
|
for (int i = 0; i < nrays; i++){
|
||||||
|
int seed = (frameCounter%40000)*nrays+i;
|
||||||
|
vec2 ij = fract(R2_samples(seed) + noise.xy);
|
||||||
|
vec3 rayDir = TangentToWorld(normal, normalize(cosineHemisphereSample(ij)) ,1.0);
|
||||||
|
|
||||||
|
#ifdef HQ_SSGI
|
||||||
|
vec3 rayHit = rayTrace_GI( mat3(gbufferModelView) * rayDir, viewPos, noise.z, 50.); // ssr rt
|
||||||
|
#else
|
||||||
|
vec3 rayHit = RT(mat3(gbufferModelView)*rayDir, viewPos, noise.z, 30., hand); // choc sspt
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef SKY_CONTRIBUTION_IN_SSRT
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
if(isGrass) rayDir.y = clamp(rayDir.y + 0.5,-1,1);
|
||||||
|
|
||||||
|
// rayDir.y = mix(-1.0, rayDir.y, lightmaps.y*lightmaps.y);
|
||||||
|
|
||||||
|
skycontribution = ((skyCloudsFromTexLOD(rayDir, colortex4, 0).rgb / 30.0) * 2.5 * ambient_brightness) * Lighting.a + Lighting.rgb;
|
||||||
|
#else
|
||||||
|
skycontribution = ((skyCloudsFromTexLOD2(rayDir, colortex4, 6).rgb / 30.0) * 2.5 * ambient_brightness) * Lighting.a + Lighting.rgb;
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
|
||||||
|
#ifdef OVERWORLD_SHADER
|
||||||
|
if(isGrass) rayDir.y = clamp(rayDir.y + 0.25,-1,1);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
skycontribution = skylightcolor * (max(rayDir.y,pow(1.0-lightmaps.y,2))*0.95+0.05) + Lighting.rgb;
|
||||||
|
|
||||||
|
#if indirect_effect == 4
|
||||||
|
skycontribution2 = skylightcolor + Lighting.rgb;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (rayHit.z < 1.){
|
||||||
|
|
||||||
|
#if indirect_effect == 4
|
||||||
|
vec3 previousPosition = mat3(gbufferModelViewInverse) * toScreenSpace(rayHit) + gbufferModelViewInverse[3].xyz + cameraPosition-previousCameraPosition;
|
||||||
|
previousPosition = mat3(gbufferPreviousModelView) * previousPosition + gbufferPreviousModelView[3].xyz;
|
||||||
|
previousPosition.xy = projMAD(gbufferPreviousProjection, previousPosition).xy / -previousPosition.z * 0.5 + 0.5;
|
||||||
|
|
||||||
|
if (previousPosition.x > 0.0 && previousPosition.y > 0.0 && previousPosition.x < 1.0 && previousPosition.x < 1.0){
|
||||||
|
radiance += texture2D(colortex5, previousPosition.xy).rgb * GI_Strength + skycontribution;
|
||||||
|
|
||||||
|
} else{
|
||||||
|
radiance += skycontribution;
|
||||||
|
}
|
||||||
|
|
||||||
|
#else
|
||||||
|
radiance += skycontribution;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
occlusion += skycontribution * GI_Strength;
|
||||||
|
|
||||||
|
#if indirect_effect == 4
|
||||||
|
occlusion2 += skycontribution2 * GI_Strength;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
} else {
|
||||||
|
radiance += skycontribution;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
occlusion *= AO_Strength;
|
||||||
|
|
||||||
|
#if indirect_effect == 4
|
||||||
|
lighting = max(radiance/nrays - max(occlusion, occlusion2*0.5)/nrays, 0.0);
|
||||||
|
#else
|
||||||
|
lighting = max(radiance/nrays - occlusion/nrays, 0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(hand) lighting = skylightcolor/1.5;
|
||||||
|
}
|
|
@ -0,0 +1,25 @@
|
||||||
|
#define ITEM_LIGHT_SOURCES 1000
|
||||||
|
#define ITEM_AMETHYST_BUD_LARGE 1001
|
||||||
|
#define ITEM_AMETHYST_BUD_MEDIUM 1002
|
||||||
|
#define ITEM_AMETHYST_CLUSTER 1003
|
||||||
|
#define ITEM_BEACON 1004
|
||||||
|
#define ITEM_BLAZE_ROD 1005
|
||||||
|
#define ITEM_END_ROD 1006
|
||||||
|
#define ITEM_FROGLIGHT_OCHRE 1007
|
||||||
|
#define ITEM_FROGLIGHT_PEARLESCENT 1008
|
||||||
|
#define ITEM_FROGLIGHT_VERDANT 1009
|
||||||
|
#define ITEM_GLOW_BERRIES 1010
|
||||||
|
#define ITEM_GLOW_LICHEN 1011
|
||||||
|
#define ITEM_GLOWSTONE 1012
|
||||||
|
#define ITEM_GLOWSTONE_DUST 1013
|
||||||
|
#define ITEM_JACK_O_LANTERN 1014
|
||||||
|
#define ITEM_LANTERN 1015
|
||||||
|
#define ITEM_LAVA_BUCKET 1016
|
||||||
|
#define ITEM_MAGMA 1017
|
||||||
|
#define ITEM_REDSTONE_TORCH 1018
|
||||||
|
#define ITEM_SCULK_CATALYST 1019
|
||||||
|
#define ITEM_SEA_LANTERN 1020
|
||||||
|
#define ITEM_SHROOMLIGHT 1021
|
||||||
|
#define ITEM_SOUL_LANTERN 1022
|
||||||
|
#define ITEM_SOUL_TORCH 1023
|
||||||
|
#define ITEM_TORCH 1024
|
|
@ -0,0 +1,62 @@
|
||||||
|
uniform vec3 lightningEffect;
|
||||||
|
#ifdef IS_IRIS
|
||||||
|
uniform vec4 lightningBoltPosition;
|
||||||
|
#else
|
||||||
|
vec4 lightningBoltPosition = vec4(0.0, 100.0, 0.0, lightningEffect.x);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec3 Iris_Lightningflash(vec3 feetPlayerPos, vec3 lightningBoltPos, vec3 WorldSpace_normal, inout float Phase){
|
||||||
|
if(lightningBoltPosition.w > 0.0){
|
||||||
|
vec3 LightningPos = feetPlayerPos - vec3(lightningBoltPosition.x, clamp(feetPlayerPos.y, lightningBoltPosition.y+16, lightningBoltPosition.y+116.0),lightningBoltPosition.z);
|
||||||
|
|
||||||
|
// point light, max distance is ~500 blocks (the maximim entity render distance)
|
||||||
|
float lightDistance = 300.0 ;
|
||||||
|
float lightningLight = max(1.0 - length(LightningPos) / lightDistance, 0.0);
|
||||||
|
|
||||||
|
// the light above ^^^ is a linear curve. me no likey. here's an exponential one instead.
|
||||||
|
lightningLight = exp((1.0 - lightningLight) * -10.0);
|
||||||
|
|
||||||
|
// a phase for subsurface scattering.
|
||||||
|
vec3 PhasePos = normalize(feetPlayerPos) + vec3(lightningBoltPosition.x, lightningBoltPosition.y + 60, lightningBoltPosition.z);
|
||||||
|
float PhaseOrigin = 1.0 - clamp(dot(normalize(feetPlayerPos), normalize(PhasePos)),0.0,1.0);
|
||||||
|
Phase = exp(sqrt(PhaseOrigin) * -2.0) * 5.0 * lightningLight;
|
||||||
|
|
||||||
|
// good old NdotL. only normals facing towards the lightning bolt origin rise to 1.0
|
||||||
|
float NdotL = clamp(dot(LightningPos, -WorldSpace_normal), 0.0, 1.0);
|
||||||
|
|
||||||
|
return lightningEffect * lightningLight * NdotL;
|
||||||
|
}else return vec3(0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 Iris_Lightningflash_VLcloud(vec3 feetPlayerPos, vec3 lightningBoltPos){
|
||||||
|
if(lightningBoltPosition.w > 0.0){
|
||||||
|
vec3 LightningPos = feetPlayerPos - vec3(lightningBoltPosition.x, clamp(feetPlayerPos.y, lightningBoltPosition.y, lightningBoltPosition.y+116.0),lightningBoltPosition.z);
|
||||||
|
|
||||||
|
float lightDistance = 400.0;
|
||||||
|
float lightningLight = max(1.0 - length(LightningPos) / lightDistance, 0.0);
|
||||||
|
|
||||||
|
lightningLight = exp((1.0 - lightningLight) * -10.0);
|
||||||
|
|
||||||
|
return lightningEffect * lightningLight;
|
||||||
|
}else return vec3(0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 Iris_Lightningflash_VLfog(vec3 feetPlayerPos, vec3 lightningBoltPos){
|
||||||
|
if(lightningBoltPosition.w > 0.0){
|
||||||
|
if(lightningBoltPosition.w < 1.0) return vec3(0.0);
|
||||||
|
|
||||||
|
vec3 LightningPos = feetPlayerPos - vec3(lightningBoltPosition.x, clamp(feetPlayerPos.y, lightningBoltPosition.y, lightningBoltPosition.y+116.0),lightningBoltPosition.z);
|
||||||
|
|
||||||
|
#ifdef TEST
|
||||||
|
float lightningLight = max(1.0 - length(LightningPos) / 50, 0.0);
|
||||||
|
lightningLight = exp((1.0 - lightningLight) * -15.0) ;
|
||||||
|
#else
|
||||||
|
float lightDistance = 300.0;
|
||||||
|
float lightningLight = max(1.0 - length(LightningPos) / lightDistance, 0.0) ;
|
||||||
|
|
||||||
|
lightningLight = exp((1.0 - lightningLight) * -15.0) ;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return lightningEffect * lightningLight;
|
||||||
|
}else return vec3(0.0);
|
||||||
|
}
|
|
@ -0,0 +1,12 @@
|
||||||
|
/*
|
||||||
|
lightColor 3*8=24
|
||||||
|
lightRange 8=8
|
||||||
|
tintColor 3*8=24
|
||||||
|
lightMask 6=8
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifdef RENDER_SETUP
|
||||||
|
layout(rg32ui) uniform writeonly uimage1D imgBlockData;
|
||||||
|
#else
|
||||||
|
layout(rg32ui) uniform readonly uimage1D imgBlockData;
|
||||||
|
#endif
|
|
@ -0,0 +1,7 @@
|
||||||
|
#ifdef RENDER_SHADOWCOMP
|
||||||
|
layout(rgba8) uniform restrict image3D imgLpv1;
|
||||||
|
layout(rgba8) uniform restrict image3D imgLpv2;
|
||||||
|
#else
|
||||||
|
layout(rgba8) uniform readonly image3D imgLpv1;
|
||||||
|
layout(rgba8) uniform readonly image3D imgLpv2;
|
||||||
|
#endif
|
|
@ -0,0 +1,10 @@
|
||||||
|
// How far light propagates (block, sky)
|
||||||
|
const vec2 LpvBlockSkyRange = vec2(15.0, 24.0);
|
||||||
|
|
||||||
|
const uint LpvSize = uint(exp2(LPV_SIZE));
|
||||||
|
const uvec3 LpvSize3 = uvec3(LpvSize);
|
||||||
|
|
||||||
|
vec3 GetLpvPosition(const in vec3 playerPos) {
|
||||||
|
vec3 cameraOffset = fract(cameraPosition);
|
||||||
|
return playerPos + cameraOffset + LpvSize3/2u;
|
||||||
|
}
|
|
@ -0,0 +1,58 @@
|
||||||
|
// LPV falloff curve
|
||||||
|
const float LpvBlockPower = 4.0;
|
||||||
|
|
||||||
|
// LPV block brightness scale
|
||||||
|
const float LpvBlockBrightness = 2.0;
|
||||||
|
|
||||||
|
float lpvCurve(float values){
|
||||||
|
// return pow(values, LpvBlockPower) ;
|
||||||
|
return pow(1.0-sqrt(1.0-values),2.0);
|
||||||
|
// return values;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 SampleLpvNearest(const in ivec3 lpvPos) {
|
||||||
|
vec4 lpvSample = (frameCounter % 2) == 0
|
||||||
|
? texelFetch(texLpv1, lpvPos, 0)
|
||||||
|
: texelFetch(texLpv2, lpvPos, 0);
|
||||||
|
|
||||||
|
lpvSample.b = lpvCurve(lpvSample.b) * LpvBlockSkyRange.x;
|
||||||
|
lpvSample.rgb = HsvToRgb(lpvSample.rgb);
|
||||||
|
|
||||||
|
return lpvSample;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 SampleLpvLinear(const in vec3 lpvPos) {
|
||||||
|
vec3 pos = lpvPos - 0.5;
|
||||||
|
ivec3 lpvCoord = ivec3(floor(pos));
|
||||||
|
vec3 lpvF = fract(pos);
|
||||||
|
|
||||||
|
vec4 sample_x1y1z1 = SampleLpvNearest(lpvCoord + ivec3(0, 0, 0));
|
||||||
|
vec4 sample_x2y1z1 = SampleLpvNearest(lpvCoord + ivec3(1, 0, 0));
|
||||||
|
vec4 sample_x1y2z1 = SampleLpvNearest(lpvCoord + ivec3(0, 1, 0));
|
||||||
|
vec4 sample_x2y2z1 = SampleLpvNearest(lpvCoord + ivec3(1, 1, 0));
|
||||||
|
|
||||||
|
vec4 sample_x1y1z2 = SampleLpvNearest(lpvCoord + ivec3(0, 0, 1));
|
||||||
|
vec4 sample_x2y1z2 = SampleLpvNearest(lpvCoord + ivec3(1, 0, 1));
|
||||||
|
vec4 sample_x1y2z2 = SampleLpvNearest(lpvCoord + ivec3(0, 1, 1));
|
||||||
|
vec4 sample_x2y2z2 = SampleLpvNearest(lpvCoord + ivec3(1, 1, 1));
|
||||||
|
|
||||||
|
vec4 sample_y1z1 = mix(sample_x1y1z1, sample_x2y1z1, lpvF.x);
|
||||||
|
vec4 sample_y2z1 = mix(sample_x1y2z1, sample_x2y2z1, lpvF.x);
|
||||||
|
|
||||||
|
vec4 sample_y1z2 = mix(sample_x1y1z2, sample_x2y1z2, lpvF.x);
|
||||||
|
vec4 sample_y2z2 = mix(sample_x1y2z2, sample_x2y2z2, lpvF.x);
|
||||||
|
|
||||||
|
vec4 sample_z1 = mix(sample_y1z1, sample_y2z1, lpvF.y);
|
||||||
|
vec4 sample_z2 = mix(sample_y1z2, sample_y2z2, lpvF.y);
|
||||||
|
|
||||||
|
return mix(sample_z1, sample_z2, lpvF.z);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 GetLpvBlockLight(const in vec4 lpvSample) {
|
||||||
|
return LpvBlockBrightness * lpvSample.rgb;
|
||||||
|
}
|
||||||
|
|
||||||
|
float GetLpvSkyLight(const in vec4 lpvSample) {
|
||||||
|
float skyLight = saturate(lpvSample.a);
|
||||||
|
return skyLight*skyLight;
|
||||||
|
}
|
|
@ -0,0 +1,107 @@
|
||||||
|
float densityAtPosFog(in vec3 pos){
|
||||||
|
pos /= 18.;
|
||||||
|
pos.xz *= 0.5;
|
||||||
|
|
||||||
|
vec3 p = floor(pos);
|
||||||
|
vec3 f = fract(pos);
|
||||||
|
|
||||||
|
f = (f*f) * (3.-2.*f);
|
||||||
|
vec2 uv = p.xz + f.xz + p.y * vec2(0.0,193.0);
|
||||||
|
vec2 coord = uv / 512.0;
|
||||||
|
vec2 xy = texture2D(noisetex, coord).yx;
|
||||||
|
return mix(xy.r,xy.g, f.y);
|
||||||
|
}
|
||||||
|
|
||||||
|
float cloudVol(in vec3 pos){
|
||||||
|
float Output = 0.0;
|
||||||
|
vec3 samplePos = pos*vec3(1.0,1./48.,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
float Wind = pow(max(pos.y-30,0.0) / 15.0,2.1);
|
||||||
|
|
||||||
|
float Plumes = texture2D(noisetex, (samplePos.xz + Wind)/256.0).b;
|
||||||
|
float floorPlumes = clamp(0.3 - exp(Plumes * -6),0,1);
|
||||||
|
Plumes *= Plumes;
|
||||||
|
|
||||||
|
float Erosion = densityAtPosFog(samplePos * 400 - frameTimeCounter*10 - Wind*10) *0.7+0.3 ;
|
||||||
|
|
||||||
|
// float maxdist = clamp((12 * 8) - length(pos - cameraPosition),0.0,1.0);
|
||||||
|
|
||||||
|
float RoofToFloorDensityFalloff = exp(max(100-pos.y,0.0) / -15);
|
||||||
|
float FloorDensityFalloff = pow(exp(max(pos.y-31,0.0) / -3.0),2);
|
||||||
|
float RoofDensityFalloff = exp(max(120-pos.y,0.0) / -10);
|
||||||
|
|
||||||
|
Output = max((RoofToFloorDensityFalloff - Plumes * (1.0-Erosion)) * 2.0, clamp((FloorDensityFalloff - floorPlumes*0.5) * Erosion ,0.0,1.0) );
|
||||||
|
|
||||||
|
return Output;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 GetVolumetricFog(
|
||||||
|
vec3 viewPos,
|
||||||
|
float dither,
|
||||||
|
float dither2
|
||||||
|
){
|
||||||
|
|
||||||
|
#ifndef TOGGLE_VL_FOG
|
||||||
|
return vec4(0.0,0.0,0.0,1.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
int SAMPLES = 16;
|
||||||
|
vec3 vL = vec3(0.0);
|
||||||
|
float absorbance = 1.0;
|
||||||
|
|
||||||
|
//project pixel position into projected shadowmap space
|
||||||
|
vec3 wpos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 fragposition = mat3(shadowModelView) * wpos + shadowModelView[3].xyz;
|
||||||
|
fragposition = diagonal3(shadowProjection) * fragposition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
//project view origin into projected shadowmap space
|
||||||
|
vec3 start = toShadowSpaceProjected(vec3(0.));
|
||||||
|
|
||||||
|
//rayvector into projected shadow map space
|
||||||
|
//we can use a projected vector because its orthographic projection
|
||||||
|
//however we still have to send it to curved shadow map space every step
|
||||||
|
vec3 dV = fragposition-start;
|
||||||
|
vec3 dVWorld = (wpos-gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
float maxLength = min(length(dVWorld),far)/length(dVWorld);
|
||||||
|
|
||||||
|
dV *= maxLength;
|
||||||
|
dVWorld *= maxLength;
|
||||||
|
|
||||||
|
float dL = length(dVWorld);
|
||||||
|
vec3 fogcolor = (gl_Fog.color.rgb / max(dot(gl_Fog.color.rgb,vec3(0.3333)),0.05)) ;
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<SAMPLES;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither)/float(SAMPLES))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
float dd = pow(expFactor, float(i+dither)/float(SAMPLES)) * log(expFactor) / float(SAMPLES)/(expFactor-1.0);
|
||||||
|
vec3 progress = start.xyz + d*dV;
|
||||||
|
vec3 progressW = gbufferModelViewInverse[3].xyz+cameraPosition + d*dVWorld;
|
||||||
|
|
||||||
|
// do main lighting
|
||||||
|
float Density = cloudVol(progressW) * pow(exp(max(progressW.y-65,0.0) / -15),2);
|
||||||
|
|
||||||
|
float clearArea = 1.0-min(max(1.0 - length(progressW - cameraPosition) / 100,0.0),1.0);
|
||||||
|
Density = min(Density * clearArea, NETHER_PLUME_DENSITY);
|
||||||
|
|
||||||
|
float fireLight = cloudVol(progressW - vec3(0,1,0)) * clamp(exp(max(30 - progressW.y,0.0) / -10.0),0,1);
|
||||||
|
|
||||||
|
vec3 vL0 = vec3(1.0,0.4,0.2) * exp(fireLight * -25) * exp(max(progressW.y-30,0.0) / -10) * 25;
|
||||||
|
vL0 += vec3(0.8,0.8,1.0) * (1.0 - exp(Density * -1)) / 10 ;
|
||||||
|
|
||||||
|
|
||||||
|
// do background fog lighting
|
||||||
|
float AirDensity = 0.01;
|
||||||
|
vec3 vL1 = fogcolor / 20.0;
|
||||||
|
|
||||||
|
vL += (vL1 - vL1*exp(-AirDensity*dd*dL)) * absorbance;
|
||||||
|
vL += (vL0 - vL0*exp(-Density*dd*dL)) * absorbance;
|
||||||
|
|
||||||
|
absorbance *= exp(-(Density+AirDensity)*dd*dL);
|
||||||
|
|
||||||
|
if (absorbance < 1e-5) break;
|
||||||
|
}
|
||||||
|
// return vec4(0.0,0.0,0.0,1.0);
|
||||||
|
return vec4(vL, absorbance);
|
||||||
|
}
|
|
@ -0,0 +1,313 @@
|
||||||
|
|
||||||
|
|
||||||
|
uniform float noPuddleAreas;
|
||||||
|
float densityAtPosFog(in vec3 pos){
|
||||||
|
pos /= 18.;
|
||||||
|
pos.xz *= 0.5;
|
||||||
|
vec3 p = floor(pos);
|
||||||
|
vec3 f = fract(pos);
|
||||||
|
f = (f*f) * (3.-2.*f);
|
||||||
|
vec2 uv = p.xz + f.xz + p.y * vec2(0.0,193.0);
|
||||||
|
vec2 coord = uv / 512.0;
|
||||||
|
vec2 xy = texture2D(noisetex, coord).yx;
|
||||||
|
return mix(xy.r,xy.g, f.y);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
float cloudVol(in vec3 pos, float maxDistance ){
|
||||||
|
|
||||||
|
vec3 samplePos = pos*vec3(1.0,1./24.,1.0);
|
||||||
|
vec3 samplePos2 = pos*vec3(1.0,1./48.,1.0);
|
||||||
|
float fogYstart = FOG_START_HEIGHT+3;
|
||||||
|
|
||||||
|
float mult = exp( -max((pos.y - fogYstart) / 35.,0.0));
|
||||||
|
float fog_shape = 1.0 - densityAtPosFog(samplePos * 24.0 );
|
||||||
|
float fog_eroded = 1.0 - densityAtPosFog(samplePos2 * 200.0 );
|
||||||
|
|
||||||
|
// float CloudyFog = max( (fog_shape*2.0 - fog_eroded*0.5) - 1.2, max(fog_shape-0.8,0.0)) * mult;
|
||||||
|
|
||||||
|
float heightlimit = exp2( -max((pos.y - fogYstart * (1.0+snowStorm)) / 25.,0.0));
|
||||||
|
float CloudyFog = max((fog_shape*1.2 - fog_eroded*0.2) - 0.75,0.0) * heightlimit ;
|
||||||
|
|
||||||
|
float UniformFog = exp( max(pos.y - fogYstart,0.0) / -25);
|
||||||
|
// UniformFog = 1.0;
|
||||||
|
|
||||||
|
float RainFog = ((2 + max(fog_shape*10. - 7.0,0.5)*2.0)) *UniformFog* rainStrength * noPuddleAreas * RainFog_amount;
|
||||||
|
// float RainFog = (CloudyFog*255) * rainStrength * noPuddleAreas * RainFog_amount;
|
||||||
|
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
// sandstorms and snowstorms
|
||||||
|
if(sandStorm > 0 || snowStorm > 0) CloudyFog = mix(CloudyFog, max(densityAtPosFog((samplePos2 - vec3(frameTimeCounter,0,frameTimeCounter)*10) * 100.0 ) - 0.2,0.0) * heightlimit, sandStorm+snowStorm);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
TimeOfDayFog(UniformFog, CloudyFog, maxDistance);
|
||||||
|
|
||||||
|
float noise = densityAtPosFog(samplePos * 12.0);
|
||||||
|
float erosion = 1.0-densityAtPosFog(samplePos2 * (125 - (1-pow(1-noise,5))*25));
|
||||||
|
|
||||||
|
|
||||||
|
// float clumpyFog = max(exp(noise * -5)*2 - (erosion*erosion), 0.0);
|
||||||
|
|
||||||
|
// float testfogshapes = clumpyFog*30;
|
||||||
|
// return testfogshapes;
|
||||||
|
|
||||||
|
// return max(exp( max(pos.y - 90,0.0) / -1), 0.0) * 100;
|
||||||
|
return CloudyFog + UniformFog + RainFog;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
float phaseRayleigh(float cosTheta) {
|
||||||
|
const vec2 mul_add = vec2(0.1, 0.28) / acos(-1.0);
|
||||||
|
return cosTheta * mul_add.x + mul_add.y; // optimized version from [Elek09], divided by 4 pi for energy conservation
|
||||||
|
}
|
||||||
|
float fogPhase(float lightPoint){
|
||||||
|
float linear = 1.0 - clamp(lightPoint*0.5+0.5,0.0,1.0);
|
||||||
|
float linear2 = 1.0 - clamp(lightPoint,0.0,1.0);
|
||||||
|
|
||||||
|
float exponential = exp2(pow(linear,0.3) * -15.0 ) * 1.5;
|
||||||
|
exponential += sqrt(exp2(sqrt(linear) * -12.5));
|
||||||
|
|
||||||
|
return exponential;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 GetVolumetricFog(
|
||||||
|
vec3 viewPosition,
|
||||||
|
vec2 dither,
|
||||||
|
vec3 LightColor,
|
||||||
|
vec3 AmbientColor
|
||||||
|
){
|
||||||
|
|
||||||
|
#ifndef TOGGLE_VL_FOG
|
||||||
|
return vec4(0.0,0.0,0.0,1.0);
|
||||||
|
#endif
|
||||||
|
int SAMPLECOUNT = VL_SAMPLES;
|
||||||
|
/// ------------- RAYMARCHING STUFF ------------- \\\
|
||||||
|
|
||||||
|
//project pixel position into projected shadowmap space
|
||||||
|
|
||||||
|
vec3 wpos = mat3(gbufferModelViewInverse) * viewPosition + gbufferModelViewInverse[3].xyz;
|
||||||
|
vec3 fragposition = mat3(shadowModelView) * wpos + shadowModelView[3].xyz;
|
||||||
|
fragposition = diagonal3(shadowProjection) * fragposition + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
//project view origin into projected shadowmap space
|
||||||
|
vec3 start = toShadowSpaceProjected(vec3(0.0));
|
||||||
|
|
||||||
|
//rayvector into projected shadow map space
|
||||||
|
//we can use a projected vector because its orthographic projection
|
||||||
|
//however we still have to send it to curved shadow map space every step
|
||||||
|
vec3 dV = fragposition - start;
|
||||||
|
vec3 dVWorld = (wpos-gbufferModelViewInverse[3].xyz);
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float maxLength = min(length(dVWorld), max(dhFarPlane-1000,0.0))/length(dVWorld);
|
||||||
|
SAMPLECOUNT += SAMPLECOUNT;
|
||||||
|
#else
|
||||||
|
float maxLength = min(length(dVWorld), far)/length(dVWorld);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
dV *= maxLength;
|
||||||
|
dVWorld *= maxLength;
|
||||||
|
|
||||||
|
float dL = length(dVWorld);
|
||||||
|
float mult = length(dVWorld)/25;
|
||||||
|
|
||||||
|
vec3 progress = start.xyz;
|
||||||
|
vec3 progressW = gbufferModelViewInverse[3].xyz + cameraPosition;
|
||||||
|
|
||||||
|
vec3 WsunVec = mat3(gbufferModelViewInverse) * sunVec * lightCol.a;
|
||||||
|
float SdotV = dot(sunVec,normalize(viewPosition))*lightCol.a;
|
||||||
|
|
||||||
|
|
||||||
|
/// ------------- COLOR/LIGHTING STUFF ------------- \\\
|
||||||
|
|
||||||
|
vec3 color = vec3(0.0);
|
||||||
|
vec3 absorbance = vec3(1.0);
|
||||||
|
|
||||||
|
///// ----- fog lighting
|
||||||
|
//Mie phase + somewhat simulates multiple scattering (Horizon zero down cloud approx)
|
||||||
|
float mie = fogPhase(SdotV) * 5.0;
|
||||||
|
float rayL = phaseRayleigh(SdotV);
|
||||||
|
|
||||||
|
vec3 rC = vec3(sky_coefficientRayleighR*1e-6, sky_coefficientRayleighG*1e-5, sky_coefficientRayleighB*1e-5);
|
||||||
|
vec3 mC = vec3(fog_coefficientMieR*1e-6, fog_coefficientMieG*1e-6, fog_coefficientMieB*1e-6);
|
||||||
|
|
||||||
|
vec3 skyLightPhased = AmbientColor;
|
||||||
|
vec3 LightSourcePhased = LightColor;
|
||||||
|
|
||||||
|
#ifdef ambientLight_only
|
||||||
|
LightSourcePhased = vec3(0.0);
|
||||||
|
#endif
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
vec3 biomeDirect = LightSourcePhased;
|
||||||
|
vec3 biomeIndirect = skyLightPhased;
|
||||||
|
float inBiome = BiomeVLFogColors(biomeDirect, biomeIndirect);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
skyLightPhased = max(skyLightPhased + skyLightPhased*(normalize(wpos).y*0.9+0.1),0.0);
|
||||||
|
LightSourcePhased *= mie;
|
||||||
|
|
||||||
|
float lightleakfix = clamp(pow(eyeBrightnessSmooth.y/240.,2) ,0.0,1.0);
|
||||||
|
|
||||||
|
#ifdef RAYMARCH_CLOUDS_WITH_FOG
|
||||||
|
vec3 SkyLightColor = AmbientColor;
|
||||||
|
vec3 LightSourceColor = LightColor;
|
||||||
|
|
||||||
|
#ifdef ambientLight_only
|
||||||
|
LightSourceColor = vec3(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float shadowStep = 200.0;
|
||||||
|
|
||||||
|
vec3 dV_Sun = WsunVec*shadowStep;
|
||||||
|
|
||||||
|
float mieDay = phaseg(SdotV, 0.75);
|
||||||
|
float mieDayMulti = (phaseg(SdotV, 0.35) + phaseg(-SdotV, 0.35) * 0.5) ;
|
||||||
|
|
||||||
|
vec3 directScattering = LightSourceColor * mieDay * 3.14;
|
||||||
|
vec3 directMultiScattering = LightSourceColor * mieDayMulti * 3.14;
|
||||||
|
|
||||||
|
vec3 sunIndirectScattering = LightSourceColor * phaseg(dot(mat3(gbufferModelView)*vec3(0,1,0),normalize(viewPosition)), 0.5) * 3.14;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef DISTANT_HORIZONS
|
||||||
|
float atmosphereMult = 1.0;
|
||||||
|
#else
|
||||||
|
float atmosphereMult = 1.5;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
float expFactor = 11.0;
|
||||||
|
for (int i=0;i<SAMPLECOUNT;i++) {
|
||||||
|
float d = (pow(expFactor, float(i+dither.x)/float(SAMPLECOUNT))/expFactor - 1.0/expFactor)/(1-1.0/expFactor);
|
||||||
|
float dd = pow(expFactor, float(i+dither.x)/float(SAMPLECOUNT)) * log(expFactor) / float(SAMPLECOUNT)/(expFactor-1.0);
|
||||||
|
progress = start.xyz + d*dV;
|
||||||
|
progressW = gbufferModelViewInverse[3].xyz+cameraPosition + d*dVWorld;
|
||||||
|
|
||||||
|
// float curvature = 1-exp(-25*pow(clamp(1.0 - length(progressW - cameraPosition)/(32*80),0.0,1.0),2));
|
||||||
|
|
||||||
|
//project into biased shadowmap space
|
||||||
|
#ifdef DISTORT_SHADOWMAP
|
||||||
|
float distortFactor = calcDistort(progress.xy);
|
||||||
|
#else
|
||||||
|
float distortFactor = 1.0;
|
||||||
|
#endif
|
||||||
|
vec3 pos = vec3(progress.xy*distortFactor, progress.z);
|
||||||
|
|
||||||
|
vec3 sh = vec3(1.0);
|
||||||
|
|
||||||
|
if (abs(pos.x) < 1.0-0.5/2048. && abs(pos.y) < 1.0-0.5/2048){
|
||||||
|
pos = pos*vec3(0.5,0.5,0.5/6.0)+0.5;
|
||||||
|
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
sh = vec3(shadow2D(shadowtex0, pos).x);
|
||||||
|
|
||||||
|
if(shadow2D(shadowtex1, pos).x > pos.z && sh.x < 1.0){
|
||||||
|
vec4 translucentShadow = texture2D(shadowcolor0, pos.xy);
|
||||||
|
if(translucentShadow.a < 0.9) sh = normalize(translucentShadow.rgb+0.0001);
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
sh = vec3(shadow2D(shadow, pos).x);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
}
|
||||||
|
vec3 sh2 = sh;
|
||||||
|
|
||||||
|
#ifdef VL_CLOUDS_SHADOWS
|
||||||
|
// if(clamp(progressW.y - CloudLayer1_height,0.0,1.0) < 1.0 && clamp(progressW.y-50,0.0,1.0) > 0.0)
|
||||||
|
sh *= GetCloudShadow_VLFOG(progressW, WsunVec);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
float maxDistance = inBiome * min(max(1.0 - length(d*dVWorld.xz)/(32*8),0.0)*2.0,1.0);
|
||||||
|
float densityVol = cloudVol(progressW, maxDistance) * lightleakfix;
|
||||||
|
#else
|
||||||
|
float densityVol = cloudVol(progressW, 0.0) * lightleakfix;
|
||||||
|
#endif
|
||||||
|
//Water droplets(fog)
|
||||||
|
float density = densityVol*300.0;
|
||||||
|
|
||||||
|
///// ----- main fog lighting
|
||||||
|
|
||||||
|
//Just air
|
||||||
|
vec2 airCoef = exp(-max(progressW.y - SEA_LEVEL, 0.0) / vec2(8.0e3, 1.2e3) * vec2(6.,7.0)) * (atmosphereMult * 24.0) * Haze_amount * clamp(CloudLayer0_height - progressW.y + max(eyeAltitude-(CloudLayer0_height-50),0),0.0,1.0);
|
||||||
|
|
||||||
|
//Pbr for air, yolo mix between mie and rayleigh for water droplets
|
||||||
|
vec3 rL = rC*airCoef.x;
|
||||||
|
vec3 m = (airCoef.y+density) * mC;
|
||||||
|
|
||||||
|
#ifdef PER_BIOME_ENVIRONMENT
|
||||||
|
vec3 Atmosphere = mix(skyLightPhased, biomeDirect, maxDistance) * (rL + m); // not pbr so just make the atmosphere also dense fog heh
|
||||||
|
vec3 DirectLight = mix(LightSourcePhased, biomeIndirect, maxDistance) * sh * (rL*rayL + m);
|
||||||
|
#else
|
||||||
|
vec3 Atmosphere = skyLightPhased * (rL + m); // not pbr so just make the atmosphere also dense fog heh
|
||||||
|
vec3 DirectLight = LightSourcePhased * sh * (rL*rayL + m);
|
||||||
|
#endif
|
||||||
|
vec3 Lightning = Iris_Lightningflash_VLfog(progressW-cameraPosition, lightningBoltPosition.xyz) * (rL + m);
|
||||||
|
|
||||||
|
vec3 foglighting = (Atmosphere + DirectLight + Lightning) * lightleakfix;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
color += (foglighting - foglighting * exp(-(rL+m)*dd*dL)) / ((rL+m)+0.00000001)*absorbance;
|
||||||
|
absorbance *= clamp(exp(-(rL+m)*dd*dL),0.0,1.0);
|
||||||
|
|
||||||
|
#ifdef RAYMARCH_CLOUDS_WITH_FOG
|
||||||
|
//////////////////////////////////////////
|
||||||
|
///// ----- cloud part
|
||||||
|
//////////////////////////////////////////
|
||||||
|
// curvature = clamp(1.0 - length(progressW - cameraPosition)/(32*128),0.0,1.0);
|
||||||
|
|
||||||
|
|
||||||
|
float otherlayer = max(progressW.y - (CloudLayer0_height+99.5), 0.0) > 0.0 ? 0.0 : 1.0;
|
||||||
|
|
||||||
|
float DUAL_MIN_HEIGHT = otherlayer > 0.0 ? CloudLayer0_height : CloudLayer1_height;
|
||||||
|
float DUAL_MAX_HEIGHT = DUAL_MIN_HEIGHT + 100.0;
|
||||||
|
|
||||||
|
float DUAL_DENSITY = otherlayer > 0.0 ? CloudLayer0_density : CloudLayer1_density;
|
||||||
|
|
||||||
|
if(clamp(progressW.y - DUAL_MAX_HEIGHT,0.0,1.0) < 1.0 && clamp(progressW.y - DUAL_MIN_HEIGHT,0.0,1.0) > 0.0){
|
||||||
|
|
||||||
|
float DUAL_MIN_HEIGHT_2 = otherlayer > 0.0 ? CloudLayer0_height : CloudLayer1_height;
|
||||||
|
float DUAL_MAX_HEIGHT_2 = DUAL_MIN_HEIGHT + 100.0;
|
||||||
|
|
||||||
|
float cumulus = GetCumulusDensity(-1, progressW, 1, CloudLayer0_height, CloudLayer1_height);
|
||||||
|
float fadedDensity = DUAL_DENSITY * clamp(exp( (progressW.y - (DUAL_MAX_HEIGHT - 75)) / 9.0 ),0.0,1.0);
|
||||||
|
|
||||||
|
float muE = cumulus*fadedDensity;
|
||||||
|
float directLight = 0.0;
|
||||||
|
for (int j=0; j < 3; j++){
|
||||||
|
vec3 shadowSamplePos = progressW + dV_Sun * (0.1 + j * (0.1 + dither.y*0.05));
|
||||||
|
float shadow = GetCumulusDensity(-1, shadowSamplePos, 0, DUAL_MIN_HEIGHT, DUAL_MAX_HEIGHT) * DUAL_DENSITY;
|
||||||
|
|
||||||
|
directLight += shadow;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// shadows cast from one layer to another
|
||||||
|
/// large cumulus -> small cumulus
|
||||||
|
#if defined CloudLayer1 && defined CloudLayer0
|
||||||
|
if(otherlayer > 0.0) directLight += LAYER1_DENSITY * 2.0 * GetCumulusDensity(1, progressW + dV_Sun/abs(dV_Sun.y) * max((LAYER1_minHEIGHT+70*dither.y) - progressW.y,0.0), 0, LAYER1_minHEIGHT, LAYER1_maxHEIGHT);
|
||||||
|
#endif
|
||||||
|
// // altostratus -> cumulus
|
||||||
|
// #ifdef CloudLayer2
|
||||||
|
// vec3 HighAlt_shadowPos = rayProgress + dV_Sun/abs(dV_Sun.y) * max(LAYER2_HEIGHT - rayProgress.y,0.0);
|
||||||
|
// float HighAlt_shadow = GetAltostratusDensity(HighAlt_shadowPos) * CloudLayer2_density;
|
||||||
|
// directLight += HighAlt_shadow;
|
||||||
|
// #endif
|
||||||
|
|
||||||
|
|
||||||
|
float skyScatter = clamp(((DUAL_MAX_HEIGHT - 20 - progressW.y) / 275.0) * (0.5+DUAL_DENSITY),0.0,1.0);
|
||||||
|
float distantfade = 1- exp( -10*pow(clamp(1.0 - length(progressW - cameraPosition)/(32*65),0.0,1.0),2));
|
||||||
|
vec3 cloudlighting = DoCloudLighting(muE, cumulus, SkyLightColor, skyScatter, directLight, directScattering*sh2, directMultiScattering*sh2, 1);
|
||||||
|
|
||||||
|
color += max(cloudlighting - cloudlighting*exp(-muE*dd*dL),0.0) * absorbance;
|
||||||
|
absorbance *= max(exp(-muE*dd*dL),0.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (min(dot(absorbance,vec3(0.335)),1.0) < 1e-5) break;
|
||||||
|
}
|
||||||
|
return vec4(color, min(dot(absorbance,vec3(0.335)),1.0));
|
||||||
|
}
|
|
@ -0,0 +1,54 @@
|
||||||
|
uniform mat4 gbufferProjection;
|
||||||
|
uniform mat4 gbufferProjectionInverse;
|
||||||
|
uniform mat4 gbufferPreviousProjection;
|
||||||
|
uniform mat4 gbufferModelViewInverse;
|
||||||
|
uniform mat4 gbufferModelView;
|
||||||
|
uniform mat4 shadowModelView;
|
||||||
|
uniform mat4 shadowProjection;
|
||||||
|
|
||||||
|
uniform vec3 cameraPosition;
|
||||||
|
|
||||||
|
#define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z)
|
||||||
|
#define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz)
|
||||||
|
|
||||||
|
vec3 toClipSpace3(vec3 viewSpacePosition) {
|
||||||
|
return projMAD(gbufferProjection, viewSpacePosition) / -viewSpacePosition.z * 0.5 + 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toScreenSpace(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return fragposition.xyz / fragposition.w;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toScreenSpaceVector(vec3 p) {
|
||||||
|
vec4 iProjDiag = vec4(gbufferProjectionInverse[0].x, gbufferProjectionInverse[1].y, gbufferProjectionInverse[2].zw);
|
||||||
|
vec3 p3 = p * 2. - 1.;
|
||||||
|
vec4 fragposition = iProjDiag * p3.xyzz + gbufferProjectionInverse[3];
|
||||||
|
return normalize(fragposition.xyz);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toWorldSpace(vec3 p3){
|
||||||
|
p3 = mat3(gbufferModelViewInverse) * p3 + gbufferModelViewInverse[3].xyz;
|
||||||
|
return p3;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toWorldSpaceCamera(vec3 p3){
|
||||||
|
p3 = mat3(gbufferModelViewInverse) * p3 + gbufferModelViewInverse[3].xyz;
|
||||||
|
return p3 + cameraPosition;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toShadowSpace(vec3 p3){
|
||||||
|
p3 = mat3(gbufferModelViewInverse) * p3 + gbufferModelViewInverse[3].xyz;
|
||||||
|
p3 = mat3(shadowModelView) * p3 + shadowModelView[3].xyz;
|
||||||
|
return p3;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 toShadowSpaceProjected(vec3 p3){
|
||||||
|
p3 = mat3(gbufferModelViewInverse) * p3 + gbufferModelViewInverse[3].xyz;
|
||||||
|
p3 = mat3(shadowModelView) * p3 + shadowModelView[3].xyz;
|
||||||
|
p3 = diagonal3(shadowProjection) * p3 + shadowProjection[3].xyz;
|
||||||
|
|
||||||
|
return p3;
|
||||||
|
}
|
|
@ -0,0 +1,16 @@
|
||||||
|
#ifndef TAA
|
||||||
|
#undef TAA_UPSCALING
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TAA_UPSCALING
|
||||||
|
#define SCALE_FACTOR 0.75 // render resolution multiplier. below 0.5 not recommended [0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95]
|
||||||
|
|
||||||
|
#define RENDER_SCALE vec2(SCALE_FACTOR, SCALE_FACTOR)
|
||||||
|
#define UPSCALING_SHARPNENING 2.0 - SCALE_FACTOR - SCALE_FACTOR
|
||||||
|
#else
|
||||||
|
#define RENDER_SCALE vec2(1.0, 1.0)
|
||||||
|
#define UPSCALING_SHARPNENING 0.0
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define BLOOM_QUALITY 0.5 // Reduces the resolution at which bloom is computed. (0.5 = half of default resolution) [0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1. ]
|
||||||
|
#define VL_RENDER_RESOLUTION 0.5 // Reduces the resolution at which volumetric fog is computed. (0.5 = half of default resolution) [0.25 0.5 1.0]
|
|
@ -0,0 +1,753 @@
|
||||||
|
#define saturate(x) clamp(x,0.0,1.0)
|
||||||
|
|
||||||
|
#define BLISS_SHADERS 0 // [0 1 2]
|
||||||
|
|
||||||
|
////////////////////////////////////////
|
||||||
|
// ----- WATER RELATED SETTINGS ----- //
|
||||||
|
////////////////////////////////////////
|
||||||
|
|
||||||
|
// #define Vanilla_like_water
|
||||||
|
#define WATER_WAVE_STRENGTH 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define WATER_WAVE_SPEED 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Dirt_Amount 0.14 // [0.0 0.04 0.08 0.12 0.16 0.2 0.24 0.28 0.32 0.36 0.4 0.44 0.48 0.52 0.56 0.6 0.64 0.68 0.72 0.76 0.8 0.84 0.88 0.92 0.96 1.0 1.04 1.08 1.12 1.16 1.2 1.24 1.28 1.32 1.36 1.4 1.44 1.48 1.52 1.56 1.6 1.64 1.68 1.72 1.76 1.8 1.84 1.88 1.92 1.96 2.0 ]
|
||||||
|
|
||||||
|
#define Dirt_Scatter_R 0.7 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 ]
|
||||||
|
#define Dirt_Scatter_G 0.7 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 ]
|
||||||
|
#define Dirt_Scatter_B 0.7 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 ]
|
||||||
|
#define Dirt_Absorb_R 0.65 // [0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 1.02 1.04 1.06 1.08 1.1 1.12 1.14 1.16 1.18 1.2 1.22 1.24 1.26 1.28 1.3 1.32 1.34 1.36 1.38 1.4 1.42 1.44 1.46 1.48 1.5 1.52 1.54 1.56 1.58 1.6 1.62 1.64 1.66 1.68 1.7 1.72 1.74 1.76 1.78 1.8 1.82 1.84 1.86 1.88 1.9 1.92 1.94 1.96 1.98 2.0 ]
|
||||||
|
#define Dirt_Absorb_G 0.85 // [0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 1.02 1.04 1.06 1.08 1.1 1.12 1.14 1.16 1.18 1.2 1.22 1.24 1.26 1.28 1.3 1.32 1.34 1.36 1.38 1.4 1.42 1.44 1.46 1.48 1.5 1.52 1.54 1.56 1.58 1.6 1.62 1.64 1.66 1.68 1.7 1.72 1.74 1.76 1.78 1.8 1.82 1.84 1.86 1.88 1.9 1.92 1.94 1.96 1.98 2.0 ]
|
||||||
|
#define Dirt_Absorb_B 1.05 // [0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 1.02 1.04 1.06 1.08 1.1 1.12 1.14 1.16 1.18 1.2 1.22 1.24 1.26 1.28 1.3 1.32 1.34 1.36 1.38 1.4 1.42 1.44 1.46 1.48 1.5 1.52 1.54 1.56 1.58 1.6 1.62 1.64 1.66 1.68 1.7 1.72 1.74 1.76 1.78 1.8 1.82 1.84 1.86 1.88 1.9 1.92 1.94 1.96 1.98 2.0 ]
|
||||||
|
#define Water_Absorb_R 0.2629 // [0.0 0.0025 0.005 0.0075 0.01 0.0125 0.015 0.0175 0.02 0.0225 0.025 0.0275 0.03 0.0325 0.035 0.0375 0.04 0.0425 0.045 0.0475 0.05 0.0525 0.055 0.0575 0.06 0.0625 0.065 0.0675 0.07 0.0725 0.075 0.0775 0.08 0.0825 0.085 0.0875 0.09 0.0925 0.095 0.0975 0.1 0.1025 0.105 0.1075 0.11 0.1125 0.115 0.1175 0.12 0.1225 0.125 0.1275 0.13 0.1325 0.135 0.1375 0.14 0.1425 0.145 0.1475 0.15 0.1525 0.155 0.1575 0.16 0.1625 0.165 0.1675 0.17 0.1725 0.175 0.1775 0.18 0.1825 0.185 0.1875 0.19 0.1925 0.195 0.1975 0.2 0.2025 0.205 0.2075 0.21 0.2125 0.215 0.2175 0.22 0.2225 0.225 0.2275 0.23 0.2325 0.235 0.2375 0.24 0.2425 0.245 0.2475 0.25 ]
|
||||||
|
#define Water_Absorb_G 0.0565 // [0.0 0.0025 0.005 0.0075 0.01 0.0125 0.015 0.0175 0.02 0.0225 0.025 0.0275 0.03 0.0325 0.035 0.0375 0.04 0.0425 0.045 0.0475 0.05 0.0525 0.055 0.0575 0.06 0.0625 0.065 0.0675 0.07 0.0725 0.075 0.0775 0.08 0.0825 0.085 0.0875 0.09 0.0925 0.095 0.0975 0.1 0.1025 0.105 0.1075 0.11 0.1125 0.115 0.1175 0.12 0.1225 0.125 0.1275 0.13 0.1325 0.135 0.1375 0.14 0.1425 0.145 0.1475 0.15 0.1525 0.155 0.1575 0.16 0.1625 0.165 0.1675 0.17 0.1725 0.175 0.1775 0.18 0.1825 0.185 0.1875 0.19 0.1925 0.195 0.1975 0.2 0.2025 0.205 0.2075 0.21 0.2125 0.215 0.2175 0.22 0.2225 0.225 0.2275 0.23 0.2325 0.235 0.2375 0.24 0.2425 0.245 0.2475 0.25 ]
|
||||||
|
#define Water_Absorb_B 0.01011 // [0.0 0.0025 0.005 0.0075 0.01 0.0125 0.015 0.0175 0.02 0.0225 0.025 0.0275 0.03 0.0325 0.035 0.0375 0.04 0.0425 0.045 0.0475 0.05 0.0525 0.055 0.0575 0.06 0.0625 0.065 0.0675 0.07 0.0725 0.075 0.0775 0.08 0.0825 0.085 0.0875 0.09 0.0925 0.095 0.0975 0.1 0.1025 0.105 0.1075 0.11 0.1125 0.115 0.1175 0.12 0.1225 0.125 0.1275 0.13 0.1325 0.135 0.1375 0.14 0.1425 0.145 0.1475 0.15 0.1525 0.155 0.1575 0.16 0.1625 0.165 0.1675 0.17 0.1725 0.175 0.1775 0.18 0.1825 0.185 0.1875 0.19 0.1925 0.195 0.1975 0.2 0.2025 0.205 0.2075 0.21 0.2125 0.215 0.2175 0.22 0.2225 0.225 0.2275 0.23 0.2325 0.235 0.2375 0.24 0.2425 0.245 0.2475 0.25 ]
|
||||||
|
|
||||||
|
#define rayMarchSampleCount 2 // [1 2 3 4 6 8 12 16 32 64]
|
||||||
|
#define Water_Top_Layer 62.90 // [0.90 1.90 2.90 3.90 4.90 5.90 6.90 7.90 8.90 9.90 10.90 11.90 12.90 13.90 14.90 15.90 16.90 17.90 18.90 19.90 20.90 21.90 22.90 23.90 24.90 25.90 26.90 27.90 28.90 29.90 30.90 31.90 32.90 33.90 34.90 35.90 36.90 37.90 38.90 39.90 40.90 41.90 42.90 43.90 44.90 45.90 46.90 47.90 48.90 49.90 50.90 51.90 52.90 53.90 54.90 55.90 56.90 57.90 58.90 59.90 60.90 61.90 62.90 63.90 64.90 65.90 66.90 67.90 68.90 69.90 70.90 71.90 72.90 73.90 74.90 75.90 76.90 77.90 78.90 79.90 80.90 81.90 82.90 83.90 84.90 85.90 86.90 87.90 88.90 89.90 90.90 91.90 92.90 93.90 94.90 95.90 96.90 97.90 98.90 99.90 100.90 101.90 102.90 103.90 104.90 105.90 106.90 107.90 108.90 109.90 110.90 111.90 112.90 113.90 114.90 115.90 116.90 117.90 118.90 119.90 120.90 121.90 122.90 123.90 124.90 125.90 126.90 127.90 128.90 129.90 130.90 131.90 132.90 133.90 134.90 135.90 136.90 137.90 138.90 139.90 140.90 141.90 142.90 143.90 144.90 145.90 146.90 147.90 148.90 149.90 150.90 151.90 152.90 153.90 154.90 155.90 156.90 157.90 158.90 159.90 160.90 161.90 162.90 163.90 164.90 165.90 166.90 167.90 168.90 169.90 170.90 171.90 172.90 173.90 174.90 175.90 176.90 177.90 178.90 179.90 180.90 181.90 182.90 183.90 184.90 185.90 186.90 187.90 188.90 189.90 190.90 191.90 192.90 193.90 194.90 195.90 196.90 197.90 198.90 199.90]
|
||||||
|
|
||||||
|
#define Refraction
|
||||||
|
|
||||||
|
#define SSR_STEPS 30 // [10 15 20 25 30 35 40 50 100 200 400]
|
||||||
|
#define USE_QUARTER_RES_DEPTH
|
||||||
|
#define WATER_REFLECTIONS
|
||||||
|
#define WATER_BACKGROUND_SPECULAR
|
||||||
|
#define WATER_SUN_SPECULAR
|
||||||
|
#define SCREENSPACE_REFLECTIONS
|
||||||
|
// #define WATER_HQ_SMOOTHNESS
|
||||||
|
|
||||||
|
#define SNELLS_WINDOW
|
||||||
|
|
||||||
|
////////////////////////////////////////
|
||||||
|
// ----- PLANT RELATED SETTINGS ----- //
|
||||||
|
////////////////////////////////////////
|
||||||
|
|
||||||
|
#define WAVY_PLANTS
|
||||||
|
#define WAVY_STRENGTH 1.0 // [0.1 0.25 0.5 0.75 1.0 1.25 1.5 1.75 2.0]
|
||||||
|
#define WAVY_SPEED 1.0 // [0.001 0.01 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 1.0 1.25 1.5 2.0 3.0 4.0]
|
||||||
|
|
||||||
|
// #define Seasons
|
||||||
|
#define Season_Length 24 // [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91]
|
||||||
|
#define Start_Season 0 // [0 1 2 3]
|
||||||
|
// #define Snowy_Winter
|
||||||
|
|
||||||
|
#define Summer_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Summer_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Summer_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Summer_Leaf_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Summer_Leaf_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Summer_Leaf_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Fall_R 1.5 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Fall_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Fall_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Fall_Leaf_R 1.8 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Fall_Leaf_G 0.9 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Fall_Leaf_B 0.7 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Winter_R 1.2 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Winter_G 0.8 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Winter_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Winter_Leaf_R 1.2 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Winter_Leaf_G 0.5 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Winter_Leaf_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Spring_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Spring_G 0.9 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Spring_B 1.1 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Spring_Leaf_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Spring_Leaf_G 0.8 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define Spring_Leaf_B 0.8 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////
|
||||||
|
// ----- INDIRECT LIGHT RELATED SETTINGS ----- //
|
||||||
|
/////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#define MIN_LIGHT_AMOUNT 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 100.0 ]
|
||||||
|
#define ambient_brightness 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ]
|
||||||
|
|
||||||
|
#define AmbientLight_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define AmbientLight_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define AmbientLight_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
|
||||||
|
|
||||||
|
#define TORCH_AMOUNT 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0]
|
||||||
|
#define TORCH_R 1.0 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define TORCH_G 0.75 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define TORCH_B 0.65 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
|
||||||
|
#define Hand_Held_lights
|
||||||
|
#define HANDHELD_LIGHT_RANGE 10 // [1 2 3 4 5 6 7 8 9 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200 205 210 215 220 225 230 235 240 245 250 255]
|
||||||
|
|
||||||
|
#define indirect_effect 1 // [0 1 2 3 4]
|
||||||
|
|
||||||
|
#define AO_in_sunlight
|
||||||
|
#define AO_Strength 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0]
|
||||||
|
|
||||||
|
// #define SKY_CONTRIBUTION_IN_SSRT
|
||||||
|
|
||||||
|
#define UseQuarterResDepth
|
||||||
|
// #define HQ_SSGI
|
||||||
|
#define GI_Strength 1.0 // [1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ]
|
||||||
|
#define RAY_COUNT 4 // [1 2 3 4 5 6 7 8 9 10 12 14 16 18 21 24 28 32 37 43 49 57 65 75 86 100]
|
||||||
|
#define STEPS 8 // [6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99]
|
||||||
|
#define STEP_LENGTH 12. // [4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. 23. 24. 25. 26. 27. 28. 29. 30.]
|
||||||
|
|
||||||
|
|
||||||
|
#define SEPARATE_AO
|
||||||
|
const float ambientOcclusionLevel = 1.0; // this controls vanilla minecrafts ambient occlusion. [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////////////////////////
|
||||||
|
// ----- SHADOW RELATED SETTINGS ----- //
|
||||||
|
/////////////////////////////////////////
|
||||||
|
|
||||||
|
const float sunPathRotation = -35; //[-90 -89 -88 -87 -86 -85 -84 -83 -82 -81 -80 -79 -78 -77 -76 -75 -74 -73 -72 -71 -70 -69 -68 -67 -66 -65 -64 -63 -62 -61 -60 -59 -58 -57 -56 -55 -54 -53 -52 -51 -50 -49 -48 -47 -46 -45 -44 -43 -42 -41 -40 -39 -38 -37 -36 -35 -34 -33 -32 -31 -30 -29 -28 -27 -26 -25 -24 -23 -22 -21 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 ]
|
||||||
|
|
||||||
|
const int shadowMapResolution = 2048; // [512 768 1024 1536 2048 3172 4096 8192]
|
||||||
|
const float shadowDistance = 128.0; // [32.0 48.0 64.0 80.0 96.0 112.0 128.0 144.0 160.0 176.0 192.0 208.0 224.0 240.0 256.0 272.0 288.0 304.0 320.0 336.0 352.0 368.0 384.0 512.0 768.0 1024.0 1536.0 2048.0 4096.0 8192.0]
|
||||||
|
|
||||||
|
#define OPTIMIZED_SHADOW_DISTANCE 1.0 // [-1.0 1.0]
|
||||||
|
|
||||||
|
const float shadowDistanceRenderMul = OPTIMIZED_SHADOW_DISTANCE;
|
||||||
|
const float entityShadowDistanceMul = 0.25; // [0.01 0.02 0.03 0.04 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.75 1.00]
|
||||||
|
|
||||||
|
|
||||||
|
#define RENDER_ENTITY_SHADOWS
|
||||||
|
#define RENDER_PLAYER_SHADOWS
|
||||||
|
|
||||||
|
|
||||||
|
#define SCREENSPACE_CONTACT_SHADOWS
|
||||||
|
#define Variable_Penumbra_Shadows
|
||||||
|
#define VPS_Search_Samples 4 // [4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32]
|
||||||
|
#define Min_Shadow_Filter_Radius 5.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 21.0 22.0 23.0 24.0 25.0 26.0 27.0 28.0 29.0 30.0 31.0 32.0 33.0 34.0 35.0 36.0 37.0 38.0 39.0 40.0 41.0 42.0 43.0 44.0 45.0 46.0 47.0 48.0 49.0 50.0 51.0 52.0 53.0 54.0 55.0 56.0 57.0 58.0 59.0 60.0 61.0 62.0 63.0 64.0 65.0 66.0 67.0 68.0 69.0 70.0 71.0 72.0 73.0 74.0 75.0 76.0 77.0 78.0 79.0 80.0 81.0 82.0 83.0 84.0 85.0 86.0 87.0 88.0 89.0 90.0 91.0 92.0 93.0 94.0 95.0 96.0 97.0 98.0 99.0 100.0 101.0 102.0 103.0 104.0 105.0 106.0 107.0 108.0 109.0 110.0 111.0 112.0 113.0 114.0 115.0 116.0 117.0 118.0 119.0 ]
|
||||||
|
#define Max_Shadow_Filter_Radius 30.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 21.0 22.0 23.0 24.0 25.0 26.0 27.0 28.0 29.0 30.0 31.0 32.0 33.0 34.0 35.0 36.0 37.0 38.0 39.0 40.0 41.0 42.0 43.0 44.0 45.0 46.0 47.0 48.0 49.0 50.0 51.0 52.0 53.0 54.0 55.0 56.0 57.0 58.0 59.0 60.0 61.0 62.0 63.0 64.0 65.0 66.0 67.0 68.0 69.0 70.0 71.0 72.0 73.0 74.0 75.0 76.0 77.0 78.0 79.0 80.0 81.0 82.0 83.0 84.0 85.0 86.0 87.0 88.0 89.0 90.0 91.0 92.0 93.0 94.0 95.0 96.0 97.0 98.0 99.0 100.0 101.0 102.0 103.0 104.0 105.0 106.0 107.0 108.0 109.0 110.0 111.0 112.0 113.0 114.0 115.0 116.0 117.0 118.0 119.0 ]
|
||||||
|
#define Max_Filter_Depth 35.0 // [0.1 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 21.0 22.0 23.0 24.0 25.0 26.0 27.0 28.0 29.0 30.0 31.0 32.0 33.0 34.0 35.0 36.0 37.0 38.0 39.0 40.0 41.0 42.0 43.0 44.0 45.0 46.0 47.0 48.0 49.0 50.0 51.0 52.0 53.0 54.0 55.0 56.0 57.0 58.0 59.0 60.0 61.0 62.0 63.0 64.0 65.0 66.0 67.0 68.0 69.0 70.0 71.0 72.0 73.0 74.0 75.0 76.0 77.0 78.0 79.0 80.0 81.0 82.0 83.0 84.0 85.0 86.0 87.0 88.0 89.0 90.0 91.0 92.0 93.0 94.0 95.0 96.0 97.0 98.0 99.0 100.0 101.0 102.0 103.0 104.0 105.0 106.0 107.0 108.0 109.0 110.0 111.0 112.0 113.0 114.0 115.0 116.0 117.0 118.0 119.0 220.0]
|
||||||
|
|
||||||
|
#define BASIC_SHADOW_FILTER
|
||||||
|
#define SHADOW_FILTER_SAMPLE_COUNT 13 // [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 ]
|
||||||
|
#define SHADOW_DISABLE_ALPHA_MIPMAPS
|
||||||
|
#define Stochastic_Transparent_Shadows
|
||||||
|
|
||||||
|
#define Glass_Tint
|
||||||
|
#define TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||||
|
#undef Stochastic_Transparent_Shadows
|
||||||
|
#endif
|
||||||
|
|
||||||
|
//////////////////////////////////////
|
||||||
|
// ----- FOG RELATED SETTINGS ----- //
|
||||||
|
//////////////////////////////////////
|
||||||
|
#define TOGGLE_VL_FOG
|
||||||
|
|
||||||
|
#define VL_SAMPLES 8 // [4 6 8 10 12 14 16 20 24 30 40 50]
|
||||||
|
|
||||||
|
#define FOG_START_HEIGHT 60 // [-200 -190 -180 -170 -160 -150 -130 -120 -110 -100 -90 -80 -70 -60 -50 -40 -30 -20 -10 0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160 170 180 190 200]
|
||||||
|
|
||||||
|
#define TOD_Fog_mult 1.0 // [0.0 0.25 0.5 0.75 1.0 2.0 3.0 4.0 5.0 10.0 15.0 20.0 25.0 50.0 75.0 100.0]
|
||||||
|
#define Morning_Uniform_Fog 1.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Noon_Uniform_Fog 0.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Evening_Uniform_Fog 3.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Night_Uniform_Fog 5.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Morning_Cloudy_Fog 10.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Noon_Cloudy_Fog 0.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Evening_Cloudy_Fog 1.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define Night_Cloudy_Fog 5.0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
|
||||||
|
#define Haze_amount 1.0 // [0.0 0.2 0.4 0.6 0.8 1.0 1.25 1.5 1.75 2.0 3.0 4.0 5.0]
|
||||||
|
#define fog_coefficientRayleighR 5.8 // [0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 9.5 10.0]
|
||||||
|
#define fog_coefficientRayleighG 1.35 // [0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 9.5 10.0]
|
||||||
|
#define fog_coefficientRayleighB 3.31 // [0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 9.5 10.0]
|
||||||
|
#define fog_coefficientMieR 3.0 // [0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 9.5 10.0]
|
||||||
|
#define fog_coefficientMieG 3.0 // [0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 9.5 10.0]
|
||||||
|
#define fog_coefficientMieB 3.0 // [0.0 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 9.5 10.0]
|
||||||
|
|
||||||
|
#define RainFog_amount 3 // [0 1 2 3 4 5 6 7 8 9 10 15 20 25]
|
||||||
|
|
||||||
|
#define BLOOMY_FOG 1.5 // [0.0 0.25 0.5 0.75 1.0 1.25 1.5 1.75 2.0 3.0 4.0 6.0 10.0 15.0 20.0]
|
||||||
|
#define BLOOM_STRENGTH 1.0 // [0.0 0.25 0.5 0.75 1.0 1.25 1.5 1.75 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 50.0 75.0 100.0]
|
||||||
|
|
||||||
|
#define CAVE_FOG
|
||||||
|
#ifdef CAVE_FOG
|
||||||
|
#endif
|
||||||
|
#define CaveFogFallOff 2.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ]
|
||||||
|
#define CaveFogColor_R 0.1 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define CaveFogColor_G 0.2 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define CaveFogColor_B 0.5 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
|
||||||
|
#define BorderFog
|
||||||
|
#if !defined OVERWORLD_SHADER
|
||||||
|
#undef BorderFog
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define DISTANT_HORIZONS_SUPPORT
|
||||||
|
#ifndef DISTANT_HORIZONS_SUPPORT
|
||||||
|
#undef DISTANT_HORIZONS
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define SEA_LEVEL 70 // [0 10 20 30 40 50 60 70 80 90 100 110 120 130 150 170 190]
|
||||||
|
|
||||||
|
//////////////////////////////////////////////////////
|
||||||
|
// ----- BIOME SPECIFIC ENVIORNMENTS SETTINGS ----- //
|
||||||
|
//////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#define PER_BIOME_ENVIRONMENT
|
||||||
|
|
||||||
|
#define SWAMP_ENV
|
||||||
|
#define SWAMP_UNIFORM_DENSITY 50 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define SWAMP_CLOUDY_DENSITY 0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define SWAMP_R 0.15 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define SWAMP_G 0.25 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define SWAMP_B 0.05 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
|
||||||
|
#define JUNGLE_ENV
|
||||||
|
#define JUNGLE_UNIFORM_DENSITY 10 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define JUNGLE_CLOUDY_DENSITY 150 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define JUNGLE_R 0.5 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define JUNGLE_G 1.0 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define JUNGLE_B 0.5 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
|
||||||
|
#define DARKFOREST_ENV
|
||||||
|
#define DARKFOREST_UNIFORM_DENSITY 15 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define DARKFOREST_CLOUDY_DENSITY 0 // [0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 75.0 100.0 125.0 150.0 175.0 200.0 255.]
|
||||||
|
#define DARKFOREST_R 0.3 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define DARKFOREST_G 0.4 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define DARKFOREST_B 1.0 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
|
||||||
|
|
||||||
|
// i have to do this so it shows up in the menu lmao
|
||||||
|
#ifdef SWAMP_ENV
|
||||||
|
#endif
|
||||||
|
#ifdef JUNGLE_ENV
|
||||||
|
#endif
|
||||||
|
#ifdef DARKFOREST_ENV
|
||||||
|
#endif
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////
|
||||||
|
// ----- LABPBR MATERIALS RELATED SETTINGS ----- //
|
||||||
|
///////////////////////////////////////////////////
|
||||||
|
|
||||||
|
// #define Specular_Reflections
|
||||||
|
// #define Screen_Space_Reflections
|
||||||
|
// #define Sky_reflection
|
||||||
|
// #define Rough_reflections
|
||||||
|
#define Dynamic_SSR_quality
|
||||||
|
#define Sun_specular_Strength 1 // [0 1 2 3 4 5 6 7 8 9 10]
|
||||||
|
#define reflection_quality 30 // [6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 55.0 60.0 65.0 70.0 75.0 80.0 85.0 90.0 95.0 100.0 ]
|
||||||
|
#define Roughness_Threshold 1.5 // [1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ]
|
||||||
|
|
||||||
|
#ifdef Specular_Reflections
|
||||||
|
#define LIGHTSOURCE_REFLECTION
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define EMISSIVE_TYPE 1 // [0 1 2 3]
|
||||||
|
#define Emissive_Brightness 1.0 // [1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 100.]
|
||||||
|
#define Emissive_Curve 2.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ]
|
||||||
|
|
||||||
|
|
||||||
|
// #define POM
|
||||||
|
// #define Horrible_slope_normals
|
||||||
|
#define Adaptive_Step_length
|
||||||
|
#define POM_DEPTH 0.25 // [0.025 0.05 0.075 0.1 0.125 0.15 0.20 0.25 0.30 0.50 0.75 1.0]
|
||||||
|
#define MAX_ITERATIONS 35 // [5 10 15 20 25 30 40 50 60 70 80 90 100 125 150 200 400]
|
||||||
|
#define MAX_DIST 25.0 // [5.0 10.0 15.0 20.0 25.0 30.0 40.0 50.0 60.0 70.0 80.0 90.0 100.0 125.0 150.0 200.0 400.0]
|
||||||
|
|
||||||
|
// #define HEIGTHMAP_DEPTH_OFFSET
|
||||||
|
|
||||||
|
#ifdef POM
|
||||||
|
#undef HEIGTHMAP_DEPTH_OFFSET
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define SSS_TYPE 1 // [0 1 2 3]
|
||||||
|
#define LabSSS_Curve 1.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ]
|
||||||
|
// #define MOB_SSS
|
||||||
|
// #define MISC_BLOCK_SSS
|
||||||
|
#define Ambient_SSS
|
||||||
|
#define ambientsss_brightness 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0]
|
||||||
|
#define sss_absorbance_multiplier 1.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0]
|
||||||
|
#define sss_density_multiplier 1.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0]
|
||||||
|
|
||||||
|
|
||||||
|
// #define Porosity
|
||||||
|
#ifdef Specular_Reflections
|
||||||
|
#define Puddles // yes
|
||||||
|
#endif
|
||||||
|
#define Puddle_Size 1.0 // [0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5]
|
||||||
|
|
||||||
|
// #define MATERIAL_AO
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////////////
|
||||||
|
// ----- SKY RELATED SETTINGS ----- //
|
||||||
|
//////////////////////////////////////
|
||||||
|
|
||||||
|
#define Sky_Brightness 1.0 //[0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.5 2.0 3.0 4.0 5.0 6.0 10.0]
|
||||||
|
|
||||||
|
#define sky_mieg 0.80 //[0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
#define sky_coefficientRayleighR 5.8 //[0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
#define sky_coefficientRayleighG 1.35 //[0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
#define sky_coefficientRayleighB 3.31 //[0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
#define sky_coefficientMieR 3.0 //[0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
#define sky_coefficientMieG 3.0 //[0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
#define sky_coefficientMieB 3.0 //[0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
|
||||||
|
#define colortype 2 // 1 = RGB sliders for sun/moon color. 2 = blackbody. [1 2]
|
||||||
|
|
||||||
|
#define sun_illuminance 128000.0 //[0.0 10.0 20.0 30.0 40.0 50.0 60.0 70.0 80.0 90.0 100.0 150.0 200.0 300.0 400.0 500.0 600.0 700.0 800.0 900.0 1000.0 2000.0 3000.0 4000.0 5000.0 6000.0 7000.0 8000.0 9000.0 10000.0 11000.0 12000.0 13000.0 14000.0 15000.0 20000.0 30000.0 40000.0 50000.0 60000.0 70000.0 80000.0 90000.0 100000.0 150000.0 200000.0 250000.0 300000.0 400000.0 500000.0]
|
||||||
|
#define Sun_temp 6300 // [1000 1100 1200 1300 1400 1500 1600 1700 1800 1900 2000 2100 2200 2300 2400 2500 2600 2700 2800 2900 3000 3100 3200 3300 3400 3500 3600 3700 3800 3900 4000 4100 4200 4300 4400 4500 4600 4700 4800 4900 5000 5100 5200 5300 5400 5500 5600 5700 5800 5900 6000 6100 6200 6300 6400 6500 6600 6700 6800 6900 7000 7100 7200 7300 7400 7500 7600 7700 7800 7900 8000 8100 8200 8300 8400 8500 8600 8700 8800 8900 9000 9100 9200 9300 9400 9500 9600 9700 9800 9900 10000]
|
||||||
|
#define sunColorR 1.0 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
#define sunColorG 0.91 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
#define sunColorB 0.81 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
|
||||||
|
#define moon_illuminance 200.0 //[0.0 10.0 20.0 30.0 40.0 50.0 60.0 70.0 80.0 90.0 100.0 150.0 200.0 300.0 400.0 500.0 600.0 700.0 800.0 900.0 1000.0 2000.0 3000.0 4000.0 5000.0 6000.0 7000.0 8000.0 9000.0 10000.0 11000.0 12000.0 13000.0 14000.0 15000.0 20000.0 30000.0 40000.0 50000.0 60000.0 70000.0 80000.0 90000.0 100000.0 150000.0 200000.0 250000.0 300000.0 400000.0 500000.0]
|
||||||
|
#define Moon_temp 15000 // [1000 1100 1200 1300 1400 1500 1600 1700 1800 1900 2000 2100 2200 2300 2400 2500 2600 2700 2800 2900 3000 3100 3200 3300 3400 3500 3600 3700 3800 3900 4000 4100 4200 4300 4400 4500 4600 4700 4800 4900 5000 5100 5200 5300 4500 5600 5700 5800 5900 6000 6100 6200 6300 6400 6500 6600 6700 6800 6900 7000 7100 7200 7300 7400 7500 7600 7700 7800 7900 8000 8100 8200 8300 8400 8500 8600 8700 8800 8900 9000 9100 9200 9300 9400 9500 9600 9700 9800 9900 10000 15000 20000 25000 50000]
|
||||||
|
#define moonColorR 0.9080 //[0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
#define moonColorG 0.9121 //[0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
#define moonColorB 0.8948 //[0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
|
||||||
|
#define MOONPHASE_BASED_MOONLIGHT
|
||||||
|
uniform int moonPhase;
|
||||||
|
|
||||||
|
#if colortype == 1
|
||||||
|
#define sunColorBase vec3(sunColorR,sunColorG,sunColorB) * sun_illuminance
|
||||||
|
#define moonColorBase vec3(moonColorR,moonColorG,moonColorB) * moon_illuminance
|
||||||
|
#else
|
||||||
|
#define sunColorBase blackbody(Sun_temp) * sun_illuminance
|
||||||
|
|
||||||
|
#ifdef MOONPHASE_BASED_MOONLIGHT
|
||||||
|
#define phasebrightness (abs(4-moonPhase))
|
||||||
|
#define moonlightbrightness (phasebrightness/4.0)
|
||||||
|
#define moonColorBase (blackbody(Moon_temp) * moon_illuminance) * moonlightbrightness
|
||||||
|
#else
|
||||||
|
#define moonColorBase blackbody(Moon_temp) * moon_illuminance
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define SKY_GROUND
|
||||||
|
|
||||||
|
|
||||||
|
////////////////////////////////////////
|
||||||
|
// ----- CLOUD RELATED SETTINGS ----- //
|
||||||
|
////////////////////////////////////////
|
||||||
|
|
||||||
|
#define VOLUMETRIC_CLOUDS
|
||||||
|
#define CLOUDS_QUALITY 0.5 // [0.1 0.125 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.9 1.0]
|
||||||
|
|
||||||
|
#define Cloud_Speed 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0]
|
||||||
|
|
||||||
|
#ifdef VOLUMETRIC_CLOUDS
|
||||||
|
#ifndef ambientLight_only
|
||||||
|
#define CLOUDS_SHADOWS
|
||||||
|
#endif
|
||||||
|
#ifdef CLOUDS_SHADOWS
|
||||||
|
#define VL_CLOUDS_SHADOWS
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define CLOUD_SHADOW_STRENGTH 1.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
|
||||||
|
#define CloudLayer0
|
||||||
|
#define CloudLayer0_coverage 0.7 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define CloudLayer0_density 0.5 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00]
|
||||||
|
#define CloudLayer0_height 250 // [-300 -290 -280 -270 -260 -250 -240 -230 -220 -210 -200 -190 -180 -170 -160 -150 -140 -130 -120 -110 -100 -90 -80 -70 -60 -50 -40 -30 -20 -10 0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160 170 180 190 200 210 220 230 240 250 260 270 280 290 300 310 320 330 340 350 360 370 380 390 400 410 420 430 440 450 460 470 480 490 500 510 520 530 540 550 560 570 580 590 600 700 800 900 1000 1250 1500 1750 2000 2250 2500 2750 3000 4000 5000]
|
||||||
|
|
||||||
|
#define CloudLayer1
|
||||||
|
#define CloudLayer1_coverage 0.7 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define CloudLayer1_density 0.5 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00]
|
||||||
|
#define CloudLayer1_height 500 // [-300 -290 -280 -270 -260 -250 -240 -230 -220 -210 -200 -190 -180 -170 -160 -150 -140 -130 -120 -110 -100 -90 -80 -70 -60 -50 -40 -30 -20 -10 0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160 170 180 190 200 210 220 230 240 250 260 270 280 290 300 310 320 330 340 350 360 370 380 390 400 410 420 430 440 450 460 470 480 490 500 510 520 530 540 550 560 570 580 590 600 700 800 900 1000 1250 1500 1750 2000 2250 2500 2750 3000 4000 5000]
|
||||||
|
|
||||||
|
#define CloudLayer2
|
||||||
|
#define CloudLayer2_coverage 0.3 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define CloudLayer2_density 0.1 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00]
|
||||||
|
#define CloudLayer2_height 2000 // [-300 -290 -280 -270 -260 -250 -240 -230 -220 -210 -200 -190 -180 -170 -160 -150 -140 -130 -120 -110 -100 -90 -80 -70 -60 -50 -40 -30 -20 -10 0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160 170 180 190 200 210 220 230 240 250 260 270 280 290 300 310 320 330 340 350 360 370 380 390 400 410 420 430 440 450 460 470 480 490 500 510 520 530 540 550 560 570 580 590 600 700 800 900 1000 1250 1500 1750 2000 2250 2500 2750 3000 4000 5000]
|
||||||
|
|
||||||
|
#if (defined CloudLayer0 || defined CloudLayer1) && defined VOLUMETRIC_CLOUDS
|
||||||
|
// #define RAYMARCH_CLOUDS_WITH_FOG
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define Rain_coverage 1.1 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
|
||||||
|
#define fbmAmount 0.5 // [0.00 0.02 0.04 0.06 0.08 0.10 0.12 0.14 0.16 0.18 0.20 0.22 0.24 0.26 0.28 0.30 0.32 0.34 0.36 0.38 0.40 0.42 0.44 0.46 0.48 0.50 0.52 0.54 0.56 0.58 0.60 0.62 0.64 0.66 0.68 0.70 0.72 0.74 0.76 0.78 0.80 0.82 0.84 0.86 0.88 0.90 0.92 0.94 0.96 0.98 1.00 1.02 1.04 1.06 1.08 1.10 1.12 1.14 1.16 1.18 1.20 1.22 1.24 1.26 1.28 1.30 1.32 1.34 1.36 1.38 1.40 1.42 1.44 1.46 1.48 1.50 1.52 1.54 1.56 1.58 1.60 1.62 1.64 1.66 1.68 1.70 1.72 1.74 1.76 1.78 1.80 1.82 1.84 1.86 1.88 1.90 1.92 1.94 1.96 1.98 2.00 2.02 2.04 2.06 2.08 2.10 2.12 2.14 2.16 2.18 2.20 2.22 2.24 2.26 2.28 2.30 2.32 2.34 2.36 2.38 2.40 2.42 2.44 2.46 2.48 2.50 2.52 2.54 2.56 2.58 2.60 2.62 2.64 2.66 2.68 2.70 2.72 2.74 2.76 2.78 2.80 2.82 2.84 2.86 2.88 2.90 2.92 2.94 2.96 2.98 3.00]
|
||||||
|
#define fbmPower1 3.00 // [1.0 1.50 1.52 1.54 1.56 1.58 1.60 1.62 1.64 1.66 1.68 1.70 1.72 1.74 1.76 1.78 1.80 1.82 1.84 1.86 1.88 1.90 1.92 1.94 1.96 1.98 2.00 2.02 2.04 2.06 2.08 2.10 2.12 2.14 2.16 2.18 2.20 2.22 2.24 2.26 2.28 2.30 2.32 2.34 2.36 2.38 2.40 2.42 2.44 2.46 2.48 2.50 2.52 2.54 2.56 2.58 2.60 2.62 2.64 2.66 2.68 2.70 2.72 2.74 2.76 2.78 2.80 2.82 2.84 2.86 2.88 2.90 2.92 2.94 2.96 2.98 3.00 3.02 3.04 3.06 3.08 3.10 3.12 3.14 3.16 3.18 3.20 3.22 3.24 3.26 3.28 3.30 3.32 3.34 3.36 3.38 3.40 3.42 3.44 3.46 3.48 3.50 3.52 3.54 3.56 3.58 3.60 3.62 3.64 3.66 3.68 3.70 3.72 3.74 3.76 3.78 3.80 3.82 3.84 3.86 3.88 3.90 3.92 3.94 3.96 3.98 4.00 5. 6. 7. 8. 9. 10.]
|
||||||
|
#define fbmPower2 2.50 // [1.00 1.50 1.52 1.54 1.56 1.58 1.60 1.62 1.64 1.66 1.68 1.70 1.72 1.74 1.76 1.78 1.80 1.82 1.84 1.86 1.88 1.90 1.92 1.94 1.96 1.98 2.00 2.02 2.04 2.06 2.08 2.10 2.12 2.14 2.16 2.18 2.20 2.22 2.24 2.26 2.28 2.30 2.32 2.34 2.36 2.38 2.40 2.42 2.44 2.46 2.48 2.50 2.52 2.54 2.56 2.58 2.60 2.62 2.64 2.66 2.68 2.70 2.72 2.74 2.76 2.78 2.80 2.82 2.84 2.86 2.88 2.90 2.92 2.94 2.96 2.98 3.00 3.02 3.04 3.06 3.08 3.10 3.12 3.14 3.16 3.18 3.20 3.22 3.24 3.26 3.28 3.30 3.32 3.34 3.36 3.38 3.40 3.42 3.44 3.46 3.48 3.50 3.52 3.54 3.56 3.58 3.60 3.62 3.64 3.66 3.68 3.70 3.72 3.74 3.76 3.78 3.80 3.82 3.84 3.86 3.88 3.90 3.92 3.94 3.96 3.98 4.00 5. 6. 7. 8. 9. 10.]
|
||||||
|
|
||||||
|
#define cloud_LevelOfDetail 1 // [-1 0 1 2 3 4 5 6 7 8]
|
||||||
|
#define cloud_ShadowLevelOfDetail 0 // [-1 0 1 2 3 4 5 6 7 8]
|
||||||
|
#define cloud_LevelOfDetailLQ 1 // [-1 0 1 2 3 4 5 6 7 8]
|
||||||
|
#define cloud_ShadowLevelOfDetailLQ 0 // [-1 0 1 2 3 4 5 6 7 8]
|
||||||
|
#define minRayMarchSteps 10 // [20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200]
|
||||||
|
#define maxRayMarchSteps 15 // [5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200]
|
||||||
|
#define minRayMarchStepsLQ 10 // [5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100]
|
||||||
|
#define maxRayMarchStepsLQ 30 // [ 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100]
|
||||||
|
|
||||||
|
#define HQ_CLOUDS
|
||||||
|
|
||||||
|
// #define Daily_Weather
|
||||||
|
|
||||||
|
// DAY 0 WEATHER PARAMETERS
|
||||||
|
#define DAY0_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY0_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 1 WEATHER PARAMETERS
|
||||||
|
#define DAY1_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY1_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 2 WEATHER PARAMETERS
|
||||||
|
#define DAY2_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY2_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 3 WEATHER PARAMETERS
|
||||||
|
#define DAY3_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY3_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 4 WEATHER PARAMETERS
|
||||||
|
#define DAY4_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY4_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 5 WEATHER PARAMETERS
|
||||||
|
#define DAY5_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY5_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 6 WEATHER PARAMETERS
|
||||||
|
#define DAY6_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY6_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 7 WEATHER PARAMETERS
|
||||||
|
#define DAY7_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY7_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 8 WEATHER PARAMETERS
|
||||||
|
#define DAY8_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY8_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
// DAY 9 WEATHER PARAMETERS
|
||||||
|
#define DAY9_l0_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_l1_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_l2_coverage 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_ufog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_l0_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_l1_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_l2_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define DAY9_cfog_density 0.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////////////
|
||||||
|
// ----- TAA RELATED SETTINGS ----- //
|
||||||
|
//////////////////////////////////////
|
||||||
|
|
||||||
|
#define TAA
|
||||||
|
// #define SCREENSHOT_MODE
|
||||||
|
// #define TAA_UPSCALING
|
||||||
|
#define BLEND_FACTOR 0.12 // [0.01 0.02 0.03 0.04 0.05 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.20 0.30 0.40 0.50 0.60 0.70 0.80 0.90 1.00]
|
||||||
|
#define CLOSEST_VELOCITY
|
||||||
|
//#define NO_CLIP
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////
|
||||||
|
// ----- DEPTH OF FIELD RELATED SETTINGS ----- //
|
||||||
|
/////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#define DOF_QUALITY -1 // [-1 0 1 2 3 4 5]
|
||||||
|
#define DOF_ANAMORPHIC_RATIO 1.0 // [0.3 0.6 1.0]
|
||||||
|
// // #define AUTOFOCUS
|
||||||
|
//#define FAR_BLUR_ONLY
|
||||||
|
#define focal 2.4 // [0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.05 1.1 1.15 1.2 1.25 1.3 1.35 1.4 1.45 1.5 1.55 1.6 1.65 1.7 1.75 1.8 1.85 1.9 1.95 2.0 2.05 2.1 2.15 2.2 2.25 2.3 2.35 2.4 2.45 2.5 2.55 2.6 2.65 2.7 2.75 2.8 2.85 2.9 2.95 3.0 3.05 3.1 3.15 3.2 3.25 3.3 3.35 3.4 3.45 3.5 3.55 3.6 3.65 3.7 3.75 3.8 3.85 3.9 3.95 4.0 4.05 4.1 4.15 4.2 4.25 4.3 4.35 4.4 4.45 4.5 4.55 4.6 4.65 4.7 4.75 4.8 4.85 4.9 4.95 5.0 5.05 5.1 5.15 5.2 5.25 5.3 5.35 5.4 5.45 5.5 5.55 5.6 5.65 5.7 5.75 5.8 5.85 5.9 5.95 6.0 6.05 6.1 6.15 6.2 6.25 6.3 6.35 6.4 6.45 6.5 6.55 6.6 6.65 6.7 6.75 6.8 6.85 6.9 6.95 7.0 7.05 7.1 7.15 7.2 7.25 7.3 7.35 7.4 7.45 7.5 7.55 7.6 7.65 7.7 7.75 7.8 7.85 7.9 7.95 8.0 8.05 8.1 8.15 8.2 8.25 8.3 8.35 8.4 8.45 8.5 8.55 8.6 8.65 8.7 8.75 8.8 8.85 8.9 8.95 9.0 9.05 9.1 9.15 9.2 9.25 9.3 9.35 9.4 9.45 9.5 9.55 9.6 9.65 9.7 9.75 9.8 9.85 9.9 9.95 ]
|
||||||
|
#define aperture 0.8 // [0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.05 1.1 1.15 1.2 1.25 1.3 1.35 1.4 1.45 1.5 1.55 1.6 1.65 1.7 1.75 1.8 1.85 1.9 1.95 2.0 2.05 2.1 2.15 2.2 2.25 2.3 2.35 2.4 2.45 2.5 2.55 2.6 2.65 2.7 2.75 2.8 2.85 2.9 2.95 3.0 3.05 3.1 3.15 3.2 3.25 3.3 3.35 3.4 3.45 3.5 3.55 3.6 3.65 3.7 3.75 3.8 3.85 3.9 3.95 4.0 4.05 4.1 4.15 4.2 4.25 4.3 4.35 4.4 4.45 4.5 4.55 4.6 4.65 4.7 4.75 4.8 4.85 4.9 4.95 5.0 5.05 5.1 5.15 5.2 5.25 5.3 5.35 5.4 5.45 5.5 5.55 5.6 5.65 5.7 5.75 5.8 5.85 5.9 5.95 6.0 6.05 6.1 6.15 6.2 6.25 6.3 6.35 6.4 6.45 6.5 6.55 6.6 6.65 6.7 6.75 6.8 6.85 6.9 6.95 7.0 7.05 7.1 7.15 7.2 7.25 7.3 7.35 7.4 7.45 7.5 7.55 7.6 7.65 7.7 7.75 7.8 7.85 7.9 7.95 8.0 8.05 8.1 8.15 8.2 8.25 8.3 8.35 8.4 8.45 8.5 8.55 8.6 8.65 8.7 8.75 8.8 8.85 8.9 8.95 9.0 9.05 9.1 9.15 9.2 9.25 9.3 9.35 9.4 9.45 9.5 9.55 9.6 9.65 9.7 9.75 9.8 9.85 9.9 9.95 ]
|
||||||
|
#define MANUAL_FOCUS -2 // [-2 -1 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 19 20 21 22 24 25 26 28 29 30 32 33 35 36 38 40 41 43 45 47 48 50 52 54 56 58 60 63 65 67 70 72 75 77 80 83 85 88 91 94 98 101 104 108 111 115 119 123 127 132 136 141 146 151 156 161 167 173 179 186 193 200 207 215 224 232 242 251 262 273 284 297 310 324 339 355 372 391 411 433 457 483 512]
|
||||||
|
#define DoF_Adaptation_Speed 1.00 // [0.20 0.21 0.23 0.24 0.25 0.27 0.29 0.30 0.32 0.34 0.36 0.39 0.41 0.43 0.46 0.49 0.52 0.55 0.59 0.62 0.66 0.70 0.74 0.79 0.84 0.89 0.94 1.00 1.06 1.13 1.20 1.27 1.35 1.43 1.52 1.61 1.71 1.82 1.93 2.05 2.18 2.31 2.45 2.60 2.76 2.93 3.11 3.30 3.51 3.72 3.95 4.19 4.45 4.73 5.02 5.33 5.65 6.00]
|
||||||
|
|
||||||
|
// #define DOF_JITTER_SHADOW
|
||||||
|
// // #define DOF_JITTER_FOCUS 32 // [-1 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 19 20 21 22 24 25 26 28 29 30 32 33 35 36 38 40 41 43 45 47 48 50 52 54 56 58 60 63 65 67 70 72 75 77 80 83 85 88 91 94 98 101 104 108 111 115 119 123 127 132 136 141 146 151 156 161 167 173 179 186 193 200 207 215 224 232 242 251 262 273 284 297 310 324 339 355 372 391 411 433 457 483 512]
|
||||||
|
#define JITTER_STRENGTH 1.0 // sorry [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 2.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0]
|
||||||
|
#define FOCUS_LASER_COLOR 1 // Red, Green, Blue, Pink, Yellow, White [0 1 2 3 4 5]
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////
|
||||||
|
// ----- COLOR/POST PROCESSING RELATED SETTINGS ----- //
|
||||||
|
////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#define TONEMAP ToneMap_AgX_minimal // [ToneMap_AgX_minimal ToneMap_AgX ToneMap_Hejl2015 Tonemap_Xonk Tonemap_Uchimura HableTonemap Full_Reinhard_Edit Tonemap_Full_Reinhard reinhard Tonemap_Lottes ACESFilm]
|
||||||
|
//#define USE_ACES_COLORSPACE_APPROXIMATION
|
||||||
|
|
||||||
|
#define CONTRAST_ADAPTATIVE_SHARPENING
|
||||||
|
#define SHARPENING 0.35 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 ]
|
||||||
|
|
||||||
|
#define SATURATION 0.00 // [-1.0 -0.98 -0.96 -0.94 -0.92 -0.9 -0.88 -0.86 -0.84 -0.82 -0.8 -0.78 -0.76 -0.74 -0.72 -0.7 -0.68 -0.66 -0.64 -0.62 -0.6 -0.58 -0.56 -0.54 -0.52 -0.5 -0.48 -0.46 -0.44 -0.42 -0.4 -0.38 -0.36 -0.34 -0.32 -0.3 -0.28 -0.26 -0.24 -0.22 -0.2 -0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 ]
|
||||||
|
#define CROSSTALK 0.0 // [-1.0 -0.98 -0.96 -0.94 -0.92 -0.9 -0.88 -0.86 -0.84 -0.82 -0.8 -0.78 -0.76 -0.74 -0.72 -0.7 -0.68 -0.66 -0.64 -0.62 -0.6 -0.58 -0.56 -0.54 -0.52 -0.5 -0.48 -0.46 -0.44 -0.42 -0.4 -0.38 -0.36 -0.34 -0.32 -0.3 -0.28 -0.26 -0.24 -0.22 -0.2 -0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 ]
|
||||||
|
|
||||||
|
// #define TONE_CURVE
|
||||||
|
#define UPPER_CURVE 0.0 // [-1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
#define LOWER_CURVE 0.0 // [-1.0 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
|
||||||
|
// #define COLOR_GRADING_ENABLED
|
||||||
|
#define SHADOWS_GRADE_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define SHADOWS_GRADE_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define SHADOWS_GRADE_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define SHADOWS_GRADE_MUL 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
const vec3 SHADOWS_TARGET = length(vec3(SHADOWS_GRADE_R, SHADOWS_GRADE_G, SHADOWS_GRADE_B)) < 0.001 ? vec3(0.0) : normalize(vec3(SHADOWS_GRADE_R, SHADOWS_GRADE_G, SHADOWS_GRADE_B));
|
||||||
|
|
||||||
|
#define MIDS_GRADE_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define MIDS_GRADE_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define MIDS_GRADE_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define MIDS_GRADE_MUL 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
const vec3 MIDS_TARGET = length(vec3(MIDS_GRADE_R, MIDS_GRADE_G, MIDS_GRADE_B)) < 0.001 ? vec3(0.0) : normalize(vec3(MIDS_GRADE_R, MIDS_GRADE_G, MIDS_GRADE_B));
|
||||||
|
|
||||||
|
#define HIGHLIGHTS_GRADE_R 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define HIGHLIGHTS_GRADE_G 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define HIGHLIGHTS_GRADE_B 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define HIGHLIGHTS_GRADE_MUL 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
const vec3 HIGHLIGHTS_TARGET = length(vec3(HIGHLIGHTS_GRADE_R, HIGHLIGHTS_GRADE_G, HIGHLIGHTS_GRADE_B)) < 0.001 ? vec3(0.0) : normalize(vec3(HIGHLIGHTS_GRADE_R, HIGHLIGHTS_GRADE_G, HIGHLIGHTS_GRADE_B));
|
||||||
|
|
||||||
|
|
||||||
|
#define CONTRAST 1.0 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 1.0 1.01 1.02 1.03 1.04 1.05 1.06 1.07 1.08 1.09 1.1 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.18 1.19 1.2 1.21 1.22 1.23 1.24 1.25 1.26 1.27 1.28 1.29 1.3 1.31 1.32 1.33 1.34 1.35 1.36 1.37 1.38 1.39 1.4 1.41 1.42 1.43 1.44 1.45 1.46 1.47 1.48 1.49 1.5 1.51 1.52 1.53 1.54 1.55 1.56 1.57 1.58 1.59 1.6 1.61 1.62 1.63 1.64 1.65 1.66 1.67 1.68 1.69 1.7 1.71 1.72 1.73 1.74 1.75 1.76 1.77 1.78 1.79 1.8 1.81 1.82 1.83 1.84 1.85 1.86 1.87 1.88 1.89 1.9 1.91 1.92 1.93 1.94 1.95 1.96 1.97 1.98 1.99 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 ]
|
||||||
|
|
||||||
|
#define EXPOSURE_MULTIPLIER 1.0 // [0.25 0.4 0.5 0.6 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 2.0 3.0 4.0]
|
||||||
|
#define AUTO_EXPOSURE
|
||||||
|
#define Manual_exposure_value 1.0 // [0.000553 0.000581 0.000611 0.000642 0.000675 0.000710 0.000746 0.000784 0.000825 0.000867 0.000911 0.000958 0.001007 0.001059 0.001113 0.001170 0.001230 0.001294 0.001360 0.001430 0.001503 0.001580 0.001661 0.001746 0.001836 0.001930 0.002029 0.002133 0.002242 0.002357 0.002478 0.002605 0.002739 0.002879 0.003027 0.003182 0.003345 0.003517 0.003697 0.003887 0.004086 0.004296 0.004516 0.004748 0.004991 0.005247 0.005516 0.005799 0.006096 0.006409 0.006737 0.007083 0.007446 0.007828 0.008229 0.008651 0.009095 0.009561 0.010051 0.010567 0.011108 0.011678 0.012277 0.012906 0.013568 0.014264 0.014995 0.015764 0.016572 0.017422 0.018315 0.019254 0.020241 0.021279 0.022370 0.023517 0.024723 0.025991 0.027323 0.028724 0.030197 0.031745 0.033373 0.035084 0.036883 0.038774 0.040762 0.042852 0.045049 0.047358 0.049787 0.052339 0.055023 0.057844 0.060810 0.063927 0.067205 0.070651 0.074273 0.078081 0.082084 0.086293 0.090717 0.095369 0.100258 0.105399 0.110803 0.116484 0.122456 0.128734 0.135335 0.142274 0.149568 0.157237 0.165298 0.173773 0.182683 0.192049 0.201896 0.212247 0.223130 0.234570 0.246596 0.259240 0.272531 0.286504 0.301194 0.316636 0.332871 0.349937 0.367879 0.386741 0.406569 0.427414 0.449328 0.472366 0.496585 0.522045 0.548811 0.576949 0.606530 0.637628 0.670320 0.704688 0.740818 0.778800 0.818730 0.860707 0.904837 0.951229 1.0 1.051271 1.105170 1.161834 1.221402 1.284025 1.349858 1.419067 1.491824 1.568312 1.648721 1.733253 1.822118 1.915540 2.013752 2.117000 2.225540 2.339646 2.459603 2.585709 2.718281 2.857651 3.004166 3.158192 3.320116 3.490342 3.669296 3.857425 4.055199 4.263114 4.481689 4.711470 4.953032 5.206979 5.473947 5.754602 6.049647 6.359819 6.685894 7.028687 7.389056 7.767901 8.166169 8.584858 9.025013 9.487735 9.974182 10.48556 11.02317 11.58834 12.18249 ]
|
||||||
|
#define Exposure_Speed 1.0 // [0.25 0.5 0.75 1.0 1.25 1.5 1.75 2.0 2.25 2.5 2.75 3.0 4.0 5.0]
|
||||||
|
|
||||||
|
#define Fake_purkinje
|
||||||
|
#define Purkinje_strength 1.0 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define Purkinje_R 0.4 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define Purkinje_G 0.7 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define Purkinje_B 1.0 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define Purkinje_Multiplier 5.0 // [0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.05 1.1 1.15 1.2 1.25 1.3 1.35 1.4 1.45 1.5 1.55 1.6 1.65 1.7 1.75 1.8 1.85 1.9 1.95 2.0 2.05 2.1 2.15 2.2 2.25 2.3 2.35 2.4 2.45 2.5 2.55 2.6 2.65 2.7 2.75 2.8 2.85 2.9 2.95 3.0 3.05 3.1 3.15 3.2 3.25 3.3 3.35 3.4 3.45 3.5 3.55 3.6 3.65 3.7 3.75 3.8 3.85 3.9 3.95 4.0 4.05 4.1 4.15 4.2 4.25 4.3 4.35 4.4 4.45 4.5 4.55 4.6 4.65 4.7 4.75 4.8 4.85 4.9 4.95 5.0 5.05 5.1 5.15 5.2 5.25 5.3 5.35 5.4 5.45 5.5 5.55 5.6 5.65 5.7 5.75 5.8 5.85 5.9 5.95 6.0 6.05 6.1 6.15 6.2 6.25 6.3 6.35 6.4 6.45 6.5 6.55 6.6 6.65 6.7 6.75 6.8 6.85 6.9 6.95 7.0 7.05 7.1 7.15 7.2 7.25 7.3 7.35 7.4 7.45 7.5 7.55 7.6 7.65 7.7 7.75 7.8 7.85 7.9 7.95 8.0 8.05 8.1 8.15 8.2 8.25 8.3 8.35 8.4 8.45 8.5 8.55 8.6 8.65 8.7 8.75 8.8 8.85 8.9 8.95 9.0 9.05 9.1 9.15 9.2 9.25 9.3 9.35 9.4 9.45 9.5 9.55 9.6 9.65 9.7 9.75 9.8 9.85 9.9 9.95 ]
|
||||||
|
|
||||||
|
// #define AEROCHROME_MODE // Infra-red film colors ^~^
|
||||||
|
// #define AEROCHROME_WOOL_ENABLED // Technically wool things should be affected but it affects a lot of builds and stuff
|
||||||
|
#define AEROCHROME_PINKNESS 0.3 // How pink it is from red [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
const vec3 aerochrome_color = mix(vec3(1.0, 0.0, 0.0), vec3(0.715, 0.303, 0.631), AEROCHROME_PINKNESS);
|
||||||
|
|
||||||
|
//#define BICUBIC_UPSCALING
|
||||||
|
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////
|
||||||
|
// ----- GAMEPLAY POST EFFECT RELATED SETTINGS ----- //
|
||||||
|
///////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#define MOTION_AMOUNT 0.25 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0]
|
||||||
|
#define DAMAGE_TAKEN_EFFECT
|
||||||
|
#define LOW_HEALTH_EFFECT
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////////////////////////
|
||||||
|
// ----- NETHER RELATED SETTINGS ----- //
|
||||||
|
/////////////////////////////////////////
|
||||||
|
|
||||||
|
#define NETHER_PLUME_DENSITY 1.0 //[0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
|
||||||
|
|
||||||
|
//////////////////////////////////////
|
||||||
|
// ----- END RELATED SETTINGS ----- //
|
||||||
|
//////////////////////////////////////
|
||||||
|
|
||||||
|
#define END_STORM_DENSTIY 1.0 // [0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0]
|
||||||
|
|
||||||
|
// #define DEBUG_endfog
|
||||||
|
// #define THE_ORB
|
||||||
|
#define ORB_X 0 // [-200 -195 -190 -185 -180 -175 -170 -165 -160 -155 -150 -145 -140 -135 -130 -125 -120 -115 -110 -105 -100 -95 -90 -85 -80 -75 -70 -65 -60 -55 -50 -45 -40 -35 -30 -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200]
|
||||||
|
#define ORB_Y 0 // [-200 -195 -190 -185 -180 -175 -170 -165 -160 -155 -150 -145 -140 -135 -130 -125 -120 -115 -110 -105 -100 -95 -90 -85 -80 -75 -70 -65 -60 -55 -50 -45 -40 -35 -30 -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200 210 220 230 240 250]
|
||||||
|
#define ORB_Z 0 // [-200 -195 -190 -185 -180 -175 -170 -165 -160 -155 -150 -145 -140 -135 -130 -125 -120 -115 -110 -105 -100 -95 -90 -85 -80 -75 -70 -65 -60 -55 -50 -45 -40 -35 -30 -25 -20 -15 -10 -5 0 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165 170 175 180 185 190 195 200]
|
||||||
|
|
||||||
|
#define ORB_R 1.0 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define ORB_G 1.0 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define ORB_B 1.0 // [0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0]
|
||||||
|
#define ORB_ColMult 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 6.0 6.1 6.2 6.3 6.4 6.5 6.6 6.7 6.8 6.9 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.8 8.9 9.0 9.1 9.2 9.3 9.4 9.5 9.6 9.7 9.8 9.9 10.0 ]
|
||||||
|
|
||||||
|
|
||||||
|
///////////////////////////////
|
||||||
|
// ----- MISC SETTINGS ----- //
|
||||||
|
///////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// #define ambientLight_only // THIS IS A DEBUG VIEW. turn the sunlight off. DOES NOT increase performance, the shadows are still working in the background
|
||||||
|
// #define WhiteWorld // THIS IS A DEBUG VIEW. uses to see AO easier. used to see fake GI better (green light)
|
||||||
|
// #define Compositing_Sky // make the sky some color to make compositing a sky in some photoediting software easier.
|
||||||
|
// #define display_LUT
|
||||||
|
// #define SSS_view
|
||||||
|
// #define BIOME_TINT_WATER
|
||||||
|
|
||||||
|
#define Texture_MipMap_Bias 0.0 // [-5.00 -4.75 -4.50 -4.25 -4.00 -3.75 -3.50 -3.25 -3.00 -2.75 -2.50 -2.25 -2.00 -1.75 -1.50 -1.25 -1.00 -0.75 -0.50 -0.25 0.00 0.25 0.50 0.75 1.00 1.25 1.50 1.75 2.00 2.25 2.50 2.75 3.00 3.25 3.50 3.75 4.00 4.25 4.50 4.75 5.00]
|
||||||
|
|
||||||
|
#define PLANET_GROUND_BRIGHTNESS 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 ]
|
||||||
|
|
||||||
|
// #define OLD_LIGHTLEAK_FIX
|
||||||
|
|
||||||
|
#define LIT_PARTICLE_BRIGHTNESS 2.0 // [1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 100.]
|
||||||
|
|
||||||
|
|
||||||
|
#define SELECT_BOX
|
||||||
|
|
||||||
|
#define LIGHTNING_FLASH // FOR OPTIFINE USERS. some mods change the sky color, which can trigger the lightning flash detection.
|
||||||
|
|
||||||
|
#define RESOURCEPACK_SKY 0 // [0 1 2]
|
||||||
|
|
||||||
|
#ifdef IS_IRIS
|
||||||
|
#define TRANSLUCENT_ENTITIES
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define WATER_CAUSTICS_BRIGHTNESS 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0]
|
||||||
|
#define DENOISE_SSS_AND_SSAO
|
||||||
|
|
||||||
|
// #define HYPER_DETAILED_WAVES
|
||||||
|
|
||||||
|
// #define DISABLE_ENCHANT_GLINT
|
||||||
|
// #define DISABLE_VANILLA_EMISSIVES
|
||||||
|
#define PARTICLE_RENDERING_FIX
|
||||||
|
|
||||||
|
|
||||||
|
///////////////////////////////////////////
|
||||||
|
// ----- DISTANT HORIZONS SETTINGS ----- //
|
||||||
|
///////////////////////////////////////////
|
||||||
|
|
||||||
|
/// distant horizons stuff
|
||||||
|
#define DISTORT_SHADOWMAP
|
||||||
|
// #define DISTANT_HORIZONS_SHADOWMAP
|
||||||
|
#ifdef DISTANT_HORIZONS_SHADOWMAP
|
||||||
|
#undef DISTORT_SHADOWMAP
|
||||||
|
|
||||||
|
const float shadowNearPlane = -1.0;
|
||||||
|
const float shadowFarPlane = -1.0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// #define DH_SHADOWPROJECTIONTWEAK
|
||||||
|
|
||||||
|
#define DH_OVERDRAW_PREVENTION
|
||||||
|
#define DH_KNOWN_ISSUES 0 // [0 1 2 3 4 5]
|
||||||
|
|
||||||
|
|
||||||
|
///////////////////////////////////////////
|
||||||
|
// ----- FLOODFILL [LPV] SETTINGS ----- //
|
||||||
|
///////////////////////////////////////////
|
||||||
|
|
||||||
|
//#define LPV_ENABLED
|
||||||
|
#define LPV_SIZE 7 // [6 7 8]
|
||||||
|
#define LPV_NORMAL_STRENGTH 50 // [0 10 20 30 40 50 60 70 80 90 100]
|
||||||
|
#define LPV_NORMAL_OFFSET
|
||||||
|
#define LPV_ENTITY_LIGHTS
|
||||||
|
#define LPV_REDSTONE_LIGHTS
|
||||||
|
//#define LPV_COLORED_CANDLES
|
||||||
|
|
||||||
|
// Fix for making nether/end work until next Iris release to fix shadow matrices
|
||||||
|
#define LPV_NOSHADOW_HACK
|
||||||
|
|
||||||
|
#ifdef LPV_ENABLED
|
||||||
|
#ifdef IRIS_FEATURE_CUSTOM_IMAGES
|
||||||
|
#define IS_LPV_ENABLED
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
////////////////////////////////
|
||||||
|
// ----- DEBUG SETTINGS ----- //
|
||||||
|
////////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
#define debug_OFF 0
|
||||||
|
#define debug_SHADOWMAP 1
|
||||||
|
#define debug_NORMALS 2
|
||||||
|
#define debug_SPECULAR 3
|
||||||
|
#define debug_INDIRECT 4
|
||||||
|
#define debug_DIRECT 5
|
||||||
|
#define debug_VIEW_POSITION 6
|
||||||
|
#define debug_DH_WATER_BLENDING 7
|
||||||
|
#define debug_FILTERED_STUFF 8
|
||||||
|
#define debug_TEMPORAL_REPROJECTION 9
|
||||||
|
#define DEBUG_VIEW debug_OFF // [debug_OFF debug_SHADOWMAP debug_NORMALS debug_SPECULAR debug_INDIRECT debug_DIRECT debug_VIEW_POSITION debug_DH_WATER_BLENDING debug_FILTERED_STUFF debug_TEMPORAL_REPROJECTION]
|
||||||
|
|
||||||
|
/////////////////////////////////
|
||||||
|
// ----- RANDOM SETTINGS ----- //
|
||||||
|
/////////////////////////////////
|
||||||
|
|
||||||
|
// #define OLD_BLOOM
|
||||||
|
// #define BLOOMY_PARTICLES
|
||||||
|
// #define ORIGINAL_CHOCAPIC_SKY
|
||||||
|
// #define CLOUDS_INFRONT_OF_WORLD
|
||||||
|
|
||||||
|
|
||||||
|
// fix settings
|
||||||
|
#ifdef TRANSLUCENT_ENTITIES
|
||||||
|
#endif
|
||||||
|
#ifdef RENDER_ENTITY_SHADOWS
|
||||||
|
#endif
|
||||||
|
#if RESOURCEPACK_SKY == 0
|
||||||
|
#endif
|
||||||
|
#ifdef VANILLA_SUN_AND_MOON
|
||||||
|
#endif
|
||||||
|
#ifdef LIGHTNING_FLASH
|
||||||
|
#endif
|
||||||
|
#if BLISS_SHADERS == 0
|
||||||
|
#endif
|
||||||
|
#if DH_KNOWN_ISSUES == 0
|
||||||
|
#endif
|
||||||
|
#ifdef PARTICLE_RENDERING_FIX
|
||||||
|
#endif
|
||||||
|
#ifdef RENDER_PLAYER_SHADOWS
|
||||||
|
#endif
|
|
@ -0,0 +1,160 @@
|
||||||
|
#define ffstep(x,y) clamp((y - x) * 1e35,0.0,1.0)
|
||||||
|
|
||||||
|
vec3 drawSun(float cosY, float sunInt,vec3 nsunlight,vec3 inColor){
|
||||||
|
return inColor+nsunlight/0.0008821203*pow(smoothstep(cos(0.0093084168595*3.2),cos(0.0093084168595*1.8),cosY),3.)*0.62;
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 drawMoon(vec3 PlayerPos, vec3 WorldSunVec, vec3 Color, inout vec3 occludeStars){
|
||||||
|
|
||||||
|
float Shape = clamp((exp(1 + -1000 * dot(WorldSunVec+PlayerPos,PlayerPos)) - 1.5),0.0,25.0);
|
||||||
|
occludeStars *= max(1.0-Shape*5,0.0);
|
||||||
|
|
||||||
|
float shape2 = pow(exp(Shape * -10),0.15) * 255.0;
|
||||||
|
|
||||||
|
vec3 sunNormal = vec3(dot(WorldSunVec+PlayerPos, vec3(shape2,0,0)), dot(PlayerPos+WorldSunVec, vec3(0,shape2,0)), -dot(WorldSunVec, PlayerPos) * 15.0);
|
||||||
|
|
||||||
|
|
||||||
|
// even has a little tilt approximation haha.... yeah....
|
||||||
|
vec3[8] phase = vec3[8](
|
||||||
|
vec3( -1.0, -0.5, 1.0 ),
|
||||||
|
vec3( -1.0, -0.5, 0.35 ),
|
||||||
|
vec3( -1.0, -0.5, 0.2 ),
|
||||||
|
vec3( -1.0, -0.5, 0.1 ),
|
||||||
|
vec3( 1.0, 0.25, -1.0 ),
|
||||||
|
vec3( 1.0, 0.25, 0.1 ),
|
||||||
|
vec3( 1.0, 0.25, 0.2 ),
|
||||||
|
vec3( 1.0, 0.25, 0.35 )
|
||||||
|
);
|
||||||
|
|
||||||
|
vec3 LightDir = phase[moonPhase];
|
||||||
|
|
||||||
|
return Shape * pow(clamp(dot(sunNormal,LightDir)/5,0.0,1.5),5) * Color + clamp(Shape * 4.0 * pow(shape2/200,2.0),0.0,1.0)*0.004;
|
||||||
|
}
|
||||||
|
|
||||||
|
const float pi = 3.141592653589793238462643383279502884197169;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
float w0(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*(a*(-a + 3.0) - 3.0) + 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
float w1(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*a*(3.0*a - 6.0) + 4.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
float w2(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*(a*(-3.0*a + 3.0) + 3.0) + 1.0);
|
||||||
|
}
|
||||||
|
|
||||||
|
float w3(float a)
|
||||||
|
{
|
||||||
|
return (1.0/6.0)*(a*a*a);
|
||||||
|
}
|
||||||
|
|
||||||
|
float g0(float a)
|
||||||
|
{
|
||||||
|
return w0(a) + w1(a);
|
||||||
|
}
|
||||||
|
|
||||||
|
float g1(float a)
|
||||||
|
{
|
||||||
|
return w2(a) + w3(a);
|
||||||
|
}
|
||||||
|
|
||||||
|
float h0(float a)
|
||||||
|
{
|
||||||
|
return -1.0 + w1(a) / (w0(a) + w1(a));
|
||||||
|
}
|
||||||
|
|
||||||
|
float h1(float a)
|
||||||
|
{
|
||||||
|
return 1.0 + w3(a) / (w2(a) + w3(a));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 texture2D_bicubic(sampler2D tex, vec2 uv)
|
||||||
|
{
|
||||||
|
vec4 texelSize = vec4(texelSize,1.0/texelSize);
|
||||||
|
uv = uv*texelSize.zw;
|
||||||
|
vec2 iuv = floor( uv );
|
||||||
|
vec2 fuv = fract( uv );
|
||||||
|
|
||||||
|
float g0x = g0(fuv.x);
|
||||||
|
float g1x = g1(fuv.x);
|
||||||
|
float h0x = h0(fuv.x);
|
||||||
|
float h1x = h1(fuv.x);
|
||||||
|
float h0y = h0(fuv.y);
|
||||||
|
float h1y = h1(fuv.y);
|
||||||
|
|
||||||
|
vec2 p0 = (vec2(iuv.x + h0x, iuv.y + h0y) - 0.5) * texelSize.xy;
|
||||||
|
vec2 p1 = (vec2(iuv.x + h1x, iuv.y + h0y) - 0.5) * texelSize.xy;
|
||||||
|
vec2 p2 = (vec2(iuv.x + h0x, iuv.y + h1y) - 0.5) * texelSize.xy;
|
||||||
|
vec2 p3 = (vec2(iuv.x + h1x, iuv.y + h1y) - 0.5) * texelSize.xy;
|
||||||
|
|
||||||
|
return g0(fuv.y) * (g0x * texture2D(tex, p0) +
|
||||||
|
g1x * texture2D(tex, p1)) +
|
||||||
|
g1(fuv.y) * (g0x * texture2D(tex, p2) +
|
||||||
|
g1x * texture2D(tex, p3));
|
||||||
|
}
|
||||||
|
vec4 texture2D_bicubic_offset(sampler2D tex, vec2 uv, float noise, float scale)
|
||||||
|
{
|
||||||
|
float offsets = noise * (2.0 * 3.141592653589793238462643383279502884197169);
|
||||||
|
vec2 circleOffsets = vec2(sin(offsets), cos(offsets)) * scale;
|
||||||
|
|
||||||
|
#ifdef SCREENSHOT_MODE
|
||||||
|
circleOffsets = vec2(0.0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
vec4 texelSize = vec4(texelSize,1.0/texelSize);
|
||||||
|
uv = uv*texelSize.zw;
|
||||||
|
|
||||||
|
vec2 iuv = floor( uv + circleOffsets );
|
||||||
|
vec2 fuv = fract( uv + circleOffsets );
|
||||||
|
|
||||||
|
float g0x = g0(fuv.x);
|
||||||
|
float g1x = g1(fuv.x);
|
||||||
|
float h0x = h0(fuv.x);
|
||||||
|
float h1x = h1(fuv.x);
|
||||||
|
float h0y = h0(fuv.y);
|
||||||
|
float h1y = h1(fuv.y);
|
||||||
|
|
||||||
|
vec2 p0 = (vec2(iuv.x + h0x, iuv.y + h0y) - 0.5) * (texelSize.xy);
|
||||||
|
vec2 p1 = (vec2(iuv.x + h1x, iuv.y + h0y) - 0.5) * (texelSize.xy);
|
||||||
|
vec2 p2 = (vec2(iuv.x + h0x, iuv.y + h1y) - 0.5) * (texelSize.xy);
|
||||||
|
vec2 p3 = (vec2(iuv.x + h1x, iuv.y + h1y) - 0.5) * (texelSize.xy);
|
||||||
|
|
||||||
|
return (g0(fuv.y) * (g0x * texture2D(tex, p0) +
|
||||||
|
g1x * texture2D(tex, p1)) +
|
||||||
|
g1(fuv.y) * (g0x * texture2D(tex, p2) +
|
||||||
|
g1x * texture2D(tex, p3)));
|
||||||
|
}
|
||||||
|
|
||||||
|
vec2 sphereToCarte(vec3 dir) {
|
||||||
|
float lonlat = clamp(atan(-dir.x, -dir.z), -pi, pi);
|
||||||
|
return vec2(lonlat * (0.5/pi) +0.5,0.5*dir.y+0.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec3 skyFromTex(vec3 pos,sampler2D sampler){
|
||||||
|
vec2 p = sphereToCarte(pos);
|
||||||
|
return texture2D(sampler,p*texelSize*256.+vec2(18.5,1.5)*texelSize).rgb;
|
||||||
|
}
|
||||||
|
vec3 skyFromTexLOD(vec3 pos,sampler2D sampler, float LOD){
|
||||||
|
vec2 p = sphereToCarte(pos);
|
||||||
|
return texture2DLod(sampler,p*texelSize*256.+vec2(18.5,1.5)*texelSize,LOD).rgb;
|
||||||
|
}
|
||||||
|
vec4 skyCloudsFromTex(vec3 pos,sampler2D sampler){
|
||||||
|
vec2 p = sphereToCarte(pos);
|
||||||
|
return texture2D(sampler,p*texelSize*256.+vec2(18.5+257.,1.5)*texelSize);
|
||||||
|
}
|
||||||
|
vec4 skyCloudsFromTexLOD(vec3 pos,sampler2D sampler, float LOD){
|
||||||
|
vec2 p = sphereToCarte(pos);
|
||||||
|
return texture2DLod(sampler,p*texelSize*256. + vec2(18.5 + 257., 1.5)*texelSize,LOD);
|
||||||
|
}
|
||||||
|
|
||||||
|
vec4 skyCloudsFromTexLOD2(vec3 pos,sampler2D sampler, float LOD){
|
||||||
|
vec2 p = sphereToCarte(pos);
|
||||||
|
return texture2DLod(sampler,p*texelSize*256. + vec2(256.0 - 256.0*0.12,1.5)*texelSize,LOD);
|
||||||
|
}
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue