![]() |
DarkPlaces
Game engine based on the Quake 1 engine by id Software, developed by LadyHavoc
|
|
#include "quakedef.h"
#include "r_shadow.h"
#include "cl_collision.h"
#include "portals.h"
#include "image.h"
Go to the source code of this file.
Macros | |
#define | ATTEN1DSIZE 32 |
#define | ATTEN2DSIZE 64 |
#define | ATTEN3DSIZE 32 |
#define | ATTENTABLESIZE 256 |
#define | BUFFER_OFFSET(i) |
#define | EDLIGHTSPRSIZE 8 |
#define | MAX_MODELSHADOWS 1024 |
#define | MAX_SCENELIGHTS 65536 |
#define | R_Shadow_CalcEntitySideMask(ent, worldtolight, radiustolight, bias) |
Variables | |
int | bboxedges [12][2] |
static const unsigned short | bboxelements [36] |
static const float | bboxpoints [8][3] |
int | con_vislines |
cvar_t | gl_flashblend = {CF_CLIENT | CF_ARCHIVE, "gl_flashblend", "0", "render bright coronas for dynamic lights instead of actual lighting, fast but ugly"} |
cvar_t | gl_lightmaps |
matrix4x4_t | matrix_attenuationxyz |
matrix4x4_t | matrix_attenuationz |
int | maxshadowmark |
int | maxshadowsides |
int | maxshadowtriangles |
int | maxshadowvertices |
int | maxvertexupdate |
int | numshadowmark |
int | numshadowsides |
cvar_t | r_coronas = {CF_CLIENT | CF_ARCHIVE, "r_coronas", "0", "brightness of corona flare effects around certain lights, 0 disables corona effects"} |
cvar_t | r_coronas_occlusionquery = {CF_CLIENT | CF_ARCHIVE, "r_coronas_occlusionquery", "0", "fades coronas according to visibility, requires OpenGL 4.4"} |
cvar_t | r_coronas_occlusionsizescale = {CF_CLIENT | CF_ARCHIVE, "r_coronas_occlusionsizescale", "0.1", "size of light source for corona occlusion checksum the proportion of hidden pixels controls corona intensity"} |
cvar_t | r_editlights = {CF_CLIENT, "r_editlights", "0", "enables .rtlights file editing mode"} |
cvar_t | r_editlights_current_ambient = {CF_CLIENT, "r_editlights_current_ambient", "0", "ambient intensity of selected light"} |
cvar_t | r_editlights_current_angles = {CF_CLIENT, "r_editlights_current_angles", "0 0 0", "angles of selected light"} |
cvar_t | r_editlights_current_color = {CF_CLIENT, "r_editlights_current_color", "1 1 1", "color of selected light"} |
cvar_t | r_editlights_current_corona = {CF_CLIENT, "r_editlights_current_corona", "0", "corona intensity of selected light"} |
cvar_t | r_editlights_current_coronasize = {CF_CLIENT, "r_editlights_current_coronasize", "0", "corona size of selected light"} |
cvar_t | r_editlights_current_cubemap = {CF_CLIENT, "r_editlights_current_cubemap", "0", "cubemap of selected light"} |
cvar_t | r_editlights_current_diffuse = {CF_CLIENT, "r_editlights_current_diffuse", "1", "diffuse intensity of selected light"} |
cvar_t | r_editlights_current_normalmode = {CF_CLIENT, "r_editlights_current_normalmode", "0", "normalmode flag of selected light"} |
cvar_t | r_editlights_current_origin = {CF_CLIENT, "r_editlights_current_origin", "0 0 0", "origin of selected light"} |
cvar_t | r_editlights_current_radius = {CF_CLIENT, "r_editlights_current_radius", "0", "radius of selected light"} |
cvar_t | r_editlights_current_realtimemode = {CF_CLIENT, "r_editlights_current_realtimemode", "0", "realtimemode flag of selected light"} |
cvar_t | r_editlights_current_shadows = {CF_CLIENT, "r_editlights_current_shadows", "0", "shadows flag of selected light"} |
cvar_t | r_editlights_current_specular = {CF_CLIENT, "r_editlights_current_specular", "1", "specular intensity of selected light"} |
cvar_t | r_editlights_current_style = {CF_CLIENT, "r_editlights_current_style", "0", "style of selected light"} |
cvar_t | r_editlights_cursordistance = {CF_CLIENT, "r_editlights_cursordistance", "1024", "maximum distance of cursor from eye"} |
cvar_t | r_editlights_cursorgrid = {CF_CLIENT, "r_editlights_cursorgrid", "4", "snaps cursor to this grid size"} |
vec3_t | r_editlights_cursorlocation |
cvar_t | r_editlights_cursorpushback = {CF_CLIENT, "r_editlights_cursorpushback", "0", "how far to pull the cursor back toward the eye"} |
cvar_t | r_editlights_cursorpushoff = {CF_CLIENT, "r_editlights_cursorpushoff", "4", "how far to push the cursor off the impacted surface"} |
cvar_t | r_editlights_drawproperties = {CF_CLIENT, "r_editlights_drawproperties", "1", "draw properties of currently selected light"} |
qbool | r_editlights_lockcursor |
cvar_t | r_editlights_quakelightsizescale = {CF_CLIENT | CF_ARCHIVE, "r_editlights_quakelightsizescale", "1", "changes size of light entities loaded from a map"} |
skinframe_t * | r_editlights_sprcubemaplight |
skinframe_t * | r_editlights_sprcubemapnoshadowlight |
skinframe_t * | r_editlights_sprcursor |
skinframe_t * | r_editlights_sprlight |
skinframe_t * | r_editlights_sprnoshadowlight |
skinframe_t * | r_editlights_sprselection |
static float | r_shadow_attendividebias |
static float | r_shadow_attenlinearscale |
static float | r_shadow_attentable [ATTENTABLESIZE+1] |
rtexture_t * | r_shadow_attenuationgradienttexture |
cvar_t | r_shadow_bouncegrid = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid", "0", "perform particle tracing for indirect lighting (Global Illumination / radiosity) using a 3D texture covering the scene, only active on levels with realtime lights active (r_shadow_realtime_world is usually required for these)"} |
cvar_t | r_shadow_bouncegrid_blur = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_blur", "0", "apply a 1-radius blur on bouncegrid to denoise it and deal with boundary issues with surfaces"} |
cvar_t | r_shadow_bouncegrid_dynamic_bounceminimumintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_bounceminimumintensity", "0.05", "stop bouncing once intensity drops below this fraction of the original particle color"} |
cvar_t | r_shadow_bouncegrid_dynamic_culllightpaths = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_culllightpaths", "0", "skip accumulating light in the bouncegrid texture where the light paths are out of view (dynamic mode only)"} |
cvar_t | r_shadow_bouncegrid_dynamic_directionalshading = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_directionalshading", "1", "use diffuse shading rather than ambient, 3D texture becomes 8x as many pixels to hold the additional data"} |
cvar_t | r_shadow_bouncegrid_dynamic_dlightparticlemultiplier = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_dlightparticlemultiplier", "1", "if set to a high value like 16 this can make dlights look great, but 0 is recommended for performance reasons"} |
cvar_t | r_shadow_bouncegrid_dynamic_hitmodels = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_hitmodels", "0", "enables hitting character model geometry (SLOW)"} |
cvar_t | r_shadow_bouncegrid_dynamic_lightradiusscale = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_lightradiusscale", "5", "particles stop at this fraction of light radius (can be more than 1)"} |
cvar_t | r_shadow_bouncegrid_dynamic_maxbounce = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_maxbounce", "5", "maximum number of bounces for a particle (minimum is 0)"} |
cvar_t | r_shadow_bouncegrid_dynamic_maxphotons = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_maxphotons", "25000", "upper bound on photons to shoot per update, divided proportionately between lights - normally the number of photons is calculated by energyperphoton"} |
cvar_t | r_shadow_bouncegrid_dynamic_quality = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_quality", "1", "amount of photons that should be fired (this is multiplied by spacing ^ 2 to make it adaptive with spacing changes)"} |
cvar_t | r_shadow_bouncegrid_dynamic_spacing = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_spacing", "64", "unit size of bouncegrid pixel"} |
cvar_t | r_shadow_bouncegrid_dynamic_updateinterval = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_updateinterval", "0", "update bouncegrid texture once per this many seconds, useful values are 0, 0.05, or 1000000"} |
cvar_t | r_shadow_bouncegrid_dynamic_x = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_x", "64", "maximum texture size of bouncegrid on X axis"} |
cvar_t | r_shadow_bouncegrid_dynamic_y = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_y", "64", "maximum texture size of bouncegrid on Y axis"} |
cvar_t | r_shadow_bouncegrid_dynamic_z = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_z", "32", "maximum texture size of bouncegrid on Z axis"} |
cvar_t | r_shadow_bouncegrid_floatcolors = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_floatcolors", "1", "upload texture as RGBA16F (or RGBA32F when set to 2) rather than RGBA8 format - this gives more dynamic range and accuracy"} |
cvar_t | r_shadow_bouncegrid_includedirectlighting = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_includedirectlighting", "0", "allows direct lighting to be recorded, not just indirect (gives an effect somewhat like r_shadow_realtime_world_lightmaps)"} |
cvar_t | r_shadow_bouncegrid_intensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_intensity", "4", "overall brightness of bouncegrid texture"} |
cvar_t | r_shadow_bouncegrid_lightpathsize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_lightpathsize", "64", "radius (in game units) of the light path for accumulation of light in the bouncegrid texture"} |
cvar_t | r_shadow_bouncegrid_normalizevectors = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_normalizevectors", "1", "normalize random vectors (otherwise their length can vary, which dims the lighting further from the light)"} |
cvar_t | r_shadow_bouncegrid_particlebounceintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_particlebounceintensity", "4", "amount of energy carried over after each bounce, this is a multiplier of texture color and the result is clamped to 1 or less, to prevent adding energy on each bounce"} |
cvar_t | r_shadow_bouncegrid_particleintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_particleintensity", "1", "brightness of particles contributing to bouncegrid texture"} |
cvar_t | r_shadow_bouncegrid_rng_seed = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_rng_seed", "0", "0+ = use this number as RNG seed, -1 = use time instead for disco-like craziness in dynamic mode"} |
cvar_t | r_shadow_bouncegrid_rng_type = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_rng_type", "0", "0 = Lehmer 128bit RNG (slow but high quality), 1 = lhcheeserand 32bit RNG (quick)"} |
r_shadow_bouncegrid_state_t | r_shadow_bouncegrid_state |
cvar_t | r_shadow_bouncegrid_static = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static", "1", "use static radiosity solution (high quality) rather than dynamic (splotchy)"} |
cvar_t | r_shadow_bouncegrid_static_bounceminimumintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_bounceminimumintensity", "0.01", "stop bouncing once intensity drops below this fraction of the original particle color"} |
cvar_t | r_shadow_bouncegrid_static_directionalshading = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_directionalshading", "1", "whether to use directionalshading when in static mode"} |
cvar_t | r_shadow_bouncegrid_static_lightradiusscale = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_lightradiusscale", "5", "particles stop at this fraction of light radius (can be more than 1) when in static mode"} |
cvar_t | r_shadow_bouncegrid_static_maxbounce = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_maxbounce", "5", "maximum number of bounces for a particle (minimum is 0) in static mode"} |
cvar_t | r_shadow_bouncegrid_static_maxphotons = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_maxphotons", "250000", "upper bound on photons in static mode"} |
cvar_t | r_shadow_bouncegrid_static_quality = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_quality", "16", "amount of photons that should be fired (this is multiplied by spacing ^ 2 to make it adaptive with spacing changes)"} |
cvar_t | r_shadow_bouncegrid_static_spacing = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_spacing", "64", "unit size of bouncegrid pixel when in static mode"} |
cvar_t | r_shadow_bouncegrid_subsamples = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_subsamples", "1", "when generating the texture, sample this many points along each dimension (multisampling uses more compute but not more memory bandwidth)"} |
cvar_t | r_shadow_bouncegrid_threaded = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_threaded", "1", "enables use of taskqueue_maxthreads to perform the traces and slice rendering of bouncegrid"} |
int * | r_shadow_buffer_leaflist |
unsigned char * | r_shadow_buffer_leafpvs |
unsigned char * | r_shadow_buffer_lighttrispvs |
int | r_shadow_buffer_numleafpvsbytes |
int | r_shadow_buffer_numlighttrispvsbytes |
int | r_shadow_buffer_numshadowtrispvsbytes |
int | r_shadow_buffer_numsurfacepvsbytes |
unsigned char * | r_shadow_buffer_shadowtrispvs |
int * | r_shadow_buffer_surfacelist |
unsigned char * | r_shadow_buffer_surfacepvs |
unsigned char * | r_shadow_buffer_surfacesides |
unsigned char * | r_shadow_buffer_visitingleafpvs |
dlight_t | r_shadow_bufferlight |
cvar_t | r_shadow_bumpscale_basetexture = {CF_CLIENT, "r_shadow_bumpscale_basetexture", "0", "generate fake bumpmaps from diffuse textures at this bumpyness, try 4 to match tenebrae, higher values increase depth, requires r_restart to take effect"} |
cvar_t | r_shadow_bumpscale_bumpmap = {CF_CLIENT, "r_shadow_bumpscale_bumpmap", "4", "what magnitude to interpret _bump.tga textures as, higher values increase depth, requires r_restart to take effect"} |
rtlight_t * | r_shadow_compilingrtlight |
int | r_shadow_cullface_back |
int | r_shadow_cullface_front |
cvar_t | r_shadow_culllights_pvs = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_pvs", "1", "check if light overlaps any visible bsp leafs when determining if the light is visible"} |
cvar_t | r_shadow_culllights_trace = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace", "1", "use raytraces from the eye to random places within light bounds to determine if the light is visible"} |
cvar_t | r_shadow_culllights_trace_delay = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_delay", "1", "light will be considered visible for this many seconds after any trace connects"} |
cvar_t | r_shadow_culllights_trace_enlarge = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_enlarge", "0", "make light bounds bigger by *(1.0+enlarge)"} |
cvar_t | r_shadow_culllights_trace_expand = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_expand", "8", "make light bounds bigger by this many units"} |
cvar_t | r_shadow_culllights_trace_eyejitter = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_eyejitter", "16", "offset eye location randomly by this much"} |
cvar_t | r_shadow_culllights_trace_pad = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_pad", "8", "accept traces that hit within this many units of the light bounds"} |
cvar_t | r_shadow_culllights_trace_samples = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_samples", "16", "use this many traces to random positions (in addition to center trace)"} |
cvar_t | r_shadow_culllights_trace_tempsamples = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_tempsamples", "16", "use this many traces if the light was created by csqc (no inter-frame caching), -1 disables the check (to avoid flicker entirely)"} |
cvar_t | r_shadow_debuglight = {CF_CLIENT, "r_shadow_debuglight", "-1", "renders only one light, for level design purposes or debugging"} |
cvar_t | r_shadow_deferred = {CF_CLIENT | CF_ARCHIVE, "r_shadow_deferred", "0", "uses image-based lighting instead of geometry-based lighting, the method used renders a depth image and a normalmap image, renders lights into separate diffuse and specular images, and then combines this into the normal rendering, requires r_shadow_shadowmapping"} |
GLuint | r_shadow_fbo2d |
rtexturepool_t * | r_shadow_filters_texturepool |
cvar_t | r_shadow_frontsidecasting = {CF_CLIENT, "r_shadow_frontsidecasting", "1", "whether to cast shadows from illuminated triangles (front side of model) or unlit triangles (back side of model)"} |
cvar_t | r_shadow_gloss = {CF_CLIENT | CF_ARCHIVE, "r_shadow_gloss", "1", "0 disables gloss (specularity) rendering, 1 uses gloss if textures are found, 2 forces a flat metallic specular effect on everything without textures (similar to tenebrae)"} |
cvar_t | r_shadow_gloss2exponent = {CF_CLIENT, "r_shadow_gloss2exponent", "32", "same as r_shadow_glossexponent but for forced gloss (gloss 2) surfaces"} |
cvar_t | r_shadow_gloss2intensity = {CF_CLIENT, "r_shadow_gloss2intensity", "0.125", "how bright the forced flat gloss should look if r_shadow_gloss is 2"} |
cvar_t | r_shadow_glossexact = {CF_CLIENT, "r_shadow_glossexact", "0", "use exact reflection math for gloss (slightly slower, but should look a tad better)"} |
cvar_t | r_shadow_glossexponent = {CF_CLIENT, "r_shadow_glossexponent", "32", "how 'sharp' the gloss should appear (specular power)"} |
cvar_t | r_shadow_glossintensity = {CF_CLIENT, "r_shadow_glossintensity", "1", "how bright textured glossmaps should look if r_shadow_gloss is 1 or 2"} |
cvar_t | r_shadow_lightattenuationdividebias = {CF_CLIENT, "r_shadow_lightattenuationdividebias", "1", "changes attenuation texture generation"} |
cvar_t | r_shadow_lightattenuationlinearscale = {CF_CLIENT, "r_shadow_lightattenuationlinearscale", "2", "changes attenuation texture generation"} |
skinframe_t * | r_shadow_lightcorona |
r_shadow_rendermode_t | r_shadow_lightingrendermode = R_SHADOW_RENDERMODE_NONE |
cvar_t | r_shadow_lightintensityscale = {CF_CLIENT, "r_shadow_lightintensityscale", "1", "renders all world lights brighter or darker"} |
cvar_t | r_shadow_lightradiusscale = {CF_CLIENT, "r_shadow_lightradiusscale", "1", "renders all world lights larger or smaller"} |
int | r_shadow_lightscissor [4] |
float | r_shadow_lightshadowmap_parameters [4] |
float | r_shadow_lightshadowmap_texturescale [4] |
char | r_shadow_mapname [MAX_QPATH] |
float | r_shadow_modelshadowmap_parameters [4] |
float | r_shadow_modelshadowmap_texturescale [4] |
static entity_render_t * | r_shadow_modelshadows [MAX_MODELSHADOWS] |
static int | r_shadow_nummodelshadows |
unsigned int | r_shadow_occlusion_buf = 0 |
int | r_shadow_prepass_height |
int | r_shadow_prepass_width |
rtexture_t * | r_shadow_prepassgeometrydepthbuffer |
GLuint | r_shadow_prepassgeometryfbo |
rtexture_t * | r_shadow_prepassgeometrynormalmaptexture |
GLuint | r_shadow_prepasslightingdiffusefbo |
GLuint | r_shadow_prepasslightingdiffusespecularfbo |
rtexture_t * | r_shadow_prepasslightingdiffusetexture |
rtexture_t * | r_shadow_prepasslightingspeculartexture |
cvar_t | r_shadow_projectdistance = {CF_CLIENT, "r_shadow_projectdistance", "0", "how far to cast shadows"} |
cvar_t | r_shadow_realtime_dlight = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_dlight", "1", "enables rendering of dynamic lights such as explosions and rocket light"} |
cvar_t | r_shadow_realtime_dlight_portalculling = {CF_CLIENT, "r_shadow_realtime_dlight_portalculling", "0", "enables portal optimization on dynamic lights (slow!)"} |
cvar_t | r_shadow_realtime_dlight_shadows = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_dlight_shadows", "1", "enables rendering of shadows from dynamic lights"} |
cvar_t | r_shadow_realtime_dlight_svbspculling = {CF_CLIENT, "r_shadow_realtime_dlight_svbspculling", "0", "enables svbsp optimization on dynamic lights (very slow!)"} |
cvar_t | r_shadow_realtime_world = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_world", "0", "enables rendering of full world lighting (whether loaded from the map, or a .rtlights file, or a .ent file, or a .lights file produced by hlight)"} |
cvar_t | r_shadow_realtime_world_compile = {CF_CLIENT, "r_shadow_realtime_world_compile", "1", "enables compilation of world lights for higher performance rendering"} |
cvar_t | r_shadow_realtime_world_compileportalculling = {CF_CLIENT, "r_shadow_realtime_world_compileportalculling", "1", "enables portal-based culling optimization during compilation (overrides compilesvbsp)"} |
cvar_t | r_shadow_realtime_world_compileshadow = {CF_CLIENT, "r_shadow_realtime_world_compileshadow", "1", "enables compilation of shadows from world lights for higher performance rendering"} |
cvar_t | r_shadow_realtime_world_compilesvbsp = {CF_CLIENT, "r_shadow_realtime_world_compilesvbsp", "1", "enables svbsp optimization during compilation (slower than compileportalculling but more exact)"} |
cvar_t | r_shadow_realtime_world_importlightentitiesfrommap = {CF_CLIENT, "r_shadow_realtime_world_importlightentitiesfrommap", "1", "load lights from .ent file or map entities at startup if no .rtlights or .lights file is present (if set to 2, always use the .ent or map entities)"} |
cvar_t | r_shadow_realtime_world_lightmaps = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_world_lightmaps", "0", "brightness to render lightmaps when using full world lighting, try 0.5 for a tenebrae-like appearance"} |
cvar_t | r_shadow_realtime_world_shadows = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_world_shadows", "1", "enables rendering of shadows from world lights"} |
r_shadow_rendermode_t | r_shadow_rendermode = R_SHADOW_RENDERMODE_NONE |
rtlight_t ** | r_shadow_scenelightlist |
int | r_shadow_scenemaxlights |
int | r_shadow_scenenumlights |
cvar_t | r_shadow_scissor = {CF_CLIENT, "r_shadow_scissor", "1", "use scissor optimization of light rendering (restricts rendering to the portion of the screen affected by the light)"} |
dlight_t * | r_shadow_selectedlight |
rtexture_t * | r_shadow_shadowmap2ddepthbuffer |
rtexture_t * | r_shadow_shadowmap2ddepthtexture |
int | r_shadow_shadowmapatlas_modelshadows_size |
int | r_shadow_shadowmapatlas_modelshadows_x |
int | r_shadow_shadowmapatlas_modelshadows_y |
mod_alloclightmap_state_t | r_shadow_shadowmapatlas_state |
int | r_shadow_shadowmapborder |
int | r_shadow_shadowmapdepthbits |
qbool | r_shadow_shadowmapdepthtexture |
int | r_shadow_shadowmapfilterquality |
matrix4x4_t | r_shadow_shadowmapmatrix |
int | r_shadow_shadowmapmaxsize |
int | r_shadow_shadowmappcf |
cvar_t | r_shadow_shadowmapping = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping", "1", "enables use of shadowmapping (shadow rendering by depth texture sampling)"} |
cvar_t | r_shadow_shadowmapping_bias = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_bias", "0.03", "shadowmap bias parameter (this is multiplied by nearclip * 1024 / lodsize)"} |
cvar_t | r_shadow_shadowmapping_bordersize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_bordersize", "5", "shadowmap size bias for filtering"} |
cvar_t | r_shadow_shadowmapping_depthbits = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_depthbits", "24", "requested minimum shadowmap texture depth bits"} |
cvar_t | r_shadow_shadowmapping_filterquality = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_filterquality", "-1", "shadowmap filter modes: -1 = auto-select, 0 = no filtering, 1 = bilinear, 2 = bilinear 2x2 blur (fast), 3 = 3x3 blur (moderate), 4 = 4x4 blur (slow)"} |
cvar_t | r_shadow_shadowmapping_maxsize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_maxsize", "512", "limit of shadowmap side size - can not be more than 1/8th of atlassize because lights store 6 sides (2x3 grid) and sometimes 12 sides (4x3 grid for shadows from EF_NOSELFSHADOW entities) and there are multiple lights..."} |
cvar_t | r_shadow_shadowmapping_minsize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_minsize", "32", "limit of shadowmap side size - must be at least r_shadow_shadowmapping_bordersize+2"} |
cvar_t | r_shadow_shadowmapping_nearclip = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_nearclip", "1", "shadowmap nearclip in world units"} |
cvar_t | r_shadow_shadowmapping_polygonfactor = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_polygonfactor", "2", "slope-dependent shadowmapping bias"} |
cvar_t | r_shadow_shadowmapping_polygonoffset = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_polygonoffset", "0", "constant shadowmapping bias"} |
cvar_t | r_shadow_shadowmapping_precision = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_precision", "1", "makes shadowmaps have a maximum resolution of this number of pixels per light source radius unit such that, for example, at precision 0.5 a light with radius 200 will have a maximum resolution of 100 pixels"} |
cvar_t | r_shadow_shadowmapping_texturesize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_texturesize", "8192", "size of shadowmap atlas texture - all shadowmaps are packed into this texture at frame start"} |
cvar_t | r_shadow_shadowmapping_useshadowsampler = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_useshadowsampler", "1", "whether to use sampler2DShadow if available"} |
cvar_t | r_shadow_shadowmapping_vsdct = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_vsdct", "1", "enables use of virtual shadow depth cube texture"} |
qbool | r_shadow_shadowmapsampler |
qbool | r_shadow_shadowmapshadowsampler |
int | r_shadow_shadowmapside |
int | r_shadow_shadowmaptexturesize |
qbool | r_shadow_shadowmapvsdct |
rtexture_t * | r_shadow_shadowmapvsdcttexture |
r_shadow_shadowmode_t | r_shadow_shadowmode |
int | r_shadow_shadowmode_deferred |
int | r_shadow_shadowmode_shadowmapping |
cvar_t | r_shadow_sortsurfaces = {CF_CLIENT, "r_shadow_sortsurfaces", "1", "improve performance by sorting illuminated surfaces by texture"} |
rtexturepool_t * | r_shadow_texturepool |
cvar_t | r_shadow_usebihculling = {CF_CLIENT, "r_shadow_usebihculling", "1", "use BIH (Bounding Interval Hierarchy) for culling lit surfaces instead of BSP (Binary Space Partitioning)"} |
cvar_t | r_shadow_usenormalmap = {CF_CLIENT | CF_ARCHIVE, "r_shadow_usenormalmap", "1", "enables use of directional shading on lights"} |
qbool | r_shadow_usingdeferredprepass |
qbool | r_shadow_usingshadowmap2d |
qbool | r_shadow_usingshadowmaportho |
rtexture_t * | r_shadow_viewcolortexture |
rtexture_t * | r_shadow_viewdepthtexture |
int | r_shadow_viewfbo |
int | r_shadow_viewheight |
int | r_shadow_viewwidth |
int | r_shadow_viewx |
int | r_shadow_viewy |
static memexpandablearray_t | r_shadow_worldlightsarray |
int * | shadowelements |
int * | shadowmark |
int | shadowmarkcount |
int * | shadowmarklist |
unsigned char * | shadowsides |
int * | shadowsideslist |
float * | shadowvertex3f |
static float | spritetexcoord2f [4 *2] = {0, 1, 0, 0, 1, 0, 1, 1} |
int * | vertexremap |
int * | vertexupdate |
int | vertexupdatenum |
#define ATTEN1DSIZE 32 |
Definition at line 264 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures().
#define ATTEN2DSIZE 64 |
Definition at line 265 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures().
#define ATTEN3DSIZE 32 |
Definition at line 266 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures().
#define ATTENTABLESIZE 256 |
Definition at line 262 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures().
#define BUFFER_OFFSET | ( | i | ) |
Referenced by R_DrawCorona().
#define EDLIGHTSPRSIZE 8 |
Definition at line 290 of file r_shadow.c.
Referenced by R_Shadow_DrawCursor_TransparentCallback(), and R_Shadow_DrawLightSprite_TransparentCallback().
#define MAX_MODELSHADOWS 1024 |
Definition at line 4238 of file r_shadow.c.
Referenced by R_Shadow_PrepareModelShadows().
#define MAX_SCENELIGHTS 65536 |
Definition at line 4015 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights_AddSceneLight().
#define R_Shadow_CalcEntitySideMask | ( | ent, | |
worldtolight, | |||
radiustolight, | |||
bias ) |
Definition at line 964 of file r_shadow.c.
Referenced by R_Shadow_DrawLightShadowMaps().
enum lighttype_t |
Enumerator | |
---|---|
LIGHTTYPE_MINUSX | |
LIGHTTYPE_RECIPX | |
LIGHTTYPE_RECIPXX | |
LIGHTTYPE_NONE | |
LIGHTTYPE_SUN | |
LIGHTTYPE_MINUSXX |
Definition at line 5036 of file r_shadow.c.
Definition at line 9 of file r_shadow.c.
Enumerator | |
---|---|
R_SHADOW_SHADOWMODE_DISABLED | |
R_SHADOW_SHADOWMODE_SHADOWMAP2D |
Definition at line 25 of file r_shadow.c.
Definition at line 4420 of file r_shadow.c.
References bound, CHECKGLERROR, rtlight_t::corona_queryindex_allpixels, rtlight_t::corona_queryindex_visiblepixels, rtlight_t::corona_visibility, rtlight_t::currentcolor, DotProduct, r_refdef_view_t::forward, GL_ALWAYS, GL_DepthFunc(), GL_LEQUAL, GL_SAMPLES_PASSED, NULL, r_refdef_view_t::origin, polygonelement3i, polygonelement3s, R_CalcSprite_Vertex3f(), r_maxqueries, R_Mesh_Draw(), R_Mesh_PrepareVertices_Vertex3f(), r_numqueries, r_queries, r_refdef, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, r_refdef_view_t::right, scale, rtlight_t::shadoworigin, r_refdef_view_t::up, VectorLength, VectorMA, vid, and r_refdef_t::view.
Referenced by R_Shadow_DrawCoronas().
void R_CompleteLightPoint | ( | float * | ambient, |
float * | diffuse, | ||
float * | lightdir, | ||
const vec3_t | p, | ||
const int | flags, | ||
float | lightmapintensity, | ||
float | ambientintensity ) |
Definition at line 6014 of file r_shadow.c.
References model_t::brush, CL_TraceLine(), collision_extendmovelength, color, rtlight_t::currentcolor, flags, rtlight_t::flags, trace_t::fraction, i, int(), intensity, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, model_brush_t::LightPoint, r_refdef_scene_t::lights, model_t::lit, LP_DYNLIGHT, LP_LIGHTMAP, LP_RTWORLD, MATERIALFLAGMASK_TRANSLUCENT, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), min, MOVE_NOMONSTERS, NULL, r_refdef_scene_t::numlights, r_refdef, r_shadow_lightattenuationdividebias, r_shadow_lightattenuationlinearscale, r_shadow_lightintensityscale, r_shadow_worldlightsarray, rtlight_t::radius, dlight_t::rtlight, r_refdef_scene_t::rtworld, r_refdef_t::scene, rtlight_t::shadow, rtlight_t::shadoworigin, sqrt(), SUPERCONTENTS_SOLID, cvar_t::value, VectorLength, VectorLength2, VectorNormalize, VectorSubtract, and r_refdef_scene_t::worldmodel.
Referenced by CL_UpdateEntityShading_Entity(), R_DrawParticle_TransparentCallback(), R_HDR_UpdateIrisAdaptation(), and VM_CL_getlight().
Definition at line 4469 of file r_shadow.c.
References BUFFER_OFFSET, CHECKGLERROR, CL_Cache_TraceLineSurfaces(), color, rtlight_t::corona_queryindex_allpixels, rtlight_t::corona_queryindex_visiblepixels, rtlight_t::corona_visibility, rtlight_t::currentcolor, trace_t::fraction, GL_BlendEquationSubtract(), GL_DYNAMIC_COPY, GL_QUERY_BUFFER, GL_QUERY_RESULT, GL_UNIFORM_BUFFER, identitymatrix, MATERIALFLAG_ADD, MATERIALFLAG_BLENDED, MATERIALFLAG_FULLBRIGHT, MATERIALFLAG_NOCULLFACE, MATERIALFLAG_NODEPTHTEST, MATERIALFLAG_OCCLUDE, MATERIALFLAGMASK_TRANSLUCENT, MOVE_NORMAL, NULL, r_refdef_view_t::origin, polygonelement3i, polygonelement3s, R_CalcSprite_Vertex3f(), R_DrawCustomSurface(), r_refdef, r_shadow_lightcorona, r_shadow_occlusion_buf, RENDER_NODEPTHTEST, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, r_refdef_view_t::right, RSurf_ActiveCustomEntity(), scale, rtlight_t::shadoworigin, spritetexcoord2f, SUPERCONTENTS_SOLID, r_refdef_view_t::up, VectorLength, VectorNegate, VectorScale, vid, and r_refdef_t::view.
Referenced by R_Shadow_DrawCoronas().
Definition at line 3023 of file r_shadow.c.
References CHECKPVSBIT, rtlight_t::compiled, Con_DPrintf(), rtlight_t::cullmaxs, rtlight_t::cullmins, data, developer_extra, i, int(), cvar_t::integer, Mem_Alloc, model, NULL, R_FrameData_ReturnToMark(), R_FrameData_SetMark(), r_main_mempool, r_refdef, r_shadow_buffer_leaflist, r_shadow_buffer_leafpvs, r_shadow_buffer_lighttrispvs, r_shadow_buffer_shadowtrispvs, r_shadow_buffer_surfacelist, r_shadow_buffer_surfacepvs, r_shadow_buffer_visitingleafpvs, r_shadow_compilingrtlight, rtlight_t::radius, r_refdef_t::scene, rtlight_t::shadow, rtlight_t::shadoworigin, rtlight_t::static_leaflist, rtlight_t::static_leafpvs, rtlight_t::static_lighttrispvs, rtlight_t::static_numleafpvsbytes, rtlight_t::static_numleafs, rtlight_t::static_numlighttrispvsbytes, rtlight_t::static_numshadowtrispvsbytes, rtlight_t::static_numsurfaces, rtlight_t::static_shadowmap_casters, rtlight_t::static_shadowmap_receivers, rtlight_t::static_shadowtrispvs, rtlight_t::static_surfacelist, r_refdef_scene_t::worldentity, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_PrepareLight().
Definition at line 3109 of file r_shadow.c.
References rtlight_t::compiled, Mem_Free, Mod_ShadowMesh_Free(), NULL, rtlight_t::static_leaflist, rtlight_t::static_leafpvs, rtlight_t::static_lighttrispvs, rtlight_t::static_meshchain_shadow_shadowmap, rtlight_t::static_numleafpvsbytes, rtlight_t::static_numleafs, rtlight_t::static_numlighttrispvsbytes, rtlight_t::static_numshadowtrispvsbytes, rtlight_t::static_numsurfaces, rtlight_t::static_shadowtrispvs, and rtlight_t::static_surfacelist.
Referenced by R_RTLight_Update(), R_Shadow_FreeWorldLight(), and R_Shadow_UncompileWorldLights().
void R_RTLight_Update | ( | rtlight_t * | rtlight, |
int | isstatic, | ||
matrix4x4_t * | matrix, | ||
vec3_t | color, | ||
int | style, | ||
const char * | cubemapname, | ||
int | shadow, | ||
vec_t | corona, | ||
vec_t | coronasizescale, | ||
vec_t | ambientscale, | ||
vec_t | diffusescale, | ||
vec_t | specularscale, | ||
int | flags ) |
Definition at line 2980 of file r_shadow.c.
References rtlight_t::ambientscale, color, rtlight_t::color, rtlight_t::corona, rtlight_t::coronasizescale, rtlight_t::cubemapname, rtlight_t::cullmaxs, rtlight_t::cullmins, rtlight_t::diffusescale, dp_strlcpy, flags, rtlight_t::flags, rtlight_t::isstatic, Matrix4x4_Invert_Simple(), Matrix4x4_OriginFromMatrix(), Matrix4x4_Scale(), Matrix4x4_ScaleFromMatrix(), rtlight_t::matrix_lighttoworld, rtlight_t::matrix_worldtolight, R_RTLight_Uncompile(), r_shadow_lightradiusscale, rtlight_t::radius, rtlight_t::shadow, rtlight_t::shadoworigin, rtlight_t::specularscale, rtlight_t::style, style, cvar_t::value, and VectorCopy.
Referenced by CL_LinkNetworkEntity(), CL_NewParticlesFromEffectinfo(), CL_ParticleEffect_Fallback(), CL_RelinkBeams(), CL_RelinkLightFlashes(), R_Shadow_UpdateWorldLight(), and VM_CL_R_AddDynamicLight().
|
static |
Definition at line 1922 of file r_shadow.c.
References rtlight_t::ambientscale, rtlight_t::bouncegrid_effectiveradius, rtlight_t::bouncegrid_hits, rtlight_t::bouncegrid_photoncolor, rtlight_t::bouncegrid_photons, rtlight_t::bouncegrid_traces, r_shadow_bouncegrid_photon_t::bounceminimumintensity2, r_shadow_bouncegrid_settings_t::bounceminimumintensity2, model_brush_t::BoxTouchingVisibleLeafs, model_t::brush, r_shadow_bouncegrid_photon_t::color, rtlight_t::color, rtlight_t::cullmaxs, rtlight_t::cullmins, rtlight_t::diffusescale, r_shadow_bouncegrid_settings_t::dlightparticlemultiplier, taskqueue_task_t::done, r_shadow_bouncegrid_photon_t::end, r_shadow_bouncegrid_settings_t::energyperphoton, f, dlight_t::flags, floor(), host, i, int(), cvar_t::integer, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, r_shadow_bouncegrid_settings_t::lightradiusscale, r_refdef_scene_t::lights, Math_RandomSeed_FromInts(), max, MAX_LIGHTSTYLES, r_shadow_bouncegrid_settings_t::maxphotons, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), r_shadow_bouncegrid_settings_t::normalizevectors, r_refdef_scene_t::numlights, r_shadow_bouncegrid_photon_t::numpaths, r_shadow_bouncegrid_state_t::numphotons, r_refdef_view_t::origin, r_shadow_bouncegrid_settings_t::particleintensity, r_shadow_bouncegrid_state_t::photons, R_CanSeeBox(), R_CullFrustum(), r_refdef, r_shadow_bouncegrid, R_Shadow_BounceGrid_RefractiveIndexAtPoint(), r_shadow_bouncegrid_state, r_shadow_culllights_trace, r_shadow_culllights_trace_delay, r_shadow_culllights_trace_enlarge, r_shadow_culllights_trace_expand, r_shadow_culllights_trace_eyejitter, r_shadow_culllights_trace_pad, r_shadow_culllights_trace_samples, r_shadow_culllights_trace_tempsamples, r_shadow_debuglight, r_shadow_lightintensityscale, r_shadow_worldlightsarray, r_stat_bouncegrid_lights, r_stat_bouncegrid_particles, rtlight_t::radius, host_static_t::realtime, r_shadow_bouncegrid_settings_t::rng_seed, r_shadow_bouncegrid_settings_t::rng_type, dlight_t::rtlight, r_refdef_scene_t::rtlightstylevalue, r_refdef_scene_t::rtworld, r_refdef_t::scene, r_shadow_bouncegrid_state_t::settings, rtlight_t::shadoworigin, rtlight_t::specularscale, r_shadow_bouncegrid_photon_t::start, r_shadow_bouncegrid_photon_t::startrefractiveindex, r_shadow_bouncegrid_settings_t::staticmode, r_refdef_t::stats, rtlight_t::style, rtlight_t::trace_timer, cvar_t::value, VectorCheeseRandom, VectorClear, VectorCopy, VectorLehmerRandom, VectorLength, VectorLength2, VectorMA, VectorNormalize, VectorScale, r_refdef_t::view, r_refdef_t::viewcache, w, r_refdef_viewcache_t::world_leafvisible, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 2391 of file r_shadow.c.
References r_shadow_bouncegrid_settings_t::blur, r_shadow_bouncegrid_state_t::blurpixels, taskqueue_task_t::done, r_shadow_bouncegrid_state_t::highpixels, r_shadow_bouncegrid_state_t::highpixels_index, pixels, R_Shadow_BounceGrid_BlurPixelsInDirection(), r_shadow_bouncegrid_state, r_shadow_bouncegrid_state_t::resolution, r_shadow_bouncegrid_state_t::settings, and VectorCopy.
Referenced by R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 2359 of file r_shadow.c.
References index, r_shadow_bouncegrid_state_t::pixelbands, r_shadow_bouncegrid_state, r_shadow_bouncegrid_state_t::resolution, VectorCopy, x, y, and z.
Referenced by R_Shadow_BounceGrid_BlurPixels_Task().
Definition at line 1674 of file r_shadow.c.
References rtlight_t::ambientscale, r_shadow_bouncegrid_state_t::capable, rtlight_t::color, rtlight_t::diffusescale, dlight_t::flags, int(), cvar_t::integer, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), r_refdef, r_shadow_bouncegrid, r_shadow_bouncegrid_state, r_shadow_bouncegrid_static, r_shadow_worldlightsarray, dlight_t::rtlight, r_refdef_t::scene, rtlight_t::specularscale, rtlight_t::style, VectorLength2, VectorScale, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 2592 of file r_shadow.c.
References taskqueue_task_t::done, r_shadow_bouncegrid_state_t::highpixels, r_shadow_bouncegrid_state_t::numpixels, and r_shadow_bouncegrid_state.
Referenced by R_Shadow_UpdateBounceGridTexture().
Definition at line 2418 of file r_shadow.c.
References bound, r_shadow_bouncegrid_state_t::bytesperband, r_shadow_bouncegrid_state_t::createtexture, f, r_shadow_bouncegrid_settings_t::floatcolors, r_shadow_bouncegrid_state_t::fp16pixels, r_shadow_bouncegrid_state_t::highpixels, host, index, int(), r_shadow_bouncegrid_state_t::lastupdatetime, Mem_Alloc, NULL, r_shadow_bouncegrid_state_t::numpixels, r_shadow_bouncegrid_state_t::pixelbands, r_shadow_bouncegrid_state_t::pixelsperband, R_FreeTexture(), R_LoadTexture3D(), r_main_mempool, r_shadow_bouncegrid_state, r_shadow_texturepool, R_UpdateTexture(), host_static_t::realtime, r_shadow_bouncegrid_state_t::resolution, r_shadow_bouncegrid_state_t::settings, TEXF_ALPHA, TEXF_CLAMP, TEXF_FORCELINEAR, r_shadow_bouncegrid_state_t::texture, TEXTYPE_BGRA, TEXTYPE_COLORBUFFER16F, TEXTYPE_COLORBUFFER32F, r_shadow_bouncegrid_state_t::u8pixels, VectorCopy, VectorCopy4, VectorLength2, VectorNormalize, VectorSet, x, y, and z.
Referenced by R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 2734 of file r_shadow.c.
References taskqueue_task_t::done, taskqueue_task_t::func, i, cvar_t::integer, NULL, r_shadow_bouncegrid_state_t::numphotons, r_shadow_bouncegrid_state_t::photons, r_shadow_bouncegrid_state_t::photons_done_task, r_shadow_bouncegrid_state_t::photons_tasks, r_shadow_bouncegrid_state, r_shadow_bouncegrid_threaded, R_Shadow_BounceGrid_TracePhotons_ShotTask(), TaskQueue_Enqueue(), TaskQueue_Setup(), and TaskQueue_Task_CheckTasksDone().
Referenced by R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 2341 of file r_shadow.c.
References r_shadow_bouncegrid_state_t::cleartex_task, taskqueue_task_t::done, i, NULL, R_Shadow_BounceGrid_Slice_Task(), r_shadow_bouncegrid_state, r_shadow_bouncegrid_state_t::resolution, r_shadow_bouncegrid_state_t::slices_done_task, r_shadow_bouncegrid_state_t::slices_tasks, TaskQueue_Enqueue(), TaskQueue_Setup(), TaskQueue_Task_CheckTasksDone(), and TaskQueue_Yield().
Referenced by R_Shadow_UpdateBounceGridTexture().
Definition at line 490 of file r_shadow.c.
References r_shadow_bouncegrid_state_t::blurpixels, r_shadow_bouncegrid_state_t::fp16pixels, r_shadow_bouncegrid_state_t::highpixels, Mem_Free, NULL, r_shadow_bouncegrid_state_t::photons, r_shadow_bouncegrid_state_t::photons_tasks, r_shadow_bouncegrid_state, r_shadow_bouncegrid_state_t::slices_tasks, and r_shadow_bouncegrid_state_t::u8pixels.
Referenced by R_Shadow_BounceGrid_UpdateSpacing(), r_shadow_newmap(), r_shadow_shutdown(), and R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 1708 of file r_shadow.c.
References r_shadow_bouncegrid_state_t::allowdirectionalshading, r_shadow_bouncegrid_settings_t::blur, r_shadow_bouncegrid_settings_t::bounceminimumintensity2, bound, r_shadow_bouncegrid_settings_t::directionalshading, r_shadow_bouncegrid_settings_t::dlightparticlemultiplier, r_shadow_bouncegrid_settings_t::energyperphoton, false, r_shadow_bouncegrid_settings_t::floatcolors, r_shadow_bouncegrid_settings_t::hitmodels, r_shadow_bouncegrid_settings_t::includedirectlighting, cvar_t::integer, r_shadow_bouncegrid_settings_t::lightpathsize, r_shadow_bouncegrid_settings_t::lightradiusscale, r_shadow_bouncegrid_settings_t::maxbounce, r_shadow_bouncegrid_settings_t::maxphotons, r_shadow_bouncegrid_settings_t::normalizevectors, r_shadow_bouncegrid_settings_t::particlebounceintensity, r_shadow_bouncegrid_settings_t::particleintensity, r_shadow_bouncegrid, r_shadow_bouncegrid_blur, r_shadow_bouncegrid_dynamic_bounceminimumintensity, r_shadow_bouncegrid_dynamic_directionalshading, r_shadow_bouncegrid_dynamic_dlightparticlemultiplier, r_shadow_bouncegrid_dynamic_hitmodels, r_shadow_bouncegrid_dynamic_lightradiusscale, r_shadow_bouncegrid_dynamic_maxbounce, r_shadow_bouncegrid_dynamic_maxphotons, r_shadow_bouncegrid_dynamic_quality, r_shadow_bouncegrid_dynamic_spacing, r_shadow_bouncegrid_floatcolors, r_shadow_bouncegrid_includedirectlighting, r_shadow_bouncegrid_lightpathsize, r_shadow_bouncegrid_normalizevectors, r_shadow_bouncegrid_particlebounceintensity, r_shadow_bouncegrid_particleintensity, r_shadow_bouncegrid_rng_seed, r_shadow_bouncegrid_rng_type, r_shadow_bouncegrid_state, r_shadow_bouncegrid_static, r_shadow_bouncegrid_static_bounceminimumintensity, r_shadow_bouncegrid_static_directionalshading, r_shadow_bouncegrid_static_lightradiusscale, r_shadow_bouncegrid_static_maxbounce, r_shadow_bouncegrid_static_maxphotons, r_shadow_bouncegrid_static_quality, r_shadow_bouncegrid_static_spacing, r_shadow_bouncegrid_subsamples, r_shadow_bouncegrid_settings_t::rng_seed, r_shadow_bouncegrid_settings_t::rng_type, r_shadow_bouncegrid_settings_t::spacing, r_shadow_bouncegrid_settings_t::staticmode, r_shadow_bouncegrid_settings_t::subsamples, and cvar_t::value.
Referenced by R_Shadow_UpdateBounceGridTexture().
Definition at line 1902 of file r_shadow.c.
References CL_TracePoint(), r_shadow_bouncegrid_settings_t::hitmodels, MATERIALFLAG_CUSTOMBLEND, MATERIALFLAG_REFRACTION, MATERIALFLAG_WATERSHADER, MOVE_HITMODEL, MOVE_NOMONSTERS, MOVE_WORLDONLY, NULL, r_shadow_bouncegrid_state, r_shadow_bouncegrid_state_t::settings, trace_t::startsupercontents, trace_t::starttexture, r_shadow_bouncegrid_settings_t::staticmode, SUPERCONTENTS_LIQUIDSMASK, and SUPERCONTENTS_SOLID.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), and R_Shadow_BounceGrid_TracePhotons_Shot().
Definition at line 2170 of file r_shadow.c.
References color, r_shadow_bouncegrid_photon_path_t::color, DotProduct, r_shadow_bouncegrid_photon_path_t::end, floor(), r_shadow_bouncegrid_state_t::highpixels, int(), intensity, r_shadow_bouncegrid_state_t::ispacing, r_shadow_bouncegrid_settings_t::lightpathsize, max, min, r_shadow_bouncegrid_state_t::mins, r_shadow_bouncegrid_photon_t::numpaths, r_shadow_bouncegrid_state_t::numphotons, r_shadow_bouncegrid_photon_t::paths, r_shadow_bouncegrid_state_t::photons, r_shadow_bouncegrid_state_t::pixelbands, r_shadow_bouncegrid_state_t::pixelsperband, r_shadow_bouncegrid_state, r_shadow_bouncegrid_state_t::resolution, samples, r_shadow_bouncegrid_state_t::settings, r_shadow_bouncegrid_state_t::spacing, sqrt(), r_shadow_bouncegrid_photon_path_t::start, r_shadow_bouncegrid_settings_t::subsamples, VectorCopy, VectorLength, VectorLength2, VectorLerp, VectorScale, VectorSubtract, and w.
Referenced by R_Shadow_BounceGrid_Slice_Task().
|
static |
Definition at line 2335 of file r_shadow.c.
References taskqueue_task_t::done, taskqueue_task_t::i, and R_Shadow_BounceGrid_Slice().
Referenced by R_Shadow_BounceGrid_EnqueueSlices_Task().
|
static |
Definition at line 2598 of file r_shadow.c.
References CL_Cache_TraceLineSurfaces(), CL_TraceLine(), collision_extendmovelength, r_shadow_bouncegrid_photon_path_t::color, DotProduct, r_shadow_bouncegrid_photon_path_t::end, trace_t::endpos, trace_t::fraction, Fresnel, r_shadow_bouncegrid_settings_t::hitmodels, trace_t::hittexture, r_shadow_bouncegrid_settings_t::includedirectlighting, cvar_t::integer, r_shadow_bouncegrid_settings_t::lightpathsize, MATERIALFLAG_ALPHA, MATERIALFLAG_ALPHATEST, MATERIALFLAG_CUSTOMBLEND, MATERIALFLAG_REFRACTION, MATERIALFLAG_WATERSHADER, max, r_shadow_bouncegrid_settings_t::maxbounce, min, MOVE_HITMODEL, MOVE_NOMONSTERS, MOVE_WORLDONLY, plane_t::normal, NULL, r_shadow_bouncegrid_photon_t::numpaths, r_shadow_bouncegrid_settings_t::particlebounceintensity, r_shadow_bouncegrid_photon_t::paths, PHOTON_MAX_PATHS, trace_t::plane, R_CullFrustum(), r_shadow_bouncegrid_dynamic_culllightpaths, R_Shadow_BounceGrid_RefractiveIndexAtPoint(), r_shadow_bouncegrid_state, r_shadow_bouncegrid_threaded, R_Shadow_BounceGrid_TracePhotons_Shot(), refractcolor, r_shadow_bouncegrid_settings_t::rng_seed, r_shadow_bouncegrid_state_t::settings, r_shadow_bouncegrid_settings_t::spacing, r_shadow_bouncegrid_photon_path_t::start, r_shadow_bouncegrid_settings_t::staticmode, SUPERCONTENTS_LIQUIDSMASK, SUPERCONTENTS_SOLID, cvar_t::value, VectorAdd, VectorClear, VectorCopy, VectorLength2, VectorMA, VectorMultiply, VectorNormalize, VectorReflect, VectorScale, VectorSet, and VectorSubtract.
Referenced by R_Shadow_BounceGrid_TracePhotons_Shot(), and R_Shadow_BounceGrid_TracePhotons_ShotTask().
|
static |
Definition at line 2727 of file r_shadow.c.
References r_shadow_bouncegrid_photon_t::bounceminimumintensity2, r_shadow_bouncegrid_photon_t::color, taskqueue_task_t::done, r_shadow_bouncegrid_photon_t::end, r_shadow_bouncegrid_settings_t::maxbounce, taskqueue_task_t::p, r_shadow_bouncegrid_state, R_Shadow_BounceGrid_TracePhotons_Shot(), r_shadow_bouncegrid_state_t::settings, r_shadow_bouncegrid_photon_t::start, and r_shadow_bouncegrid_photon_t::startrefractiveindex.
Referenced by R_Shadow_BounceGrid_EnqueuePhotons_Task().
Definition at line 1751 of file r_shadow.c.
References bound, r_shadow_bouncegrid_state_t::bytesperband, r_shadow_bouncegrid_state_t::createtexture, rtlight_t::cullmaxs, rtlight_t::cullmins, r_shadow_bouncegrid_state_t::directional, r_shadow_bouncegrid_settings_t::directionalshading, floor(), int(), cvar_t::integer, r_shadow_bouncegrid_state_t::ispacing, r_shadow_bouncegrid_state_t::matrix, Matrix4x4_FromArrayFloatD3D(), max, maxs, r_shadow_bouncegrid_state_t::maxs, viddef_t::maxtexturesize_3d, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), min, mins, r_shadow_bouncegrid_state_t::mins, model_t::normalmaxs, model_t::normalmins, NULL, r_shadow_bouncegrid_state_t::numpixels, r_refdef_view_t::origin, r_shadow_bouncegrid_state_t::pixelbands, r_shadow_bouncegrid_state_t::pixelsperband, R_FreeTexture(), r_refdef, r_shadow_bouncegrid_dynamic_x, r_shadow_bouncegrid_dynamic_y, r_shadow_bouncegrid_dynamic_z, R_Shadow_BounceGrid_FreeHighPixels(), r_shadow_bouncegrid_state, r_shadow_worldlightsarray, r_shadow_bouncegrid_state_t::resolution, dlight_t::rtlight, r_refdef_t::scene, r_shadow_bouncegrid_state_t::settings, r_shadow_bouncegrid_state_t::size, size, r_shadow_bouncegrid_settings_t::spacing, r_shadow_bouncegrid_state_t::spacing, r_shadow_bouncegrid_settings_t::staticmode, r_shadow_bouncegrid_state_t::texture, VectorAdd, VectorCopy, VectorMA, VectorSet, VectorSubtract, vid, r_refdef_t::view, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_UpdateBounceGridTexture().
|
static |
Definition at line 914 of file r_shadow.c.
References fabs(), mask, Matrix4x4_Transform(), Matrix4x4_Transform3x3(), maxs, mins, VectorAdd, VectorScale, and VectorSubtract.
Referenced by R_Shadow_DrawLightShadowMaps().
Definition at line 966 of file r_shadow.c.
Definition at line 863 of file r_shadow.c.
Referenced by R_Shadow_ChooseSidesFromBox().
int R_Shadow_ChooseSidesFromBox | ( | int | firsttriangle, |
int | numtris, | ||
const float * | invertex3f, | ||
const int * | elements, | ||
const matrix4x4_t * | worldtolight, | ||
const vec3_t | projectorigin, | ||
const vec3_t | projectdirection, | ||
const vec3_t | lightmins, | ||
const vec3_t | lightmaxs, | ||
const vec3_t | surfacemins, | ||
const vec3_t | surfacemaxs, | ||
int * | totals ) |
Definition at line 1058 of file r_shadow.c.
References BoxesOverlap, BoxInsideBox, DotProduct, float, cvar_t::integer, mask, Matrix4x4_Transform(), normal, numshadowsides, PointInfrontOfTriangle, R_Shadow_CalcTriangleSideMask(), r_shadow_frontsidecasting, r_shadow_shadowmapborder, r_shadow_shadowmapmaxsize, shadowsides, shadowsideslist, TriangleBBoxOverlapsBox, TriangleNormal, and v.
Referenced by R_Mod_CompileShadowMap().
Definition at line 1480 of file r_shadow.c.
References r_refdef_view_t::cullface_back, GL_Clear(), GL_COLOR_BUFFER_BIT, GL_ColorMask(), GL_CullFace(), GL_DEPTH_BUFFER_BIT, GL_DepthMask(), GL_DepthTest(), GL_PolygonOffset(), GL_Scissor(), r_viewport_t::height, identitymatrix, NULL, R_Mesh_ResetTextureState(), R_Mesh_SetRenderTargets(), r_refdef, R_SetupShader_DepthOrShadow(), R_SetViewport(), r_shadow_fbo2d, R_Shadow_MakeShadowMap(), R_Shadow_MakeVSDCT(), r_shadow_rendermode, R_Shadow_RenderMode_Reset(), R_SHADOW_RENDERMODE_SHADOWMAP2D, r_shadow_shadowmap2ddepthbuffer, r_shadow_shadowmap2ddepthtexture, r_shadow_shadowmapping_polygonfactor, r_shadow_shadowmapping_polygonoffset, r_shadow_shadowmaptexturesize, r_shadow_shadowmapvsdct, r_shadow_shadowmapvsdcttexture, R_Viewport_InitOrtho(), viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, cvar_t::value, Vector4Set, vid, r_refdef_t::view, r_viewport_t::width, r_viewport_t::x, and r_viewport_t::y.
Referenced by R_Shadow_DrawShadowMaps().
Definition at line 1430 of file r_shadow.c.
References GL_Clear(), GL_STENCIL_BUFFER_BIT, NULL, r_refdef, r_stat_lights_clears, and r_refdef_t::stats.
Definition at line 4686 of file r_shadow.c.
References Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), NULL, R_Shadow_FreeWorldLight(), r_shadow_selectedlight, and r_shadow_worldlightsarray.
Referenced by R_Shadow_EditLights_Clear_f(), R_Shadow_EditLights_ImportLightEntitiesFromMap_f(), R_Shadow_EditLights_ImportLightsFile_f(), and R_Shadow_EditLights_Reload_f().
Definition at line 3147 of file r_shadow.c.
References rtlight_t::cached_cullmaxs, rtlight_t::cached_cullmins, rtlight_t::cached_frustumplanes, rtlight_t::cached_numfrustumplanes, Con_Printf(), mplane_t::dist, DotProduct, r_refdef_view_t::frustum, r_refdef_view_t::frustumcorner, i, cvar_t::integer, matrix4x4_t::m, Matrix4x4_Transform(), rtlight_t::matrix_lighttoworld, mplane_t::normal, r_refdef_view_t::origin, PlaneClassify(), PlaneDiff, r_refdef, r_trippy, rtlight_t::shadoworigin, TriangleNormal, r_refdef_view_t::useperspective, v, VectorClear, VectorNegate, VectorNormalize, VectorNormalizeLength(), VectorSet, VectorSubtract, and r_refdef_t::view.
Referenced by R_Shadow_PrepareLight().
Definition at line 983 of file r_shadow.c.
References border, fabs(), r_refdef_t::farclip, float, r_refdef_view_t::frustum, r_refdef_view_t::frustumcorner, i, Matrix4x4_OriginFromMatrix(), Matrix4x4_Transform(), Matrix4x4_Transform3x3(), rtlight_t::matrix_lighttoworld, rtlight_t::matrix_worldtolight, n, r_refdef_t::nearclip, mplane_t::normal, r_refdef_view_t::origin, PlaneDiff, r_refdef, scale, size, VectorLength2, VectorSubtract, and r_refdef_t::view.
Referenced by R_Shadow_DrawLightShadowMaps().
Definition at line 4528 of file r_shadow.c.
References CHECKGLERROR, r_refdef_view_t::colormask, rtlight_t::corona, rtlight_t::corona_queryindex_allpixels, rtlight_t::corona_queryindex_visiblepixels, rtlight_t::corona_visibility, rtlight_t::coronasizescale, rtlight_t::flags, GL_BlendFunc(), GL_ColorMask(), GL_CullFace(), GL_DepthMask(), GL_DepthRange(), GL_DepthTest(), gl_flashblend, GL_NONE, GL_ONE, GL_PolygonOffset(), GL_ZERO, viddef_support_t::glversion, i, identitymatrix, int(), cvar_t::integer, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, r_refdef_scene_t::lights, MAX_OCCLUSION_QUERIES, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), min, r_refdef_scene_t::numlights, R_BeginCoronaQuery(), r_coronas, r_coronas_occlusionquery, r_coronas_occlusionsizescale, R_DrawCorona(), R_EntityMatrix(), r_fb, r_maxqueries, R_Mesh_ResetTextureState(), r_numqueries, r_queries, r_refdef, R_SetupShader_Generic_NoTexture(), r_shadow_debuglight, r_shadow_worldlightsarray, rtlight_t::radius, r_waterstate_t::renderingscene, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, RSurf_ActiveModelEntity(), dlight_t::rtlight, r_refdef_scene_t::rtworld, r_refdef_t::scene, viddef_t::support, cvar_t::value, vid, r_refdef_t::view, r_framebufferstate_t::water, and r_refdef_scene_t::worldentity.
Referenced by R_RenderScene().
|
static |
Definition at line 4709 of file r_shadow.c.
References EDLIGHTSPRSIZE, identitymatrix, MATERIALFLAG_ALPHA, MATERIALFLAG_BLENDED, MATERIALFLAG_FULLBRIGHT, MATERIALFLAG_NOCULLFACE, MATERIALFLAG_NODEPTHTEST, NULL, polygonelement3i, polygonelement3s, R_CalcSprite_Vertex3f(), R_DrawCustomSurface(), r_editlights_cursorlocation, r_editlights_sprcursor, r_refdef, r_refdef_view_t::right, RSurf_ActiveCustomEntity(), spritetexcoord2f, r_refdef_view_t::up, and r_refdef_t::view.
Referenced by R_Shadow_DrawLightSprites().
|
static |
Definition at line 3384 of file r_shadow.c.
References rsurfacestate_t::entity, entity_render_t::model, model, NULL, R_Shadow_SetupEntityLight(), and rsurface.
Referenced by R_Shadow_DrawLight().
|
static |
Definition at line 3339 of file r_shadow.c.
References model_t::DrawShadowMap, rsurfacestate_t::entity, entity_render_t::inversematrix, Matrix4x4_Transform(), entity_render_t::model, model_t::modelsurfaces_sorted, NULL, r_shadow_shadowmapside, rtlight_t::radius, RSurf_ActiveModelEntity(), rsurface, rsurfacestate_t::rtlight, entity_render_t::scale, rtlight_t::shadoworigin, model_t::submodelsurfaces_end, and model_t::submodelsurfaces_start.
Referenced by R_Shadow_DrawLightShadowMaps().
Definition at line 3838 of file r_shadow.c.
References rtlight_t::cached_cullmaxs, rtlight_t::cached_cullmins, rtlight_t::cached_lightentities, rtlight_t::cached_lightentities_noselfshadow, rtlight_t::cached_lighttrispvs, rtlight_t::cached_numlightentities, rtlight_t::cached_numlightentities_noselfshadow, rtlight_t::cached_numsurfaces, rtlight_t::cached_surfacelist, rtlight_t::castshadows, rtlight_t::draw, i, cvar_t::integer, Matrix4x4_Abs(), rtlight_t::matrix_worldtolight, r_refdef, R_Shadow_DrawEntityLight(), R_Shadow_DrawWorldLight(), R_Shadow_RenderMode_ActiveLight(), R_Shadow_RenderMode_DrawDeferredLight(), R_Shadow_RenderMode_Lighting(), R_Shadow_RenderMode_VisibleLighting(), R_Shadow_ScissorForBBox(), r_shadow_shadowmode, R_SHADOW_SHADOWMODE_SHADOWMAP2D, r_shadow_usingdeferredprepass, r_showlighting, r_refdef_view_t::showdebug, and r_refdef_t::view.
Referenced by R_Shadow_DrawLights(), and R_Shadow_DrawPrepass().
Definition at line 4226 of file r_shadow.c.
References R_Shadow_DrawLight(), R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_End(), r_shadow_scenelightlist, and r_shadow_scenenumlights.
Referenced by R_RenderScene().
Definition at line 3700 of file r_shadow.c.
References rtlight_t::cached_cullmaxs, rtlight_t::cached_cullmins, rtlight_t::cached_lightentities, rtlight_t::cached_lightentities_noselfshadow, rtlight_t::cached_numlightentities, rtlight_t::cached_numlightentities_noselfshadow, rtlight_t::cached_numshadowentities, rtlight_t::cached_numshadowentities_noselfshadow, rtlight_t::cached_numsurfaces, rtlight_t::cached_shadowentities, rtlight_t::cached_shadowentities_noselfshadow, rtlight_t::cached_shadowtrispvs, rtlight_t::cached_surfacelist, rtlight_t::castshadows, rtlight_t::compiled, model_t::data_surfaces, rtlight_t::draw, float, i, cvar_t::integer, Matrix4x4_Abs(), rtlight_t::matrix_worldtolight, MAX_EDICTS, msurface_t::maxs, msurface_t::mins, NULL, r_refdef, r_shadow_buffer_surfacesides, R_Shadow_CalcBBoxSideMask(), R_Shadow_CalcEntitySideMask, R_Shadow_CullFrustumSides(), R_Shadow_DrawEntityShadow(), R_Shadow_DrawWorldShadow_ShadowMap(), r_shadow_realtime_world_compile, r_shadow_realtime_world_compileshadow, R_Shadow_RenderMode_ActiveLight(), R_Shadow_RenderMode_ShadowMap(), R_Shadow_ScissorForBBox(), r_shadow_shadowmapborder, r_refdef_t::scene, rtlight_t::shadowmapatlasposition, rtlight_t::shadowmapatlassidesize, size, rtlight_t::static_shadowmap_casters, rtlight_t::static_shadowmap_receivers, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_DrawShadowMaps().
|
static |
Definition at line 4718 of file r_shadow.c.
References dlight_t::color, dlight_t::cubemapname, EDLIGHTSPRSIZE, identitymatrix, intensity, MATERIALFLAG_ALPHA, MATERIALFLAG_BLENDED, MATERIALFLAG_FULLBRIGHT, MATERIALFLAG_NOCULLFACE, NULL, dlight_t::origin, polygonelement3i, polygonelement3s, R_CalcSprite_Vertex3f(), R_DrawCustomSurface(), r_editlights_sprcubemaplight, r_editlights_sprcubemapnoshadowlight, r_editlights_sprlight, r_editlights_sprnoshadowlight, r_editlights_sprselection, r_refdef, r_refdef_view_t::right, RSurf_ActiveCustomEntity(), dlight_t::selected, dlight_t::shadow, spritetexcoord2f, r_refdef_view_t::up, VectorLength, VectorNormalize, VectorScale, VectorSet, and r_refdef_t::view.
Referenced by R_Shadow_DrawLightSprites().
Definition at line 4762 of file r_shadow.c.
References Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), NULL, dlight_t::origin, r_editlights_cursorlocation, r_editlights_lockcursor, R_MeshQueue_AddTransparent(), R_Shadow_DrawCursor_TransparentCallback(), R_Shadow_DrawLightSprite_TransparentCallback(), r_shadow_worldlightsarray, and TRANSPARENTSORT_DISTANCE.
Referenced by R_Shadow_PrepareLights().
Definition at line 4311 of file r_shadow.c.
References bound, CHECKGLERROR, CrossProduct, Cvar_SetValueQuick(), DotProduct, model_t::DrawShadowMap, rsurfacestate_t::entity, fabs(), r_refdef_view_t::forward, GL_DEPTH_COMPONENT, GL_Scissor(), GL_UNSIGNED_INT, r_viewport_t::height, i, Image_WriteTGABGRA(), cvar_t::integer, entity_render_t::inversematrix, Math_atov(), Matrix4x4_AdjustOrigin(), Matrix4x4_Concat(), Matrix4x4_CreateScale3(), Matrix4x4_FromArray12FloatD3D(), Matrix4x4_Invert_Full(), Matrix4x4_ScaleFromMatrix(), Matrix4x4_Transform(), Matrix4x4_Transform3x3(), entity_render_t::model, model_t::modelsurfaces_sorted, NULL, r_refdef_view_t::origin, r_viewport_t::projectmatrix, r_refdef, R_SetViewport(), r_shadow_modelshadowmap_parameters, r_shadow_modelshadowmap_texturescale, r_shadow_modelshadows, r_shadow_nummodelshadows, r_shadow_shadowmapatlas_modelshadows_size, r_shadow_shadowmapatlas_modelshadows_x, r_shadow_shadowmapatlas_modelshadows_y, r_shadow_shadowmapborder, r_shadow_shadowmapmatrix, r_shadow_shadowmapping_bias, r_shadow_shadowmapping_nearclip, r_shadow_shadowmapping_precision, r_shadow_shadowmaptexturesize, r_shadow_usingshadowmaportho, r_shadows_darken, r_shadows_focus, r_shadows_shadowmapbias, r_shadows_shadowmapscale, r_shadows_throwdirection, r_shadows_throwdistance, r_test, R_Viewport_InitOrtho(), r_refdef_view_t::right, RSurf_ActiveModelEntity(), rsurface, scale, size, cvar_t::string, model_t::submodelsurfaces_end, model_t::submodelsurfaces_start, r_refdef_view_t::up, cvar_t::value, VectorAdd, VectorCopy, VectorM, VectorMA, VectorNormalize, r_refdef_t::view, r_viewport_t::viewmatrix, r_refdef_view_t::viewport, r_viewport_t::width, r_viewport_t::x, r_viewport_t::y, Z_Free, and Z_Malloc.
Referenced by R_Shadow_DrawShadowMaps().
Definition at line 3958 of file r_shadow.c.
References cl, client_state_t::csqc_vidvars, model_t::DrawPrepass, csqc_vidvars_t::drawworld, r_refdef_scene_t::entities, r_refdef_viewcache_t::entityvisible, GL_BlendFunc(), GL_Clear(), GL_Color(), GL_COLOR_BUFFER_BIT, GL_ColorMask(), GL_DEPTH_BUFFER_BIT, GL_DepthMask(), GL_DepthTest(), GL_ONE, GL_ZERO, i, entity_render_t::model, NULL, r_refdef_scene_t::numentities, R_Mesh_ResetTextureState(), R_Mesh_SetRenderTargets(), r_refdef, R_Shadow_DrawLight(), r_shadow_prepassgeometryfbo, r_shadow_prepasslightingdiffusespecularfbo, R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_End(), r_shadow_scenelightlist, r_shadow_scenenumlights, R_TimeReport(), r_timereport_active, r_refdef_t::scene, Vector4Set, r_refdef_t::viewcache, r_refdef_scene_t::worldentity, and r_refdef_scene_t::worldmodel.
Referenced by R_RenderScene().
Definition at line 4204 of file r_shadow.c.
References NULL, R_Shadow_ClearShadowMapTexture(), R_Shadow_DrawLightShadowMaps(), R_Shadow_DrawModelShadowMaps(), R_Shadow_RenderMode_ActiveLight(), R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_End(), r_shadow_scenelightlist, r_shadow_scenenumlights, r_shadow_shadowmapatlas_modelshadows_size, and R_Shadow_ShadowMappingEnabled().
Referenced by R_RenderScene().
|
static |
Definition at line 3367 of file r_shadow.c.
References model_t::DrawLight, rsurfacestate_t::entity, rsurfacestate_t::entitylightorigin, rsurfacestate_t::entitytoattenuationxyz, rsurfacestate_t::entitytoattenuationz, rsurfacestate_t::entitytolight, Matrix4x4_Concat(), matrix_attenuationxyz, matrix_attenuationz, rtlight_t::matrix_worldtolight, NULL, r_refdef, RSurf_ActiveModelEntity(), rsurface, rsurfacestate_t::rtlight, r_refdef_t::scene, rtlight_t::shadoworigin, VectorCopy, r_refdef_scene_t::worldentity, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_DrawLight().
|
static |
Definition at line 3316 of file r_shadow.c.
References rtlight_t::cached_cullmaxs, rtlight_t::cached_cullmins, CHECKGLERROR, rtlight_t::compiled, model_t::DrawShadowMap, shadowmesh_t::element3i, shadowmesh_t::element3i_bufferoffset, shadowmesh_t::element3i_indexbuffer, shadowmesh_t::element3s, shadowmesh_t::element3s_bufferoffset, shadowmesh_t::element3s_indexbuffer, rsurfacestate_t::entity, GL_CullFace(), GL_NONE, cvar_t::integer, entity_render_t::model, NULL, shadowmesh_t::numverts, R_Mesh_Draw(), R_Mesh_PrepareVertices_Vertex3f(), r_refdef, r_shadow_realtime_world_compile, r_shadow_realtime_world_compileshadow, r_shadow_shadowmapside, r_stat_lights_shadowtriangles, rtlight_t::radius, RSurf_ActiveModelEntity(), rsurface, rsurfacestate_t::rtlight, r_refdef_t::scene, rtlight_t::shadoworigin, shadowmesh_t::sideoffsets, shadowmesh_t::sidetotals, rtlight_t::static_meshchain_shadow_shadowmap, r_refdef_t::stats, shadowmesh_t::vbo_vertexbuffer, shadowmesh_t::vbooffset_vertex3f, shadowmesh_t::vertex3f, r_refdef_scene_t::worldentity, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_DrawLightShadowMaps().
|
static |
Definition at line 5300 of file r_shadow.c.
References R_Shadow_ClearWorldLights().
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5900 of file r_shadow.c.
References dlight_t::ambientscale, dlight_t::angles, dlight_t::color, Con_Print(), dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dp_strlcpy, dlight_t::flags, cvar_t::integer, r_editlights, r_shadow_bufferlight, r_shadow_selectedlight, dlight_t::radius, dlight_t::shadow, dlight_t::specularscale, dlight_t::style, and VectorCopy.
Referenced by R_Shadow_EditLights_Init().
Definition at line 5713 of file r_shadow.c.
References dlight_t::ambientscale, dlight_t::angles, rtlight_t::bouncegrid_effectiveradius, rtlight_t::bouncegrid_hits, rtlight_t::bouncegrid_photoncolor, rtlight_t::bouncegrid_photons, rtlight_t::bouncegrid_traces, rtlight_t::cached_numlightentities, rtlight_t::cached_numlightentities_noselfshadow, rtlight_t::cached_numshadowentities, rtlight_t::cached_numshadowentities_noselfshadow, rtlight_t::cached_numsurfaces, dlight_t::color, dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, rtlight_t::currentcolor, Cvar_SetQuick(), Cvar_SetValueQuick(), dlight_t::diffusescale, dpsnprintf(), DrawQ_Pic(), DrawQ_String(), dlight_t::flags, FONT_DEFAULT, int(), cvar_t::integer, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), NULL, dlight_t::origin, r_editlights, r_editlights_current_ambient, r_editlights_current_angles, r_editlights_current_color, r_editlights_current_corona, r_editlights_current_coronasize, r_editlights_current_cubemap, r_editlights_current_diffuse, r_editlights_current_normalmode, r_editlights_current_origin, r_editlights_current_radius, r_editlights_current_realtimemode, r_editlights_current_shadows, r_editlights_current_specular, r_editlights_current_style, r_editlights_cursorlocation, r_editlights_drawproperties, r_shadow_selectedlight, r_shadow_worldlightsarray, dlight_t::radius, dlight_t::rtlight, dlight_t::shadow, rtlight_t::shadowmapatlassidesize, dlight_t::specularscale, dlight_t::style, cvar_t::value, vid_conwidth, x, and y.
Referenced by SCR_DrawScreen().
|
static |
Definition at line 5360 of file r_shadow.c.
References dlight_t::ambientscale, angles, dlight_t::angles, cmd(), Cmd_Argc(), Cmd_Argv(), color, dlight_t::color, Con_Print(), Con_Printf(), dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dp_strlcpy, dlight_t::flags, flags, cvar_t::integer, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, MAX_INPUTLINE, dlight_t::origin, origin, r_editlights, r_shadow_selectedlight, R_Shadow_UpdateWorldLight(), dlight_t::radius, scale, dlight_t::shadow, dlight_t::specularscale, dlight_t::style, style, and VectorCopy.
Referenced by R_Shadow_EditLights_EditAll_f(), and R_Shadow_EditLights_Init().
|
static |
Definition at line 5686 of file r_shadow.c.
References cmd_local, Con_Print(), cvar_t::integer, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), r_editlights, R_Shadow_EditLights_Edit_f(), r_shadow_selectedlight, R_Shadow_SelectLight(), and r_shadow_worldlightsarray.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5843 of file r_shadow.c.
References Con_Print().
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5331 of file r_shadow.c.
References R_Shadow_ClearWorldLights(), and R_Shadow_LoadWorldLightsFromMap_LightArghliteTyrlite().
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5337 of file r_shadow.c.
References R_Shadow_ClearWorldLights(), and R_Shadow_LoadLightsFile().
Referenced by R_Shadow_EditLights_Init().
Definition at line 5964 of file r_shadow.c.
References CF_CLIENT, Cmd_AddCommand(), Cvar_RegisterVariable(), r_editlights, r_editlights_current_ambient, r_editlights_current_angles, r_editlights_current_color, r_editlights_current_corona, r_editlights_current_coronasize, r_editlights_current_cubemap, r_editlights_current_diffuse, r_editlights_current_normalmode, r_editlights_current_origin, r_editlights_current_radius, r_editlights_current_realtimemode, r_editlights_current_shadows, r_editlights_current_specular, r_editlights_current_style, r_editlights_cursordistance, r_editlights_cursorgrid, r_editlights_cursorpushback, r_editlights_cursorpushoff, r_editlights_drawproperties, r_editlights_quakelightsizescale, R_Shadow_EditLights_Clear_f(), R_Shadow_EditLights_CopyInfo_f(), R_Shadow_EditLights_Edit_f(), R_Shadow_EditLights_EditAll_f(), R_Shadow_EditLights_Help_f(), R_Shadow_EditLights_ImportLightEntitiesFromMap_f(), R_Shadow_EditLights_ImportLightsFile_f(), R_Shadow_EditLights_Lock_f(), R_Shadow_EditLights_PasteInfo_f(), R_Shadow_EditLights_Reload_f(), R_Shadow_EditLights_Remove_f(), R_Shadow_EditLights_Save_f(), R_Shadow_EditLights_Spawn_f(), R_Shadow_EditLights_ToggleCorona_f(), and R_Shadow_EditLights_ToggleShadow_f().
Referenced by R_Shadow_Init().
|
static |
Definition at line 5944 of file r_shadow.c.
References Con_Print(), cvar_t::integer, r_editlights, r_editlights_lockcursor, and r_shadow_selectedlight.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5929 of file r_shadow.c.
References dlight_t::ambientscale, dlight_t::angles, dlight_t::color, Con_Print(), dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dlight_t::flags, cvar_t::integer, dlight_t::origin, r_editlights, r_shadow_bufferlight, r_shadow_selectedlight, R_Shadow_UpdateWorldLight(), dlight_t::radius, dlight_t::shadow, dlight_t::specularscale, and dlight_t::style.
Referenced by R_Shadow_EditLights_Init().
void R_Shadow_EditLights_Reload_f | ( | cmd_state_t * | cmd | ) |
Definition at line 5305 of file r_shadow.c.
References cl, dp_strlcpy, cvar_t::integer, Mem_ExpandableArray_IndexRange(), R_Shadow_ClearWorldLights(), R_Shadow_LoadLightsFile(), R_Shadow_LoadWorldLights(), R_Shadow_LoadWorldLightsFromMap_LightArghliteTyrlite(), r_shadow_mapname, r_shadow_realtime_world_importlightentitiesfrommap, r_shadow_worldlightsarray, client_state_t::worldmodel, and client_state_t::worldname.
Referenced by R_Shadow_EditLights_Init(), and r_shadow_newmap().
|
static |
Definition at line 5827 of file r_shadow.c.
References Con_Print(), cvar_t::integer, NULL, r_editlights, R_Shadow_FreeWorldLight(), and r_shadow_selectedlight.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5324 of file r_shadow.c.
References cl, R_Shadow_SaveWorldLights(), and client_state_t::worldmodel.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5343 of file r_shadow.c.
References cmd(), Cmd_Argc(), color, Con_Print(), cvar_t::integer, LIGHTFLAG_REALTIMEMODE, NULL, r_editlights, r_editlights_cursorlocation, R_Shadow_NewWorldLight(), R_Shadow_UpdateWorldLight(), and vec3_origin.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5812 of file r_shadow.c.
References dlight_t::ambientscale, dlight_t::angles, dlight_t::color, Con_Print(), dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dlight_t::flags, cvar_t::integer, dlight_t::origin, r_editlights, r_shadow_selectedlight, R_Shadow_UpdateWorldLight(), dlight_t::radius, dlight_t::shadow, dlight_t::specularscale, and dlight_t::style.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 5797 of file r_shadow.c.
References dlight_t::ambientscale, dlight_t::angles, dlight_t::color, Con_Print(), dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dlight_t::flags, cvar_t::integer, dlight_t::origin, r_editlights, r_shadow_selectedlight, R_Shadow_UpdateWorldLight(), dlight_t::radius, dlight_t::shadow, dlight_t::specularscale, and dlight_t::style.
Referenced by R_Shadow_EditLights_Init().
|
static |
Definition at line 776 of file r_shadow.c.
References Mem_Alloc, Mem_Free, r_main_mempool, r_shadow_buffer_leaflist, r_shadow_buffer_leafpvs, r_shadow_buffer_lighttrispvs, r_shadow_buffer_numleafpvsbytes, r_shadow_buffer_numlighttrispvsbytes, r_shadow_buffer_numshadowtrispvsbytes, r_shadow_buffer_numsurfacepvsbytes, r_shadow_buffer_shadowtrispvs, r_shadow_buffer_surfacelist, r_shadow_buffer_surfacepvs, r_shadow_buffer_surfacesides, and r_shadow_buffer_visitingleafpvs.
Referenced by R_Shadow_PrepareLights().
Definition at line 3930 of file r_shadow.c.
References NULL, R_FreeTexture(), R_Mesh_DestroyFramebufferObject(), r_shadow_prepassgeometrydepthbuffer, r_shadow_prepassgeometryfbo, r_shadow_prepassgeometrynormalmaptexture, r_shadow_prepasslightingdiffusefbo, r_shadow_prepasslightingdiffusespecularfbo, r_shadow_prepasslightingdiffusetexture, and r_shadow_prepasslightingspeculartexture.
Referenced by R_Shadow_PrepareLights(), and r_shadow_shutdown().
Definition at line 390 of file r_shadow.c.
References Mod_AllocLightmap_Free(), NULL, R_FreeTexture(), R_Mesh_DestroyFramebufferObject(), r_shadow_fbo2d, R_Shadow_SetShadowMode(), r_shadow_shadowmap2ddepthbuffer, r_shadow_shadowmap2ddepthtexture, r_shadow_shadowmapatlas_state, r_shadow_shadowmapvsdcttexture, and R_Shadow_UncompileWorldLights().
Referenced by R_Shadow_MakeTextures(), R_Shadow_PrepareLights(), r_shadow_shutdown(), and r_shadow_start().
Definition at line 4678 of file r_shadow.c.
References Mem_ExpandableArray_FreeRecord(), NULL, R_RTLight_Uncompile(), r_shadow_selectedlight, r_shadow_worldlightsarray, and dlight_t::rtlight.
Referenced by R_Shadow_ClearWorldLights(), and R_Shadow_EditLights_Remove_f().
int R_Shadow_GetRTLightInfo | ( | unsigned int | lightindex, |
float * | origin, | ||
float * | radius, | ||
float * | color ) |
Definition at line 4777 of file r_shadow.c.
References color, rtlight_t::color, int(), Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), origin, r_shadow_worldlightsarray, rtlight_t::radius, dlight_t::rtlight, rtlight_t::shadoworigin, and VectorCopy.
Referenced by Mod_GenerateLightmaps_CreateLights(), and Mod_GenerateLightmaps_LightPoint().
Definition at line 601 of file r_shadow.c.
References Cvar_RegisterVariable(), gl_flashblend, maxshadowmark, maxshadowsides, maxshadowtriangles, maxshadowvertices, maxvertexupdate, Mem_ExpandableArray_NewArray(), NULL, numshadowmark, numshadowsides, r_coronas, r_coronas_occlusionquery, r_coronas_occlusionsizescale, r_main_mempool, R_RegisterModule(), r_shadow_bouncegrid, r_shadow_bouncegrid_blur, r_shadow_bouncegrid_dynamic_bounceminimumintensity, r_shadow_bouncegrid_dynamic_culllightpaths, r_shadow_bouncegrid_dynamic_directionalshading, r_shadow_bouncegrid_dynamic_dlightparticlemultiplier, r_shadow_bouncegrid_dynamic_hitmodels, r_shadow_bouncegrid_dynamic_lightradiusscale, r_shadow_bouncegrid_dynamic_maxbounce, r_shadow_bouncegrid_dynamic_maxphotons, r_shadow_bouncegrid_dynamic_quality, r_shadow_bouncegrid_dynamic_spacing, r_shadow_bouncegrid_dynamic_updateinterval, r_shadow_bouncegrid_dynamic_x, r_shadow_bouncegrid_dynamic_y, r_shadow_bouncegrid_dynamic_z, r_shadow_bouncegrid_floatcolors, r_shadow_bouncegrid_includedirectlighting, r_shadow_bouncegrid_intensity, r_shadow_bouncegrid_lightpathsize, r_shadow_bouncegrid_normalizevectors, r_shadow_bouncegrid_particlebounceintensity, r_shadow_bouncegrid_particleintensity, r_shadow_bouncegrid_rng_seed, r_shadow_bouncegrid_rng_type, r_shadow_bouncegrid_static, r_shadow_bouncegrid_static_bounceminimumintensity, r_shadow_bouncegrid_static_directionalshading, r_shadow_bouncegrid_static_lightradiusscale, r_shadow_bouncegrid_static_maxbounce, r_shadow_bouncegrid_static_maxphotons, r_shadow_bouncegrid_static_quality, r_shadow_bouncegrid_static_spacing, r_shadow_bouncegrid_subsamples, r_shadow_bouncegrid_threaded, r_shadow_buffer_leaflist, r_shadow_buffer_leafpvs, r_shadow_buffer_lighttrispvs, r_shadow_buffer_numleafpvsbytes, r_shadow_buffer_numsurfacepvsbytes, r_shadow_buffer_shadowtrispvs, r_shadow_buffer_surfacelist, r_shadow_buffer_surfacepvs, r_shadow_buffer_surfacesides, r_shadow_buffer_visitingleafpvs, r_shadow_bumpscale_basetexture, r_shadow_bumpscale_bumpmap, r_shadow_culllights_pvs, r_shadow_culllights_trace, r_shadow_culllights_trace_delay, r_shadow_culllights_trace_enlarge, r_shadow_culllights_trace_expand, r_shadow_culllights_trace_eyejitter, r_shadow_culllights_trace_pad, r_shadow_culllights_trace_samples, r_shadow_culllights_trace_tempsamples, r_shadow_debuglight, r_shadow_deferred, R_Shadow_EditLights_Init(), r_shadow_frontsidecasting, r_shadow_gloss, r_shadow_gloss2exponent, r_shadow_gloss2intensity, r_shadow_glossexact, r_shadow_glossexponent, r_shadow_glossintensity, r_shadow_lightattenuationdividebias, r_shadow_lightattenuationlinearscale, r_shadow_lightintensityscale, r_shadow_lightradiusscale, r_shadow_newmap(), r_shadow_projectdistance, r_shadow_realtime_dlight, r_shadow_realtime_dlight_portalculling, r_shadow_realtime_dlight_shadows, r_shadow_realtime_dlight_svbspculling, r_shadow_realtime_world, r_shadow_realtime_world_compile, r_shadow_realtime_world_compileportalculling, r_shadow_realtime_world_compileshadow, r_shadow_realtime_world_compilesvbsp, r_shadow_realtime_world_importlightentitiesfrommap, r_shadow_realtime_world_lightmaps, r_shadow_realtime_world_shadows, r_shadow_scenelightlist, r_shadow_scenemaxlights, r_shadow_scenenumlights, r_shadow_scissor, r_shadow_shadowmapping, r_shadow_shadowmapping_bias, r_shadow_shadowmapping_bordersize, r_shadow_shadowmapping_depthbits, r_shadow_shadowmapping_filterquality, r_shadow_shadowmapping_maxsize, r_shadow_shadowmapping_minsize, r_shadow_shadowmapping_nearclip, r_shadow_shadowmapping_polygonfactor, r_shadow_shadowmapping_polygonoffset, r_shadow_shadowmapping_precision, r_shadow_shadowmapping_texturesize, r_shadow_shadowmapping_useshadowsampler, r_shadow_shadowmapping_vsdct, r_shadow_shutdown(), r_shadow_sortsurfaces, r_shadow_start(), r_shadow_usebihculling, r_shadow_usenormalmap, r_shadow_worldlightsarray, shadowelements, shadowmark, shadowmarkcount, shadowmarklist, shadowsides, shadowsideslist, shadowvertex3f, vertexremap, vertexupdate, and vertexupdatenum.
Referenced by Render_Init().
Definition at line 4987 of file r_shadow.c.
References a, bound, cl, color, Con_Print(), Con_Printf(), DotProduct, dpsnprintf(), FS_LoadFile(), LIGHTFLAG_REALTIMEMODE, MAX_QPATH, Mem_Free, n, name, NULL, origin, R_Shadow_NewWorldLight(), R_Shadow_UpdateWorldLight(), sqrt(), style, tempmempool, vec3_origin, VectorScale, client_state_t::worldmodel, and client_state_t::worldnamenoextension.
Referenced by R_Shadow_EditLights_ImportLightsFile_f(), and R_Shadow_EditLights_Reload_f().
Definition at line 4829 of file r_shadow.c.
References a, angles, cl, color, Con_Print(), Con_Printf(), dpsnprintf(), flags, FS_LoadFile(), LIGHTFLAG_REALTIMEMODE, MAX_QPATH, Mem_Free, n, name, NULL, origin, R_Shadow_NewWorldLight(), R_Shadow_UpdateWorldLight(), strlen(), style, tempmempool, VectorClear, client_state_t::worldmodel, and client_state_t::worldnamenoextension.
Referenced by R_Shadow_EditLights_Reload_f().
Definition at line 5038 of file r_shadow.c.
References angles, cl, color, COM_ParseToken_Simple(), com_token, Con_Print(), data, dp_strlcpy, dpsnprintf(), entnum, FS_LoadFile(), int(), LIGHTFLAG_REALTIMEMODE, LIGHTTYPE_MINUSX, LIGHTTYPE_MINUSXX, LIGHTTYPE_NONE, LIGHTTYPE_RECIPX, LIGHTTYPE_RECIPXX, LIGHTTYPE_SUN, MAX_INPUTLINE, Mem_Free, mod_brushq3, n, NULL, origin, pflags, PFLAGS_CORONA, PFLAGS_NOSHADOW, r_editlights_quakelightsizescale, R_Shadow_NewWorldLight(), R_Shadow_UpdateWorldLight(), skin, strlen(), style, tempmempool, type, va(), cvar_t::value, value, VectorAdd, VectorScale, client_state_t::worldmodel, and client_state_t::worldnamenoextension.
Referenced by R_Shadow_EditLights_ImportLightEntitiesFromMap_f(), and R_Shadow_EditLights_Reload_f().
Definition at line 1456 of file r_shadow.c.
References NULL, r_fb, R_LoadTexture2D(), R_LoadTextureRenderBuffer(), R_LoadTextureShadowMap2D(), R_Mesh_CreateFramebufferObject(), r_shadow_fbo2d, r_shadow_shadowmap2ddepthbuffer, r_shadow_shadowmap2ddepthtexture, r_shadow_shadowmapdepthbits, r_shadow_shadowmapsampler, r_shadow_shadowmode, R_SHADOW_SHADOWMODE_DISABLED, R_SHADOW_SHADOWMODE_SHADOWMAP2D, r_shadow_texturepool, TEXF_ALPHA, TEXF_CLAMP, TEXF_FORCENEAREST, TEXF_RENDERTARGET, TEXTYPE_COLORBUFFER, TEXTYPE_DEPTHBUFFER16, TEXTYPE_DEPTHBUFFER24, TEXTYPE_SHADOWMAP16_COMP, TEXTYPE_SHADOWMAP16_RAW, TEXTYPE_SHADOWMAP24_COMP, TEXTYPE_SHADOWMAP24_RAW, and r_framebufferstate_t::usedepthtextures.
Referenced by R_Shadow_ClearShadowMapTexture().
Definition at line 1232 of file r_shadow.c.
References ATTEN1DSIZE, ATTEN2DSIZE, ATTEN3DSIZE, ATTENTABLESIZE, bound, data, intensity, max, Mem_Alloc, Mem_Free, NULL, palette_bgra_embeddedpic, R_AllocTexturePool(), r_editlights_sprcubemaplight, r_editlights_sprcubemapnoshadowlight, r_editlights_sprcursor, r_editlights_sprlight, r_editlights_sprnoshadowlight, r_editlights_sprselection, R_FreeTexturePool(), R_LoadTexture2D(), r_shadow_attendividebias, r_shadow_attenlinearscale, r_shadow_attentable, r_shadow_attenuationgradienttexture, R_Shadow_FreeShadowMaps(), r_shadow_lightattenuationdividebias, r_shadow_lightattenuationlinearscale, R_Shadow_MakeTextures_MakeCorona(), R_Shadow_MakeTextures_SamplePoint(), r_shadow_texturepool, R_SkinFrame_LoadInternal8bit(), tempmempool, TEXF_ALPHA, TEXF_CLAMP, TEXF_FORCELINEAR, TEXTYPE_BGRA, cvar_t::value, and x.
Referenced by R_Shadow_RenderMode_Begin(), and r_shadow_start().
Definition at line 1202 of file r_shadow.c.
References a, bound, int(), pixels, r_shadow_lightcorona, R_SkinFrame_LoadInternalBGRA(), TEXF_FORCELINEAR, x, and y.
Referenced by R_Shadow_MakeTextures().
Definition at line 1224 of file r_shadow.c.
References bound, intensity, r_shadow_lightattenuationdividebias, r_shadow_lightattenuationlinearscale, sqrt(), cvar_t::value, x, y, and z.
Referenced by R_Shadow_MakeTextures().
Definition at line 1436 of file r_shadow.c.
References data, NULL, R_LoadTextureCubeMap(), r_shadow_shadowmapvsdcttexture, r_shadow_texturepool, TEXF_ALPHA, TEXF_CLAMP, TEXF_FORCENEAREST, and TEXTYPE_RGBA.
Referenced by R_Shadow_ClearShadowMapTexture().
Definition at line 585 of file r_shadow.c.
References cl, cmd_local, NULL, r_editlights_sprcubemaplight, r_editlights_sprcubemapnoshadowlight, r_editlights_sprcursor, r_editlights_sprlight, r_editlights_sprnoshadowlight, r_editlights_sprselection, R_FreeTexture(), R_Shadow_BounceGrid_FreeHighPixels(), r_shadow_bouncegrid_state, R_Shadow_EditLights_Reload_f(), r_shadow_lightcorona, r_shadow_mapname, R_SkinFrame_MarkUsed(), r_shadow_bouncegrid_state_t::texture, and client_state_t::worldname.
Referenced by R_Shadow_Init().
Definition at line 4634 of file r_shadow.c.
References Mem_ExpandableArray_AllocRecord(), and r_shadow_worldlightsarray.
Referenced by R_Shadow_EditLights_Spawn_f(), R_Shadow_LoadLightsFile(), R_Shadow_LoadWorldLights(), and R_Shadow_LoadWorldLightsFromMap_LightArghliteTyrlite().
Definition at line 3397 of file r_shadow.c.
References rtlight_t::ambientscale, bound, BoxesOverlap, model_brush_t::BoxTouchingLeafPVS, model_brush_t::BoxTouchingVisibleLeafs, model_t::brush, rtlight_t::cached_cullmaxs, rtlight_t::cached_cullmins, rtlight_t::cached_frustumplanes, rtlight_t::cached_lightentities, rtlight_t::cached_lightentities_noselfshadow, rtlight_t::cached_lighttrispvs, rtlight_t::cached_numfrustumplanes, rtlight_t::cached_numlightentities, rtlight_t::cached_numlightentities_noselfshadow, rtlight_t::cached_numshadowentities, rtlight_t::cached_numshadowentities_noselfshadow, rtlight_t::cached_numsurfaces, rtlight_t::cached_shadowentities, rtlight_t::cached_shadowentities_noselfshadow, rtlight_t::cached_shadowtrispvs, rtlight_t::cached_surfacelist, rtlight_t::castshadows, rtlight_t::color, rtlight_t::compiled, rtlight_t::cubemapname, rtlight_t::cullmaxs, rtlight_t::cullmins, rtlight_t::currentcolor, rtlight_t::currentcubemap, rtlight_t::diffusescale, rtlight_t::draw, r_refdef_scene_t::entities, r_refdef_viewcache_t::entityvisible, f, entity_render_t::flags, model_t::GetLightInfo, host, i, cvar_t::integer, rtlight_t::isstatic, entity_render_t::matrix, Matrix4x4_OriginFromMatrix(), max, MAX_EDICTS, MAX_LIGHTSTYLES, entity_render_t::maxs, entity_render_t::mins, entity_render_t::model, model, NULL, surfmesh_t::num_triangles, r_refdef_scene_t::numentities, r_refdef_view_t::origin, R_AnimCache_GetEntity(), R_CanSeeBox(), R_CullBox(), R_CullFrustum(), R_FrameData_Store(), R_GetCubemap(), r_refdef, R_RTLight_Compile(), r_shadow_bouncegrid, r_shadow_bouncegrid_static, r_shadow_buffer_leaflist, r_shadow_buffer_leafpvs, r_shadow_buffer_lighttrispvs, r_shadow_buffer_shadowtrispvs, r_shadow_buffer_surfacelist, r_shadow_buffer_surfacepvs, r_shadow_buffer_visitingleafpvs, R_Shadow_ComputeShadowCasterCullingPlanes(), r_shadow_culllights_pvs, r_shadow_culllights_trace, r_shadow_culllights_trace_delay, r_shadow_culllights_trace_enlarge, r_shadow_culllights_trace_expand, r_shadow_culllights_trace_eyejitter, r_shadow_culllights_trace_pad, r_shadow_culllights_trace_samples, r_shadow_culllights_trace_tempsamples, r_shadow_lightintensityscale, r_shadow_realtime_world_compile, r_shadow_shadowmapborder, r_shadow_shadowmapmaxsize, r_shadow_shadowmapping_minsize, r_shadow_shadowmapping_precision, R_Shadow_ShadowMappingEnabled(), r_shadow_usingdeferredprepass, r_stat_lights, r_texture_whitecube, rtlight_t::radius, host_static_t::realtime, RENDER_EXTERIORMODEL, RENDER_LIGHT, RENDER_NOSELFSHADOW, RENDER_SHADOW, r_refdef_scene_t::rtdlightshadows, r_refdef_scene_t::rtlightstylevalue, r_refdef_scene_t::rtworldshadows, r_refdef_t::scene, rtlight_t::shadow, rtlight_t::shadowmapsidesize, rtlight_t::shadoworigin, rtlight_t::specularscale, sqrt(), rtlight_t::static_leaflist, rtlight_t::static_leafpvs, rtlight_t::static_lighttrispvs, rtlight_t::static_numleafs, rtlight_t::static_numsurfaces, rtlight_t::static_shadowtrispvs, rtlight_t::static_surfacelist, r_refdef_t::stats, rtlight_t::style, model_t::surfmesh, rtlight_t::trace_timer, cvar_t::value, VectorCopy, VectorDistance, VectorDistance2, VectorLength2, VectorScale, r_refdef_t::view, r_refdef_t::viewcache, r_refdef_viewcache_t::world_leafvisible, r_refdef_scene_t::worldentity, and r_refdef_scene_t::worldmodel.
Referenced by R_Shadow_PrepareLights().
Definition at line 4031 of file r_shadow.c.
References bound, model_t::brush, rtlight_t::cached_numshadowentities_noselfshadow, rtlight_t::castshadows, rtlight_t::color, rtlight_t::currentcolor, f, dlight_t::flags, gl_flashblend, height, cvar_t::integer, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, r_refdef_scene_t::lights, r_refdef_scene_t::lightstylevalue, lod, MAX_LIGHTSTYLES, viddef_t::maxdrawbuffers, viddef_t::maxtexturesize_2d, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), Mod_AllocLightmap_Block(), Mod_AllocLightmap_Reset(), NULL, model_brush_t::num_leafs, model_t::num_surfaces, surfmesh_t::num_triangles, r_refdef_scene_t::numlights, r_editlights, r_fb, R_LoadTexture2D(), R_LoadTextureRenderBuffer(), R_Mesh_CreateFramebufferObject(), R_Mesh_SetRenderTargets(), r_refdef, r_shadow_debuglight, r_shadow_deferred, R_Shadow_DrawLightSprites(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_FreeDeferred(), R_Shadow_FreeShadowMaps(), r_shadow_lightintensityscale, R_Shadow_PrepareLight(), R_Shadow_PrepareLights_AddSceneLight(), r_shadow_prepass_height, r_shadow_prepass_width, r_shadow_prepassgeometrydepthbuffer, r_shadow_prepassgeometryfbo, r_shadow_prepassgeometrynormalmaptexture, r_shadow_prepasslightingdiffusefbo, r_shadow_prepasslightingdiffusespecularfbo, r_shadow_prepasslightingdiffusetexture, r_shadow_prepasslightingspeculartexture, r_shadow_scenelightlist, r_shadow_scenenumlights, r_shadow_shadowmapatlas_modelshadows_size, r_shadow_shadowmapatlas_modelshadows_x, r_shadow_shadowmapatlas_modelshadows_y, r_shadow_shadowmapatlas_state, r_shadow_shadowmapborder, r_shadow_shadowmapdepthbits, r_shadow_shadowmapdepthtexture, r_shadow_shadowmapfilterquality, r_shadow_shadowmapmaxsize, r_shadow_shadowmapping, r_shadow_shadowmapping_bordersize, r_shadow_shadowmapping_depthbits, r_shadow_shadowmapping_filterquality, r_shadow_shadowmapping_maxsize, r_shadow_shadowmapping_texturesize, r_shadow_shadowmapping_useshadowsampler, r_shadow_shadowmapping_vsdct, R_Shadow_ShadowMappingEnabled(), r_shadow_shadowmapshadowsampler, r_shadow_shadowmaptexturesize, r_shadow_shadowmapvsdct, r_shadow_shadowmode_deferred, r_shadow_shadowmode_shadowmapping, r_shadow_texturepool, r_shadow_usingdeferredprepass, r_shadow_usingshadowmaportho, r_shadow_worldlightsarray, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, r_refdef_scene_t::rtdlight, dlight_t::rtlight, r_refdef_scene_t::rtworld, r_refdef_t::scene, r_framebufferstate_t::screentextureheight, r_framebufferstate_t::screentexturewidth, rtlight_t::shadowmapatlasposition, rtlight_t::shadowmapatlassidesize, rtlight_t::shadowmapsidesize, size, rtlight_t::style, model_t::surfmesh, TEXF_ALPHA, TEXF_CLAMP, TEXF_FORCENEAREST, TEXF_RENDERTARGET, TEXTYPE_COLORBUFFER16F, TEXTYPE_COLORBUFFER32F, TEXTYPE_DEPTHBUFFER24, r_framebufferstate_t::usedepthtextures, cvar_t::value, VectorScale, vid, width, and r_refdef_scene_t::worldmodel.
Referenced by R_RenderScene().
Definition at line 4016 of file r_shadow.c.
References bound, MAX_SCENELIGHTS, Mem_Realloc, r_main_mempool, r_shadow_scenelightlist, r_shadow_scenemaxlights, and r_shadow_scenenumlights.
Referenced by R_Shadow_PrepareLights().
Definition at line 4242 of file r_shadow.c.
References BoxesOverlap, model_t::brush, CrossProduct, DotProduct, model_t::DrawShadowMap, r_refdef_scene_t::entities, fabs(), entity_render_t::flags, r_refdef_view_t::forward, i, cvar_t::integer, r_refdef_scene_t::lightmapintensity, Math_atov(), MAX_MODELSHADOWS, entity_render_t::maxs, entity_render_t::mins, entity_render_t::model, NULL, r_refdef_scene_t::numentities, r_refdef_view_t::origin, R_AnimCache_GetEntity(), r_refdef, r_shadow_modelshadows, r_shadow_nummodelshadows, r_shadow_shadowmapatlas_modelshadows_size, r_shadow_shadowmapatlas_modelshadows_x, r_shadow_shadowmapatlas_modelshadows_y, r_shadow_shadowmapping_precision, r_shadow_shadowmaptexturesize, r_shadows, r_shadows_castfrombmodels, r_shadows_focus, r_shadows_shadowmapscale, r_shadows_throwdirection, r_shadows_throwdistance, RENDER_SHADOW, r_refdef_view_t::right, scale, r_refdef_t::scene, size, cvar_t::string, model_brush_t::submodel, r_refdef_view_t::up, cvar_t::value, VectorAdd, VectorCopy, VectorM, VectorMA, VectorNormalize, and r_refdef_t::view.
Referenced by R_RenderScene().
Definition at line 824 of file r_shadow.c.
References maxshadowmark, Mem_Alloc, Mem_Free, numshadowmark, r_main_mempool, shadowmark, shadowmarkcount, and shadowmarklist.
Definition at line 848 of file r_shadow.c.
References maxshadowsides, Mem_Alloc, Mem_Free, numshadowsides, r_main_mempool, shadowsides, and shadowsideslist.
Referenced by R_Mod_CompileShadowMap().
void R_Shadow_RenderLighting | ( | int | texturenumsurfaces, |
const msurface_t ** | texturesurfacelist ) |
Definition at line 2936 of file r_shadow.c.
References rtlight_t::ambientscale, Con_Printf(), rtlight_t::currentcolor, texture_t::currentmaterialflags, rtlight_t::diffusescale, GL_BlendEquationSubtract(), GL_DepthTest(), cvar_t::integer, MATERIALFLAG_NODEPTHTEST, max, R_Shadow_RenderLighting_Light_GLSL(), R_Shadow_RenderLighting_VisibleLighting(), r_shadow_rendermode, R_SHADOW_RENDERMODE_LIGHT_GLSL, R_SHADOW_RENDERMODE_VISIBLELIGHTING, r_shadow_usenormalmap, r_showdisabledepthtest, texture_t::render_rtlight_diffuse, texture_t::render_rtlight_specular, RSurf_SetupDepthAndCulling(), rsurface, rsurfacestate_t::rtlight, texture_t::rtlightambient, rtlight_t::specularscale, rsurfacestate_t::texture, VectorClear, VectorLength2, VectorM, VectorMAM, VectorMultiply, and VectorNegate.
Referenced by R_Mod_DrawLight(), and R_Q1BSP_DrawLight_TransparentCallback().
|
static |
Definition at line 2928 of file r_shadow.c.
References NULL, R_SetupShader_Surface(), RSurf_DrawBatch(), and RSURFPASS_RTLIGHT.
Referenced by R_Shadow_RenderLighting().
|
static |
Definition at line 2920 of file r_shadow.c.
References BATCHNEED_ARRAY_VERTEX, BATCHNEED_NOGAPS, rsurfacestate_t::batchnumvertices, rsurfacestate_t::batchvertex3f, NULL, R_Mesh_PrepareVertices_Generic_Arrays(), RSurf_DrawBatch(), RSurf_PrepareVerticesForBatch(), and rsurface.
Referenced by R_Shadow_RenderLighting().
Definition at line 1404 of file r_shadow.c.
References rsurface, and rsurfacestate_t::rtlight.
Referenced by R_Q1BSP_DrawLight_TransparentCallback(), R_Shadow_DrawLight(), R_Shadow_DrawLightShadowMaps(), R_Shadow_DrawShadowMaps(), and R_Shadow_RenderMode_End().
Definition at line 1369 of file r_shadow.c.
References CHECKGLERROR, r_refdef_view_t::cullface_back, r_refdef_view_t::cullface_front, GL_BlendFunc(), GL_Color(), GL_DepthMask(), GL_DepthRange(), GL_DepthTest(), GL_DRAW_BUFFER, GL_ONE, GL_PolygonOffset(), GL_READ_BUFFER, GL_Scissor(), GL_ZERO, r_viewport_t::height, r_refdef_t::polygonfactor, r_refdef_t::polygonoffset, R_Mesh_ResetTextureState(), r_refdef, r_shadow_attendividebias, r_shadow_attenlinearscale, r_shadow_cullface_back, r_shadow_cullface_front, r_shadow_lightattenuationdividebias, r_shadow_lightattenuationlinearscale, r_shadow_lightingrendermode, R_Shadow_MakeTextures(), r_shadow_rendermode, R_SHADOW_RENDERMODE_LIGHT_GLSL, R_SHADOW_RENDERMODE_NONE, cvar_t::value, r_refdef_t::view, r_refdef_view_t::viewport, r_viewport_t::width, r_viewport_t::x, and r_viewport_t::y.
Referenced by R_Q1BSP_DrawLight_TransparentCallback(), R_Shadow_DrawLights(), R_Shadow_DrawPrepass(), and R_Shadow_DrawShadowMaps().
Definition at line 1642 of file r_shadow.c.
References bboxelements, bboxpoints, r_refdef_view_t::cullface_back, GL_BlendFunc(), GL_ColorMask(), GL_CullFace(), GL_DepthFunc(), GL_DepthMask(), GL_DepthRange(), GL_DepthTest(), GL_GREATER, GL_ONE, GL_PolygonOffset(), GL_SRC_ALPHA, i, identitymatrix, cvar_t::integer, Matrix4x4_Transform(), rtlight_t::matrix_lighttoworld, NULL, R_EntityMatrix(), R_Mesh_Draw(), R_Mesh_PrepareVertices_Vertex3f(), R_Mesh_SetRenderTargets(), r_refdef, R_SetupShader_DeferredLight(), r_shadow_gloss, r_shadow_lightingrendermode, r_shadow_prepasslightingdiffusefbo, r_shadow_prepasslightingdiffusespecularfbo, r_shadow_rendermode, R_Shadow_RenderMode_Reset(), r_shadow_usingshadowmap2d, rsurface, rsurfacestate_t::rtlight, rtlight_t::specularscale, and r_refdef_t::view.
Referenced by R_Shadow_DrawLight().
Definition at line 2872 of file r_shadow.c.
References GL_DepthMask(), GL_Scissor(), r_viewport_t::height, NULL, r_refdef, r_shadow_rendermode, R_Shadow_RenderMode_ActiveLight(), R_SHADOW_RENDERMODE_NONE, R_Shadow_RenderMode_Reset(), r_refdef_t::view, r_refdef_view_t::viewport, r_viewport_t::width, r_viewport_t::x, and r_viewport_t::y.
Referenced by R_Q1BSP_DrawLight_TransparentCallback(), R_Shadow_DrawLights(), R_Shadow_DrawPrepass(), and R_Shadow_DrawShadowMaps().
void R_Shadow_RenderMode_Lighting | ( | qbool | transparent, |
qbool | shadowmapping, | ||
qbool | noselfshadowpass ) |
Definition at line 1597 of file r_shadow.c.
References r_refdef_view_t::colormask, GL_BlendFunc(), GL_ColorMask(), GL_DepthFunc(), GL_EQUAL, GL_ONE, GL_SRC_ALPHA, r_viewport_t::height, R_Mesh_ResetTextureState(), r_refdef, r_shadow_lightingrendermode, r_shadow_lightscissor, r_shadow_rendermode, R_SHADOW_RENDERMODE_LIGHT_GLSL, R_Shadow_RenderMode_Reset(), R_Shadow_SetShadowmapParametersForLight(), r_shadow_usingshadowmap2d, r_refdef_t::view, r_refdef_view_t::viewport, r_viewport_t::width, r_viewport_t::x, and r_viewport_t::y.
Referenced by R_Q1BSP_DrawLight_TransparentCallback(), and R_Shadow_DrawLight().
Definition at line 1409 of file r_shadow.c.
References CHECKGLERROR, r_refdef_view_t::colormask, r_refdef_view_t::cullface_back, r_refdef_view_t::cullface_front, GL_BlendFunc(), GL_Color(), GL_ColorMask(), GL_CullFace(), GL_DepthFunc(), GL_DepthMask(), GL_DepthRange(), GL_DepthTest(), GL_LEQUAL, GL_ONE, GL_PolygonOffset(), GL_Scissor(), GL_ZERO, r_refdef_t::polygonfactor, r_refdef_t::polygonoffset, R_Mesh_ResetTextureState(), R_Mesh_SetRenderTargets(), r_refdef, R_SetupShader_Generic_NoTexture(), R_SetViewport(), r_shadow_cullface_back, r_shadow_cullface_front, r_shadow_lightscissor, r_shadow_usingshadowmap2d, r_shadow_viewfbo, r_refdef_t::view, and r_refdef_view_t::viewport.
Referenced by R_Shadow_ClearShadowMapTexture(), R_Shadow_RenderMode_DrawDeferredLight(), R_Shadow_RenderMode_End(), R_Shadow_RenderMode_Lighting(), R_Shadow_RenderMode_ShadowMap(), and R_Shadow_RenderMode_VisibleLighting().
Definition at line 1549 of file r_shadow.c.
References r_refdef_view_t::cullface_back, r_refdef_view_t::cullface_front, GL_ColorMask(), GL_CullFace(), GL_DepthMask(), GL_DepthTest(), GL_PolygonOffset(), GL_Scissor(), r_viewport_t::height, rtlight_t::matrix_lighttoworld, NULL, R_Mesh_ResetTextureState(), R_Mesh_SetRenderTargets(), r_refdef, R_SetupShader_DepthOrShadow(), R_SetViewport(), r_shadow_cullface_back, r_shadow_cullface_front, r_shadow_fbo2d, r_shadow_rendermode, R_Shadow_RenderMode_Reset(), R_SHADOW_RENDERMODE_SHADOWMAP2D, r_shadow_shadowmap2ddepthbuffer, r_shadow_shadowmapborder, r_shadow_shadowmapping_nearclip, r_shadow_shadowmapping_polygonfactor, r_shadow_shadowmapping_polygonoffset, r_shadow_shadowmapside, R_Viewport_InitRectSideView(), rtlight_t::radius, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, rsurface, rsurfacestate_t::rtlight, size, cvar_t::value, vid, r_refdef_t::view, r_viewport_t::width, r_viewport_t::x, x, r_viewport_t::y, and y.
Referenced by R_Shadow_DrawLightShadowMaps().
Definition at line 2860 of file r_shadow.c.
References r_refdef_view_t::colorscale, GL_BlendFunc(), GL_Color(), GL_DepthFunc(), GL_DepthRange(), GL_DepthTest(), GL_EQUAL, GL_ONE, cvar_t::integer, r_refdef, r_shadow_rendermode, R_Shadow_RenderMode_Reset(), R_SHADOW_RENDERMODE_VISIBLELIGHTING, r_showlighting, and r_refdef_t::view.
Referenced by R_Shadow_DrawLight().
|
static |
Definition at line 754 of file r_shadow.c.
References maxshadowtriangles, maxshadowvertices, Mem_Alloc, Mem_Free, r_main_mempool, shadowelements, and shadowvertex3f.
Referenced by R_Shadow_ShadowMapFromList().
Definition at line 4932 of file r_shadow.c.
References dlight_t::ambientscale, dlight_t::angles, buf, cl, dlight_t::color, Con_Print(), dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dpsnprintf(), dlight_t::flags, FS_WriteFile(), LIGHTFLAG_REALTIMEMODE, MAX_INPUTLINE, MAX_QPATH, Mem_Alloc, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), Mem_Free, name, NULL, dlight_t::origin, r_shadow_worldlightsarray, dlight_t::radius, dlight_t::shadow, dlight_t::specularscale, strlen(), dlight_t::style, tempmempool, client_state_t::worldmodel, and client_state_t::worldnamenoextension.
Referenced by R_Shadow_EditLights_Save_f().
Definition at line 2900 of file r_shadow.c.
References r_viewport_t::height, cvar_t::integer, maxs, mins, r_refdef, R_ScissorForBBox(), r_shadow_lightscissor, r_shadow_scissor, r_shadow_usingdeferredprepass, r_stat_lights_scissored, r_trippy, r_refdef_t::stats, r_refdef_t::view, r_refdef_view_t::viewport, r_viewport_t::width, r_viewport_t::x, and r_viewport_t::y.
Referenced by R_Shadow_DrawLight(), and R_Shadow_DrawLightShadowMaps().
Definition at line 4700 of file r_shadow.c.
References r_shadow_selectedlight, and dlight_t::selected.
Referenced by R_Shadow_EditLights_EditAll_f(), R_Shadow_SelectLightInView(), and R_Shadow_UpdateWorldLightSelection().
Definition at line 4797 of file r_shadow.c.
References CL_TraceLine(), collision_extendmovelength, DotProduct, r_refdef_view_t::forward, trace_t::fraction, MATERIALFLAGMASK_TRANSLUCENT, Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), MOVE_NORMAL, NULL, dlight_t::origin, r_refdef_view_t::origin, r_editlights_lockcursor, r_refdef, R_Shadow_SelectLight(), r_shadow_worldlightsarray, sqrt(), SUPERCONTENTS_SOLID, cvar_t::value, VectorSubtract, and r_refdef_t::view.
Referenced by R_Shadow_UpdateWorldLightSelection().
Definition at line 5263 of file r_shadow.c.
References CL_TraceLine(), collision_extendmovelength, trace_t::endpos, floor(), r_refdef_view_t::forward, trace_t::fraction, MATERIALFLAGMASK_TRANSLUCENT, MOVE_NORMAL, plane_t::normal, NULL, r_refdef_view_t::origin, trace_t::plane, r_editlights_cursordistance, r_editlights_cursorgrid, r_editlights_cursorlocation, r_editlights_cursorpushback, r_editlights_cursorpushoff, r_refdef, SUPERCONTENTS_SOLID, cvar_t::value, VectorClear, VectorMA, and r_refdef_t::view.
Referenced by R_Shadow_UpdateWorldLightSelection().
Definition at line 1527 of file r_shadow.c.
References r_shadow_lightshadowmap_parameters, r_shadow_lightshadowmap_texturescale, r_shadow_shadowmap2ddepthbuffer, r_shadow_shadowmap2ddepthtexture, r_shadow_shadowmapborder, r_shadow_shadowmapping_bias, r_shadow_shadowmapping_nearclip, r_shadow_shadowmapvsdct, R_TextureHeight(), R_TextureWidth(), rtlight_t::radius, rsurface, rsurfacestate_t::rtlight, rtlight_t::shadowmapatlasposition, rtlight_t::shadowmapatlassidesize, size, and cvar_t::value.
Referenced by R_Shadow_RenderMode_Lighting().
Definition at line 301 of file r_shadow.c.
References viddef_support_t::amd_texture_texture4, viddef_support_t::arb_texture_gather, bound, cmd_local, gl_renderer, gl_vendor, gl_version, cvar_t::integer, viddef_t::maxtexturesize_2d, Mod_AllocLightmap_Init(), R_CompileShader_CheckStaticParms(), r_fb, R_GLSL_Restart_f(), r_main_mempool, r_shadow_deferred, r_shadow_shadowmapatlas_state, r_shadow_shadowmapborder, r_shadow_shadowmapdepthbits, r_shadow_shadowmapdepthtexture, r_shadow_shadowmapfilterquality, r_shadow_shadowmapmaxsize, r_shadow_shadowmappcf, r_shadow_shadowmapping, r_shadow_shadowmapping_bordersize, r_shadow_shadowmapping_depthbits, r_shadow_shadowmapping_filterquality, r_shadow_shadowmapping_maxsize, r_shadow_shadowmapping_texturesize, r_shadow_shadowmapping_useshadowsampler, r_shadow_shadowmapping_vsdct, r_shadow_shadowmapsampler, r_shadow_shadowmapshadowsampler, r_shadow_shadowmaptexturesize, r_shadow_shadowmapvsdct, r_shadow_shadowmode, r_shadow_shadowmode_deferred, R_SHADOW_SHADOWMODE_DISABLED, R_SHADOW_SHADOWMODE_SHADOWMAP2D, r_shadow_shadowmode_shadowmapping, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, viddef_t::support, r_framebufferstate_t::usedepthtextures, and vid.
Referenced by R_Shadow_FreeShadowMaps().
void R_Shadow_SetupEntityLight | ( | const entity_render_t * | ent | ) |
Definition at line 3357 of file r_shadow.c.
References rsurfacestate_t::entitylightorigin, rsurfacestate_t::entitytoattenuationxyz, rsurfacestate_t::entitytoattenuationz, rsurfacestate_t::entitytolight, entity_render_t::inversematrix, entity_render_t::matrix, Matrix4x4_Concat(), Matrix4x4_Transform(), matrix_attenuationxyz, matrix_attenuationz, rtlight_t::matrix_worldtolight, RSurf_ActiveModelEntity(), rsurface, rsurfacestate_t::rtlight, and rtlight_t::shadoworigin.
Referenced by R_Q1BSP_DrawLight_TransparentCallback(), and R_Shadow_DrawEntityLight().
void R_Shadow_ShadowMapFromList | ( | int | numverts, |
int | numtris, | ||
const float * | vertex3f, | ||
const int * | elements, | ||
int | numsidetris, | ||
const int * | sidetotals, | ||
const unsigned char * | sides, | ||
const int * | sidetris ) |
Definition at line 1162 of file r_shadow.c.
References i, maxshadowtriangles, Mod_ShadowMesh_AddMesh(), r_shadow_compilingrtlight, R_Shadow_ResizeShadowArrays(), shadowelements, shadowmesh_t::sideoffsets, shadowmesh_t::sidetotals, and rtlight_t::static_meshchain_shadow_shadowmap.
Referenced by R_Mod_CompileShadowMap().
Definition at line 378 of file r_shadow.c.
References r_shadow_shadowmode, R_SHADOW_SHADOWMODE_DISABLED, and R_SHADOW_SHADOWMODE_SHADOWMAP2D.
Referenced by R_RenderScene(), R_Shadow_DrawShadowMaps(), R_Shadow_PrepareLight(), and R_Shadow_PrepareLights().
Definition at line 503 of file r_shadow.c.
References CHECKGLERROR, maxshadowmark, maxshadowsides, maxshadowtriangles, maxvertexupdate, Mem_Free, NULL, numshadowmark, numshadowsides, R_FreeTexturePool(), r_shadow_attenuationgradienttexture, R_Shadow_BounceGrid_FreeHighPixels(), r_shadow_bouncegrid_state, r_shadow_buffer_leaflist, r_shadow_buffer_leafpvs, r_shadow_buffer_lighttrispvs, r_shadow_buffer_numleafpvsbytes, r_shadow_buffer_numlighttrispvsbytes, r_shadow_buffer_numshadowtrispvsbytes, r_shadow_buffer_numsurfacepvsbytes, r_shadow_buffer_shadowtrispvs, r_shadow_buffer_surfacelist, r_shadow_buffer_surfacepvs, r_shadow_buffer_surfacesides, r_shadow_buffer_visitingleafpvs, r_shadow_filters_texturepool, R_Shadow_FreeDeferred(), R_Shadow_FreeShadowMaps(), r_shadow_prepass_height, r_shadow_prepass_width, r_shadow_scenelightlist, r_shadow_scenemaxlights, r_shadow_scenenumlights, r_shadow_texturepool, r_shadow_usingdeferredprepass, shadowelements, shadowmark, shadowmarkcount, shadowmarklist, shadowsides, shadowsideslist, shadowvertex3f, vertexremap, vertexupdate, and vertexupdatenum.
Referenced by R_Shadow_Init().
Definition at line 416 of file r_shadow.c.
References r_shadow_bouncegrid_state_t::allowdirectionalshading, r_shadow_bouncegrid_state_t::capable, maxshadowmark, maxshadowsides, maxshadowtriangles, maxshadowvertices, maxvertexupdate, NULL, numshadowmark, numshadowsides, r_shadow_attenuationgradienttexture, r_shadow_bouncegrid_state, r_shadow_buffer_leaflist, r_shadow_buffer_leafpvs, r_shadow_buffer_lighttrispvs, r_shadow_buffer_numleafpvsbytes, r_shadow_buffer_numlighttrispvsbytes, r_shadow_buffer_numshadowtrispvsbytes, r_shadow_buffer_numsurfacepvsbytes, r_shadow_buffer_shadowtrispvs, r_shadow_buffer_surfacelist, r_shadow_buffer_surfacepvs, r_shadow_buffer_surfacesides, r_shadow_buffer_visitingleafpvs, r_shadow_fbo2d, r_shadow_filters_texturepool, R_Shadow_FreeShadowMaps(), R_Shadow_MakeTextures(), r_shadow_prepass_height, r_shadow_prepass_width, r_shadow_scenelightlist, r_shadow_scenemaxlights, r_shadow_scenenumlights, r_shadow_shadowmap2ddepthbuffer, r_shadow_shadowmap2ddepthtexture, r_shadow_shadowmapdepthbits, r_shadow_shadowmapfilterquality, r_shadow_shadowmapmaxsize, r_shadow_shadowmappcf, r_shadow_shadowmapsampler, r_shadow_shadowmaptexturesize, r_shadow_shadowmapvsdct, r_shadow_shadowmapvsdcttexture, r_shadow_shadowmode, R_SHADOW_SHADOWMODE_DISABLED, r_shadow_texturepool, r_shadow_usingdeferredprepass, viddef_t::renderpath, RENDERPATH_GL32, RENDERPATH_GLES2, shadowelements, shadowmark, shadowmarkcount, shadowmarklist, shadowsides, shadowsideslist, shadowvertex3f, vertexremap, vertexupdate, vertexupdatenum, and vid.
Referenced by R_Shadow_Init().
Definition at line 3133 of file r_shadow.c.
References Mem_ExpandableArray_IndexRange(), Mem_ExpandableArray_RecordAtIndex(), R_RTLight_Uncompile(), r_shadow_worldlightsarray, and dlight_t::rtlight.
Referenced by R_Shadow_FreeShadowMaps().
Definition at line 2755 of file r_shadow.c.
References r_shadow_bouncegrid_state_t::assignphotons_task, r_shadow_bouncegrid_settings_t::blur, r_shadow_bouncegrid_state_t::blurpixels, r_shadow_bouncegrid_state_t::blurpixels_task, r_shadow_bouncegrid_state_t::cleartex_task, r_shadow_bouncegrid_state_t::directional, r_shadow_bouncegrid_state_t::enqueue_slices_task, r_shadow_bouncegrid_state_t::enqueuephotons_task, r_shadow_bouncegrid_state_t::highpixels, r_shadow_bouncegrid_state_t::highpixels_index, host, r_shadow_bouncegrid_state_t::intensity, r_shadow_bouncegrid_state_t::lastupdatetime, LIGHTFLAG_NORMALMODE, LIGHTFLAG_REALTIMEMODE, r_shadow_bouncegrid_settings_t::maxphotons, Mem_Alloc, NULL, r_shadow_bouncegrid_state_t::numphotons, r_shadow_bouncegrid_state_t::numpixels, r_shadow_bouncegrid_state_t::photons, r_shadow_bouncegrid_state_t::photons_done_task, r_shadow_bouncegrid_state_t::photons_tasks, R_FreeTexture(), r_main_mempool, r_refdef, R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_BounceGrid_BlurPixels_Task(), R_Shadow_BounceGrid_CheckEnable(), R_Shadow_BounceGrid_ClearTex_Task(), R_Shadow_BounceGrid_ConvertPixelsAndUpload(), r_shadow_bouncegrid_dynamic_updateinterval, R_Shadow_BounceGrid_EnqueuePhotons_Task(), R_Shadow_BounceGrid_EnqueueSlices_Task(), R_Shadow_BounceGrid_FreeHighPixels(), R_Shadow_BounceGrid_GenerateSettings(), r_shadow_bouncegrid_intensity, r_shadow_bouncegrid_state, R_Shadow_BounceGrid_UpdateSpacing(), R_TimeReport(), host_static_t::realtime, r_shadow_bouncegrid_state_t::resolution, r_refdef_scene_t::rtworld, r_refdef_t::scene, r_shadow_bouncegrid_state_t::settings, r_shadow_bouncegrid_state_t::slices_done_task, r_shadow_bouncegrid_state_t::slices_tasks, r_shadow_bouncegrid_settings_t::staticmode, TaskQueue_Enqueue(), TaskQueue_Setup(), TaskQueue_WaitForTaskDone(), r_shadow_bouncegrid_state_t::texture, and cvar_t::value.
Referenced by R_RenderView().
|
static |
Definition at line 4639 of file r_shadow.c.
References dlight_t::ambientscale, angles, dlight_t::angles, color, dlight_t::color, dlight_t::corona, dlight_t::coronasizescale, dlight_t::cubemapname, dlight_t::diffusescale, dp_strlcpy, dlight_t::flags, flags, floor(), Matrix4x4_CreateFromQuakeEntity(), max, NULL, dlight_t::origin, origin, R_RTLight_Update(), dlight_t::radius, dlight_t::rtlight, dlight_t::shadow, dlight_t::specularscale, dlight_t::style, style, and VectorCopy.
Referenced by R_Shadow_EditLights_Edit_f(), R_Shadow_EditLights_PasteInfo_f(), R_Shadow_EditLights_Spawn_f(), R_Shadow_EditLights_ToggleCorona_f(), R_Shadow_EditLights_ToggleShadow_f(), R_Shadow_LoadLightsFile(), R_Shadow_LoadWorldLights(), and R_Shadow_LoadWorldLightsFromMap_LightArghliteTyrlite().
Definition at line 5289 of file r_shadow.c.
References cvar_t::integer, NULL, r_editlights, R_Shadow_SelectLight(), R_Shadow_SelectLightInView(), and R_Shadow_SetCursorLocationForView().
Referenced by R_RenderView().
int bboxedges[12][2] |
Definition at line 2881 of file r_shadow.c.
|
static |
Definition at line 1620 of file r_shadow.c.
Referenced by R_Shadow_RenderMode_DrawDeferredLight().
|
static |
Definition at line 1630 of file r_shadow.c.
Referenced by R_Shadow_RenderMode_DrawDeferredLight().
|
extern |
Definition at line 95 of file console.c.
Referenced by Con_DrawConsole().
cvar_t gl_flashblend = {CF_CLIENT | CF_ARCHIVE, "gl_flashblend", "0", "render bright coronas for dynamic lights instead of actual lighting, fast but ugly"} |
Definition at line 236 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_DrawCoronas(), R_Shadow_Init(), R_Shadow_PrepareLights(), and R_UpdateVariables().
|
extern |
Definition at line 233 of file gl_rmain.c.
Referenced by GL_Main_Init(), R_GetCurrentTexture(), and R_SetupShader_Surface().
matrix4x4_t matrix_attenuationxyz |
Definition at line 734 of file r_shadow.c.
Referenced by R_Shadow_DrawWorldLight(), and R_Shadow_SetupEntityLight().
matrix4x4_t matrix_attenuationz |
Definition at line 744 of file r_shadow.c.
Referenced by R_Shadow_DrawWorldLight(), and R_Shadow_SetupEntityLight().
int maxshadowmark |
Definition at line 76 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareShadowMark(), r_shadow_shutdown(), and r_shadow_start().
int maxshadowsides |
Definition at line 82 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareShadowSides(), r_shadow_shutdown(), and r_shadow_start().
int maxshadowtriangles |
Definition at line 70 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_ResizeShadowArrays(), R_Shadow_ShadowMapFromList(), r_shadow_shutdown(), and r_shadow_start().
int maxshadowvertices |
Definition at line 73 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_ResizeShadowArrays(), and r_shadow_start().
int maxvertexupdate |
Definition at line 87 of file r_shadow.c.
Referenced by R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().
int numshadowmark |
Definition at line 77 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareShadowMark(), r_shadow_shutdown(), and r_shadow_start().
int numshadowsides |
Definition at line 83 of file r_shadow.c.
Referenced by R_Mod_CompileShadowMap(), R_Shadow_ChooseSidesFromBox(), R_Shadow_Init(), R_Shadow_PrepareShadowSides(), r_shadow_shutdown(), and r_shadow_start().
cvar_t r_coronas = {CF_CLIENT | CF_ARCHIVE, "r_coronas", "0", "brightness of corona flare effects around certain lights, 0 disables corona effects"} |
Definition at line 233 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_DrawCoronas(), and R_Shadow_Init().
cvar_t r_coronas_occlusionquery = {CF_CLIENT | CF_ARCHIVE, "r_coronas_occlusionquery", "0", "fades coronas according to visibility, requires OpenGL 4.4"} |
Definition at line 235 of file r_shadow.c.
Referenced by R_Shadow_DrawCoronas(), and R_Shadow_Init().
cvar_t r_coronas_occlusionsizescale = {CF_CLIENT | CF_ARCHIVE, "r_coronas_occlusionsizescale", "0.1", "size of light source for corona occlusion checksum the proportion of hidden pixels controls corona intensity"} |
Definition at line 234 of file r_shadow.c.
Referenced by R_Shadow_DrawCoronas(), and R_Shadow_Init().
Definition at line 237 of file r_shadow.c.
Referenced by R_Shadow_EditLights_CopyInfo_f(), R_Shadow_EditLights_DrawSelectedLightProperties(), R_Shadow_EditLights_Edit_f(), R_Shadow_EditLights_EditAll_f(), R_Shadow_EditLights_Init(), R_Shadow_EditLights_Lock_f(), R_Shadow_EditLights_PasteInfo_f(), R_Shadow_EditLights_Remove_f(), R_Shadow_EditLights_Spawn_f(), R_Shadow_EditLights_ToggleCorona_f(), R_Shadow_EditLights_ToggleShadow_f(), R_Shadow_PrepareLights(), and R_Shadow_UpdateWorldLightSelection().
cvar_t r_editlights_current_ambient = {CF_CLIENT, "r_editlights_current_ambient", "0", "ambient intensity of selected light"} |
Definition at line 253 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_angles = {CF_CLIENT, "r_editlights_current_angles", "0 0 0", "angles of selected light"} |
Definition at line 245 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_color = {CF_CLIENT, "r_editlights_current_color", "1 1 1", "color of selected light"} |
Definition at line 246 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_corona = {CF_CLIENT, "r_editlights_current_corona", "0", "corona intensity of selected light"} |
Definition at line 248 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_coronasize = {CF_CLIENT, "r_editlights_current_coronasize", "0", "corona size of selected light"} |
Definition at line 249 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_cubemap = {CF_CLIENT, "r_editlights_current_cubemap", "0", "cubemap of selected light"} |
Definition at line 252 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_diffuse = {CF_CLIENT, "r_editlights_current_diffuse", "1", "diffuse intensity of selected light"} |
Definition at line 254 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_normalmode = {CF_CLIENT, "r_editlights_current_normalmode", "0", "normalmode flag of selected light"} |
Definition at line 256 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_origin = {CF_CLIENT, "r_editlights_current_origin", "0 0 0", "origin of selected light"} |
Definition at line 244 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_radius = {CF_CLIENT, "r_editlights_current_radius", "0", "radius of selected light"} |
Definition at line 247 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_realtimemode = {CF_CLIENT, "r_editlights_current_realtimemode", "0", "realtimemode flag of selected light"} |
Definition at line 257 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_shadows = {CF_CLIENT, "r_editlights_current_shadows", "0", "shadows flag of selected light"} |
Definition at line 251 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_specular = {CF_CLIENT, "r_editlights_current_specular", "1", "specular intensity of selected light"} |
Definition at line 255 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_current_style = {CF_CLIENT, "r_editlights_current_style", "0", "style of selected light"} |
Definition at line 250 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
cvar_t r_editlights_cursordistance = {CF_CLIENT, "r_editlights_cursordistance", "1024", "maximum distance of cursor from eye"} |
Definition at line 238 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Init(), and R_Shadow_SetCursorLocationForView().
cvar_t r_editlights_cursorgrid = {CF_CLIENT, "r_editlights_cursorgrid", "4", "snaps cursor to this grid size"} |
Definition at line 241 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Init(), and R_Shadow_SetCursorLocationForView().
vec3_t r_editlights_cursorlocation |
Definition at line 276 of file r_shadow.c.
Referenced by R_Shadow_DrawCursor_TransparentCallback(), R_Shadow_DrawLightSprites(), R_Shadow_EditLights_DrawSelectedLightProperties(), R_Shadow_EditLights_Spawn_f(), and R_Shadow_SetCursorLocationForView().
cvar_t r_editlights_cursorpushback = {CF_CLIENT, "r_editlights_cursorpushback", "0", "how far to pull the cursor back toward the eye"} |
Definition at line 239 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Init(), and R_Shadow_SetCursorLocationForView().
cvar_t r_editlights_cursorpushoff = {CF_CLIENT, "r_editlights_cursorpushoff", "4", "how far to push the cursor off the impacted surface"} |
Definition at line 240 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Init(), and R_Shadow_SetCursorLocationForView().
cvar_t r_editlights_drawproperties = {CF_CLIENT, "r_editlights_drawproperties", "1", "draw properties of currently selected light"} |
Definition at line 243 of file r_shadow.c.
Referenced by R_Shadow_EditLights_DrawSelectedLightProperties(), and R_Shadow_EditLights_Init().
qbool r_editlights_lockcursor |
Definition at line 277 of file r_shadow.c.
Referenced by R_Shadow_DrawLightSprites(), R_Shadow_EditLights_Lock_f(), and R_Shadow_SelectLightInView().
cvar_t r_editlights_quakelightsizescale = {CF_CLIENT | CF_ARCHIVE, "r_editlights_quakelightsizescale", "1", "changes size of light entities loaded from a map"} |
Definition at line 242 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Init(), and R_Shadow_LoadWorldLightsFromMap_LightArghliteTyrlite().
skinframe_t* r_editlights_sprcubemaplight |
Definition at line 294 of file r_shadow.c.
Referenced by R_Shadow_DrawLightSprite_TransparentCallback(), R_Shadow_MakeTextures(), and r_shadow_newmap().
skinframe_t* r_editlights_sprcubemapnoshadowlight |
Definition at line 295 of file r_shadow.c.
Referenced by R_Shadow_DrawLightSprite_TransparentCallback(), R_Shadow_MakeTextures(), and r_shadow_newmap().
skinframe_t* r_editlights_sprcursor |
Definition at line 291 of file r_shadow.c.
Referenced by R_Shadow_DrawCursor_TransparentCallback(), R_Shadow_MakeTextures(), and r_shadow_newmap().
skinframe_t* r_editlights_sprlight |
Definition at line 292 of file r_shadow.c.
Referenced by R_Shadow_DrawLightSprite_TransparentCallback(), R_Shadow_MakeTextures(), and r_shadow_newmap().
skinframe_t* r_editlights_sprnoshadowlight |
Definition at line 293 of file r_shadow.c.
Referenced by R_Shadow_DrawLightSprite_TransparentCallback(), R_Shadow_MakeTextures(), and r_shadow_newmap().
skinframe_t* r_editlights_sprselection |
Definition at line 296 of file r_shadow.c.
Referenced by R_Shadow_DrawLightSprite_TransparentCallback(), R_Shadow_MakeTextures(), and r_shadow_newmap().
|
static |
Definition at line 268 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures(), and R_Shadow_RenderMode_Begin().
|
static |
Definition at line 269 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures(), and R_Shadow_RenderMode_Begin().
|
static |
Definition at line 270 of file r_shadow.c.
Referenced by R_Shadow_MakeTextures().
rtexture_t* r_shadow_attenuationgradienttexture |
Definition at line 108 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_MakeTextures(), r_shadow_shutdown(), and r_shadow_start().
cvar_t r_shadow_bouncegrid = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid", "0", "perform particle tracing for indirect lighting (Global Illumination / radiosity) using a 3D texture covering the scene, only active on levels with realtime lights active (r_shadow_realtime_world is usually required for these)"} |
Definition at line 198 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_BounceGrid_CheckEnable(), R_Shadow_BounceGrid_GenerateSettings(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_bouncegrid_blur = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_blur", "0", "apply a 1-radius blur on bouncegrid to denoise it and deal with boundary issues with surfaces"} |
Definition at line 199 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_bounceminimumintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_bounceminimumintensity", "0.05", "stop bouncing once intensity drops below this fraction of the original particle color"} |
Definition at line 200 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_culllightpaths = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_culllightpaths", "0", "skip accumulating light in the bouncegrid texture where the light paths are out of view (dynamic mode only)"} |
Definition at line 201 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_TracePhotons_Shot(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_directionalshading = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_directionalshading", "1", "use diffuse shading rather than ambient, 3D texture becomes 8x as many pixels to hold the additional data"} |
Definition at line 202 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_dlightparticlemultiplier = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_dlightparticlemultiplier", "1", "if set to a high value like 16 this can make dlights look great, but 0 is recommended for performance reasons"} |
Definition at line 203 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_hitmodels = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_hitmodels", "0", "enables hitting character model geometry (SLOW)"} |
Definition at line 204 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_lightradiusscale = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_lightradiusscale", "5", "particles stop at this fraction of light radius (can be more than 1)"} |
Definition at line 205 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_maxbounce = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_maxbounce", "5", "maximum number of bounces for a particle (minimum is 0)"} |
Definition at line 206 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_maxphotons = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_maxphotons", "25000", "upper bound on photons to shoot per update, divided proportionately between lights - normally the number of photons is calculated by energyperphoton"} |
Definition at line 207 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_quality = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_quality", "1", "amount of photons that should be fired (this is multiplied by spacing ^ 2 to make it adaptive with spacing changes)"} |
Definition at line 208 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_spacing = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_spacing", "64", "unit size of bouncegrid pixel"} |
Definition at line 209 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_updateinterval = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_updateinterval", "0", "update bouncegrid texture once per this many seconds, useful values are 0, 0.05, or 1000000"} |
Definition at line 210 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_Shadow_UpdateBounceGridTexture().
cvar_t r_shadow_bouncegrid_dynamic_x = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_x", "64", "maximum texture size of bouncegrid on X axis"} |
Definition at line 211 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_UpdateSpacing(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_y = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_y", "64", "maximum texture size of bouncegrid on Y axis"} |
Definition at line 212 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_UpdateSpacing(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_dynamic_z = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_dynamic_z", "32", "maximum texture size of bouncegrid on Z axis"} |
Definition at line 213 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_UpdateSpacing(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_floatcolors = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_floatcolors", "1", "upload texture as RGBA16F (or RGBA32F when set to 2) rather than RGBA8 format - this gives more dynamic range and accuracy"} |
Definition at line 214 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_includedirectlighting = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_includedirectlighting", "0", "allows direct lighting to be recorded, not just indirect (gives an effect somewhat like r_shadow_realtime_world_lightmaps)"} |
Definition at line 215 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_intensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_intensity", "4", "overall brightness of bouncegrid texture"} |
Definition at line 216 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_Shadow_UpdateBounceGridTexture().
cvar_t r_shadow_bouncegrid_lightpathsize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_lightpathsize", "64", "radius (in game units) of the light path for accumulation of light in the bouncegrid texture"} |
Definition at line 217 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_normalizevectors = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_normalizevectors", "1", "normalize random vectors (otherwise their length can vary, which dims the lighting further from the light)"} |
Definition at line 218 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_particlebounceintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_particlebounceintensity", "4", "amount of energy carried over after each bounce, this is a multiplier of texture color and the result is clamped to 1 or less, to prevent adding energy on each bounce"} |
Definition at line 219 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_particleintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_particleintensity", "1", "brightness of particles contributing to bouncegrid texture"} |
Definition at line 220 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_rng_seed = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_rng_seed", "0", "0+ = use this number as RNG seed, -1 = use time instead for disco-like craziness in dynamic mode"} |
Definition at line 221 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_rng_type = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_rng_type", "0", "0 = Lehmer 128bit RNG (slow but high quality), 1 = lhcheeserand 32bit RNG (quick)"} |
Definition at line 222 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
r_shadow_bouncegrid_state_t r_shadow_bouncegrid_state |
Definition at line 259 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_BounceGrid_BlurPixels_Task(), R_Shadow_BounceGrid_BlurPixelsInDirection(), R_Shadow_BounceGrid_CheckEnable(), R_Shadow_BounceGrid_ClearTex_Task(), R_Shadow_BounceGrid_ConvertPixelsAndUpload(), R_Shadow_BounceGrid_EnqueuePhotons_Task(), R_Shadow_BounceGrid_EnqueueSlices_Task(), R_Shadow_BounceGrid_FreeHighPixels(), R_Shadow_BounceGrid_GenerateSettings(), R_Shadow_BounceGrid_RefractiveIndexAtPoint(), R_Shadow_BounceGrid_Slice(), R_Shadow_BounceGrid_TracePhotons_Shot(), R_Shadow_BounceGrid_TracePhotons_ShotTask(), R_Shadow_BounceGrid_UpdateSpacing(), r_shadow_newmap(), r_shadow_shutdown(), r_shadow_start(), and R_Shadow_UpdateBounceGridTexture().
cvar_t r_shadow_bouncegrid_static = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static", "1", "use static radiosity solution (high quality) rather than dynamic (splotchy)"} |
Definition at line 223 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_CheckEnable(), R_Shadow_BounceGrid_GenerateSettings(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_bouncegrid_static_bounceminimumintensity = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_bounceminimumintensity", "0.01", "stop bouncing once intensity drops below this fraction of the original particle color"} |
Definition at line 224 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_static_directionalshading = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_directionalshading", "1", "whether to use directionalshading when in static mode"} |
Definition at line 225 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_static_lightradiusscale = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_lightradiusscale", "5", "particles stop at this fraction of light radius (can be more than 1) when in static mode"} |
Definition at line 226 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_static_maxbounce = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_maxbounce", "5", "maximum number of bounces for a particle (minimum is 0) in static mode"} |
Definition at line 227 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_static_maxphotons = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_maxphotons", "250000", "upper bound on photons in static mode"} |
Definition at line 228 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_static_quality = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_quality", "16", "amount of photons that should be fired (this is multiplied by spacing ^ 2 to make it adaptive with spacing changes)"} |
Definition at line 229 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_static_spacing = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_static_spacing", "64", "unit size of bouncegrid pixel when in static mode"} |
Definition at line 230 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_subsamples = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_subsamples", "1", "when generating the texture, sample this many points along each dimension (multisampling uses more compute but not more memory bandwidth)"} |
Definition at line 231 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_GenerateSettings(), and R_Shadow_Init().
cvar_t r_shadow_bouncegrid_threaded = {CF_CLIENT | CF_ARCHIVE, "r_shadow_bouncegrid_threaded", "1", "enables use of taskqueue_maxthreads to perform the traces and slice rendering of bouncegrid"} |
Definition at line 232 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_EnqueuePhotons_Task(), R_Shadow_BounceGrid_TracePhotons_Shot(), and R_Shadow_Init().
int* r_shadow_buffer_leaflist |
Definition at line 95 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* r_shadow_buffer_leafpvs |
Definition at line 94 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* r_shadow_buffer_lighttrispvs |
Definition at line 105 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_buffer_numleafpvsbytes |
Definition at line 92 of file r_shadow.c.
Referenced by R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_buffer_numlighttrispvsbytes |
Definition at line 104 of file r_shadow.c.
Referenced by R_Shadow_EnlargeLeafSurfaceTrisBuffer(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_buffer_numshadowtrispvsbytes |
Definition at line 102 of file r_shadow.c.
Referenced by R_Shadow_EnlargeLeafSurfaceTrisBuffer(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_buffer_numsurfacepvsbytes |
Definition at line 97 of file r_shadow.c.
Referenced by R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* r_shadow_buffer_shadowtrispvs |
Definition at line 103 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
int* r_shadow_buffer_surfacelist |
Definition at line 99 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* r_shadow_buffer_surfacepvs |
Definition at line 98 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* r_shadow_buffer_surfacesides |
Definition at line 100 of file r_shadow.c.
Referenced by R_Shadow_DrawLightShadowMaps(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* r_shadow_buffer_visitingleafpvs |
Definition at line 93 of file r_shadow.c.
Referenced by R_RTLight_Compile(), R_Shadow_EnlargeLeafSurfaceTrisBuffer(), R_Shadow_Init(), R_Shadow_PrepareLight(), r_shadow_shutdown(), and r_shadow_start().
dlight_t r_shadow_bufferlight |
Definition at line 275 of file r_shadow.c.
Referenced by R_Shadow_EditLights_CopyInfo_f(), and R_Shadow_EditLights_PasteInfo_f().
cvar_t r_shadow_bumpscale_basetexture = {CF_CLIENT, "r_shadow_bumpscale_basetexture", "0", "generate fake bumpmaps from diffuse textures at this bumpyness, try 4 to match tenebrae, higher values increase depth, requires r_restart to take effect"} |
Definition at line 141 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_SkinFrame_GenerateTexturesFromQPixels(), R_SkinFrame_LoadExternal_SkinFrame(), R_SkinFrame_LoadInternalBGRA(), and R_SkinFrame_LoadInternalQuake().
cvar_t r_shadow_bumpscale_bumpmap = {CF_CLIENT, "r_shadow_bumpscale_bumpmap", "4", "what magnitude to interpret _bump.tga textures as, higher values increase depth, requires r_restart to take effect"} |
Definition at line 142 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_SkinFrame_LoadExternal_SkinFrame().
rtlight_t* r_shadow_compilingrtlight |
Definition at line 272 of file r_shadow.c.
Referenced by R_Mod_CompileShadowMap(), R_Mod_GetLightInfo(), R_Q1BSP_RecursiveGetLightInfo_BIH(), R_Q1BSP_RecursiveGetLightInfo_BSP(), R_RTLight_Compile(), and R_Shadow_ShadowMapFromList().
int r_shadow_cullface_back |
Definition at line 48 of file r_shadow.c.
Referenced by R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_Reset(), and R_Shadow_RenderMode_ShadowMap().
int r_shadow_cullface_front |
Definition at line 48 of file r_shadow.c.
Referenced by R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_Reset(), and R_Shadow_RenderMode_ShadowMap().
cvar_t r_shadow_culllights_pvs = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_pvs", "1", "check if light overlaps any visible bsp leafs when determining if the light is visible"} |
Definition at line 189 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace", "1", "use raytraces from the eye to random places within light bounds to determine if the light is visible"} |
Definition at line 190 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_delay = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_delay", "1", "light will be considered visible for this many seconds after any trace connects"} |
Definition at line 197 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_enlarge = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_enlarge", "0", "make light bounds bigger by *(1.0+enlarge)"} |
Definition at line 192 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_expand = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_expand", "8", "make light bounds bigger by this many units"} |
Definition at line 193 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_eyejitter = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_eyejitter", "16", "offset eye location randomly by this much"} |
Definition at line 191 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_pad = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_pad", "8", "accept traces that hit within this many units of the light bounds"} |
Definition at line 194 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_samples = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_samples", "16", "use this many traces to random positions (in addition to center trace)"} |
Definition at line 195 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_culllights_trace_tempsamples = {CF_CLIENT | CF_ARCHIVE, "r_shadow_culllights_trace_tempsamples", "16", "use this many traces if the light was created by csqc (no inter-frame caching), -1 disables the check (to avoid flicker entirely)"} |
Definition at line 196 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_debuglight = {CF_CLIENT, "r_shadow_debuglight", "-1", "renders only one light, for level design purposes or debugging"} |
Definition at line 143 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_DrawCoronas(), R_Shadow_Init(), and R_Shadow_PrepareLights().
cvar_t r_shadow_deferred = {CF_CLIENT | CF_ARCHIVE, "r_shadow_deferred", "0", "uses image-based lighting instead of geometry-based lighting, the method used renders a depth image and a normalmap image, renders lights into separate diffuse and specular images, and then combines this into the normal rendering, requires r_shadow_shadowmapping"} |
Definition at line 144 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
GLuint r_shadow_fbo2d |
Definition at line 49 of file r_shadow.c.
Referenced by R_Shadow_ClearShadowMapTexture(), R_Shadow_FreeShadowMaps(), R_Shadow_MakeShadowMap(), R_Shadow_RenderMode_ShadowMap(), and r_shadow_start().
rtexturepool_t* r_shadow_filters_texturepool |
Definition at line 139 of file r_shadow.c.
Referenced by r_shadow_shutdown(), and r_shadow_start().
cvar_t r_shadow_frontsidecasting = {CF_CLIENT, "r_shadow_frontsidecasting", "1", "whether to cast shadows from illuminated triangles (front side of model) or unlit triangles (back side of model)"} |
Definition at line 158 of file r_shadow.c.
Referenced by R_Mod_GetLightInfo(), R_Shadow_ChooseSidesFromBox(), R_Shadow_Init(), and R_UpdateVariables().
cvar_t r_shadow_gloss = {CF_CLIENT | CF_ARCHIVE, "r_shadow_gloss", "1", "0 disables gloss (specularity) rendering, 1 uses gloss if textures are found, 2 forces a flat metallic specular effect on everything without textures (similar to tenebrae)"} |
Definition at line 147 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_GetCurrentTexture(), R_SetupShader_DeferredLight(), R_Shadow_Init(), and R_Shadow_RenderMode_DrawDeferredLight().
cvar_t r_shadow_gloss2exponent = {CF_CLIENT, "r_shadow_gloss2exponent", "32", "same as r_shadow_glossexponent but for forced gloss (gloss 2) surfaces"} |
Definition at line 151 of file r_shadow.c.
Referenced by R_GetCurrentTexture(), R_SetupShader_DeferredLight(), and R_Shadow_Init().
cvar_t r_shadow_gloss2intensity = {CF_CLIENT, "r_shadow_gloss2intensity", "0.125", "how bright the forced flat gloss should look if r_shadow_gloss is 2"} |
Definition at line 148 of file r_shadow.c.
Referenced by R_GetCurrentTexture(), and R_Shadow_Init().
cvar_t r_shadow_glossexact = {CF_CLIENT, "r_shadow_glossexact", "0", "use exact reflection math for gloss (slightly slower, but should look a tad better)"} |
Definition at line 152 of file r_shadow.c.
Referenced by R_CompileShader_CheckStaticParms(), R_SetupShader_DeferredLight(), R_SetupShader_Surface(), and R_Shadow_Init().
cvar_t r_shadow_glossexponent = {CF_CLIENT, "r_shadow_glossexponent", "32", "how 'sharp' the gloss should appear (specular power)"} |
Definition at line 150 of file r_shadow.c.
Referenced by R_GetCurrentTexture(), R_SetupShader_DeferredLight(), and R_Shadow_Init().
cvar_t r_shadow_glossintensity = {CF_CLIENT, "r_shadow_glossintensity", "1", "how bright textured glossmaps should look if r_shadow_gloss is 1 or 2"} |
Definition at line 149 of file r_shadow.c.
Referenced by R_GetCurrentTexture(), and R_Shadow_Init().
cvar_t r_shadow_lightattenuationdividebias = {CF_CLIENT, "r_shadow_lightattenuationdividebias", "1", "changes attenuation texture generation"} |
Definition at line 153 of file r_shadow.c.
Referenced by Mod_GenerateLightmaps_LightPoint(), Mod_GenerateLightmaps_SamplePoint(), R_CompleteLightPoint(), R_Shadow_Init(), R_Shadow_MakeTextures(), R_Shadow_MakeTextures_SamplePoint(), and R_Shadow_RenderMode_Begin().
cvar_t r_shadow_lightattenuationlinearscale = {CF_CLIENT, "r_shadow_lightattenuationlinearscale", "2", "changes attenuation texture generation"} |
Definition at line 154 of file r_shadow.c.
Referenced by Mod_GenerateLightmaps_LightPoint(), Mod_GenerateLightmaps_SamplePoint(), R_CompleteLightPoint(), R_Shadow_Init(), R_Shadow_MakeTextures(), R_Shadow_MakeTextures_SamplePoint(), and R_Shadow_RenderMode_Begin().
skinframe_t* r_shadow_lightcorona |
Definition at line 109 of file r_shadow.c.
Referenced by R_DrawCorona(), R_Shadow_MakeTextures_MakeCorona(), and r_shadow_newmap().
r_shadow_rendermode_t r_shadow_lightingrendermode = R_SHADOW_RENDERMODE_NONE |
Definition at line 33 of file r_shadow.c.
Referenced by R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_DrawDeferredLight(), and R_Shadow_RenderMode_Lighting().
cvar_t r_shadow_lightintensityscale = {CF_CLIENT, "r_shadow_lightintensityscale", "1", "renders all world lights brighter or darker"} |
Definition at line 155 of file r_shadow.c.
Referenced by R_CompleteLightPoint(), R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_Init(), R_Shadow_PrepareLight(), and R_Shadow_PrepareLights().
cvar_t r_shadow_lightradiusscale = {CF_CLIENT, "r_shadow_lightradiusscale", "1", "renders all world lights larger or smaller"} |
int r_shadow_lightscissor[4] |
Definition at line 63 of file r_shadow.c.
Referenced by R_Shadow_RenderMode_Lighting(), R_Shadow_RenderMode_Reset(), and R_Shadow_ScissorForBBox().
float r_shadow_lightshadowmap_parameters[4] |
Definition at line 41 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), and R_Shadow_SetShadowmapParametersForLight().
float r_shadow_lightshadowmap_texturescale[4] |
Definition at line 40 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), and R_Shadow_SetShadowmapParametersForLight().
char r_shadow_mapname[MAX_QPATH] |
Definition at line 133 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Reload_f(), and r_shadow_newmap().
float r_shadow_modelshadowmap_parameters[4] |
Definition at line 43 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), and R_Shadow_DrawModelShadowMaps().
float r_shadow_modelshadowmap_texturescale[4] |
Definition at line 42 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), and R_Shadow_DrawModelShadowMaps().
|
static |
Definition at line 4240 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), and R_Shadow_PrepareModelShadows().
|
static |
Definition at line 4239 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), and R_Shadow_PrepareModelShadows().
unsigned int r_shadow_occlusion_buf = 0 |
Definition at line 136 of file r_shadow.c.
Referenced by gl_main_shutdown(), and R_DrawCorona().
int r_shadow_prepass_height |
Definition at line 118 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_prepass_width |
Definition at line 117 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), r_shadow_shutdown(), and r_shadow_start().
rtexture_t* r_shadow_prepassgeometrydepthbuffer |
Definition at line 119 of file r_shadow.c.
Referenced by R_Shadow_FreeDeferred(), and R_Shadow_PrepareLights().
GLuint r_shadow_prepassgeometryfbo |
Definition at line 114 of file r_shadow.c.
Referenced by R_Shadow_DrawPrepass(), R_Shadow_FreeDeferred(), and R_Shadow_PrepareLights().
rtexture_t* r_shadow_prepassgeometrynormalmaptexture |
Definition at line 120 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_FreeDeferred(), and R_Shadow_PrepareLights().
GLuint r_shadow_prepasslightingdiffusefbo |
Definition at line 116 of file r_shadow.c.
Referenced by R_Shadow_FreeDeferred(), R_Shadow_PrepareLights(), and R_Shadow_RenderMode_DrawDeferredLight().
GLuint r_shadow_prepasslightingdiffusespecularfbo |
Definition at line 115 of file r_shadow.c.
Referenced by R_Shadow_DrawPrepass(), R_Shadow_FreeDeferred(), R_Shadow_PrepareLights(), and R_Shadow_RenderMode_DrawDeferredLight().
rtexture_t* r_shadow_prepasslightingdiffusetexture |
Definition at line 121 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), R_Shadow_FreeDeferred(), and R_Shadow_PrepareLights().
rtexture_t* r_shadow_prepasslightingspeculartexture |
Definition at line 122 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), R_Shadow_FreeDeferred(), and R_Shadow_PrepareLights().
cvar_t r_shadow_projectdistance = {CF_CLIENT, "r_shadow_projectdistance", "0", "how far to cast shadows"} |
cvar_t r_shadow_realtime_dlight = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_dlight", "1", "enables rendering of dynamic lights such as explosions and rocket light"} |
Definition at line 159 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_Init(), R_UpdateVariables(), and R_Water_ProcessPlanes().
cvar_t r_shadow_realtime_dlight_portalculling = {CF_CLIENT, "r_shadow_realtime_dlight_portalculling", "0", "enables portal optimization on dynamic lights (slow!)"} |
Definition at line 162 of file r_shadow.c.
Referenced by R_Mod_GetLightInfo(), and R_Shadow_Init().
cvar_t r_shadow_realtime_dlight_shadows = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_dlight_shadows", "1", "enables rendering of shadows from dynamic lights"} |
Definition at line 160 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_Init(), and R_UpdateVariables().
cvar_t r_shadow_realtime_dlight_svbspculling = {CF_CLIENT, "r_shadow_realtime_dlight_svbspculling", "0", "enables svbsp optimization on dynamic lights (very slow!)"} |
Definition at line 161 of file r_shadow.c.
Referenced by R_Mod_GetLightInfo(), and R_Shadow_Init().
cvar_t r_shadow_realtime_world = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_world", "0", "enables rendering of full world lighting (whether loaded from the map, or a .rtlights file, or a .ent file, or a .lights file produced by hlight)"} |
Definition at line 163 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_Init(), R_UpdateVariables(), and R_Water_ProcessPlanes().
cvar_t r_shadow_realtime_world_compile = {CF_CLIENT, "r_shadow_realtime_world_compile", "1", "enables compilation of world lights for higher performance rendering"} |
Definition at line 167 of file r_shadow.c.
Referenced by R_Shadow_DrawLightShadowMaps(), R_Shadow_DrawWorldShadow_ShadowMap(), R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_realtime_world_compileportalculling = {CF_CLIENT, "r_shadow_realtime_world_compileportalculling", "1", "enables portal-based culling optimization during compilation (overrides compilesvbsp)"} |
Definition at line 170 of file r_shadow.c.
Referenced by R_Mod_GetLightInfo(), and R_Shadow_Init().
cvar_t r_shadow_realtime_world_compileshadow = {CF_CLIENT, "r_shadow_realtime_world_compileshadow", "1", "enables compilation of shadows from world lights for higher performance rendering"} |
Definition at line 168 of file r_shadow.c.
Referenced by R_Shadow_DrawLightShadowMaps(), R_Shadow_DrawWorldShadow_ShadowMap(), and R_Shadow_Init().
cvar_t r_shadow_realtime_world_compilesvbsp = {CF_CLIENT, "r_shadow_realtime_world_compilesvbsp", "1", "enables svbsp optimization during compilation (slower than compileportalculling but more exact)"} |
Definition at line 169 of file r_shadow.c.
Referenced by R_Mod_GetLightInfo(), and R_Shadow_Init().
cvar_t r_shadow_realtime_world_importlightentitiesfrommap = {CF_CLIENT, "r_shadow_realtime_world_importlightentitiesfrommap", "1", "load lights from .ent file or map entities at startup if no .rtlights or .lights file is present (if set to 2, always use the .ent or map entities)"} |
Definition at line 164 of file r_shadow.c.
Referenced by R_Shadow_EditLights_Reload_f(), and R_Shadow_Init().
cvar_t r_shadow_realtime_world_lightmaps = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_world_lightmaps", "0", "brightness to render lightmaps when using full world lighting, try 0.5 for a tenebrae-like appearance"} |
Definition at line 165 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_Init(), and R_UpdateVariables().
cvar_t r_shadow_realtime_world_shadows = {CF_CLIENT | CF_ARCHIVE, "r_shadow_realtime_world_shadows", "1", "enables rendering of shadows from world lights"} |
Definition at line 166 of file r_shadow.c.
Referenced by M_Menu_Options_Graphics_AdjustSliders(), M_Options_Graphics_Draw(), R_Shadow_Init(), and R_UpdateVariables().
r_shadow_rendermode_t r_shadow_rendermode = R_SHADOW_RENDERMODE_NONE |
Definition at line 32 of file r_shadow.c.
Referenced by R_Shadow_ClearShadowMapTexture(), R_Shadow_RenderLighting(), R_Shadow_RenderMode_Begin(), R_Shadow_RenderMode_DrawDeferredLight(), R_Shadow_RenderMode_End(), R_Shadow_RenderMode_Lighting(), R_Shadow_RenderMode_ShadowMap(), and R_Shadow_RenderMode_VisibleLighting().
rtlight_t** r_shadow_scenelightlist |
Definition at line 36 of file r_shadow.c.
Referenced by R_Shadow_DrawLights(), R_Shadow_DrawPrepass(), R_Shadow_DrawShadowMaps(), R_Shadow_Init(), R_Shadow_PrepareLights(), R_Shadow_PrepareLights_AddSceneLight(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_scenemaxlights |
Definition at line 34 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights_AddSceneLight(), r_shadow_shutdown(), and r_shadow_start().
int r_shadow_scenenumlights |
Definition at line 35 of file r_shadow.c.
Referenced by R_Shadow_DrawLights(), R_Shadow_DrawPrepass(), R_Shadow_DrawShadowMaps(), R_Shadow_Init(), R_Shadow_PrepareLights(), R_Shadow_PrepareLights_AddSceneLight(), r_shadow_shutdown(), and r_shadow_start().
cvar_t r_shadow_scissor = {CF_CLIENT, "r_shadow_scissor", "1", "use scissor optimization of light rendering (restricts rendering to the portion of the screen affected by the light)"} |
Definition at line 171 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_Shadow_ScissorForBBox().
dlight_t* r_shadow_selectedlight |
Definition at line 274 of file r_shadow.c.
Referenced by R_Shadow_ClearWorldLights(), R_Shadow_EditLights_CopyInfo_f(), R_Shadow_EditLights_DrawSelectedLightProperties(), R_Shadow_EditLights_Edit_f(), R_Shadow_EditLights_EditAll_f(), R_Shadow_EditLights_Lock_f(), R_Shadow_EditLights_PasteInfo_f(), R_Shadow_EditLights_Remove_f(), R_Shadow_EditLights_ToggleCorona_f(), R_Shadow_EditLights_ToggleShadow_f(), R_Shadow_FreeWorldLight(), and R_Shadow_SelectLight().
rtexture_t* r_shadow_shadowmap2ddepthbuffer |
Definition at line 110 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_ClearShadowMapTexture(), R_Shadow_FreeShadowMaps(), R_Shadow_MakeShadowMap(), R_Shadow_RenderMode_ShadowMap(), R_Shadow_SetShadowmapParametersForLight(), and r_shadow_start().
rtexture_t* r_shadow_shadowmap2ddepthtexture |
Definition at line 111 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_ClearShadowMapTexture(), R_Shadow_FreeShadowMaps(), R_Shadow_MakeShadowMap(), R_Shadow_SetShadowmapParametersForLight(), and r_shadow_start().
int r_shadow_shadowmapatlas_modelshadows_size |
Definition at line 69 of file r_shadow.c.
Referenced by R_RenderScene(), R_Shadow_DrawModelShadowMaps(), R_Shadow_DrawShadowMaps(), R_Shadow_PrepareLights(), and R_Shadow_PrepareModelShadows().
int r_shadow_shadowmapatlas_modelshadows_x |
Definition at line 67 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), R_Shadow_PrepareLights(), and R_Shadow_PrepareModelShadows().
int r_shadow_shadowmapatlas_modelshadows_y |
Definition at line 68 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), R_Shadow_PrepareLights(), and R_Shadow_PrepareModelShadows().
mod_alloclightmap_state_t r_shadow_shadowmapatlas_state |
Definition at line 66 of file r_shadow.c.
Referenced by R_Shadow_FreeShadowMaps(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
int r_shadow_shadowmapborder |
Definition at line 61 of file r_shadow.c.
Referenced by R_Shadow_ChooseSidesFromBox(), R_Shadow_DrawLightShadowMaps(), R_Shadow_DrawModelShadowMaps(), R_Shadow_PrepareLight(), R_Shadow_PrepareLights(), R_Shadow_RenderMode_ShadowMap(), R_Shadow_SetShadowmapParametersForLight(), and R_Shadow_SetShadowMode().
int r_shadow_shadowmapdepthbits |
Definition at line 54 of file r_shadow.c.
Referenced by R_Shadow_MakeShadowMap(), R_Shadow_PrepareLights(), R_Shadow_SetShadowMode(), and r_shadow_start().
qbool r_shadow_shadowmapdepthtexture |
Definition at line 65 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
int r_shadow_shadowmapfilterquality |
Definition at line 53 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), R_Shadow_SetShadowMode(), and r_shadow_start().
matrix4x4_t r_shadow_shadowmapmatrix |
Definition at line 62 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), and R_Shadow_DrawModelShadowMaps().
int r_shadow_shadowmapmaxsize |
Definition at line 55 of file r_shadow.c.
Referenced by R_Shadow_ChooseSidesFromBox(), R_Shadow_PrepareLight(), R_Shadow_PrepareLights(), R_Shadow_SetShadowMode(), and r_shadow_start().
int r_shadow_shadowmappcf |
Definition at line 60 of file r_shadow.c.
Referenced by R_CompileShader_CheckStaticParms(), R_Shadow_SetShadowMode(), and r_shadow_start().
cvar_t r_shadow_shadowmapping = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping", "1", "enables use of shadowmapping (shadow rendering by depth texture sampling)"} |
Definition at line 172 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_bias = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_bias", "0.03", "shadowmap bias parameter (this is multiplied by nearclip * 1024 / lodsize)"} |
Definition at line 185 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), R_Shadow_Init(), and R_Shadow_SetShadowmapParametersForLight().
cvar_t r_shadow_shadowmapping_bordersize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_bordersize", "5", "shadowmap size bias for filtering"} |
Definition at line 183 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_depthbits = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_depthbits", "24", "requested minimum shadowmap texture depth bits"} |
Definition at line 175 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_filterquality = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_filterquality", "-1", "shadowmap filter modes: -1 = auto-select, 0 = no filtering, 1 = bilinear, 2 = bilinear 2x2 blur (fast), 3 = 3x3 blur (moderate), 4 = 4x4 blur (slow)"} |
Definition at line 173 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_maxsize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_maxsize", "512", "limit of shadowmap side size - can not be more than 1/8th of atlassize because lights store 6 sides (2x3 grid) and sometimes 12 sides (4x3 grid for shadows from EF_NOSELFSHADOW entities) and there are multiple lights..."} |
Definition at line 178 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_minsize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_minsize", "32", "limit of shadowmap side size - must be at least r_shadow_shadowmapping_bordersize+2"} |
Definition at line 177 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_Shadow_PrepareLight().
cvar_t r_shadow_shadowmapping_nearclip = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_nearclip", "1", "shadowmap nearclip in world units"} |
Definition at line 184 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), R_Shadow_Init(), R_Shadow_RenderMode_ShadowMap(), and R_Shadow_SetShadowmapParametersForLight().
cvar_t r_shadow_shadowmapping_polygonfactor = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_polygonfactor", "2", "slope-dependent shadowmapping bias"} |
Definition at line 186 of file r_shadow.c.
Referenced by R_Shadow_ClearShadowMapTexture(), R_Shadow_Init(), and R_Shadow_RenderMode_ShadowMap().
cvar_t r_shadow_shadowmapping_polygonoffset = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_polygonoffset", "0", "constant shadowmapping bias"} |
Definition at line 187 of file r_shadow.c.
Referenced by R_Shadow_ClearShadowMapTexture(), R_Shadow_Init(), and R_Shadow_RenderMode_ShadowMap().
cvar_t r_shadow_shadowmapping_precision = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_precision", "1", "makes shadowmaps have a maximum resolution of this number of pixels per light source radius unit such that, for example, at precision 0.5 a light with radius 200 will have a maximum resolution of 100 pixels"} |
Definition at line 180 of file r_shadow.c.
Referenced by R_Shadow_DrawModelShadowMaps(), R_Shadow_Init(), R_Shadow_PrepareLight(), and R_Shadow_PrepareModelShadows().
cvar_t r_shadow_shadowmapping_texturesize = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_texturesize", "8192", "size of shadowmap atlas texture - all shadowmaps are packed into this texture at frame start"} |
Definition at line 179 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_useshadowsampler = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_useshadowsampler", "1", "whether to use sampler2DShadow if available"} |
Definition at line 174 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_shadowmapping_vsdct = {CF_CLIENT | CF_ARCHIVE, "r_shadow_shadowmapping_vsdct", "1", "enables use of virtual shadow depth cube texture"} |
Definition at line 176 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
qbool r_shadow_shadowmapsampler |
Definition at line 58 of file r_shadow.c.
Referenced by R_CompileShader_CheckStaticParms(), R_Shadow_MakeShadowMap(), R_Shadow_SetShadowMode(), and r_shadow_start().
qbool r_shadow_shadowmapshadowsampler |
Definition at line 59 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
int r_shadow_shadowmapside |
Definition at line 39 of file r_shadow.c.
Referenced by R_Shadow_DrawEntityShadow(), R_Shadow_DrawWorldShadow_ShadowMap(), and R_Shadow_RenderMode_ShadowMap().
int r_shadow_shadowmaptexturesize |
Definition at line 56 of file r_shadow.c.
Referenced by R_Shadow_ClearShadowMapTexture(), R_Shadow_DrawModelShadowMaps(), R_Shadow_PrepareLights(), R_Shadow_PrepareModelShadows(), R_Shadow_SetShadowMode(), and r_shadow_start().
qbool r_shadow_shadowmapvsdct |
Definition at line 57 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_ClearShadowMapTexture(), R_Shadow_PrepareLights(), R_Shadow_SetShadowmapParametersForLight(), R_Shadow_SetShadowMode(), and r_shadow_start().
rtexture_t* r_shadow_shadowmapvsdcttexture |
Definition at line 112 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_ClearShadowMapTexture(), R_Shadow_FreeShadowMaps(), R_Shadow_MakeVSDCT(), and r_shadow_start().
r_shadow_shadowmode_t r_shadow_shadowmode |
Definition at line 52 of file r_shadow.c.
Referenced by R_Shadow_DrawLight(), R_Shadow_MakeShadowMap(), R_Shadow_SetShadowMode(), R_Shadow_ShadowMappingEnabled(), and r_shadow_start().
int r_shadow_shadowmode_deferred |
Definition at line 51 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
int r_shadow_shadowmode_shadowmapping |
Definition at line 50 of file r_shadow.c.
Referenced by R_Shadow_PrepareLights(), and R_Shadow_SetShadowMode().
cvar_t r_shadow_sortsurfaces = {CF_CLIENT, "r_shadow_sortsurfaces", "1", "improve performance by sorting illuminated surfaces by texture"} |
Definition at line 188 of file r_shadow.c.
Referenced by R_Mod_GetLightInfo(), and R_Shadow_Init().
rtexturepool_t* r_shadow_texturepool |
Definition at line 107 of file r_shadow.c.
Referenced by R_Shadow_BounceGrid_ConvertPixelsAndUpload(), R_Shadow_MakeShadowMap(), R_Shadow_MakeTextures(), R_Shadow_MakeVSDCT(), R_Shadow_PrepareLights(), r_shadow_shutdown(), and r_shadow_start().
cvar_t r_shadow_usebihculling = {CF_CLIENT, "r_shadow_usebihculling", "1", "use BIH (Bounding Interval Hierarchy) for culling lit surfaces instead of BSP (Binary Space Partitioning)"} |
Definition at line 145 of file r_shadow.c.
Referenced by R_Q1BSP_CallRecursiveGetLightInfo(), and R_Shadow_Init().
cvar_t r_shadow_usenormalmap = {CF_CLIENT | CF_ARCHIVE, "r_shadow_usenormalmap", "1", "enables use of directional shading on lights"} |
Definition at line 146 of file r_shadow.c.
Referenced by R_Shadow_Init(), and R_Shadow_RenderLighting().
qbool r_shadow_usingdeferredprepass |
Definition at line 64 of file r_shadow.c.
Referenced by R_Mod_DrawLight(), R_ProcessModelTextureSurfaceList(), R_RenderScene(), R_SetupShader_Surface(), R_Shadow_DrawLight(), R_Shadow_PrepareLight(), R_Shadow_PrepareLights(), R_Shadow_ScissorForBBox(), r_shadow_shutdown(), and r_shadow_start().
qbool r_shadow_usingshadowmap2d |
Definition at line 37 of file r_shadow.c.
Referenced by R_SetupShader_DeferredLight(), R_SetupShader_Surface(), R_Shadow_RenderMode_DrawDeferredLight(), R_Shadow_RenderMode_Lighting(), and R_Shadow_RenderMode_Reset().
qbool r_shadow_usingshadowmaportho |
Definition at line 38 of file r_shadow.c.
Referenced by R_SetupShader_Surface(), R_Shadow_DrawModelShadowMaps(), and R_Shadow_PrepareLights().
rtexture_t* r_shadow_viewcolortexture |
Definition at line 126 of file r_shadow.c.
Referenced by R_RenderScene().
rtexture_t* r_shadow_viewdepthtexture |
Definition at line 125 of file r_shadow.c.
Referenced by R_RenderScene().
int r_shadow_viewfbo |
Definition at line 124 of file r_shadow.c.
Referenced by R_RenderScene(), and R_Shadow_RenderMode_Reset().
int r_shadow_viewheight |
Definition at line 130 of file r_shadow.c.
Referenced by R_RenderScene().
int r_shadow_viewwidth |
Definition at line 129 of file r_shadow.c.
Referenced by R_RenderScene().
int r_shadow_viewx |
Definition at line 127 of file r_shadow.c.
Referenced by R_RenderScene().
int r_shadow_viewy |
Definition at line 128 of file r_shadow.c.
Referenced by R_RenderScene().
|
static |
Definition at line 273 of file r_shadow.c.
Referenced by R_CompleteLightPoint(), R_Shadow_BounceGrid_AssignPhotons_Task(), R_Shadow_BounceGrid_CheckEnable(), R_Shadow_BounceGrid_UpdateSpacing(), R_Shadow_ClearWorldLights(), R_Shadow_DrawCoronas(), R_Shadow_DrawLightSprites(), R_Shadow_EditLights_DrawSelectedLightProperties(), R_Shadow_EditLights_EditAll_f(), R_Shadow_EditLights_Reload_f(), R_Shadow_FreeWorldLight(), R_Shadow_GetRTLightInfo(), R_Shadow_Init(), R_Shadow_NewWorldLight(), R_Shadow_PrepareLights(), R_Shadow_SaveWorldLights(), R_Shadow_SelectLightInView(), and R_Shadow_UncompileWorldLights().
int* shadowelements |
Definition at line 71 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_ResizeShadowArrays(), R_Shadow_ShadowMapFromList(), r_shadow_shutdown(), and r_shadow_start().
int* shadowmark |
Definition at line 78 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareShadowMark(), r_shadow_shutdown(), and r_shadow_start().
int shadowmarkcount |
Definition at line 80 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareShadowMark(), r_shadow_shutdown(), and r_shadow_start().
int* shadowmarklist |
Definition at line 79 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_PrepareShadowMark(), r_shadow_shutdown(), and r_shadow_start().
unsigned char* shadowsides |
Definition at line 84 of file r_shadow.c.
Referenced by R_Mod_CompileShadowMap(), R_Shadow_ChooseSidesFromBox(), R_Shadow_Init(), R_Shadow_PrepareShadowSides(), r_shadow_shutdown(), and r_shadow_start().
int* shadowsideslist |
Definition at line 85 of file r_shadow.c.
Referenced by R_Mod_CompileShadowMap(), R_Shadow_ChooseSidesFromBox(), R_Shadow_Init(), R_Shadow_PrepareShadowSides(), r_shadow_shutdown(), and r_shadow_start().
float* shadowvertex3f |
Definition at line 74 of file r_shadow.c.
Referenced by R_Shadow_Init(), R_Shadow_ResizeShadowArrays(), r_shadow_shutdown(), and r_shadow_start().
|
static |
Definition at line 4467 of file r_shadow.c.
Referenced by R_DrawCorona(), R_Shadow_DrawCursor_TransparentCallback(), and R_Shadow_DrawLightSprite_TransparentCallback().
int* vertexremap |
Definition at line 89 of file r_shadow.c.
Referenced by R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().
int* vertexupdate |
Definition at line 88 of file r_shadow.c.
Referenced by R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().
int vertexupdatenum |
Definition at line 90 of file r_shadow.c.
Referenced by R_Shadow_Init(), r_shadow_shutdown(), and r_shadow_start().