# sixthsurge/photon architecture

> Architecture diagram of the GitHub repository sixthsurge/photon, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sixthsurge/photon
- Repository: https://github.com/sixthsurge/photon

## Overview

Photon Shaders is a Minecraft shader pack: a player installs it through Iris or OptiFine, and the loader applies its shaders to produce the game’s rendered image. The graph preserves the README’s major visual capabilities and the special-mod integrations. The tree identifies plausible implementation areas, but shader source excerpts were not provided, so internal calls and render-stage ordering are not asserted.

Main entry points: [`shaders/shaders.properties`](https://github.com/sixthsurge/photon/blob/main/shaders/shaders.properties) (Photon Shader Pack), [`shaders/settings.glsl`](https://github.com/sixthsurge/photon/blob/main/shaders/settings.glsl) (Settings Menu), [`shaders/program`](https://github.com/sixthsurge/photon/tree/main/shaders/program) (Scene Buffers), [`shaders/world0`](https://github.com/sixthsurge/photon/tree/main/shaders/world0) (World Passes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Pack Runtime"]
  node_photon["Photon Shader Pack<br/>[shaders.properties]"]
  node_settings["Settings Menu<br/>[settings.glsl]"]
end

subgraph group_world["World Rendering"]
  node_gbuffers["Scene Buffers"]
  node_worldpasses["World Passes"]
  node_surfaces["Surface Materials"]
end

subgraph group_lighting["Lighting and Atmosphere"]
  node_sky["Sky and Clouds"]
  node_weather["Weather System"]
  node_lighting["Lighting"]
  node_fog["Volumetric Fog"]
  node_ao["Ambient Occlusion"]
end

subgraph group_effects["Image Effects"]
  node_post["Post Processing"]
  node_temporal["Temporal Effects"]
  node_output["Rendered Image<br/>[final.fsh]"]
end

subgraph group_integrations["Integrations"]
  node_distant["Distant Horizons"]
  node_voxy["Voxy Support<br/>[voxy_opaque.glsl]"]
  node_photonics["Photonics Support<br/>[photonics.glsl]"]
  node_iris["Iris Loader"]
  node_optifine["OptiFine Loader"]
end

node_player(("Minecraft Player"))
node_loader["Shader Loader"]

node_player -->|"installs through"| node_loader
node_loader -->|"loads pack"| node_photon
node_photon -->|"offers customization"| node_settings
node_photon -.->|"provides shaders"| node_gbuffers
node_photon -.->|"renders worlds"| node_worldpasses
node_photon -->|"supports materials"| node_surfaces
node_photon -->|"renders sky"| node_sky
node_photon -->|"adds weather"| node_weather
node_photon -->|"provides lighting"| node_lighting
node_photon -->|"provides fog"| node_fog
node_photon -->|"provides occlusion"| node_ao
node_photon -->|"applies bloom"| node_post
node_photon -->|"improves image quality"| node_temporal
node_photon -.->|"renders image"| node_output
node_photon -->|"supports mod"| node_distant
node_photon -->|"supports mod"| node_voxy
node_photon -->|"supports mod"| node_photonics
node_loader -->|"compatible with"| node_iris
node_loader -->|"compatible with"| node_optifine
node_iris -->|"loads pack"| node_photon
node_optifine -->|"loads pack"| node_photon

click node_photon "https://github.com/sixthsurge/photon/blob/main/shaders/shaders.properties"
click node_settings "https://github.com/sixthsurge/photon/blob/main/shaders/settings.glsl"
click node_gbuffers "https://github.com/sixthsurge/photon/tree/main/shaders/program"
click node_worldpasses "https://github.com/sixthsurge/photon/tree/main/shaders/world0"
click node_surfaces "https://github.com/sixthsurge/photon/tree/main/shaders/include/surface"
click node_sky "https://github.com/sixthsurge/photon/tree/main/shaders/include/sky"
click node_weather "https://github.com/sixthsurge/photon/tree/main/shaders/include/weather"
click node_lighting "https://github.com/sixthsurge/photon/tree/main/shaders/include/lighting"
click node_fog "https://github.com/sixthsurge/photon/tree/main/shaders/include/fog"
click node_ao "https://github.com/sixthsurge/photon/tree/main/shaders/include/lighting/ao"
click node_post "https://github.com/sixthsurge/photon/tree/main/shaders/include/post_processing"
click node_temporal "https://github.com/sixthsurge/photon/blob/main/shaders/program/c4_taa_exposure.fsh"
click node_output "https://github.com/sixthsurge/photon/blob/main/shaders/program/final.fsh"
click node_distant "https://github.com/sixthsurge/photon/blob/main/shaders/include/misc/lod_mod_support.glsl"
click node_voxy "https://github.com/sixthsurge/photon/blob/main/shaders/program/voxy_opaque.glsl"
click node_photonics "https://github.com/sixthsurge/photon/blob/main/shaders/photonics/photonics.glsl"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_photon,node_settings toneBlue
class node_gbuffers,node_worldpasses,node_surfaces toneAmber
class node_sky,node_weather,node_lighting,node_fog,node_ao toneMint
class node_post,node_temporal,node_output toneRose
class node_distant,node_voxy,node_photonics,node_iris,node_optifine,node_player,node_loader toneIndigo
```

## Components

### Pack Runtime

- [Photon Shader Pack](https://github.com/sixthsurge/photon/blob/main/shaders/shaders.properties): `shaders/shaders.properties`
- [Settings Menu](https://github.com/sixthsurge/photon/blob/main/shaders/settings.glsl): `shaders/settings.glsl`

### World Rendering

- [Scene Buffers](https://github.com/sixthsurge/photon/tree/main/shaders/program): `shaders/program`
- [World Passes](https://github.com/sixthsurge/photon/tree/main/shaders/world0): `shaders/world0`
- [Surface Materials](https://github.com/sixthsurge/photon/tree/main/shaders/include/surface): `shaders/include/surface`

### Lighting and Atmosphere

- [Sky and Clouds](https://github.com/sixthsurge/photon/tree/main/shaders/include/sky): `shaders/include/sky`
- [Weather System](https://github.com/sixthsurge/photon/tree/main/shaders/include/weather): `shaders/include/weather`
- [Lighting](https://github.com/sixthsurge/photon/tree/main/shaders/include/lighting): `shaders/include/lighting`
- [Volumetric Fog](https://github.com/sixthsurge/photon/tree/main/shaders/include/fog): `shaders/include/fog`
- [Ambient Occlusion](https://github.com/sixthsurge/photon/tree/main/shaders/include/lighting/ao): `shaders/include/lighting/ao`

### Image Effects

- [Post Processing](https://github.com/sixthsurge/photon/tree/main/shaders/include/post_processing): `shaders/include/post_processing`
- [Temporal Effects](https://github.com/sixthsurge/photon/blob/main/shaders/program/c4_taa_exposure.fsh): `shaders/program/c4_taa_exposure.fsh`
- [Rendered Image](https://github.com/sixthsurge/photon/blob/main/shaders/program/final.fsh): `shaders/program/final.fsh`

### Integrations

- [Distant Horizons](https://github.com/sixthsurge/photon/blob/main/shaders/include/misc/lod_mod_support.glsl): `shaders/include/misc/lod_mod_support.glsl`
- [Voxy Support](https://github.com/sixthsurge/photon/blob/main/shaders/program/voxy_opaque.glsl): `shaders/program/voxy_opaque.glsl`
- [Photonics Support](https://github.com/sixthsurge/photon/blob/main/shaders/photonics/photonics.glsl): `shaders/photonics/photonics.glsl`
- **Iris Loader**
- **OptiFine Loader**

### Other components

- **Minecraft Player**
- **Shader Loader**

## Connections

- Minecraft Player → Shader Loader: installs through (evidence: `README.md`)
- Shader Loader → Photon Shader Pack: loads pack (evidence: `README.md`)
- Photon Shader Pack → Settings Menu: offers customization (evidence: `README.md`)
- Photon Shader Pack → Scene Buffers: provides shaders
- Photon Shader Pack → World Passes: renders worlds
- Photon Shader Pack → Surface Materials: supports materials (evidence: `README.md`)
- Photon Shader Pack → Sky and Clouds: renders sky (evidence: `README.md`)
- Photon Shader Pack → Weather System: adds weather (evidence: `README.md`)
- Photon Shader Pack → Lighting: provides lighting (evidence: `README.md`)
- Photon Shader Pack → Volumetric Fog: provides fog (evidence: `README.md`)
- Photon Shader Pack → Ambient Occlusion: provides occlusion (evidence: `README.md`)
- Photon Shader Pack → Post Processing: applies bloom (evidence: `README.md`)
- Photon Shader Pack → Temporal Effects: improves image quality (evidence: `README.md`)
- Photon Shader Pack → Rendered Image: renders image
- Photon Shader Pack → Distant Horizons: supports mod (evidence: `README.md`)
- Photon Shader Pack → Voxy Support: supports mod (evidence: `README.md`)
- Photon Shader Pack → Photonics Support: supports mod (evidence: `README.md`)
- Shader Loader → Iris Loader: compatible with (evidence: `README.md`)
- Shader Loader → OptiFine Loader: compatible with (evidence: `README.md`)
- Iris Loader → Photon Shader Pack: loads pack (evidence: `README.md`)
- OptiFine Loader → Photon Shader Pack: loads pack (evidence: `README.md`)
