r_shadow_realtime_world_lightmaps 0 brightness to render lightmaps when using full world lighting, try 0.5 for a tenebrae-like appearance\r
r_shadow_realtime_world_shadows 1 enables rendering of shadows from world lights\r
r_shadow_scissor 1 use scissor optimization of light rendering (restricts rendering to the portion of the screen affected by the light)\r
-r_shadow_shadow_polygonfactor 0 how much to enlarge shadow volume polygons when rendering (should be 0!)\r
-r_shadow_shadow_polygonoffset 1 how much to push shadow volumes into the distance when rendering, to reduce chances of zfighting artifacts (should not be less than 0)\r
+r_shadow_polygonfactor 0 how much to enlarge shadow volume polygons when rendering (should be 0!)\r
+r_shadow_polygonoffset 1 how much to push shadow volumes into the distance when rendering, to reduce chances of zfighting artifacts (should not be less than 0)\r
r_shadow_texture3d 1 use 3D voxel textures for spherical attenuation rather than cylindrical (does not affect r_glsl lighting)\r
r_shadows 0 casts fake stencil shadows from models onto the world (rtlights are unaffected by this)\r
r_shadows_throwdistance 500 how far to cast shadows from models\r
Cvar_SetValueQuick(&r_shadow_frontsidecasting, 1);
r_refdef.polygonfactor = 0;
r_refdef.polygonoffset = 0;
- r_refdef.shadowpolygonfactor = r_refdef.polygonfactor + r_shadow_shadow_polygonfactor.value * (r_shadow_frontsidecasting.integer ? 1 : -1);
- r_refdef.shadowpolygonoffset = r_refdef.polygonoffset + r_shadow_shadow_polygonoffset.value * (r_shadow_frontsidecasting.integer ? 1 : -1);
+ r_refdef.shadowpolygonfactor = r_refdef.polygonfactor + r_shadow_polygonfactor.value * (r_shadow_frontsidecasting.integer ? 1 : -1);
+ r_refdef.shadowpolygonoffset = r_refdef.polygonoffset + r_shadow_polygonoffset.value * (r_shadow_frontsidecasting.integer ? 1 : -1);
r_refdef.rtworld = r_shadow_realtime_world.integer;
r_refdef.rtworldshadows = r_shadow_realtime_world_shadows.integer && gl_stencil;
cvar_t r_shadow_realtime_world_compileportalculling = {0, "r_shadow_realtime_world_compileportalculling", "1", "enables portal-based culling optimization during compilation"};
cvar_t r_shadow_scissor = {0, "r_shadow_scissor", "1", "use scissor optimization of light rendering (restricts rendering to the portion of the screen affected by the light)"};
cvar_t r_shadow_culltriangles = {0, "r_shadow_culltriangles", "1", "performs more expensive tests to remove unnecessary triangles of lit surfaces"};
-cvar_t r_shadow_shadow_polygonfactor = {0, "r_shadow_shadow_polygonfactor", "0", "how much to enlarge shadow volume polygons when rendering (should be 0!)"};
-cvar_t r_shadow_shadow_polygonoffset = {0, "r_shadow_shadow_polygonoffset", "1", "how much to push shadow volumes into the distance when rendering, to reduce chances of zfighting artifacts (should not be less than 0)"};
+cvar_t r_shadow_polygonfactor = {0, "r_shadow_polygonfactor", "0", "how much to enlarge shadow volume polygons when rendering (should be 0!)"};
+cvar_t r_shadow_polygonoffset = {0, "r_shadow_polygonoffset", "1", "how much to push shadow volumes into the distance when rendering, to reduce chances of zfighting artifacts (should not be less than 0)"};
cvar_t r_shadow_texture3d = {0, "r_shadow_texture3d", "1", "use 3D voxel textures for spherical attenuation rather than cylindrical (does not affect r_glsl lighting)"};
cvar_t gl_ext_separatestencil = {0, "gl_ext_separatestencil", "1", "make use of OpenGL 2.0 glStencilOpSeparate or GL_ATI_separate_stencil extension"};
cvar_t gl_ext_stenciltwoside = {0, "gl_ext_stenciltwoside", "1", "make use of GL_EXT_stenciltwoside extension (NVIDIA only)"};
"r_shadow_realtime_world_compile : compile surface/visibility information\n"
"r_shadow_realtime_world_compileshadow : compile shadow geometry\n"
"r_shadow_scissor : use scissor optimization\n"
-"r_shadow_shadow_polygonfactor : nudge shadow volumes closer/further\n"
-"r_shadow_shadow_polygonoffset : nudge shadow volumes closer/further\n"
+"r_shadow_polygonfactor : nudge shadow volumes closer/further\n"
+"r_shadow_polygonoffset : nudge shadow volumes closer/further\n"
"r_shadow_texture3d : use 3d attenuation texture (if hardware supports)\n"
"r_showlighting : useful for performance testing; bright = slow!\n"
"r_showshadowvolumes : useful for performance testing; bright = slow!\n"
Cvar_RegisterVariable(&r_shadow_realtime_world_compileportalculling);
Cvar_RegisterVariable(&r_shadow_scissor);
Cvar_RegisterVariable(&r_shadow_culltriangles);
- Cvar_RegisterVariable(&r_shadow_shadow_polygonfactor);
- Cvar_RegisterVariable(&r_shadow_shadow_polygonoffset);
+ Cvar_RegisterVariable(&r_shadow_polygonfactor);
+ Cvar_RegisterVariable(&r_shadow_polygonoffset);
Cvar_RegisterVariable(&r_shadow_texture3d);
Cvar_RegisterVariable(&gl_ext_separatestencil);
Cvar_RegisterVariable(&gl_ext_stenciltwoside);
extern cvar_t r_shadow_realtime_world_compileportalculling;
extern cvar_t r_shadow_scissor;
extern cvar_t r_shadow_culltriangles;
-extern cvar_t r_shadow_shadow_polygonfactor;
-extern cvar_t r_shadow_shadow_polygonoffset;
+extern cvar_t r_shadow_polygonfactor;
+extern cvar_t r_shadow_polygonoffset;
extern cvar_t r_shadow_singlepassvolumegeneration;
extern cvar_t r_shadow_texture3d;
extern cvar_t gl_ext_separatestencil;