promotional bannermobile promotional banner

Dynamic Spotlight API

Unlisted
An API for Dynamic Spotlights in Veil, Sodium Dynamic Lights, or various Shaders! Sable/Create Aeronautics compatible!

Dynamic Spotlights API (For Developers & Modpack Creators)

Dynamic Spotlights API is a lightweight, asset-less developer library designed to manage, coordinate, and register custom light sources in modern rendering setups. It acts as the backbone of the Dynamic Spotlights mod, allowing any third-party mod or add-on to implement customized point or volumetric lights.

If you ended up here and are not a developer or making a modpack, you might be in the wrong place. You might be looking for the actual spotlight mod that depends on this. It's here: [TODO add link to my Dynamic Spotlight Mod when it finishes].




Dev Features:

Universal Light Source Interface (ILightSource): Expose any block entity, entity, or object as an active light source by implementing a single interface defining position, direction, brightness, cone angle, beam distance, and dye color.


Thread-Safe Light Registry (ActiveLightRegistry): A centralized, client-side registry that lets light sources register/unregister themselves during lifecycle events (like chunk load/unload), avoiding performance-heavy per-frame level scans.


Dynamic Uniform Gathering: Features optimized spatial gathering (gatherForShader()) that sorts and uploads the closest 
 active lights to shader uniform arrays every frame.


Reflective Soft-Dependency Proxies: Contains pre-built, thread-safe dynamic classloaders (SableHelper, DynLightsHelper, IrisHelper) using double-checked locking to safely integrate with Sable physics, Sodium/Embeddium Dynamic Lights, and Iris/Oculus Shaders at runtime without requiring compile-time hard dependencies or causing linkage crashes.


Custom Light Pipelines (ILightPipeline): Switch between active rendering modes (Veil GPU volumetric shaders, Sodium Dynamic Lights rendering faked spotlights, or even shader injection for your favorite shader packs such as Complementary.

Soft dependencies: 
Veil: [TODO Add links before release]
Sodium Dynamic Lights

Other compatabilities:
Sable/ Create: Aeronautics

Dynamic Spotlight API Team

profile avatar
  • 2
    Projects
  • 9
    Downloads