Minetest  5.4.0
light.h File Reference
#include <cassert>
#include "irrlichttypes.h"
+ Include dependency graph for light.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define LIGHT_MAX   14
 
#define LIGHT_SUN   15
 

Functions

u8 decode_light (u8 light)
 
float decode_light_f (float light_f)
 
void set_light_table (float gamma)
 
u8 blend_light (u32 daylight_factor, u8 lightday, u8 lightnight)
 

Variables

const u8 * light_decode_table
 

Macro Definition Documentation

◆ LIGHT_MAX

#define LIGHT_MAX   14

◆ LIGHT_SUN

#define LIGHT_SUN   15

Function Documentation

◆ blend_light()

u8 blend_light ( u32  daylight_factor,
u8  lightday,
u8  lightnight 
)
inline

References LIGHT_SUN.

Referenced by MapNode::getLightBlend(), Particle::updateLight(), and GenericCAO::updateLight().

+ Here is the caller graph for this function:

◆ decode_light()

u8 decode_light ( u8  light)
inline

References light_decode_table, and LIGHT_SUN.

Referenced by SmokePuffCSO::SmokePuffCSO(), ClientMap::getBackgroundBrightness(), getFaceLight(), getInteriorLight(), getSmoothLightCombined(), getVisibleBrightness(), MapblockMeshGenerator::prepareLiquidNodeDrawing(), Particle::updateLight(), and GenericCAO::updateLight().

+ Here is the caller graph for this function:

◆ decode_light_f()

float decode_light_f ( float  light_f)

References LightingParams::a, LightingParams::b, LightingParams::boost, LightingParams::c, LightingParams::center, LightingParams::gamma, params, LightingParams::sigma, and sqr().

Referenced by set_light_table(), and Game::updateFrame().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_light_table()

void set_light_table ( float  gamma)

References LightingParams::a, LightingParams::b, LightingParams::boost, LightingParams::c, LightingParams::center, decode_light_f(), g_settings, LightingParams::gamma, Settings::getFloat(), light_LUT, LIGHT_SUN, params, rangelim, and LightingParams::sigma.

Referenced by Game::run().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ light_decode_table

const u8* light_decode_table
extern

Referenced by decode_light().