aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ports
Commit message (Collapse)AuthorAge
* Provide static global initializers for SkColorTable and SkComposeShader.Gravatar scroggo2012-07-02
| | | | | | | | | | This makes some GMs which were broken on Android work. Reenable them on Android. Also fix a typo in gmmain. Review URL: https://codereview.appspot.com/6344069 git-svn-id: http://skia.googlecode.com/svn/trunk@4426 2bbb7eff-a529-9590-31e7-b0007b416f81
* Cleanup flattening code to properly serialize lighting image filters.Gravatar djsollen@google.com2012-06-26
| | | | | | Review URL: https://codereview.appspot.com/6333070 git-svn-id: http://skia.googlecode.com/svn/trunk@4340 2bbb7eff-a529-9590-31e7-b0007b416f81
* [android] Add an API to load customized font config for testing.Gravatar djsollen@google.com2012-06-25
| | | | | | | | | | | When running WebKit layout tests, we need to load some fonts from Linux to match baselines of chromium linux. However, font config file is hard-coded in Skia now. This change add an API to customize font config in skia. https://codereview.appspot.com/6296067/ git-svn-id: http://skia.googlecode.com/svn/trunk@4316 2bbb7eff-a529-9590-31e7-b0007b416f81
* add MS UI GOTHIC to list of bad fonts.Gravatar reed@google.com2012-06-18
| | | | | | | | | | specify per-rect-edge outset for bad fonts http://code.google.com/p/chromium/issues/detail?id=121586 git-svn-id: http://skia.googlecode.com/svn/trunk@4275 2bbb7eff-a529-9590-31e7-b0007b416f81
* add more font names to our extra-bottom-space hackGravatar reed@google.com2012-06-15
| | | | | | | | | | http://code.google.com/p/chromium/issues/detail?id=130842 Change cached names to be UTF8 encoded, since we now have some non-ascii names git-svn-id: http://skia.googlecode.com/svn/trunk@4264 2bbb7eff-a529-9590-31e7-b0007b416f81
* http://codereview.appspot.com/6307089Gravatar reed@google.com2012-06-13
| | | | | | | | Detect bad font, and adjust glyph heights to avoid clipping git-svn-id: http://skia.googlecode.com/svn/trunk@4257 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix warnings on Mac in miscellaneous filesGravatar caryclark@google.com2012-06-06
| | | | | | | | | | | | | | | | | | Fix these class of warnings: - unused functions - unused locals - sign mismatch - missing function prototypes - missing newline at end of file - 64 to 32 bit truncation The changes prefer to link in dead code in the debug build with 'if (false)' than to comment it out, but trivial cases are commented out or sometimes deleted if it appears to be a copy/paste error. Review URL: https://codereview.appspot.com/6305047 git-svn-id: http://skia.googlecode.com/svn/trunk@4186 2bbb7eff-a529-9590-31e7-b0007b416f81
* Added missing #include in SkGlobalInitialization_default.cpp for Android buildGravatar robertphillips@google.com2012-06-05
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@4156 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixed flattening of SkStippleMaskFilterGravatar robertphillips@google.com2012-06-05
| | | | | | | | http://codereview.appspot.com/6279052/ git-svn-id: http://skia.googlecode.com/svn/trunk@4154 2bbb7eff-a529-9590-31e7-b0007b416f81
* Serialize support for GDI.Gravatar bungeman@google.com2012-06-01
| | | | | | | | http://codereview.appspot.com/6263046/ git-svn-id: http://skia.googlecode.com/svn/trunk@4126 2bbb7eff-a529-9590-31e7-b0007b416f81
* read/write sfnt-data length, to match convetion of other fonthosts.Gravatar reed@google.com2012-06-01
| | | | | | | | | | | | TODO: move that "convention" into shared code (SkTypeface.cpp or SkFontHost.cpp) and just require each port to support: 1. typeface <--> descriptor 2. typeface_raw_data <--> stream (possibly with algo-style flags) git-svn-id: http://skia.googlecode.com/svn/trunk@4125 2bbb7eff-a529-9590-31e7-b0007b416f81
* use SkFontDescriptor on macGravatar reed@google.com2012-06-01
| | | | | | Review URL: https://codereview.appspot.com/6247064 git-svn-id: http://skia.googlecode.com/svn/trunk@4117 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove 'legacy' font descriptor methods.Gravatar bungeman@google.com2012-06-01
| | | | | | | http://codereview.appspot.com/6261059/ git-svn-id: http://skia.googlecode.com/svn/trunk@4115 2bbb7eff-a529-9590-31e7-b0007b416f81
* Store font family when serializing android fonts.Gravatar djsollen@google.com2012-06-01
| | | | | | Review URL: https://codereview.appspot.com/6259063 git-svn-id: http://skia.googlecode.com/svn/trunk@4114 2bbb7eff-a529-9590-31e7-b0007b416f81
* Update the implementation of SkTypeface_android.h functions.Gravatar djsollen@google.com2012-06-01
| | | | | | | | | | | This CL removes the hardcoded mappings of FallbackScripts to a particular font file and replaces it with a dynamic mechanism that takes a style and representative character code for a given FallbackScript class and returns the most appropriate SkTypeface that contains that character code. Review URL: https://codereview.appspot.com/6197074 git-svn-id: http://skia.googlecode.com/svn/trunk@4111 2bbb7eff-a529-9590-31e7-b0007b416f81
* add more names to fontdescriptorGravatar reed@google.com2012-05-31
| | | | | | Review URL: https://codereview.appspot.com/6249074 git-svn-id: http://skia.googlecode.com/svn/trunk@4110 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add SkFontDescriptor for serializing fonts.Gravatar djsollen@google.com2012-05-31
| | | | | | Review URL: https://codereview.appspot.com/6250080 git-svn-id: http://skia.googlecode.com/svn/trunk@4106 2bbb7eff-a529-9590-31e7-b0007b416f81
* Change patheffect to take a (new) StrokeRec object, which encapsulates the fillGravatar reed@google.com2012-05-25
| | | | | | | | | | | | | | | | | | | or stroke parameters for a path. Today, the patheffect only sees if the caller was going to stroke or fill, and if stroke, it just sees the width. With this change, the effect can see all of the related parameters (e.g. cap/join/miter). No other change is intended at this time. After this change, I hope to use this additional data to allow SkDashPathEffect to, at times, apply the stroke as part of its effect, which may be much more efficient than first dashing, and then reading that and stroking it. Most of these files changed just because of the new parameter to filterPath. The key changes are in SkPathEffect.[h,cpp], SkPaint.cpp and SkScalerContext.cpp Review URL: https://codereview.appspot.com/6250051 git-svn-id: http://skia.googlecode.com/svn/trunk@4048 2bbb7eff-a529-9590-31e7-b0007b416f81
* revert 4046 -- GM:pathfill failed on one bot, maybe uninitialized memory ↵Gravatar reed@google.com2012-05-24
| | | | | | somewhere? git-svn-id: http://skia.googlecode.com/svn/trunk@4047 2bbb7eff-a529-9590-31e7-b0007b416f81
* Change patheffect to take a (new) StrokeRec object, which encapsulates the fillGravatar reed@google.com2012-05-24
| | | | | | | | | | | | | | | | | | | or stroke parameters for a path. Today, the patheffect only sees if the caller was going to stroke or fill, and if stroke, it just sees the width. With this change, the effect can see all of the related parameters (e.g. cap/join/miter). No other change is intended at this time. After this change, I hope to use this additional data to allow SkDashPathEffect to, at times, apply the stroke as part of its effect, which may be much more efficient than first dashing, and then reading that and stroking it. Most of these files changed just because of the new parameter to filterPath. The key changes are in SkPathEffect.[h,cpp], SkPaint.cpp and SkScalerContext.cpp Review URL: https://codereview.appspot.com/6249050 git-svn-id: http://skia.googlecode.com/svn/trunk@4046 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix assignment of non-copyable.Gravatar bungeman@google.com2012-05-21
| | | | | | | see http://connect.microsoft.com/VisualStudio/feedback/details/552586/inherting-noncopyable-base-allows-equal-sign-initialization git-svn-id: http://skia.googlecode.com/svn/trunk@4008 2bbb7eff-a529-9590-31e7-b0007b416f81
* CreateTypefaceFromStream for GDI.Gravatar bungeman@google.com2012-05-18
| | | | | | | http://codereview.appspot.com/5616047/ git-svn-id: http://skia.googlecode.com/svn/trunk@4001 2bbb7eff-a529-9590-31e7-b0007b416f81
* reuse() is no longer available, call reset()Gravatar reed@google.com2012-05-17
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3990 2bbb7eff-a529-9590-31e7-b0007b416f81
* Mutexes in pixelrefs were done very sloppily initially. The code (a) assumes allGravatar reed@google.com2012-05-17
| | | | | | | | | | | | | | | | | | | | 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. Review URL: https://codereview.appspot.com/6199075 git-svn-id: http://skia.googlecode.com/svn/trunk@3985 2bbb7eff-a529-9590-31e7-b0007b416f81
* WeakRefCntGravatar bungeman@google.com2012-05-16
| | | | | | | http://codereview.appspot.com/5649046/ git-svn-id: http://skia.googlecode.com/svn/trunk@3978 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add bench and test for SkRefCnt.Gravatar bungeman@google.com2012-05-14
| | | | | | | | | http://codereview.appspot.com/6195071/ This also adds a cross platform SkThread for testing purposes. git-svn-id: http://skia.googlecode.com/svn/trunk@3921 2bbb7eff-a529-9590-31e7-b0007b416f81
* Use a NDK-compliant way of reading locale.Gravatar djsollen@google.com2012-05-10
| | | | | | Remove !SK_BUILD_FOR_ANDROID_NDK from locale-related code git-svn-id: http://skia.googlecode.com/svn/trunk@3899 2bbb7eff-a529-9590-31e7-b0007b416f81
* move SkStrokePathEffect into hiding for now, as its functionality is rethought.Gravatar reed@google.com2012-05-10
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3890 2bbb7eff-a529-9590-31e7-b0007b416f81
* add flag/hint to PlatformGetSpecific. If true, then the caller requires thatGravatar reed@google.com2012-05-08
| | | | | | | | | | | the tls slot be allocated even if this is the first, to ensure that it can later call PlatformSetSpecific. When this is false (which is most of the time) the implementation may optimize by not even creating the slot, and just returning null. git-svn-id: http://skia.googlecode.com/svn/trunk@3871 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove unused ptr/len parameters from CreateTypefaceGravatar reed@google.com2012-05-07
| | | | | | Review URL: https://codereview.appspot.com/6201056 git-svn-id: http://skia.googlecode.com/svn/trunk@3862 2bbb7eff-a529-9590-31e7-b0007b416f81
* must include SkTLS.hGravatar reed@google.com2012-05-07
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3860 2bbb7eff-a529-9590-31e7-b0007b416f81
* impl SkTLS for windows, refactoring to share code with pthread implGravatar reed@google.com2012-05-07
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3859 2bbb7eff-a529-9590-31e7-b0007b416f81
* Upstream font changes from Android repository.Gravatar djsollen@google.com2012-05-04
| | | | | | Review URL: https://codereview.appspot.com/6166043 git-svn-id: http://skia.googlecode.com/svn/trunk@3838 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix copy/paste errorGravatar reed@google.com2012-04-23
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3753 2bbb7eff-a529-9590-31e7-b0007b416f81
* add SkTLS::DeleteGravatar reed@google.com2012-04-23
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3752 2bbb7eff-a529-9590-31e7-b0007b416f81
* add experimental tls (for font cache eventually)Gravatar reed@google.com2012-04-23
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3748 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix the Android build.Gravatar scroggo@google.com2012-04-20
| | | | | | | Use the correct macro for SkEmbossMaskFilter Review URL: https://codereview.appspot.com/6081045 git-svn-id: http://skia.googlecode.com/svn/trunk@3743 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix gdi assert that the font is not a vector FON font.Gravatar bungeman@google.com2012-04-20
| | | | | | | See http://code.google.com/p/chromium/issues/detail?id=124313 git-svn-id: http://skia.googlecode.com/svn/trunk@3740 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix memory leaksGravatar reed@google.com2012-04-18
| | | | | | Review URL: https://codereview.appspot.com/6063049 git-svn-id: http://skia.googlecode.com/svn/trunk@3724 2bbb7eff-a529-9590-31e7-b0007b416f81
* Basic support for bitmap fonts on Windows.Gravatar bungeman@google.com2012-04-18
| | | | | | | http://codereview.appspot.com/6062044/ git-svn-id: http://skia.googlecode.com/svn/trunk@3723 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add cast to support 64 bit.Gravatar caryclark@google.com2012-04-16
| | | | | | | http://code.google.com/p/skia/issues/detail?id=524 Review URL: https://codereview.appspot.com/6038053 git-svn-id: http://skia.googlecode.com/svn/trunk@3701 2bbb7eff-a529-9590-31e7-b0007b416f81
* Some fonts do not measure correctly in Mountain Lion,Gravatar caryclark@google.com2012-04-13
| | | | | | | | carrying over a bug from Lion. Add the check appropriately. Review URL: https://codereview.appspot.com/6026045 git-svn-id: http://skia.googlecode.com/svn/trunk@3675 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix crash with LCD vertical text.Gravatar bungeman@google.com2012-04-12
| | | | | | | https://codereview.appspot.com/6012050/ git-svn-id: http://skia.googlecode.com/svn/trunk@3660 2bbb7eff-a529-9590-31e7-b0007b416f81
* Compare scalars to scalars (fixes fixed point).Gravatar bungeman@google.com2012-04-02
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3570 2bbb7eff-a529-9590-31e7-b0007b416f81
* Temp fix for very large text sizes.Gravatar bungeman@google.com2012-04-02
| | | | | | | http://codereview.appspot.com/5970065/ git-svn-id: http://skia.googlecode.com/svn/trunk@3569 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix deadlock in Android's font deserializer.Gravatar djsollen@google.com2012-03-30
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3551 2bbb7eff-a529-9590-31e7-b0007b416f81
* partial revert of r3541 to removed accidentally uploaded fileGravatar djsollen@google.com2012-03-29
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@3542 2bbb7eff-a529-9590-31e7-b0007b416f81
* Landing arm patch from contributor.Gravatar djsollen@google.com2012-03-29
| | | | | | http://codereview.appspot.com/5649055 git-svn-id: http://skia.googlecode.com/svn/trunk@3541 2bbb7eff-a529-9590-31e7-b0007b416f81
* Cleanup code related to SkFlattenable::flatten()Gravatar djsollen@google.com2012-03-29
| | | | | | | | | | | | | | | | | The following changes were made by this CL: 1. Make flatten() a protected method as callers should use SkFlattenableWriteBuffer to flatten an object 2. Make flatten a const method (including subclasses) 3. Mark subclass implementation of flatten with SK_OVERRIDE 4. Ensure overridden flatten impls call their parent 5. Remove no-op implementations of flatten from subclasses Additionally, if necessary the unflattening constructor was also moved to the protected section of the subclasses header if it was not already there. git-svn-id: http://skia.googlecode.com/svn/trunk@3540 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix coverity defects in FontHost_FreeTypeGravatar vandebo@chromium.org2012-03-28
| | | | | | | | Reviewed in https://codereview.appspot.com/5940049/ Review URL: https://codereview.appspot.com/5942043 git-svn-id: http://skia.googlecode.com/svn/trunk@3536 2bbb7eff-a529-9590-31e7-b0007b416f81