{
 "id": "hillaire-sky-atmosphere",
 "title": "Scalable Production Sky and Atmosphere (Hillaire)",
 "aliases": [
  "UE Sky Atmosphere",
  "multi-scattering LUT"
 ],
 "domain": "volumes",
 "subdomain": "atmosphere",
 "stage": "volume",
 "realtime": "realtime",
 "platforms": [
  "webgl2",
  "webgpu",
  "desktop-gpu",
  "mobile-gpu",
  "unreal"
 ],
 "year_introduced": 2020,
 "inputs": [
  "material-params",
  "depth"
 ],
 "outputs": [
  "radiance",
  "hdr-image"
 ],
 "style": "photoreal",
 "dynamic": "dynamic",
 "summary": "Real-time planetary atmosphere built from small per-frame lookup tables: transmittance, a multiple-scattering table and a sky-view table, plus a camera froxel volume for aerial perspective.",
 "how_it_works": "Every frame a few tiny LUTs are rebuilt, so all atmosphere parameters can be animated. A transmittance LUT stores optical depth to the top of atmosphere indexed by height and sun angle. A multi-scattering LUT replaces higher-order scattering with an isotropic-source approximation: it evaluates a geometric series of the second-order bounce, indexed by height and sun angle, which is cheap and close to brute-force results. A sky-view LUT then ray-marches single scattering once per direction (parametrized to concentrate texels at the horizon) and adds the multi-scattering term. For geometry, a low-resolution camera-aligned volume of scattering and transmittance gives aerial perspective on opaque and transparent objects by one fetch. Sun and moon discs, ground bounce and planet shadow fall out of the same tables.",
 "when_to_use": "Choose it when the atmosphere must be fully dynamic (time of day, weather-driven density, alien planets), run on a console or mobile-class budget, and be applied to opaque objects, particles and clouds consistently.\n\nPrefer `precomputed-atmospheric-scattering` when parameters are fixed and you want the more exact multi-order reference with irradiance tables. Prefer `preetham-sky` or `hosek-wilkie-sky` when you only need a ground-level sky dome with no aerial perspective. Pair with `nubis-volumetric-clouds` for the cloud layer.",
 "cost": {
  "class": "cheap",
  "notes": "The paper reports it runs within a small frame budget on consoles and mobile hardware; the LUT updates are low resolution so cost scales mainly with the sky-view and froxel passes."
 },
 "failure_modes": [
  "Multi-scattering approximation drifts from ground truth for very thick atmospheres or high-albedo ground",
  "Low-res aerial perspective volume shows banding or leaks near depth discontinuities",
  "Sky-view LUT interpolation can blur the sun's near-horizon glow and produce a faint ring around the sun disc",
  "Camera inside a cloud or fog layer needs separate handling; the model assumes space-like atmosphere layers",
  "No shadowing of atmosphere by terrain unless extra shadow-volume sampling is added"
 ],
 "sources": [
  {
   "role": "primary",
   "key": "doi:10.1111/cgf.14050",
   "type": "paper",
   "title": "A Scalable and Production Ready Sky and Atmosphere Rendering Technique",
   "authors": [
    "Sébastien Hillaire"
   ],
   "year": 2020,
   "venue": "Computer Graphics Forum",
   "url": "https://doi.org/10.1111/cgf.14050",
   "ids": {
    "doi": "10.1111/cgf.14050"
   },
   "license": null,
   "extra": {
    "csl_type": "journal-article"
   },
   "provenance": {
    "title": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1111/cgf.14050",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1111/cgf.14050",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1111/cgf.14050",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1111/cgf.14050",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "crossref",
     "endpoint": "https://api.crossref.org/works/10.1111/cgf.14050",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": 1,
   "__bib": "hillaire2020scalable"
  },
  {
   "role": "implementation",
   "key": "gh:sebh/unrealengineskyatmosphere",
   "type": "code",
   "title": "sebh/UnrealEngineSkyAtmosphere",
   "description": "Unreal Engine Sky Atmosphere Rendering Technique",
   "authors": [
    "sebh"
   ],
   "year": 2020,
   "venue": "GitHub",
   "url": "https://github.com/sebh/UnrealEngineSkyAtmosphere",
   "ids": {
    "repo": "sebh/UnrealEngineSkyAtmosphere"
   },
   "license": "MIT",
   "extra": {
    "stars": 876,
    "stars_checked": "2026-11-29",
    "archived": false,
    "fork": false,
    "pushed_at": "2022-09-11T12:50:14Z",
    "language": "C++",
    "homepage": "https://www.unrealengine.com",
    "license_name": "MIT License"
   },
   "provenance": {
    "title": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/sebh/UnrealEngineSkyAtmosphere",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/sebh/UnrealEngineSkyAtmosphere",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/sebh/UnrealEngineSkyAtmosphere",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/sebh/UnrealEngineSkyAtmosphere",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/sebh/UnrealEngineSkyAtmosphere",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "license": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/sebh/UnrealEngineSkyAtmosphere",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": null,
   "__bib": "sebh2020sebh"
  },
  {
   "role": "implementation",
   "key": "gh:takram-design-engineering/three-geospatial",
   "type": "code",
   "title": "takram-design-engineering/three-geospatial",
   "description": "Geospatial Rendering in Three.js",
   "authors": [
    "takram-design-engineering"
   ],
   "year": 2024,
   "venue": "GitHub",
   "url": "https://github.com/takram-design-engineering/three-geospatial",
   "ids": {
    "repo": "takram-design-engineering/three-geospatial"
   },
   "license": "MIT",
   "extra": {
    "stars": 1798,
    "stars_checked": "2026-11-29",
    "archived": false,
    "fork": false,
    "pushed_at": "2026-05-27T06:40:25Z",
    "language": "TypeScript",
    "homepage": "https://takram-design-engineering.github.io/three-geospatial",
    "license_name": "MIT License"
   },
   "provenance": {
    "title": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/takram-design-engineering/three-geospatial",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "authors": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/takram-design-engineering/three-geospatial",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "year": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/takram-design-engineering/three-geospatial",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "venue": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/takram-design-engineering/three-geospatial",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "url": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/takram-design-engineering/three-geospatial",
     "checked_at": "2026-11-29T15:51:27.588Z"
    },
    "license": {
     "authority": "github",
     "endpoint": "https://api.github.com/repos/takram-design-engineering/three-geospatial",
     "checked_at": "2026-11-29T15:51:27.588Z"
    }
   },
   "status": "verified",
   "checked_at": "2026-11-29T15:51:27.588Z",
   "title_sim": null,
   "__bib": "takramdesignengineering2024takram"
  }
 ],
 "presets": [
  {
   "id": "hillaire-sky-atmosphere-specimen",
   "title": "Toy ray-marched single-scattering atmosphere with Hillaire coefficients at sunset",
   "runtime": "glsl-fragment",
   "params": {
    "R_PLANET": 6360,
    "R_ATMOS": 6460,
    "SUN_I": 22
   },
   "code": "// Toy single-scattering atmosphere ray-march using the Hillaire (2020) coefficient set:\n// Rayleigh + Mie + ozone absorption, planet shadow, ground bounce. Real-time version bakes this into LUTs.\nconst float R_PLANET = 6360.0;\nconst float R_ATMOS = 6460.0;\nconst vec3 BETA_R = vec3(5.802, 13.558, 33.1) * 1e-3;\nconst float BETA_M_S = 3.996e-3;\nconst float BETA_M_E = 4.44e-3;\nconst vec3 BETA_O = vec3(0.65, 1.881, 0.085) * 1e-3;\nconst float SUN_I = 22.0;\n\nvec2 raySph(vec3 ro, vec3 rd, float r) {\n  float b = dot(ro, rd), c = dot(ro, ro) - r * r, h = b * b - c;\n  if (h < 0.0) return vec2(-1.0);\n  h = sqrt(h); return vec2(-b - h, -b + h);\n}\nvec3 densities(vec3 p) {\n  float h = length(p) - R_PLANET;\n  return vec3(exp(-h / 8.0), exp(-h / 1.2), max(0.0, 1.0 - abs(h - 25.0) / 15.0));\n}\nvec3 ext(vec3 d) { return BETA_R * d.x + BETA_M_E * d.y + BETA_O * d.z; }\nvec3 sunTrans(vec3 p, vec3 sd) {\n  if (raySph(p, sd, R_PLANET).x > 0.0) return vec3(0.0);\n  float len = raySph(p, sd, R_ATMOS).y; float ds = len / 6.0; vec3 od = vec3(0.0);\n  for (int i = 0; i < 6; i++) od += ext(densities(p + sd * (float(i) + 0.5) * ds)) * ds;\n  return exp(-od);\n}\nvoid mainImage(out vec4 fragColor, in vec2 fragCoord) {\n  vec2 uv = (fragCoord - 0.5 * iResolution.xy) / iResolution.y;\n  vec3 ro = vec3(0.0, R_PLANET + 0.3, 0.0);\n  vec3 rd = normalize(vec3(uv.x * 1.3, uv.y * 1.3 + 0.14, -1.0));\n  vec3 sd = normalize(vec3(0.25, 0.07, -1.0));\n  vec2 pg = raySph(ro, rd, R_PLANET);\n  float tmax = pg.x > 0.0 ? pg.x : raySph(ro, rd, R_ATMOS).y;\n  float cs = dot(rd, sd);\n  float phR = 3.0 / (16.0 * 3.14159) * (1.0 + cs * cs);\n  float g = 0.8; float phM = (1.0 - g * g) / (12.566 * pow(1.0 + g * g - 2.0 * g * cs, 1.5));\n  vec3 od = vec3(0.0), L = vec3(0.0);\n  for (int i = 0; i < 24; i++) {\n    float t0 = tmax * pow(float(i) / 24.0, 2.0), t1 = tmax * pow(float(i + 1) / 24.0, 2.0);\n    float ds = t1 - t0; vec3 p = ro + rd * (0.5 * (t0 + t1));\n    vec3 d = densities(p); od += ext(d) * ds;\n    L += exp(-od) * sunTrans(p, sd) * (BETA_R * d.x * phR + BETA_M_S * d.y * phM) * ds * SUN_I;\n  }\n  if (pg.x > 0.0) {\n    vec3 hp = ro + rd * pg.x; vec3 n = normalize(hp);\n    L += exp(-od) * vec3(0.12, 0.1, 0.08) * sunTrans(hp, sd) * max(dot(n, sd), 0.0) * SUN_I;\n  } else if (cs > 0.99995) L += exp(-od) * SUN_I * 8.0;\n  L = 1.0 - exp(-L * 0.9);\n  fragColor = vec4(pow(L, vec3(1.0 / 2.2)), 1.0);\n}\n",
   "basis": "original",
   "license_note": "written for this index",
   "execution_fidelity": "conceptual-diagram",
   "proof": {
    "kind": "rendered",
    "label": "rendered 2026-11-29",
    "ok": true,
    "proof": {
     "ok": true,
     "technique": "hillaire-sky-atmosphere",
     "runtime": "glsl-fragment",
     "checked_at": "2026-11-29T15:51:50.471Z",
     "renderer": "Chromium 145.0.7632.6 headless, WebGL2 via ANGLE/SwiftShader, 512×512, iTime=1.5",
     "stats": {
      "mean": 0.4435,
      "std": 0.1722,
      "unique_colors": 340
     },
     "image": "/specimens/hillaire-sky-atmosphere-specimen.webp",
     "reason": null
    }
   }
  }
 ],
 "related": [
  "precomputed-atmospheric-scattering",
  "rayleigh-mie-single-scattering",
  "nubis-volumetric-clouds",
  "froxel-volumetric-fog"
 ],
 "extends": [
  "precomputed-atmospheric-scattering"
 ],
 "supersedes": [],
 "combines_with": [
  {
   "id": "nubis-volumetric-clouds",
   "why": "Sky-view and transmittance LUTs light the cloud layer; clouds are composited before the aerial-perspective volume is applied."
  },
  {
   "id": "exponential-height-fog",
   "why": "Aerial perspective handles distant haze while height fog covers the low, dense layer near ground."
  }
 ],
 "provenance": {
  "prose": "original text written for this index (research draft, editorially reviewed)",
  "sources_verified_at": "2026-11-29T15:51:27.588Z",
  "draft": "data/drafts/volumes/hillaire-sky-atmosphere.json"
 },
 "solves": [
  "real-time sky with time of day changes",
  "view from ground to space atmosphere in a game",
  "aerial perspective haze over distant terrain",
  "sky colour must update without long precompute"
 ],
 "authority": "Hillaire, 2020",
 "url": "https://texelatlas.vercel.app/t/hillaire-sky-atmosphere/",
 "execution_fidelity": "conceptual-diagram",
 "fidelity_label": "Visual Diagram",
 "benchmark_eligible": false,
 "gpu_weight": {
  "weight_x": 103.13,
  "tier": "extreme",
  "p50_ms": 3.393,
  "p95_ms": 3.5244,
  "baseline_p50_ms": 0.0329,
  "gpu": "Tesla T4/PCIe/SSE2",
  "resolution": "1920x1080",
  "method": "opengl-timer-query",
  "frames": 40,
  "preset_id": "hillaire-sky-atmosphere-specimen",
  "execution_fidelity": "conceptual-diagram",
  "fidelity_label": "Visual Diagram",
  "benchmark_eligible": false,
  "generated_at": "2026-11-30T21:07:47Z",
  "l4": {
   "weight_x": 90.42,
   "tier": "extreme",
   "p50_ms": 1.4377,
   "p95_ms": 1.4633,
   "speedup_x": 2.36,
   "gpu": "NVIDIA L4/PCIe/SSE2",
   "resolution": "1920x1080",
   "baseline_p50_ms": 0.0159
  },
  "a100": {
   "weight_x": 70.36,
   "tier": "extreme",
   "p50_ms": 2.0265,
   "p95_ms": 2.0265,
   "speedup_x": 1.67,
   "gpu": "NVIDIA A100-SXM4-40GB/PCIe/SSE2",
   "resolution": "1920x1080",
   "baseline_p50_ms": 0.0288
  }
 }
}