Home
last modified time | relevance | path

Searched refs:lightBody (Results 1 – 1 of 1) sorted by relevance

/external/skia/src/effects/imagefilters/
DSkLightingImageFilter.cpp1928 SkString lightBody; in emitLightFunc() local
1929 lightBody.appendf("half colorScale = %s * dot(normal, surfaceToLight);", kd); in emitLightFunc()
1930 lightBody.appendf("return half4(saturate(lightColor * colorScale), 1.0);"); in emitLightFunc()
1935 lightBody.c_str()); in emitLightFunc()
2035 SkString lightBody; in emitLightFunc() local
2036 lightBody.appendf("half3 halfDir = half3(normalize(surfaceToLight + half3(0, 0, 1)));"); in emitLightFunc()
2037 lightBody.appendf("half colorScale = half(%s * pow(dot(normal, halfDir), %s));", in emitLightFunc()
2039 lightBody.appendf("half3 color = saturate(lightColor * colorScale);"); in emitLightFunc()
2040 lightBody.appendf("return half4(color, max(max(color.r, color.g), color.b));"); in emitLightFunc()
2045 lightBody.c_str()); in emitLightFunc()