aboutsummaryrefslogtreecommitdiffstats
path: root/include/core
Commit message (Collapse)AuthorAgeFilesLines
* Several skia tunings for JB_2.5Xin Qi2013-01-203-2/+39
| | | | | | | | * Optiming constructor of Paint object * Special copy path for small object * Global Language list instead of constructing a new obj everytime. Change-Id: I8d4687fffe055166a4758059872af09bfdc973d4
* Add Android specific APIRomain Guy2012-10-161-0/+14
| | | | | | | | | Bug #7353771 This API is just a boolean property that tells the hardware renderer whether it should use mipmap levels. Change-Id: I123a334b89b0d64d711bdad43f5e2feb416de8b4
* DO NOT MERGE Han PreferenceBilly Hewlett2012-08-203-17/+90
| | | | | | | | | | | | | | | | Cherry-pick Id8c91ae0be6cad8a7ef77a0cd5803676290986c1 from master. During font initialization, create a seperate fallback list for each locale. At runtime, use the fallbacklist associated with the locale set in the paint object. Fallback files are associated with locales in fallback_fonts.xml. Multiple files can be associated with the same locale, ordering within that langauge and apart from that language in the fallback order is preserved. This changelist also includes some refactoring, notably of the functions that call getNextContext(). Change-Id: I121f0e491a522c4a8558a0066b2d8969fb8a3667
* Revert "Revert "Use Elegant fonts for Webkit, Compact fonts for Textview""Billy Hewlett2012-06-213-1/+32
| | | This reverts commit 81957ccb58db76c172e195dc3e31eba85d3e4ac9
* Revert "Use Elegant fonts for Webkit, Compact fonts for Textview"Billy Hewlett2012-06-213-32/+1
| | | This reverts commit 421654d4bf3ca50e2247a7389851d2e8f4812564
* Use Elegant fonts for Webkit, Compact fonts for TextviewBilly Hewlett2012-06-203-1/+32
| | | | | | | | | | Fonts can be marked with elegant or compact in fallback_fonts.xml. Webkit uses elegant fonts, Textview uses compact fonts (the default), unmarked fonts are used by both. Bug: 6649136 Change-Id: I6ab6173c2efc50eba8fcc488c89dfdd083fb9c06
* Fix hardcoded font path. Allow adding new font path thru Skia changes.Billy Hewlett2012-06-041-0/+14
| | | | | Bug: 6609231 Change-Id: Ie37ada42e7e78ab78318f3ed76eb627bffaddb1a
* Merge "Cleanup pixel ref mutexes in Skia" into jb-devDerek Sollenberger2012-05-162-5/+25
|\
| * Cleanup pixel ref mutexes in SkiaDerek Sollenberger2012-05-142-5/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mutexes in pixelrefs were done very sloppily initially. The code (a) assumes all pixelref subclasses want a mutex to guard their lock/unlock virtuals, and (b) most subclasses use the same mutex for *all* of their instances, even when there is no explicit need to guard modifying one instances with another. When we try drawing bitmaps from multiple threads, we are seeing a lot of slow- down from these mutexes. This CL has two changes to try to speed things up. 1. Add setPreLocked(), for pixelrefs who never need the onLockPixels virtual to be called. This speeds up those subclasses in multithreaded environs as it avoids the mutex lock all together (e.g. SkMallocPixelRef). 2. Add setMutex() to allow a subclass to change the mutex choice. ashmem wants this, since its unflattening constructor cannot pass down the null, it needs to cleanup afterwards. see https://codereview.appspot.com/6199075/ bug: 6469917 Change-Id: I81a7cfa0b2ead5a42059697eafa58de1e7a87da2
* | Add new utfToGlyphs API for GL rendererRomain Guy2012-05-141-0/+3
|/ | | | | | Bug #6408362 Change-Id: I69c21d9aeeb663aa6244132ce8d598be888886e2
* Reset Skia to the default font cache size that we used in ICS.Derek Sollenberger2012-04-191-1/+1
| | | | | bug: 6226962 Change-Id: I8d078faa836c1daa38810bc24aa24942cb70676f
* Add SkPaint.setTextLocale()Fabrice Di Meglio2012-04-111-0/+16
| | | | | | | | - will be used for better CJK shaping - forced to use a "placement new" operator because of use of sk_bzero / memcpy in the Skia contructor and copy operator Change-Id: If6f62634c9088d2401250c35239a1722102fe80c
* Skia Merge (revision 3312)Derek Sollenberger2012-03-0620-82/+489
| | | | | | | This CL also includes changes made to Android's copy of Skia in their J release branch. Change-Id: Ib2baecf48004951a3ad4a1574cdc38790c814cbc
* Skia merge (revision 3022)Derek Sollenberger2012-02-0699-2004/+3495
| | | | | | | | This CL has companion changes to account for API updates in... (1) frameworks/base (2) external/webkit Change-Id: Ibb989e76e8bd24313849f9631dbef42cdef9eb7d
* Fix rendering bug in pages with shadowed text.Derek Sollenberger2011-11-303-9/+39
| | | | | | | | | | | | | | | | | | Shadowed text currently does not get subjected to culling until immediately prior to rendering each glyph. This is problematic for any page with an axis greater than 32k as we can't covert the glyph coordinates to fixed point. Additionally, this is a large perf hit as we look at every shadowed glyph on the page for every draw call regardless of the canvas' clip. This fix enables shadowed text to be quickly rejected based on the canvas' clip when the draw text command is executed. Finally, a mirror image of this CL is currently under review for inclusion in the open-source Skia project. bug: 5571685 Change-Id: I5df94eccecbd7d77a08004b5cbcca02120e390f7
* Skia Merge (revision 1562)Derek Sollenberger2011-06-235-10/+22
| | | | Change-Id: Ief005abc9eb741ccf5efec3d1f29fe2dfc23103d
* Make this virtual function non-pure, temporarily.Jean-Baptiste Queru2011-06-131-1/+1
| | | | | | | This makes it easier for now to deal with situations where derived classes don't have an implementation. Change-Id: Iaf4b3495441cb5881ad98633e55da1c5acdd9768
* Skia Merge (revision 1510)Derek Sollenberger2011-06-0715-69/+151
| | | | | | | | | | | | | | | | | | This CL includes bug fixes and closely mirrors the version of Skia used in Chrome M13, which is likely to be our baseline for ICS. The CL also adds source files for the SampleApp which will allow us to execute basic skia tests. The SampleApp requires the utils/views directory in order to run. Finally, we have included the PDF backend for Skia in order to experiment with using it to generate PDF files for certain applications. Note: The SampleApp and PDF code are not built as part of libskia. Change-Id: I1895ccfbd8074e25f19148cc7bd1b4af571fb307
* Add method to SkPaint to get a glyph from a glyph id.Romain Guy2011-06-011-0/+1
| | | | Change-Id: I34121c66fc53aaa47aed798f7cd8e33d5977e0d8
* Skia Merge (revision 1327)Derek Sollenberger2011-05-1731-240/+736
| | | | Change-Id: I46f41274d07a3d7bac4728f8841c7f5e89dc9181
* Skia Merge (revision 1116)Derek Sollenberger2011-04-1431-381/+854
| | | | | | There is a companion change in external/webkit Change-Id: I1c4110e7520bbef3f4e5f9551adb7ec79ac1e3ed
* Fix Path generation id tracking.Romain Guy2011-03-181-3/+12
| | | | Change-Id: I5acaa683a402162c31a566c524b53b0b16445a3f
* Skia Merge (revision 950)Derek Sollenberger2011-03-1730-106/+138
| | | | | | | This merge will allow us to now import the sample app infrastructure in skia to do on device measurements. Change-Id: Idcab6b1524f371521717cde61a6e98a12d897e6b
* Skia Merge (revision 922)Derek Sollenberger2011-03-1421-145/+419
| | | | Change-Id: I7ed57d10905d8bad6486a4d7410165eec1cc2b4f
* Skia Merge (revision 842)Derek Sollenberger2011-02-246-21/+116
| | | | | | | This merge picks up the fixed width font updates and improved blur code from the Skia repository. Change-Id: Iad2301a353c31da27ca214527cf4ed8f24641749
* Merge "Skia Merge (revision 808)"Derek Sollenberger2011-02-2441-403/+1145
|\
| * Skia Merge (revision 808)Derek Sollenberger2011-02-2341-403/+1145
| | | | | | | | | | | | | | | | | | | | This merge has companion changes in the following projects in order to be compatible with changes to skia interfaces and practices: 1. /frameworks/base 2. /external/webkit Change-Id: I54092971305579e81a8fdb27bbe04ec340792e3b
* | Check for pixels allocation failureEric Hassold2011-02-231-0/+13
|/ | | | | | | | | | Standard memory allocator in Skia abort when an allocation request fails. However, when allocating in managed heap, need to check for allocation failure in allocPixels(). This add checks for all allocPixels calls in Skia Bitmap code. Bug: 3418381 Change-Id: I3c4ac403a3c073d64a689b29d3baccdc7fc90e1a
* Implement SkRegion::toString().Joe Onorato2011-01-191-0/+4
| | | | Change-Id: I012feed3eb119a9eda98989e13dacc53c0199e19
* Merge "Add optional data argument to SkPixelRef::globalRef()"Patrick Dubroy2010-12-151-1/+1
|\
| * Add optional data argument to SkPixelRef::globalRef()Patrick Dubroy2010-12-151-1/+1
| |
* | Merge "Fix issue with SkPaint references being out of date."Chet Haase2010-12-151-1/+4
|\ \ | |/ |/|
| * Fix issue with SkPaint references being out of date.Chet Haase2010-12-151-1/+4
| | | | | | | | | | | | | | | | | | | | | | The mechanism used for determining whether an SkPaint object is the same as a cached version was broken. The problem was that Skia would blow away the generationID in some situations (assignment and reset), making that ID completely invalid. This would cause the displayList rendering code to sometimes make the wrong decision, thinking that an out of date object was actually still valid. Change-Id: I5e11eb9ac41e5d87d528b99e3781a4d348f76490
* | Changes to support bitmaps allocated in the Java heap.Patrick Dubroy2010-12-143-2/+20
|/ | | Change-Id: Ib083409abc4110dafa32b5ee4bfa01c0caeb907b
* Allow bitmap reuse with PNG decodingChet Haase2010-12-101-2/+5
| | | | Change-Id: I8ba53eb6d4b99ce6352358b666d30b7668aa834f
* Skia: Merge upstream patch series that refactors SkCanvas to avoid subclassing.tedbo2010-11-112-27/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change merges upstream Skia revisions r604,r605,r618, and r623. The patch series refactors SkCanvas so that backends don't need to override it. The r623 patch was upstreamed explicitly so that this series can be made into a clean patch for Android to avoid merge conflicts in the future. The log messages from the original commits are as follows: * r604: http://code.google.com/p/skia/source/detail?r=604 Refactor SkCanvas so that backends don't need to override it. Methods or classes that should go away are marked deprecated. The only thing I know of that breaks backward compatibility is SkCanvas((SkDevice*)NULL), but that is fairly unlikely to occur in the wild because that constructor had a default value of NULL. * r605: http://code.google.com/p/skia/source/detail?r=605 Fix a memory leak in the new Canvas/Device workflow. The previous change made it difficult to inherit from SkCanvas without leaking memory. By making SkDeviceFactory not reference counted, the right thing happens more naturally, just NewCanvas : public SkCanvas(new NewDeviceFactory()) {...} * r618: http://code.google.com/p/skia/source/detail?r=618 Move the device capability method to SkDevice. These are not the capabilities of the factory, but of the device. Additionally, it is more often needed when you have a device then when you have a factory, which caused creating of a new factory. * r623: http://code.google.com/p/skia/source/detail?r=623 Remove include of SkGLDevice.h from SkGLCanvas.h The '#include "SkGLDevice.h"' from include/core/SkDevice.h requires internal Skia code to be added to the include search paths when using the deprecated API. This change adds back SkGLCanvas.cpp to avoid exposing SkGLDevice.h to the public API. The change also includes an explicit virtual destructor on SkDeviceFactory to silence a -Wnon-virtual-dtor warning and allow for -Werror. Change-Id: I3442e2801c1d8d8c9cb2a20259f15bc870c393dc
* Added generation ID to SkPaint to easily detect changed object.Chet Haase2010-10-251-0/+3
| | | | | | | | This new ID is used by display list objects to detect when the SkPaint object's properties have changed and the display list needs to copy the paint into a new object to avoid reusing an obsolete copy of it. Change-Id: I1fb7034bea63eca247b72b939cb20f0fcece067a
* Expose SkPictureFlatRomain Guy2010-09-261-0/+209
| | | | Change-Id: Ib6c873b7e7e42a3680a3d9110dae1fc369dfa393
* am 3a1cc970: Fix bug in SkImageDecoderJoseph Wen2010-09-101-0/+1
|\ | | | | | | | | | | | | Merge commit '3a1cc9700bf928ed3b1e05c7edc543124440c54c' * commit '3a1cc9700bf928ed3b1e05c7edc543124440c54c': Fix bug in SkImageDecoder
| * Fix bug in SkImageDecoderJoseph Wen2010-09-101-0/+1
| | | | | | | | Change-Id: I6d214e4d8cce49f7e12eeb924493161dadd5aa26
* | Expose Xfermode's mode in the SkXfermode class.Romain Guy2010-09-091-0/+2
| | | | | | | | Change-Id: Ibdb7620348ee7af585a58ad43b26d3d6f47c403c
* | Ensure the OpenGL renderer is not given gamma corrected fonts.Romain Guy2010-08-271-1/+1
| | | | | | | | Change-Id: Ie58f75c2bb2b09fc2e1e96ad94ad7c907d067bd4
* | Add a generation id to SkPath.Romain Guy2010-08-051-0/+3
| | | | | | | | | | | | This can be used to know whether a path was modified. Change-Id: I3a839357de4305d29cb608eacbada371682a5578
* | Expose two APIs to be able to retrieve glyphs from font cache.Romain Guy2010-07-201-0/+3
| | | | | | | | Change-Id: I4e033c009bef6f00b0cd2a8233f63351adc11df4
* | am d66241cf: am 4701b5d2: merge from open-source masterThe Android Open Source Project2010-05-121-0/+10
|\ \ | |/
| * merge from open-source masterThe Android Open Source Project2010-05-121-0/+10
| |\ | | | | | | | | | Change-Id: Ic7024b390883841714ac6fb5f6a11f87a9f707a6
| | * Added GetUnitsPerEM method to SkFontHostPeter Eliasson2010-05-111-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | GetUnitsPerEM can be used as convenience method to find out the number of font units per EM square without having to fetch the head table. Change-Id: I6f09b86a13e020ff74156571782f4bc822b7c1f3
* | | am 74054d95: am ff1f6696: merge from open-source masterThe Android Open Source Project2010-05-103-0/+19
|\ \ \ | |/ /
| * | merge from open-source masterThe Android Open Source Project2010-05-103-0/+19
| |\ \ | | |/ | | | | | | Change-Id: I064902aa9745342ccfe868331ccc000767e92fc0
| | * Added drawPosTextOnPath method.Andreas Borglin2010-04-263-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | The drawPosTextOnPath method allows for text positioned on a straight line to be drawn along a path. This method can be used by layout engines to implement the Canvas::drawTextOnPath method for complex scripts. Change-Id: I2f9c22b8c97eeacb61cd6de7429ba875a1e7ade9