sample.material 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. material colored
  2. {
  3. technique
  4. {
  5. pass
  6. {
  7. // shaders
  8. vertexShader = res/shaders/colored.vert
  9. fragmentShader = res/shaders/colored.frag
  10. defines = DIRECTIONAL_LIGHT_COUNT 1
  11. // uniforms
  12. u_worldViewProjectionMatrix = WORLD_VIEW_PROJECTION_MATRIX
  13. u_inverseTransposeWorldViewMatrix = INVERSE_TRANSPOSE_WORLD_VIEW_MATRIX
  14. u_ambientColor = SCENE_AMBIENT_COLOR
  15. // render state
  16. renderState
  17. {
  18. cullFace = true
  19. depthTest = true
  20. }
  21. }
  22. }
  23. }
  24. material cube : colored
  25. {
  26. technique
  27. {
  28. pass
  29. {
  30. u_diffuseColor = 0.1, .6, 0.1, 1
  31. }
  32. }
  33. }
  34. material blue : colored
  35. {
  36. technique
  37. {
  38. pass
  39. {
  40. u_diffuseColor = 0, 0, 1, 1
  41. }
  42. }
  43. }
  44. material red : colored
  45. {
  46. technique
  47. {
  48. pass
  49. {
  50. u_diffuseColor = 1, 0, 0, 1
  51. }
  52. }
  53. }
  54. material cylinder : colored
  55. {
  56. technique
  57. {
  58. pass
  59. {
  60. u_diffuseColor = 0.38, 0.63, 1, 1
  61. }
  62. }
  63. }
  64. material torus : colored
  65. {
  66. technique
  67. {
  68. pass
  69. {
  70. u_diffuseColor = 1, 0.5, 0.0, 1
  71. }
  72. }
  73. }
  74. material sphere : colored
  75. {
  76. technique
  77. {
  78. pass
  79. {
  80. u_diffuseColor = 0.7, 0.7, 0.7, 1
  81. }
  82. }
  83. }
  84. material cone : colored
  85. {
  86. technique
  87. {
  88. pass
  89. {
  90. u_diffuseColor = 0.5, 0.25, 0.5, 1
  91. }
  92. }
  93. }