When closing a namespace a } is sufficient. It doesn't need to be };
like closing a class or enum.
Within frameworks/base/libs/hwui there is a mix between } and }; when
closing a namespace. There are even mixes between a .h and the
corresponding .cpp files.
In a separate CL I was asked to not close with };. That was a good
comment. I adopted the style from nearby code. This CL cleans up the
nearby code.
Test: I made sure the code still built as expected.
Change-Id: Ieb314a4f48d6e33752463f3be4361fdc9be97482
bug:22480459
Also switches std::functions to function pointers on OpReorderer, and
switches AssetAtlas' entry getter methods to using pixelRef pointers,
so it's clear they're the keys.
Change-Id: I3040ce5ff4e178a8364e0fd7ab0876ada7d4de05
Changes generated with clang-modernize.
Additionally, fixed some struct-vs-class usage to make clang happy.
Change-Id: Ic6ef2427401ff1e794d26f21f7b44868fc75fb72
Fix the valid umbra detection.
This looks better b/c every vertex will have one ray shooting at it, such that
we don't miss the corner.
This performs better too, due to the polygon intersection is removed and less ray
intersection. 2x performance for rect and circle for spot shadow in test app.
b/17288227
b/15598793
b/16712006
Change-Id: I4a5ee397b9e192e93c8e35e6260b499e3e38a6f4
Using the vertices, instead of ray casting for the triangulation.
This request a dynamic index buffer associated with vertex buffer,
so we update the VertexBuffer to support it.
The ambient shadow could be 3x-6x times faster for circle and rect now.
b/16712006
b/14257173
Change-Id: I2f22a8fe19bc59acee5c18e4a3a395acd5042a66
Basically we compute the shadow as a strip of triangles, whose alpha value
is the strength of the shadow.
We use the normal to extend the geometry.
And we use static function and try to avoid new/malloc in the computation.
Change-Id: I382286f1cad351bd5ff983f76f446c075819dcaf