From a2fe7affd3d077ac163da90996cb2e5e0ca3b8d1 Mon Sep 17 00:00:00 2001 From: Chris Craik Date: Tue, 28 Jan 2014 17:25:06 -0800 Subject: Add initial hidden outline APIs Background drawable outline usage and drawable outline calculation still to come. Change-Id: I8c7539f1638f86e1f8eb11f4fe49f705f61d58ba --- libs/hwui/OpenGLRenderer.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'libs/hwui/OpenGLRenderer.cpp') diff --git a/libs/hwui/OpenGLRenderer.cpp b/libs/hwui/OpenGLRenderer.cpp index 7a1194870d57..b71082572ce2 100644 --- a/libs/hwui/OpenGLRenderer.cpp +++ b/libs/hwui/OpenGLRenderer.cpp @@ -3199,6 +3199,11 @@ status_t OpenGLRenderer::drawShadow(const mat4& casterTransform, float casterAlp PathTessellator::approximatePathOutlineVertices(*casterOutline, casterRefinementThresholdSquared, casterVertices2d); + if (casterVertices2d.size() == 0) { + // empty caster polygon computed from path + return DrawGlInfo::kStatusDone; + } + // map 2d caster poly into 3d const int casterVertexCount = casterVertices2d.size(); Vector3 casterPolygon[casterVertexCount]; -- cgit v1.2.3-59-g8ed1b