← Назад к ресурсам

AuraLite Shaders

Lightweight OpenGL 4.6 shaders for Minecraft 1.16.5–26.2 with volumetric godrays, HDR rendering, 3D clouds, and LabPBR support.

Modrinth low pbr realistic

Описание

# 🌌 AuraLite Shaders (Minecraft 1.16 – 26.2) ![Minecraft Version](https://img.shields.io/badge/Minecraft-1.16.5%20--%2026.2-blue?logo=minecraft&logoColor=white) [![Shader Loader](https://img.shields.io/badge/Loader-Iris%20%2F%20Sodium-green)](https://modrinth.com/mod/iris) [![API Standard](https://img.shields.io/badge/API-OpenGL%204.6%20%2F%20GLSL%20460-orange)](https://khronos.org/) [![Materials Standard](https://img.shields.io/badge/PBR-LabPBR%201.3-cyan)](https://github.com/rre36/lab-pbr) [![Version](https://img.shields.io/badge/Release-v1.1.4-purple)](https://github.com/AlexanderNyr/AuraLite-Shaders) [![License](https://img.shields.io/badge/License-CC%20BY--NC--SA%204.0-lightgrey.svg)](https://creativecommons.org/licenses/by-nc-sa/4.0/) **AuraLite** is a modern, lightweight, and highly optimized shader pack built on top of the **OpenGL 4.6 / GLSL 460** standard. It is specifically designed and **tested for Minecraft 1.16 – 26.2 with Sodium + Iris** (and compatible with **OptiFine**, **Oculus**). AuraLite delivers a breathtaking, realistic visual experience without overcomplicating the screen with bloated post-processing effects (such as aggressive motion blur or heavy bloom). A lightweight HDR bloom (gaussian pyramid since v1.1.3, **half-resolution and skippable since v1.1.4**) softly glows emissive sources without smearing the scene. Optional FXAA/SMAA anti-aliasing, SSR, TAA, godrays, and SSAO are profile-scaled so AuraLite keeps **high FPS and smooth frametimes** on modern GPUs. > 🧪 **v1.1.4 note:** Adds tiny **physical-atmosphere LUTs** (`begin`/`begin1` → 64×32 `colortex5` + 32×16 `colortex6`), a **hard Distant Horizons seam** (the v1.1.3 screen-door dither punched white holes on DH 3.2), **DH-aware TAA** with a material reactive mask, a **Gerstner water spectrum**, **half-res schedulable bloom**, and an Iris 1.7.6 compatibility workaround (`dhShadow.enabled=false` by default). **TAA remains on by default in HIGH/ULTRA/EXTREME; camera jitter stays OFF.** See changelog below. --- > ℹ️ **Historical note:** older changelog sections below are preserved as original release notes. ## 🚀 What's New in v1.1.4 — *Atmosphere LUTs, Distant Horizons Seam Fix & Half-Res Bloom* Version **1.1.4** rebuilds the experimental physical sky around shared low-frequency LUTs, replaces the hole-producing DH screen-door seam with a deterministic hand-off, and cuts post-process cost with skippable half-resolution bloom. It also finishes the TAA story for Distant Horizons (correct DH reprojection + Halton jitter on LOD geometry) and swaps glittery water fBm for a coherent Gerstner swell. ### 🧪 Shared Physical-Atmosphere LUTs (`begin` / `begin1`) * **Tiny HDR LUTs, not fullscreen buffers.** v1.1.3 deleted unused full-screen `colortex5`/`colortex6` to save VRAM. v1.1.4 brings them back as **64×32** solar-transmittance (`colortex5`) and **32×16** multi-scatter / ground-bounce (`colortex6`) tables — kilobytes, not megabytes. * **`begin.fsh`** rebuilds direct solar transmittance every frame: sun elevation on X (`−0.16…1.0`, including civil twilight), camera altitude on Y (`0–30 km`), Kasten–Young airmass × Rayleigh + aerosol extinction, zeroed below the night hemisphere. * **`begin1.fsh`** layers bounded multi-scattering and biome-aware ground bounce on top of that transmittance. Noon is Rayleigh-blue; low sun is warm; swamp/snow/vegetation tints come from `GROUND_BOUNCE_MODE`. * **Shared by every physical-sky consumer** — `gbuffers_skybasic`, terrain fog, water analytic reflection, volumetric godrays, clouds and the SSR sky fallback all sample the same LUTs instead of each running a second atmosphere march. * When **`SKY_MODE=0`** (every shipped profile) the LUT passes write constants and cost almost nothing. Enable Physical Sky manually in the Experimental tab. New Experimental → Atmosphere options (off-profile defaults stay cinematic / auto): * **`ATMOSPHERE_TURBIDITY`** — *Crisp / Balanced / Hazy* aerosol load. * **`ATMOSPHERE_SCALE`** — *Compact 25 m / Balanced 50 m / Cinematic 100 m* per block (how Minecraft Y maps into atmosphere kilometres). * **`GROUND_BOUNCE_MODE`** — *Auto (biome-aware) / Neutral Soil / Vegetation / Snow / Desert*. * **`SKY_TEMPORAL`** — rotation-only history blend for the sky (requires TAA). Physical sky uses a higher history weight than the animated gradient sky so stars/aurora do not trail. The swamp detector now also matches **`BIOME_MANGROVE_SWAMP`**. ### 🌍 Distant Horizons — Hard Seam, TAA & Iris Workaround > ⚠️ AuraLite still does **NOT** claim full Distant Horizons compatibility. v1.1.4 is a targeted correctness pass on the v1.1.2/v1.1.3 experimental path. * **Hard deterministic hand-off at `far`.** The v1.1.3 16 m screen-door dither discarded random LOD fragments in the seam band; on DH 3.2 those holes showed sky/white whenever vanilla geometry did not fill the same pixel. DH fragments with `dist < far` are now simply discarded — less cinematic, never stochastic. * **DH receives the same optional Halton camera jitter** as vanilla gbuffers. `composite1.fsh` reprojects DH pixels through `dhProjectionInverse` + `dhPreviousProjection` (vanilla matrices have the wrong far plane). * **Conservative DH history cap (0.45)** — LOD meshes change topology as chunks stream; they participate in TAA but cannot leave long trails. * **`DH_BLOCK_ILLUMINATED` tag `colortex2.a = 0.24`** — distant sea lanterns / glowstone stay self-emissive even when they are not lava-orange or portal-violet. Extra DH material classes: DIRT, SAND, TERRACOTTA. * **`dh_water`** now honours `WATER_WAVES` / riffles / transparency / specular, applies the frozen-ocean navy floor, and occludes against `dhDepthTex1` (plus Iris `depthtex1` via view-space Z, because raw depths use different projections). * **`DH_SHADOW_RANGE`** — *Seam (1.25×) / Extended (2×) / Far (4×)* of vanilla `far`. LOD receivers can keep sampling the shared shadow map past the vanilla chunk edge. * **Shadow-map footprint rebalanced for DH:** MED **192 m**, HIGH/ULTRA **512 m**, EXTREME **768 m** (VERY_LOW/LOW stay 60 m, no shadows). * **`dhShadow.enabled=false` by default.** DH 3.2.0-b + Iris 1.7.6 can replace/cull the *vanilla* terrain shadow pass — symptom: mob shadows remain, block shadows vanish even in vanilla chunks. Users with a verified working Iris/DH bridge can turn the DH shadow pass back on and then use `DH_SHADOW_RANGE`. ### 🎯 TAA — Sky Temporal Resolve & Material Reactive Mask * **Sky temporal resolve (`SKY_TEMPORAL`)** — sky pixels have no stable world position, so history is reprojected with **camera rotation only** (no translation). Gradient-sky history weight is lower (0.28) than Physical (0.46) so clouds/aurora/meteors do not smear. * **Material reactive mask** — water (`0.8`), foliage (`0.62`) and emissive/lava (`< 0.5`) cut history weight by 46% / 30% / 58%. Without a per-object velocity buffer this is what stops waving leaves and water from ghosting after TAA. ### 🌊 Gerstner Water Spectrum * Replaces the v1.1.3 value-noise / fBm central-difference normal in `final.fsh`. That field was mathematically stable but read as high-frequency random glitter. * A 4-direction travelling swell (dominant wind + cross swell + two low-amplitude ripples) produces **analytic slopes** and a calmer default surface. Amplitude is clamped to `±0.22`. * Near-water vertex swell is slightly reduced (`0.04/0.02 → 0.032/0.016`) so the geometric mesh matches the new reflection spectrum. * Dead Voronoi lava-height helpers removed from `gbuffers_water`, `gbuffers_terrain_translucent` and `gbuffers_terrain` (lava stays texture-driven). ### ✨ Half-Resolution, Skippable HDR Bloom * New master **`BLOOM`** toggle. VERY_LOW / LOW skip the entire 5-pass chain via `program.composite3–7.enabled=BLOOM` (Iris/OptiFine do not even dispatch the programs). * **`colortex3`/`colortex4` are half-resolution** (`size.buffer = 0.5 0.5`). Gaussian strides are doubled so the world-space radius stays the same; `final.fsh` linearly upsamples the glow. * `TAA` similarly gates `composite1`/`composite2`, so lighter profiles no longer pay for unused fullscreen passes. ### 🌌 Aurora Quality * New **`AURORA_QUALITY`** — *Soft 8 / Balanced 12 / Silky 18* raymarch steps, with a centred globally-animated ray start (the previous per-pixel hash grain is gone). ### 🎚️ Profile Rebalance (v1.1.4) | Profile | Shadows | DH receivers | TAA | Bloom | Sky temporal | | --- | --- | --- | --- | --- | --- | | VERY_LOW / LOW | ❌ 512 / 60 m | Seam | ❌ | ❌ | ❌ | | MED | ✅ 1024 / **192 m** Balanced | Seam | ❌ | ✅ Balanced | ❌ | | HIGH | ✅ 2048 / **512 m** Balanced | Extended | ✅ | ✅ Balanced | ✅ | | ULTRA | ✅ 4096 / **512 m** Aggressive | Extended | ✅ | ✅ Balanced | ✅ | | EXTREME | ✅ 8192 / **768 m** Aggressive | Far | ✅ | ✅ Strong | ✅ | Camera jitter remains **off by default in every profile**. --- ## 🚀 What's New in v1.1.3 — *True TAA, HDR Bloom Pyramid & Black-Water Regression Fix* Version **1.1.3** completes the TAA pipeline (Halton sub-pixel camera jitter + YCoCg variance clipping), replaces the old single-pass bloom with a true multi-octave HDR gaussian pyramid, and fixes the long-standing **black-water regression** with MRT-proof water detection. It also adds procedural raindrop rings, biome-aware murky swamp water, underwater plant sway, post-TAA sharpening, and a ~48 MB VRAM cleanup. ### 🎯 True Temporal Anti-Aliasing (Halton Jitter + YCoCg Clipping) * **Halton(2,3) sub-pixel camera jitter** — every gbuffer vertex shader can offset `gl_Position` by a rotating 8-frame Halton pattern (±0.5 px). Previously TAA only blended history without jittering the sample point, so it could only blur noise instead of reconstructing sub-pixel detail. * **`TAA_JITTER` option — Off / Subtle / Standard / Strong** (new in v1.1.3). The jitter is **OFF by default in all profiles** for a rock-steady image; Subtle (±0.25 px), Standard (±0.5 px) and Strong (±0.75 px) scale the amplitude for users who want the full sub-pixel reconstruction (removes high-frequency shimmer at the cost of a slight temporal wobble). Requires TAA enabled. * **Previous-frame jitter compensation** in `composite1.fsh` — the old frame's offset is re-added to the reprojection (with the same strength scale), so static images converge instead of smearing ~0.5 px. Only active while jitter is on. * **YCoCg variance clipping (μ ± γσ)** replaces the axis-aligned 3×3 min/max box — the old box caused ghost trails on saturated high-contrast edges (fences, wires, hot specular) while being too tight on flat gradients. Clip width scales with `TAA_STRENGTH`: 1.50 Light / 1.25 Balanced / 1.10 Stable. * **Frame-rotated IGN dithers now resolve cleanly** — godrays and volumetric clouds rotate their interleaved-gradient-noise patterns per frame; with the temporal resolve they integrate into smooth gradients instead of shimmering. * **TAA is on by default in HIGH / ULTRA / EXTREME profiles** (off on VERY_LOW / LOW / MED for maximum FPS); it can be toggled in the Post-Processing menu, and `TAA_STRENGTH` presets the variance-clip tightness. ### ✨ HDR Gaussian-Pyramid Bloom (composite3 – composite7) * Replaces the v1.0.1 single-pass 3×3 neighbour glow, whose ~1.5 px radius could only produce a tight halo. * New 5-pass chain: threshold **brightpass** (0.75 luma soft-knee, exposure-aware) → tight separable gaussian (9-tap, σ≈2.0) → wide separable gaussian (4× stride). Successive blurs compose to an effective **σ ≈ 8.2 px** — a soft cinematic falloff around the sun/moon disks, lava, portals and hot specular, without a mip chain. * Runs **after the TAA resolve**, so the bloom energy is temporally stable. * New **`HDR_BLOOM`** option (Subtle 0.06 / Balanced 0.12 / Strong 0.22 amplitude) wired into every quality profile. ### 💧 Black-Water Regression Fix — MRT-Proof Water Detection * **Root cause:** on some Iris builds the translucent pass drops the `colortex1`/`colortex2` MRT writes entirely — water then arrives with a zeroed normal + alpha + lightmap. The emissive fast-path (alpha < 0.5) swallowed it and every tag/lightmap-based system died with it. * **Detection ladder:** primary = `colortex2.a = 0.8` tag; **rescue** = the depth difference (`depthtex1` solid-only vs `depthtex0`) proves a translucent surface on top, then a **hue-fingerprint classifier** on the albedo rejects portals (violet, green-starved) and lava (blue-starved) while accepting water (blue/blue-green, never pale). Water, ice and glass classify; torch flames, portal sparkles, squid ink, pale ice and clear glass do not. * **Synthesized flat water normal** when the decoded normal is untrustworthy (MRT loss or clear value), so Fresnel/reflections still have sane inputs. * **Analytic sky reflection (`waterSkyRefl`)** — zenith/horizon gradient + warm sun-side glow, dimension-aware (Overworld palette, Nether biome sheen, End violet sheen), applied via Schlick Fresnel with a **0.20 floor** (pure F0≈0.02 at steep look-down angles was exactly what let shadowed water crush to black), multiplied by skyLight so cave water stays dark. This is the actual black-water fix and works with SSR disabled. * **Diffuse ambient floor** for rescued pixels whose lightmap may read zero. * **Navy-tint floor** in `gbuffers_water`/`gbuffers_terrain_translucent` — frozen-ocean biome tints (e.g. 0x3938C9) can no longer crush R/G to black after the gamma pipeline. * **`WATER_DEBUG`** diagnostics overlay (Off / Classify / Lightmap / Raw tag alpha) — green = healthy tag, red = depth-rescued, yellow = rescued from the emissive path, magenta = lava/portal-guarded. ### 🪟 SSR & Refraction Fixes (final.fsh) * **Procedural sky fallback** for reflection rays that leave the screen or hit the sky — previously black (the reason the `waterMirrorBoost` hack existed); now a day/night/sunset/storm-aware gradient with moon-phase brightness, Schlick-Fresnel weighting and edge fade. * SSR march start moved **1.0 → 0.5** view units off the surface so the water plane at the player's feet still reflects near-field geometry. * MRT-proof water detection reused for SSR/refraction (same hue guards as `composite.fsh`). * **Procedural raindrop rings** on wet up-facing surfaces — two layers of expanding, world-stable circular waves perturb the SSR normal so rain reads as thousands of tiny ripples instead of one flat mirror. ### 🔍 Post-TAA Sharpening (POST_SHARPEN) * Gentle 5-tap unsharp mask (0.18 amplitude, clamped ≥ 0) applied to the resolved image **before** refraction/SSR/bloom work, recovering texture detail softened by TAA's history blending. On in MED+ profiles. ### ☁️ Volumetric Clouds — Quality Scaling & Dithered Ray Start * New **`CLOUD_QUALITY`** option: 8 / 12 / 16 raymarch steps (was hardcoded 12) — Cheap / Standard / High. * **Dithered ray start** (frame-rotated IGN) on geometry pixels when TAA is enabled: the frame-rotating pattern is temporally resolved into a smooth volumetric integral, killing the 12-step ribbing on thick cumulus without the v0.2.5-era "swimming". Sky pixels keep the stable centred start. ### 🌿 Underwater Plants Sway * New block class **10010** (`seagrass`, `tall_seagrass`, `kelp`, `kelp_plant`, `sea_pickle`) — fronds sway in a current, phase-shifted by height so the tips lag the base, storm-agitated along with the surface foliage path. Displacement is mirrored in `shadow.vsh` so shadows follow the visible fronds. ### 🌊 Biome-Aware Murky Water * Smoothed swamp/mangrove detector (`isSwampBiome`) — swamp water absorbs more red and reads **greener and murkier** (`absorption (0.23, 0.038, 0.10)`, deep colour pushed to dark green) instead of open-ocean blue. ### 🧪 Physical Sky — Warm Ground Bounce * The experimental `SKY_MODE=1` atmosphere now includes a **warm ground-bounce term**: terrain's ~15–20% mean albedo re-scatters in the lower atmosphere (strongest at the horizon and with a high sun), removing the "sterile" blue-bias horizon band. ### 🌇 Lighting & Ambience * **Rayleigh-tinted day ambient** — the day hemisphere ambient now follows the actual sun extinction: golden-hour light is warm and blue-depleted instead of static grey-blue. * **Held-light temperature** — strong held sources (sea lantern, glowstone, shroomlight, lava bucket) read slightly cooler than candle-strength light. ### 🌍 Distant Horizons — Soft Seam * The v1.1.2 hard `discard` at `far + 16` is replaced by a **screen-door dithered transition band**: DH LOD fragments stochastically blend into vanilla chunks over 16 m, so crossing the boundary or changing render distance no longer shows a hard cut. The pattern is static per frame (DH-only pixels are excluded from TAA history). ### 🛠️ Pipeline & VRAM Cleanup * **Removed `colortex5`/`colortex6` format directives** — never read or written, but each forced Iris/OptiFine to allocate a full RGBA16F screen buffer: **~32 MB saved @1080p, ~128 MB @4K**. * **`shadowcolor0Format` RGBA16F → RGBA8** (it only carries LDR `tex * glcolor`): another ~16 MB @1080p / ~64 MB @4K. * **`shadowcolor1Format` removed** (nothing ever wrote to it). * **`colortex0Clear = true`** — no stale garbage on the first frame or after a window resize. * `colortex3`/`colortex4` are now actually used by the bloom pyramid; the full 8-buffer HDR pipeline is engaged. --- ## 🚀 What's New in v1.1.2 — *Render-Distance Shadows & Experimental Distant Horizons (Partial)* Version **1.1.2** extends shadow rendering to the actual render distance with an adaptive LOD system, fixes HDR/TAA pipeline strictness, cleans up deprecated GLSL, and introduces **partial, experimental Distant Horizons support (WIP)** — without claiming full compatibility yet. Work is ongoing. ### 🌗 Extended Shadow Distance with Adaptive LOD * **Shadows now reach render distance.** `shadowDistance` was `60-160m` with a hard cutoff at `shadowDistance`. Now it scales with quality profiles: **60m (VERY_LOW/LOW, no shadows) → 120m (MED) → 256m (HIGH/ULTRA) → 384m (EXTREME)**. The cutoff is replaced by a soft fade `smoothstep(far*0.85, far*0.98)`. * **New `SHADOW_LOD` toggle — Off / Balanced / Aggressive.** Reduces sample count and expands filter radius at distance to keep performance stable: * Balanced: `>25% far → 16 samples ×1.8 radius, >50% → 8 ×2.8` * Aggressive: `>15% → 16×2.0, >35% → 8×3.5, >60% → 4×5.0` * Beyond 95% `far` shadow sampling is skipped entirely. * **`shadowMapResolution` now includes `8192`.** EXTREME uses 8192 for maximum texel density at 384m. HIGH stays 2048, ULTRA 4096. * **New `SHADOW_PCSS_BLUR` toggle — fixed softness vs PCSS penumbra softening.** When enabled, penumbra grows with blocker distance and rain. When disabled, shadows use constant softness. * **PCSS correctness fixes in `composite.fsh:sampleShadow()`:** added UV bounds checks (prevents clamp-to-border artifacts), `avgBlockerDepth` clamped to `1e-4` to avoid NaN, `penumbraSize` clamped `0-2.0`, `lightSize` reduced `140→40` to prevent light bleeding, `actualSpread` capped to `16.0`, out-of-bounds samples counted as unshadowed (1.0) for correct averaging. * Shadow bias `distBias` now scales with `far` instead of `shadowDistance`, plus extra water receiver bias for tagged water pixels (`colortex2.a≈0.8`). ### 🔧 HDR Pipeline Strictness Fix * **Dummy `#define RGBA16F 0` guards** added before the `const int colortex*Format = RGBA16F` directives. This satisfies strict GLSL validators (`C1503 undefined variable RGBA16F`) while Iris/OptiFine's parser still reads the format names (spec second clause). In v1.1.1 the directives were inside a `/* */` comment and were ignored by some loaders. * Now **all used buffers are explicitly `RGBA16F`**: `colortex0/1/2` (main HDR + PBR + material tags), `colortex3/4/5/6` (unused today but set to HDR for a full pipeline), `colortex7` (TAA history, `colortex7Clear=false`), and optional `shadowcolor0/1Format = RGBA16F`. * Cost noted: ~16MB per 1080p RGBA16F buffer → ~128MB VRAM for 8 buffers. ### 🌍 Experimental — Partial Distant Horizons Support (WIP, not full support) > ⚠️ AuraLite does **NOT** yet claim full Distant Horizons compatibility. v1.1.2 only adds a **minimal, experimental code path** so LOD chunks are no longer invisible under Iris. It's functional enough for testing, but considered partial and work-in-progress. * **Why it was needed:** Without `dh_terrain.vsh/.fsh`, `dh_water.vsh/.fsh`, `dh_shadow.vsh/.fsh`, Iris marks the pack as incompatible with DH and simply doesn't draw DH's simplified LOD chunks at all — symptom "shader works but DH chunks invisible". Presence of these files is enough for Iris/DH auto-detection (`dhShadow.enabled` defaults true). * **What v1.1.2 does:** * `dh_terrain`/`dh_water` write the same `colortex0/1/2` layout as vanilla passes, so existing lighting/fog/shadow/cloud/godray code in `composite.fsh` applies to LOD geometry without other changes. * Depth reconciliation in `composite.fsh`: detects `depthtex0>=1.0 && dhDepthTex0