diff options
-rw-r--r-- | src/render/materialsystem/prototypes/default.json | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/src/render/materialsystem/prototypes/default.json b/src/render/materialsystem/prototypes/default.json index 97ce7e0fd..a3a8deae6 100644 --- a/src/render/materialsystem/prototypes/default.json +++ b/src/render/materialsystem/prototypes/default.json @@ -395,6 +395,40 @@ } ] }, + "phongFunction": { + "inputs": [ + "ambient", + "diffuse", + "specular", + "shininess", + "worldPosition", + "worldView", + "worldNormal" + ], + "outputs": [ + "outputColor" + ], + "rules": [ + { + "format": { + "api": "OpenGLES", + "major": 2, + "minor": 0 + }, + "substitution": "highp vec4 $outputColor = phongFunction($ambient, $diffuse, $specular, $shininess, $worldPosition, $worldView, $worldNormal);", + "headerSnippets": [ "#pragma include :/shaders/es2/phong.inc.frag" ] + }, + { + "format": { + "api": "OpenGLCoreProfile", + "major": 3, + "minor": 0 + }, + "substitution": "vec4 $outputColor = phongFunction($ambient, $diffuse, $specular, $shininess, $worldPosition, $worldView, $worldNormal);", + "headerSnippets": [ "#pragma include :/shaders/gl3/phong.inc.frag" ] + } + ] + }, "metalRoughFunction": { "inputs": [ "baseColor", |