-Wall -Wextra and -Wno-unused in common.gypi. This revealed a lot of warnings
(and some actual bugs), all of which I fixed here. This is pretty mindless
stuff for the most part (order of intialization, missing initializers, && within
||, etc), but will allow us to build cleanly with -Wall and -Wextra (and
-Werror, if we so choose).
I put defaults into switches that were missing cases. I could put in the actual
missing enums instead if that's desired. I could also assert on missing enums
instead of break, if that's desired. I wasn't sure how to test the stuff in
"animator", so that should be looked at a bit more closely.
Review URL: http://codereview.appspot.com/4547055/
git-svn-id: http://skia.googlecode.com/svn/trunk@1386 2bbb7eff-a529-9590-31e7-b0007b416f81
edge AA polys, so we minimize state changes and GL calls. This requires
querying GL for the maximum number of fragment uniforms. It also makes the
shader generator produce custom shaders for the number of relevant edges.
This gives a ~5X speedup on the "Shapes" SampleApp.
Review URL: http://codereview.appspot.com/4536070/
git-svn-id: http://skia.googlecode.com/svn/trunk@1380 2bbb7eff-a529-9590-31e7-b0007b416f81
GrPathUtils::worstCasePointCount(). worstCasePointCount() is sometimes
returning a lower value than the number of points subsequently generated by
the path renderers. This is because it constructs the SkPath::Iter with
forceClose set to "false", while the path renderers use one with forceClose
set to "true". They should both be the same, and since we're filling paths, I
think it should be set "true".
Review URL: http://codereview.appspot.com/4552047/
git-svn-id: http://skia.googlecode.com/svn/trunk@1353 2bbb7eff-a529-9590-31e7-b0007b416f81
Problem was resolved by adding the notion of a custom texture domain in generated shaders, when necessary.
git-svn-id: http://skia.googlecode.com/svn/trunk@1337 2bbb7eff-a529-9590-31e7-b0007b416f81
isCCW() code in GrTesselatedPathRenderer was using untransformed vertices,
which fails for transforms with negative scale. Doing the check after
transformation fixes it. This was causing some missing geometry in the
PolyToPoly and Shapes tests in SampleApp.
Review URL: http://codereview.appspot.com/4545049/
git-svn-id: http://skia.googlecode.com/svn/trunk@1334 2bbb7eff-a529-9590-31e7-b0007b416f81
This patch implements edge antialiasing for convex shapes, using the fragment
shader to compare against the edge equations for each triangle. Currently, it
only works for flat shaded primitives (i.e., it was not integrated into the
"active stages" path). The skia.gyp changes cause this code to be compiled into
SampleApp, but do not enable the tesselated path by default.
Notes: the SkOSWindow_Unix.cpp change is to silence a valgrind warning about
memcpy() with overlapping regions. The GrBinHashKey change is to avoid running
a two-pass hash (GrProgramDesc is now 52 bytes or so, exceeding the 32 byte
default size).
Review URL: http://codereview.appspot.com/4519054/
git-svn-id: http://skia.googlecode.com/svn/trunk@1314 2bbb7eff-a529-9590-31e7-b0007b416f81
assumes GL_RGBA texture format on all platforms except Windows (where it uses
GL_BGRA), so texture colours come out wrong. As a temporary fix, do on Linux
what we do on Windows, and assume GL_BGRA. (This should be made more general
later, and the assumption of matching formats between Skia and Ganesh removed.)
Review URL: http://codereview.appspot.com/4474046/
git-svn-id: http://skia.googlecode.com/svn/trunk@1247 2bbb7eff-a529-9590-31e7-b0007b416f81
SkOSWindow::fGLAttched (and fVi while we're at it), since it was being checked
uninitialized. Don't call has_gl_extension() while initializing the
GrGLDefaultInterface, since it derefs the default interface (which is still
NULL); use has_gl_extension_from_string() instead.
Review URL: http://codereview.appspot.com/4480041/
git-svn-id: http://skia.googlecode.com/svn/trunk@1242 2bbb7eff-a529-9590-31e7-b0007b416f81