Torque3D/Engine/source/materials
Azaezel 2753f562e8 shadow caching
SPECIAL NOTE: highly suggest https://github.com/GarageGames/Torque3D/pull/1441 or a variation thereof to prevent debug spew and false-postives for occlusion results.

With significant research, development and prototyping assistance from both @andr3wmac (shaders and partial hook work), and @LuisAntonRebollo (additional culling)

System operates as follows:
1) materials are given an additional castDynamicShadows boolean entry. (Default at time of writing is true by request. Personal usage at time of writing defaults to false. value is default-initialized in materialDefinition.cpp. script/gui exposed)
2) lights are given a staticRefreshFreq and dynamicRefreshFreq (in milliseconds). script/gui exposed
3) materials are (effectively) sorted into dynamic and static shadowmap render lists based on flag. (see shadowMapPass.cpp)
4) initial shadowmaps are generated for each light and 'list'.
5) as each refreshFreq times out, the relevant shadowmap for a given light is refreshed.

Special notes:
dynamicRefreshFreq for all lights is set to a (script exposed) 8MS refresh timer.
StaticRefreshFreq for the lions share of lights defaults to 250 MS (1/4 of a second)
scattersky's embedded light, which is intended to operate in a mobile manner, defaults to 8
to reiterate, these are all customizable per-light via script/inspector gui in the case of alternate project needs.
2015-10-13 18:12:19 -05:00
..
baseMaterialDefinition.h shadow caching 2015-10-13 18:12:19 -05:00
baseMatInstance.cpp Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
baseMatInstance.h cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
customMaterialDefinition.cpp Fix preprocessor directive 2015-02-25 21:12:01 +01:00
customMaterialDefinition.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
materialDefinition.cpp shadow caching 2015-10-13 18:12:19 -05:00
materialDefinition.h shadow caching 2015-10-13 18:12:19 -05:00
materialFeatureData.cpp Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
materialFeatureData.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
materialFeatureTypes.cpp cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
materialFeatureTypes.h cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
materialList.cpp Fix use-after-delete 2014-12-11 19:09:02 -05:00
materialList.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
materialManager.cpp Merge remote-tracking branch 'Winterleaf/Development-Console' into defineconsolemethod 2014-12-21 21:23:55 +11:00
materialManager.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
materialParameters.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
matInstance.cpp Merge remote-tracking branch 'gg/development-3.6' into development 2015-01-29 21:17:38 +11:00
matInstance.h cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
matInstanceHook.cpp Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
matInstanceHook.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
matStateHint.cpp Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
matStateHint.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
matTextureTarget.cpp Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
matTextureTarget.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
miscShdrDat.h Fixes for dedicated build on linux. 2014-05-30 12:35:39 +02:00
processedCustomMaterial.cpp shadow caching 2015-10-13 18:12:19 -05:00
processedCustomMaterial.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
processedFFMaterial.cpp cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
processedFFMaterial.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
processedMaterial.cpp cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
processedMaterial.h Merge remote-tracking branch 'gg/development-3.6' into development 2015-01-29 21:17:38 +11:00
processedShaderMaterial.cpp Merge pull request #719 from rextimmy/dxtnm-parallax-fix 2015-08-27 23:59:20 -05:00
processedShaderMaterial.h cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
sceneData.h cleaned up variant of https://github.com/GarageGames/Torque3D/pull/768 alterations: opengl support, in-shader bug-reporting, direction vector fit to material slider-bar. 2014-12-21 14:07:42 -06:00
shaderData.cpp Add sampler names to ShaderData for use on old versions of OpenGL and Opengl ES2 that not support explicit sampler location on shader files. 2014-11-08 17:50:37 +01:00
shaderData.h Add sampler names to ShaderData for use on old versions of OpenGL and Opengl ES2 that not support explicit sampler location on shader files. 2014-11-08 17:50:37 +01:00
shaderMaterialParameters.cpp Engine directory for ticket #1 2012-09-19 11:15:01 -04:00
shaderMaterialParameters.h Engine directory for ticket #1 2012-09-19 11:15:01 -04:00