!Header CPU.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /******************************************************************************/
  2. // Shader Bump Mapping Modes
  3. #define SBUMP_ZERO 0 // no vertex normal
  4. #define SBUMP_FLAT 1
  5. #define SBUMP_NORMAL 2
  6. #define SBUMP_PARALLAX0 2 // !! this is on purpose the same as SBUMP_NORMAL because it's never used anyway, it's used just for calculations
  7. #define SBUMP_PARALLAX1 3
  8. #define SBUMP_PARALLAX2 4
  9. #define SBUMP_PARALLAX3 5
  10. #define SBUMP_PARALLAX4 6
  11. #define SBUMP_RELIEF 7
  12. #define SBUMP_PARALLAX_MIN SBUMP_PARALLAX2 // ignore SBUMP_PARALLAX1 because just 1 sample is not worth to keep as separate shader
  13. #define SBUMP_PARALLAX_MAX SBUMP_PARALLAX4
  14. #define SBUMP_PARALLAX_MAX_MULTI SBUMP_PARALLAX2 // for multi-material shaders, limit to only SBUMP_PARALLAX2
  15. // Effects
  16. #define FX_NONE 0
  17. #define FX_GRASS 1
  18. #define FX_LEAF 2
  19. #define FX_LEAFS 3
  20. #define FX_BONE 4
  21. #define MAX_MOTION_BLUR_PIXEL_RANGE 24
  22. #define MAX_MTRLS 4 // 3 or 4 (3 to make shaders smaller, 4 to support more materials per tri)
  23. #define LCScale 0.2f // must be in sync with GLSL
  24. // Buffer Indexes
  25. #define SBI_GLOBAL 0
  26. #define SBI_OBJ_MATRIX 1
  27. #define SBI_OBJ_VEL 2
  28. #define SBI_MESH 3
  29. #define SBI_MATERIAL 4
  30. #define SBI_VIEWPORT 5
  31. #define SBI_COLOR 6
  32. #define SBI_NUM 7
  33. // !! if any change is made here then all shaders need to be recompiled !!
  34. // Sampler Indexes
  35. #define SSI_DEFAULT 0
  36. #define SSI_POINT 1
  37. #define SSI_LINEAR_CLAMP 2
  38. #define SSI_LINEAR_WRAP 3
  39. #define SSI_SHADOW 4
  40. #define SSI_FONT 5
  41. #define SSI_LINEAR_CWW 6
  42. /******************************************************************************/