summaryrefslogtreecommitdiffstats
path: root/libs/hwui/TextDropShadowCache.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Cleanup propertiesChris Craik2015-05-051-1/+1
| | | | | | | | | | | | bug:19967854 Separate properties from Caches, into static, RenderThread-only class. Also rewrites the means for java to set properties to correctly handle threading, and adds an override for profile bars so that SysUi doesn't clutter the screen with them. Change-Id: I6e21a96065f52b9ecc49d1a126244804ba106fa9
* Refactor blending and texture gl stateChris Craik2015-01-301-1/+1
| | | | Change-Id: Ia6b3c8b2afd3dfcee7f3ce401d846b789612054a
* Add overrides and switch to nullptr keyword for all filesChris Craik2015-01-051-2/+2
| | | | | | | Adds remaining missing overrides and nullptr usages, missed due to an extreme failure in tool usage. Change-Id: I56abd72975a3999ad13330003c348db40f59aebf
* am 582bdf9a: am d8c169fe: am 0c437fd3: Merge "Add appropriate casts for ↵Dan Albert2014-11-201-1/+2
|\ | | | | | | | | | | | | char16_t." * commit '582bdf9a5961a32de27556832e23e0611c4d1cbb': Add appropriate casts for char16_t.
| * Add appropriate casts for char16_t.Dan Albert2014-11-201-1/+2
| | | | | | | | | | | | | | | | C++11 defines a real char16_t, which is not implicitly convertible to uint16_t (and by extension jchar). Add casts as needed. Bug: 18300613 Change-Id: I00752002ef2e938bdb57f70947e8fd53ec103293
* | Clean up physical couplingTom Hudson2014-10-151-0/+1
|/ | | | | | | | Narrow the use of #include directives in hwui, replacing with forward declarations where straightforward. Speeds compiles; doesn't do any restructuring of code. Change-Id: Icac2baffb5896f55d8c6718e9bd9d4bfa02d3ca0
* Use const where possible for drawing parametersChris Craik2014-01-031-1/+1
| | | | | | They should never be modified by a Renderer, only read and copied. Change-Id: I9d8d55dca19115ee9dfeb2bb3f092ba2fb327cd4
* Clean unused parameters, disable warningsChris Craik2013-10-171-1/+1
| | | | Change-Id: Iddb872f53075dd022eeef45265594d1c6a9e2bc0
* Assume a texture is unbound after deleting itRomain Guy2013-06-061-1/+1
| | | | | | | | | | | Bug #9316260 The GL specification indicates that deleting a bound texture has the side effect of binding the default texture (name=0). This change replaces all calls to glDeleteTextures() by Caches::deleteTexture() to properly keep track of texture bindings. Change-Id: Ifbc60ef433e0f9776a668dd5bd5f0adbc65a77a0
* Introduce Caches::bindTexture() to reduce glBindTexture callsRomain Guy2013-06-041-2/+5
| | | | Change-Id: Ic345422567c020c0a9035ff51dcf2ae2a1fc59f4
* Introduce PixelBuffer API to enable PBOsRomain Guy2013-04-111-0/+4
| | | | | | | | | | | | | | | | | | | | | | | PBOs (Pixel Buffer Objects) can be used on OpenGL ES 3.0 to perform asynchronous texture uploads to free up the CPU. This change does not enable the use of PBOs unless a specific property is set (Adreno drivers have issues with PBOs at the moment, Mali drivers work just fine.) This change also cleans up Font/FontRenderer a little bit and improves performance of drop shadows generations by using memcpy() instead of a manual byte-by-byte copy. On GL ES 2.0 devices, or when PBOs are disabled, a PixelBuffer instance behaves like a simple byte array. The extra APIs introduced for PBOs (map/unmap and bind/unbind) are pretty much no-ops for CPU pixel buffers and won't introduce any significant overhead. This change also fixes a bug with text drop shadows: if the drop shadow is larger than the max texture size, the renderer would leave the GL context in a bad state and generate 0x501 errors. This change simply skips drop shadows if they are too large. Change-Id: I2700aadb0c6093431dc5dee3d587d689190c4e23
* Use free for memory chunks allocated through memalign.Ben Cheng2013-02-201-1/+1
| | | | | BUG: 8234423 Change-Id: Ic4100a780908c94540722cc4af5f73f4940431b4
* Revert "Revert "Use RenderScript for large text blurs""Chris Craik2013-02-131-1/+1
| | | | | | This reverts commit bf5703e52e3304246cbf0e73f6976f7d7312d238. Change-Id: Ic6f991277dec9e80a6fed93db91499726b30ab2a
* Revert "Use RenderScript for large text blurs"Chris Craik2013-02-131-1/+1
| | | | | | This reverts commit 3f76e65d251ead65fe8ff98e3bd4c7623fbaac07 Change-Id: Ia81cd485e5ca696bb284c419dc8a1d2f3247100e
* Use RenderScript for large text blursChris Craik2013-02-121-1/+1
| | | | | | Still fall back to simple path for small tasks Change-Id: I492f1b3f7d6fec1738f3e45cbfb15864bd23a392
* Fix crash in TextDropShadowCacheRomain Guy2012-11-301-4/+8
| | | | | | The lengths used to copy/read arrays were completely wrong. Change-Id: If21f23a73cce59bbd32975760e6d728eeeb9e40d
* Use LruCache instead of GenerationCache in libhwuiRomain Guy2012-11-291-3/+65
| | | | Change-Id: Ic26ddc7151eb5462bcd243b21daf7187ed6d3bec
* Fix bug 6892600 Font (character pairs) rendering issueRaph Levien2012-07-301-1/+3
| | | | | | | | | | | | | | Alignment on paint for actual glyph drawing needs to always be left, even when drawing centered or right aligned text. The x offset for alignment is applied by OpenGLRenderer::drawText (and needs to be early in the pipeline for quickReject to work). Similar change needed for drawing drop shadow. Also fixes bug with mispositioned underline (offset for alignment has already been applied once, no need to do it again in drawTextDecorations). Change-Id: Id3dcd62de5536a26b158d768889273a1492b35d6
* Add drop shadow for drawPosText in hwui renderer.Raph Levien2012-07-201-3/+3
| | | | | | | | | | | | | | This patch adds support for drop shadows (setShadowLayer) for drawPosText in the hwui renderer. In and of itself, it's not very important, but it's on the critical path for correct mark positioning, tracked as bug 5443796. The change itself is fairly straightforward - it basically just adds an extra "positions" argument to all draw and measure methods on the code path for drawing drop shadowed text, as well as to the cache key for cached shadow textures. Change-Id: Ic1cb63299ba61ccbef31779459ecb82aa4a5e672
* Rename (IF_)LOGD(_IF) to (IF_)ALOGD(_IF) DO NOT MERGESteve Block2012-01-031-2/+2
| | | | | | | See https://android-git.corp.google.com/g/156016 Bug: 5449033 Change-Id: I4c4e33bb9df3e39e11cd985e193e6fbab4635298
* Various OpenGL optimizationsRomain Guy2011-12-121-2/+2
| | | | Change-Id: Ib0742c96f10f5f50e7e5148b742c31b6c232d127
* Improve rendering performance on some GPUsRomain Guy2011-07-251-5/+2
| | | | | | | | This change sets textures filtering to GL_NEAREST by default. GL_LINEAR filtering is only used when textures are transformed with a scale or a rotation. This helps save a couple of fps on some GPUs. Change-Id: I1efaa452c2c79905f00238e54d886a37203a2ac1
* Avoid UTF-8 conversions and string copies whenever possible.Romain Guy2011-03-011-0/+3
| | | | Change-Id: Ie4584417bbb7247e6c567fbfdb819529e548bb8f
* Log only 1 line per process when using OpenGLRenderer.Romain Guy2011-01-211-2/+4
| | | | Change-Id: Idbdd6b84f31301e58ed53e0d50fd61fece192dfa
* Correctly compare strings in UTF-8 instead of UTF-16Romain Guy2010-12-101-4/+17
| | | | | | Bug #3272858 Change-Id: Idacd5d7c2c052b4834a8ddb5906ab32b3f548f73
* Fix possible crash when texture is NULL in the drop shadow cache.Romain Guy2010-11-091-3/+3
| | | | Change-Id: I2142c55dbcfebcdf013a7f4ae04b266a60f5ce8a
* Apply gamma correction to font rendering.Romain Guy2010-08-271-0/+1
| | | | Change-Id: I1b05f40e356221b2a5eb9400e67d77ecd98ed6c4
* Use only one GL context per process, share chaches.Romain Guy2010-08-241-0/+14
| | | | Change-Id: Ieabaa25338d2f4b8d4fd90e7401ad6e7452eae11
* Add drop shadows.Romain Guy2010-08-131-0/+134
Change-Id: Ic6a72409d4785968d1fbdff229f17ee5c00b240b