11718bc17bcfc56dfb9f4362eebf640b025c4415 |
|
22-Sep-2015 |
Chris Craik <ccraik@google.com> |
Remove shader based gamma approach Also fixes some INIT_LOGD logs Change-Id: I212a71a1e7b366aea41f7c3c8cc169d509d6e4a2
/frameworks/base/libs/hwui/Program.h
|
b9ce116dac378b4cf4490f265dcbd5704a1dd43c |
|
21-Aug-2015 |
Chris Craik <ccraik@google.com> |
Switch several enums to enum classes Change-Id: I00ecd0b61657196b51704f70ca31a9d1c1ac254e
/frameworks/base/libs/hwui/Program.h
|
0519c810a56bded1284fcb2ae40f438878c6585f |
|
11-Feb-2015 |
Chris Craik <ccraik@google.com> |
Glop Bitmap and RoundRect clipping support Change-Id: I4577546a5d2e5f084cc03f39a89db9231b8111ee
/frameworks/base/libs/hwui/Program.h
|
117bdbcfa3e8306dad21e7e01fa71b00cdfa7265 |
|
05-Feb-2015 |
Chris Craik <ccraik@google.com> |
Glop ColorFilter & VertexBuffer support, initial enable Enables Glop rendering for supported Rects and VertexBuffers Also removes unused Query object Change-Id: Ibe227bc362685a153159f75077664f0947764e06
/frameworks/base/libs/hwui/Program.h
|
6c15ffa196fc9b7724c189d833c3435d8db12266 |
|
02-Feb-2015 |
Chris Craik <ccraik@google.com> |
Refactoring of Program ownership/lifecycle, and WIP Glop rendering path Change-Id: I2549032790bddbc048b0bccc224ed8f386b4517c
/frameworks/base/libs/hwui/Program.h
|
64bb413a664001c95c8439cf097dc3033f4ed733 |
|
22-Nov-2014 |
Andreas Gampe <agampe@google.com> |
Revert "resolved conflicts for merge of 220c3f4f to master" Reverted as hwui doesn't agree. This reverts commit 8a902d9f24e83c87b054adb5836b4a5b8a257be9. Change-Id: I109e7b02bee2921e2155ded6df36f52e6f574b5a
/frameworks/base/libs/hwui/Program.h
|
2ab8298dc37851aab4623ba3f98d71055d653a73 |
|
21-Nov-2014 |
Andreas Gampe <agampe@google.com> |
resolved conflicts for merge of 99377df1 to lmp-mr1-dev-plus-aosp Change-Id: I3a98f55832ac447b1ed0dd129c7a93d088025943
|
42ddc18d108f789705ad4eb697ce9599ad322507 |
|
21-Nov-2014 |
Andreas Gampe <agampe@google.com> |
Frameworks/base: Unused parameters in hwui Remove Clang cutout for unused parameters. Fix warnings. Remove Clang cutout for deprecated Skia function usage. Has been fixed in the L push. Change-Id: I7ea073ff67127cc1e14e798b655e2c50615fe8e7
/frameworks/base/libs/hwui/Program.h
|
23d307c8d88f4a3849163b9e5b7cd11d0d4f372c |
|
27-Oct-2014 |
John Reck <jreck@google.com> |
Cleanup debug options Bug: 18138852 Bug: 18065434 Change-Id: Ibb07b73b147c2a8b287fe8aee3f6624582f21b00
/frameworks/base/libs/hwui/Program.h
|
91a8c7c62913c2597e3bf5a6d59d2ed5fc7ba4e0 |
|
12-Aug-2014 |
Chris Craik <ccraik@google.com> |
Switch to cos interpolation of shadow alpha bug:16852257 Updates default shadow opacities to compensate. Also, update variable/constant naming related to vertex alpha. Change-Id: I9055b4ac3c9ac305ca9d515f21b52d6aa6dc9c5c
/frameworks/base/libs/hwui/Program.h
|
bf75945e7a1ae7c1000682716643c942c1e19ba6 |
|
12-Aug-2014 |
Chris Craik <ccraik@google.com> |
Rework shadow interpolation bug:16852257 Use pow(alpha, 1.5) to avoid harsh edges on shadow alpha ramps. Also adjusts shadow constants to compensate. Change-Id: I5869956d7d292db2a8e496bc320084b6d64c3fb7
/frameworks/base/libs/hwui/Program.h
|
deeda3d337aed1eee218b89a7aba5992ced371f0 |
|
06-May-2014 |
Chris Craik <ccraik@google.com> |
Round rect outline clipping Change-Id: Iee9cf4f719f6f1917507b69189ad114fa365917b
/frameworks/base/libs/hwui/Program.h
|
76d3a1b8d035d27bc80b0f2fc480a903bd001514 |
|
10-Dec-2013 |
Derek Sollenberger <djsollen@google.com> |
Removing SkiaColorFilter and inspecting the native object directly. bug: 10650594 Change-Id: I4fcf66d008765afa0e35d011f58bc792183cb74f
/frameworks/base/libs/hwui/Program.h
|
d04a6b15f74035fd2068f34225825b55e94521f4 |
|
29-Jan-2014 |
Chris Craik <ccraik@google.com> |
Fix projection offset caching Because the caching of projection matrix didn't account for changes in the offset flag, the flag could be ignored. Now we use both to verify that the cached matrix can be used. Change-Id: I193b94eaf0b98f046a6484f0866c3d25048653fd
/frameworks/base/libs/hwui/Program.h
|
e63f7c622a2086aefa80983c6f41b74fb166bb42 |
|
17-Oct-2013 |
Chris Craik <ccraik@google.com> |
Clean unused parameters, disable warnings Change-Id: Iddb872f53075dd022eeef45265594d1c6a9e2bc0
/frameworks/base/libs/hwui/Program.h
|
6d29c8d5218cac0fb35f3b7c253f2bdebd44f15a |
|
09-May-2013 |
Chris Craik <ccraik@google.com> |
Add tessellation path for points bug:4351353 bug:8185479 Point tessellation is similar to line special case, except that we only tessellate one point (as a circle or rect) and duplicate it across other instances. Additionally: Fixes square caps for AA=false lines Cleanup in CanvasCompare, disabling interpolation on zoomed-in comparison view Change-Id: I0756fcc4b20f77878fed0d8057297c80e82ed9dc
/frameworks/base/libs/hwui/Program.h
|
78dd96d5af20f489f0e8b288617d57774ec284f7 |
|
03-May-2013 |
Romain Guy <romainguy@google.com> |
Add an on-screen overdraw counter The counter can be enabled by setting the system property called debug.hwui.overdraw to the string "count". If the string is set to "show", overdraw will be highlighted on screen instead of printing out a simple counter. Change-Id: I9a9c970d54bffab43138bbb7682f6c04bc2c40bd
/frameworks/base/libs/hwui/Program.h
|
3b748a44c6bd2ea05fe16839caf73dbe50bd7ae9 |
|
18-Apr-2013 |
Romain Guy <romainguy@google.com> |
Pack preloaded framework assets in a texture atlas When the Android runtime starts, the system preloads a series of assets in the Zygote process. These assets are shared across all processes. Unfortunately, each one of these assets is later uploaded in its own OpenGL texture, once per process. This wastes memory and generates unnecessary OpenGL state changes. This CL introduces an asset server that provides an atlas to all processes. Note: bitmaps used by skia shaders are *not* sampled from the atlas. It's an uncommon use case and would require extra texture transforms in the GL shaders. WHAT IS THE ASSETS ATLAS The "assets atlas" is a single, shareable graphic buffer that contains all the system's preloaded bitmap drawables (this includes 9-patches.) The atlas is made of two distinct objects: the graphic buffer that contains the actual pixels and the map which indicates where each preloaded bitmap can be found in the atlas (essentially a pair of x and y coordinates.) HOW IS THE ASSETS ATLAS GENERATED Because we need to support a wide variety of devices and because it is easy to change the list of preloaded drawables, the atlas is generated at runtime, during the startup phase of the system process. There are several steps that lead to the atlas generation: 1. If the device is booting for the first time, or if the device was updated, we need to find the best atlas configuration. To do so, the atlas service tries a number of width, height and algorithm variations that allows us to pack as many assets as possible while using as little memory as possible. Once a best configuration is found, it gets written to disk in /data/system/framework_atlas 2. Given a best configuration (algorithm variant, dimensions and number of bitmaps that can be packed in the atlas), the atlas service packs all the preloaded bitmaps into a single graphic buffer object. 3. The packing is done using Skia in a temporary native bitmap. The Skia bitmap is then copied into the graphic buffer using OpenGL ES to benefit from texture swizzling. HOW PROCESSES USE THE ATLAS Whenever a process' hardware renderer initializes its EGL context, it queries the atlas service for the graphic buffer and the map. It is important to remember that both the context and the map will be valid for the lifetime of the hardware renderer (if the system process goes down, all apps get killed as well.) Every time the hardware renderer needs to render a bitmap, it first checks whether the bitmap can be found in the assets atlas. When the bitmap is part of the atlas, texture coordinates are remapped appropriately before rendering. Change-Id: I8eaecf53e7f6a33d90da3d0047c5ceec89ea3af0
/frameworks/base/libs/hwui/Program.h
|
096b8d96d539429de5e67b2821ef3f9ee0300842 |
|
01-Mar-2013 |
Chris Craik <ccraik@google.com> |
Add shader program selection shortcut Add a key manipulation that makes black text/paths use the standard simple bitmap/patch shader, since they are the same. Previously we'd create a separate shader for each because the keys differed, even though the shaders were functionally equivalent. Also fixes some issues around setting DEBUG_PROGRAM Change-Id: I0c77c684d58da03501ee9ab8239c7d4a70fd6b5c
/frameworks/base/libs/hwui/Program.h
|
3ff0bfdd144bba3b023eda8c49b25fb0d0de8653 |
|
25-Feb-2013 |
Romain Guy <romainguy@google.com> |
Add new property to debug non-rectangular clip operations This change adds a new property called "debug.hwui.show_stencil_clip" that accepts the following values: - "highlight", colorizes in green any drawing command that's tested against a non-rectangular clip region - "region", shows the non-rectangular clip region in blue every time it is used - "hide", default value, nothing is shown Change-Id: I83c8602310edc4aaeb8b905371cdd185b17d32b5
/frameworks/base/libs/hwui/Program.h
|
ff316ec7a76e52572a2e89b691e6b3bba0cafba3 |
|
14-Feb-2013 |
Romain Guy <romainguy@google.com> |
Implement support for drawBitmapMesh's colors array Change-Id: I3d901f6267c2918771ac30ff55c8d80c3ab5b725
/frameworks/base/libs/hwui/Program.h
|
65cd612face362d054a85d0f7e5881c59cd523be |
|
11-Dec-2012 |
Chris Craik <ccraik@google.com> |
Add cap tessellation support bug:7117155 bug:8114304 Currently used for lines (with and without AA) and arcs with useCenter=false Also removes 0.375, 0.375 offset for AA lines Change-Id: Ic8ace418739344db1e2814edf65253fe7448b0b0
/frameworks/base/libs/hwui/Program.h
|
39284b763a09688468ed3799ebd2ebb76ea5dfd5 |
|
27-Sep-2012 |
Romain Guy <romainguy@google.com> |
Make gradients beautiful again Bug #7239634 This change passes two matrices to the vertex shader instead of one. We used to compute the final MVP matrix on the CPU to minimize the number of operations in the vertex shaders. Shader compilers are however smart enough to perform this optimization for us. Since we need the MV matrix to properly compute gradients dithering, this change splits the MVP matrix into two. This has the advantage of removing one matrix multiplication per drawing operation on the CPU. The SGX 540 shader compiler produces the same number of instructions in both cases. There is no penalty hit with having two matrices instead of one. We also send so few vertices per frame that it does not matter very much. Change-Id: I17d47ac4772615418e0e1885b97493d31435a936
/frameworks/base/libs/hwui/Program.h
|
710f46d9d6a5bf9ea1c1833384caf61e1934124f |
|
18-Sep-2012 |
Chris Craik <ccraik@google.com> |
Polygonal rendering of simple fill shapes bug:4419017 Change-Id: If0428e1732139786cba15f54b285d880e4a56b89
/frameworks/base/libs/hwui/Program.h
|
a938f569ce206c1ed68d736181016b5b708c0084 |
|
14-Sep-2012 |
Romain Guy <romainguy@google.com> |
Fix modulation and gamma correction issues Modulation is normally enabled in a shader when drawing with an alpha mask (A8 texture.) Modulation is used to do one of two things: - Colorize the primitive (to draw text in red for instance) - Apply extra translucency (50% translucent circle filled with a bitmap) The current implementation has four issues: 1. Unnecessary work is performed by assigning the modulation color to vec4 fragColor early in the shader 2. The modulation color's alpha is applied twice when the primitive is drawn with an SkShader 3. The decision to modulate is wrong and triggers when any of the RGB channels is < 1.0. Only the alpha channel needs to be taken into account to make the decision 4. Gamma correction is not applied properly This change addresses all four issues above. Change-Id: I73fcc74efc4b094bf2d1b835f10ffaa2ea4b9eb9
/frameworks/base/libs/hwui/Program.h
|
6ebdc114e0d72137394f02bc8ffe9d7a782a65c4 |
|
01-Sep-2012 |
Chris Craik <ccraik@google.com> |
Varying-based AA rect drawing Instead of calculating opacity from relative position in the shader, use a shader varying to do this computation for us. bug:5045101 Also adds a test to HwAccelerationTest to show incorrect antialiasing in scaled drawAARect / boundarySize calculation. Change-Id: Icdc41acb01dc10ce354834f8389a5aed2f439162
/frameworks/base/libs/hwui/Program.h
|
42e1e0d482d774cf18a55773e434f02edb9e4462 |
|
30-Jul-2012 |
Romain Guy <romainguy@google.com> |
Improve gradients Avoid using textures for common gradients (two stops from 0.0 to 1.0) Change-Id: Iff55d21b126c8cfc4cfb701669f2339c8f6b131a
/frameworks/base/libs/hwui/Program.h
|
4121063313ac0d6f69f6253cac821d0c1c122086 |
|
17-Jul-2012 |
Romain Guy <romainguy@google.com> |
Add shader-based text gamma correction To enable it, the system property ro.hwui.text_gamma_shader must be set to true. For testing, DEBUG_FONT_RENDERER_FORCE_SHADER_GAMMA can be set to 1 in libhwui/Debug.h. Change-Id: If345c6b71b67ecf1ef2e8847b71f30f3ef251a27
/frameworks/base/libs/hwui/Program.h
|
f877308f77f7c6f3edd91618a092207dd3be9077 |
|
13-Jul-2012 |
Romain Guy <romainguy@google.com> |
Remove obsolete optimization Change-Id: I2d43c009c62a7f4a4a2e0a6303bdfa692c4b8c8c
/frameworks/base/libs/hwui/Program.h
|
5baa3a62a97544669fba6d65a11c07f252e654dd |
|
20-Dec-2011 |
Steve Block <steveblock@google.com> |
Rename (IF_)LOGD(_IF) to (IF_)ALOGD(_IF) DO NOT MERGE See https://android-git.corp.google.com/g/156016 Bug: 5449033 Change-Id: I4c4e33bb9df3e39e11cd985e193e6fbab4635298
/frameworks/base/libs/hwui/Program.h
|
2d4fd364843d3efc6e6ee59ccc5beb513a86d789 |
|
14-Dec-2011 |
Romain Guy <romainguy@google.com> |
Reduce the number of active texture changes Change-Id: I94046bdfe20740c26c8183822e3002d692fde7c4
/frameworks/base/libs/hwui/Program.h
|
f3a910b423db7ad79cf61518bdd9278c048ad0d8 |
|
13-Dec-2011 |
Romain Guy <romainguy@google.com> |
Optimize state changes Change-Id: Iae59bc8dfd6427d0967472462cc1994987092827
/frameworks/base/libs/hwui/Program.h
|
3e263fac8c9c0e0fb242186b514a7af8efb40961 |
|
13-Dec-2011 |
Romain Guy <romainguy@google.com> |
Keep shaders to render properly I don't know who's to blame, SGX or Tegra2 but one of those two GPUs is not following the OpenGL ES 2.0 spec. Change-Id: I2624e0efbc9c57d571c55c8b440a5e43f08a54f2
/frameworks/base/libs/hwui/Program.h
|
05bbde70fd2a3af737656b9f8c5a25b56429632e |
|
09-Dec-2011 |
Romain Guy <romainguy@google.com> |
Free up resources by deleting shaders early on Change-Id: I29a39775732c0a48d3e6823f7afa3e741cae8541
/frameworks/base/libs/hwui/Program.h
|
8a5cc92a150bae38ec43732d941b38bb381fe153 |
|
26-Apr-2011 |
Chet Haase <chet@google.com> |
Fix various hw-accelerated line/point bugs All accelerated lines are now rendered as quads. Hairlines used to be rendered as GL_LINES, but these lines don't render the same as our non-accelerated lines, so we're using quads for everything. Also, fixed a bug in the way that we were offsetting quads (and not offseting points) to ensure that our lines/points actuall start on the same pixels as Skia's. Change-Id: I51b923cc08a9858444c430ba07bc8aa0c83cbe6a
/frameworks/base/libs/hwui/Program.h
|
67f27952c1bcb2230beef9b5ca0bf42edad436a9 |
|
08-Dec-2010 |
Romain Guy <romainguy@google.com> |
Correctly release the OpenGL Canvas on EGL error. Change-Id: Ib31fd8445f7ce5f7aa7e0205de0e7db80d024fc2
/frameworks/base/libs/hwui/Program.h
|
5b3b35296e8b2c8d3f07d32bb645d5414db41a1d |
|
28-Oct-2010 |
Romain Guy <romainguy@google.com> |
Optimize FBO drawing with regions. This optimization is currently disabled until Launcher is modified to take advantage of it. The optimization can be enabled by turning on RENDER_LAYERS_AS_REGIONS in the OpenGLRenderer.h file. Change-Id: I2fdf59d0f4dc690a3d7f712173ab8db3848b27b1
/frameworks/base/libs/hwui/Program.h
|
707b2f78ccaa09965d7e030fda3a883ce9b75ea8 |
|
12-Oct-2010 |
Romain Guy <romainguy@google.com> |
Optimize GLSL shaders. Change-Id: I9a5e01bced63d8da0c61330a543a2b805388a59d
/frameworks/base/libs/hwui/Program.h
|
889f8d1403761d5668115ced6cbb3f767cfe966d |
|
29-Jul-2010 |
Romain Guy <romainguy@google.com> |
Moved all the rendering code to the new shader generator. The generator supports features that are not yet implement in the renderer: color matrix, lighting, porterduff color blending and composite shaders. This change also adds support for repeated/mirrored non-power of 2 bitmap shaders. Change-Id: I903a11a070c0eb9cc8850a60ef305751e5b47234
/frameworks/base/libs/hwui/Program.h
|
ac670c0433d19397d4e36ced2110475b6f54fe26 |
|
28-Jul-2010 |
Romain Guy <romainguy@google.com> |
Generate shaders to cover all possible cases. With this change, all the vertex and fragment shaders used by the GL renderer are now generated based on a program description supplied by the caller. This allows the renderer to generate a large number of shaders without having to write all the possible combinations by hand. The generated shaders are stored in a program cache. Change-Id: If54d286e77ae021c724d42090da476df12a18ebb
/frameworks/base/libs/hwui/Program.h
|
694b519ac647fe998fd396fe0784cc8e179aadc4 |
|
22-Jul-2010 |
Romain Guy <romainguy@google.com> |
Add text rendering. Change-Id: Ibe5a9fa844d531b31b55e43de403a98d49f659b9
/frameworks/base/libs/hwui/Program.h
|
c0ac193b9415680f0a69e20a3f5f22d16f8053be |
|
20-Jul-2010 |
Romain Guy <romainguy@google.com> |
Add support for linear gradients. Change-Id: Id15329da065045b3f06fdaed615f33cd57608496
/frameworks/base/libs/hwui/Program.h
|
f9764a4f532561f6e2e985ff3b25112f1132ce44 |
|
17-Jul-2010 |
Romain Guy <romainguy@android.com> |
Add program for linear gradient. This change adds a new DrawLinearGradientProgram class to enable the drawing of linear gradients. Two new vertex and fragment shaders are introduced, based on DrawTextureProgram's shaders. Change-Id: I885afc076bb6cef8cd3962ae21a086fa6a03bf96
/frameworks/base/libs/hwui/Program.h
|
6926c72e25b8dec3dd4b84af0819fa1937ae7296 |
|
13-Jul-2010 |
Romain Guy <romainguy@google.com> |
Correctly support pre-multiplied alpha, optimizations, more stuff. Add support for the following drawing functions: - drawBitmap(int[]...) - drawPaint() Optimizes shader state changes by enabling/disabling attribute arrays only when needed. Adds quick rejects when drawing trivial shapes to avoid unnecessary OpenGL operations. Change-Id: Ic2c6c2ed1523d08a63a8c95601a1ec40b6c7fbc9
/frameworks/base/libs/hwui/Program.h
|
260e102162322958cf17dbd895cd6bd30dc87e32 |
|
12-Jul-2010 |
Romain Guy <romainguy@google.com> |
Optimize shader binding changes. This change also cleans up the internal API a little bit by using mat4 everywhere instead of float[16] (for the ortho matrix for instance.) Change-Id: I35924c7dc17bad17f30307118d5ed437c2ed37e0
/frameworks/base/libs/hwui/Program.h
|
0b9db91c3dc8007b47c8fd4fb9dd85be97201a88 |
|
10-Jul-2010 |
Romain Guy <romainguy@google.com> |
Remove math from the vertex shader. Change-Id: I02847a60a8734bf8b3d29ec12e76297795095e38
/frameworks/base/libs/hwui/Program.h
|
5cbbce535744b89df5ecea95de21ee3733298260 |
|
28-Jun-2010 |
Romain Guy <romainguy@android.com> |
Reduced the complexity of layers composition. This change also refactors the code base a bit by moving classes out of OpenGLRenderer into separate headers/implementations. This makes the code more manageable. This change also adds documentation for implementation methods. The undocumented methods are simply Skia's Canvas methods. Change-Id: I54c68b443580a0129251dddc1a7ac95813d5289e
/frameworks/base/libs/hwui/Program.h
|