skia2/include
kkinnunen ec56e45454 Implement NV_path_rendering on OpenGL ES
Implement support for NV_path_rendering on OpenGL ES. Use
glProgramPathFragmentInputGenNV function call instead of glPathTexGenNV to
communicate transforms to fragment shader.

The intention is that the NVPR paths will be drawn with the same shader program
as non-NVPR geometry. For NVPR calls, the GPU will skip the vertex shader and
just run the fragment shader.

After program is linked, query the locations of the fragment shader inputs with
glGetResourceLocation. The location will be used to set the transforms with
glProgramPathFragmentInputGenNV.

The functions and their workings are documented in:

glProgramPathFragmentInputGenNV
https://www.opengl.org/registry/specs/NV/path_rendering.txt
(note: addition as of API version 1.3)

glGetResourceLocation
https://www.opengl.org/registry/specs/ARB/program_interface_query.txt
http://www.opengl.org/registry/doc/glspec44.core.pdf
(function is in core Open GL 4.4)

Note: glProgramPathFragmentInputGenNV could be used also for OpenGL. However,
using seems to trigger a bug in the driver. Disable this feature on OpenGL at
least until the driver is fixed and released. The bug manifests in shadertext
test, where the lower-left text pair is missing. Valgrind catches a bad read
for the test and causes the context to OOM reproducibly.

R=bsalomon@google.com, cdalton@nvidia.com, joshualitt@google.com, joshualitt@chromium.org

Author: kkinnunen@nvidia.com

Review URL: https://codereview.chromium.org/367643004
2014-08-25 22:21:16 -07:00
..
animator Sanitizing source files in Skia_Periodic_House_Keeping 2013-01-26 07:06:02 +00:00
config Add SkBarriers to ports. 2014-05-29 18:24:54 +00:00
core Add a working SkFontMgr_fontconfig. 2014-08-25 12:00:49 -07:00
device/xps Add testing flag for XPS for deterministic ids. 2014-08-22 15:07:06 -04:00
effects Simplify flattening to just write enough to call the factory/public-constructor for the class. We want to *not* rely on private constructors, and not rely on calling through the inheritance hierarchy for either flattening or unflattening(CreateProc). 2014-08-21 07:59:51 -07:00
gpu Implement NV_path_rendering on OpenGL ES 2014-08-25 22:21:16 -07:00
images Remove SkImageRef and related functionality. 2014-06-04 14:38:48 -04:00
pathops add pathops tight bounds; conform path ops' gyp to unit tests 2014-06-24 07:55:12 -07:00
pdf change gpudevice and pdfdevice to inherit from basedevice 2014-06-27 11:34:19 -07:00
pipe Fixes for piping bitmaps with encoded data. 2013-04-30 02:32:41 +00:00
ports Delete the old font management implementation based on SkFontConfigInterface, now that SkFontMgr_Android is live. 2014-08-13 10:41:25 -07:00
record add SK_API to include/record 2014-04-28 21:04:32 +00:00
svg Sanitizing source files in Skia_Periodic_House_Keeping 2013-01-26 07:06:02 +00:00
utils Migrate SkRTConfRegistry test to DEF_TEST(). 2014-08-12 09:03:16 -07:00
views share dm and command flags 2014-07-22 10:15:35 -07:00
xml Sanitizing source files in Skia_Periodic_House_Keeping 2013-01-26 07:06:02 +00:00