skia2/include
senorblanco@chromium.org 894790d77c This patch implements the diffuse and specular lighting filters in Ganesh.
There are three light types for each:  distant, point and spot, whose code
generation lives in a GrGLLight class hierarchy.  This similar to the CPU
implementation, where each light type provides a function to compute the vector
from the surface plane to the light (surfaceToLight) and to compute the light
colour (emitLightColour).  Instead of templated member functions, as in the CPU
implementation, these are virtual functions to emit the light-specific GLSL
code.

All of the code for the GPU path lives in the same file as that for the CPU
path, SkLightingImageFilter.cpp.  In order to provide Ganesh a hook to access
it, SkImageFilter now has a asNewCustomStage() virtual, which allows an image
filter to return a GrCustomStage representing that filter.

Note that this patch does not handle the border conditions correctly (the
[top|bottom][Left|Right]Normal() functions in the CPU implementation).  That
will come in a future patch.

Review URL: http://codereview.appspot.com/6345081/



git-svn-id: http://skia.googlecode.com/svn/trunk@4535 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-07-11 16:01:22 +00:00
..
animator Automatic update of all copyright notices to reflect new license terms. 2011-07-28 14:26:00 +00:00
config Separated Inst counting from the SK_DEBUG #define (now SK_ENABLE_INST_COUNT) 2012-06-27 19:41:42 +00:00
core This patch implements the diffuse and specular lighting filters in Ganesh. 2012-07-11 16:01:22 +00:00
device/xps Formatting cleanup: remove extra whitespace 2012-01-28 01:45:11 +00:00
effects This patch implements the diffuse and specular lighting filters in Ganesh. 2012-07-11 16:01:22 +00:00
gpu This patch implements the diffuse and specular lighting filters in Ganesh. 2012-07-11 16:01:22 +00:00
images Expanded distribution of instance counting 2012-06-21 20:25:03 +00:00
pdf [PDF] Move most of the headers to be private. 2012-03-22 20:45:15 +00:00
pipe Fix SkGPipe drawing, and turn it on by default. 2012-06-28 15:41:32 +00:00
ports [android] Add an API to load customized font config for testing. 2012-06-25 13:58:22 +00:00
svg Automatic update of all copyright notices to reflect new license terms. 2011-07-28 14:26:00 +00:00
text Expanded distribution of instance counting 2012-06-21 20:25:03 +00:00
utils add SkPath::contains(x, y) 2012-07-11 01:51:33 +00:00
views Move animated view headers to correct directory. 2012-07-10 21:54:31 +00:00
xml Make SkMath.h less visible in public header files. 2011-09-27 17:38:17 +00:00