Torque3D Documentation / _generateds / shaderGenVars.h

shaderGenVars.h

Engine/source/shaderGen/shaderGenVars.h

More...

Classes:

class

ShaderGenVars, predefined string names for variables that shadergen based shaders use, this avoids misspelling and string creation issues.

Detailed Description

  1
  2//-----------------------------------------------------------------------------
  3// Copyright (c) 2012 GarageGames, LLC
  4//
  5// Permission is hereby granted, free of charge, to any person obtaining a copy
  6// of this software and associated documentation files (the "Software"), to
  7// deal in the Software without restriction, including without limitation the
  8// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
  9// sell copies of the Software, and to permit persons to whom the Software is
 10// furnished to do so, subject to the following conditions:
 11//
 12// The above copyright notice and this permission notice shall be included in
 13// all copies or substantial portions of the Software.
 14//
 15// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 16// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 17// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 18// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 19// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
 20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
 21// IN THE SOFTWARE.
 22//-----------------------------------------------------------------------------
 23#ifndef _SHADERGENVARS_H_
 24#define _SHADERGENVARS_H_
 25
 26#ifndef _TORQUE_STRING_H_
 27#include "core/util/str.h"
 28#endif
 29
 30///
 31/// ShaderGenVars, predefined string names for variables that shadergen based shaders use, this avoids
 32/// misspelling and string creation issues
 33///
 34struct ShaderGenVars
 35{
 36   const static String modelview;
 37   const static String worldViewOnly;
 38   const static String worldToCamera;
 39   const static String worldToObj;
 40   const static String viewToObj;
 41   const static String cubeTrans;
 42   const static String objTrans;
 43   const static String cubeEyePos;
 44   const static String eyePos;
 45   const static String eyePosWorld;
 46   const static String vEye;
 47   const static String eyeMat;
 48   const static String oneOverFarplane;
 49   const static String nearPlaneWorld;
 50   const static String fogData;
 51   const static String fogColor;
 52   const static String detailScale;
 53   const static String visibility;
 54   const static String colorMultiply;
 55   const static String alphaTestValue;
 56   const static String texMat;
 57   const static String accumTime;
 58   const static String minnaertConstant;
 59   const static String subSurfaceParams;
 60
 61   // Texture atlasing parameters
 62   const static String diffuseAtlasParams;
 63   const static String diffuseAtlasTileParams;
 64   const static String bumpAtlasParams;
 65   const static String bumpAtlasTileParams;
 66
 67   // Render target parameters
 68   const static String targetSize;
 69   const static String oneOverTargetSize;
 70
 71   // Lighting parameters used by the default
 72   // RTLighting shader feature.
 73   const static String lightPosition;
 74   const static String lightDiffuse;
 75   const static String lightAmbient;
 76   const static String lightInvRadiusSq;
 77   const static String lightSpotDir;
 78   const static String lightSpotAngle;
 79   const static String lightSpotFalloff;
 80   const static String specularColor;
 81   const static String specularPower;
 82   const static String specularStrength;
 83   
 84   // Textures
 85   const static String fogMap;
 86   const static String dlightMap;
 87   const static String dlightMask;
 88   const static String dlightMapSec;
 89   const static String blackfogMap;
 90   const static String bumpMap;
 91   const static String lightMap;
 92   const static String lightNormMap;
 93   const static String cubeMap;
 94   const static String dLightMap;
 95   const static String dLightMapSec;
 96   const static String dLightMask;
 97   const static String toneMap;
 98
 99   // Deferred Shading
100   const static String matInfoFlags;
101};
102
103#endif
104