aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkDrawProcs.h
Commit message (Collapse)AuthorAge
* Change type of SkGlyph::fAdvance[XY] to float.Gravatar benjaminwagner2016-03-24
| | | | | | | BUG=skia:4632 GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1737693006 Review URL: https://codereview.chromium.org/1737693006
* Remove SkDrawProcsGravatar herb2015-11-24
| | | | | | TBR=reed@google.com Review URL: https://codereview.chromium.org/1476563002
* Glyph positions maintain 32 bit integer part.Gravatar bungeman2015-03-11
| | | | | | | | | | | | | A glyph position when mapped from canvas space to device space may land outside the bounds of the current 16 bit integer part of device space. Device space is already limited to 32 bits for the integer part, but for a short space in drawText and drawPosText it is currently limited to 16 bits (SkFixed). Raise this limit by moving to 48.16. This matches the current similar fix for measureText. BUG=chromium:375322 Review URL: https://codereview.chromium.org/977623002
* Extract "text align proc" functions as reusable classesGravatar kkinnunen2014-06-12
| | | | | | | | | | | | | | | | | | | | | | | Extract "text align proc" as reusable classes. These classes need to be used when writing GrTextContext subclasses. Moves "text align proc" code that is duplicated in SkDraw and SkBitmapTextContext to SkDrawProcs.h and SkTextMapState.h. This functionality is also used in the new GrStencilAndCoverTextContext. Creates new functor classes SkTextAlignProc and SkTextAlignProcScalar which represent the previous "text align procs". Moves TextMapState from SkDraw to SkTextMapStateProc and make it similar functor. The transform should be comparable in speed, as the compiler can and does avoid the call and eliminate some of the branches. R=jvanverth@google.com, reed@google.com Author: kkinnunen@nvidia.com Review URL: https://codereview.chromium.org/335573002
* remove SkBounder -- unused and unlovedGravatar reed2014-06-03
| | | | | | | | | BUG=skia: R=scroggo@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/312553006
* Move distance field font code into GrDistanceFieldTextContext.Gravatar commit-bot@chromium.org2013-12-19
| | | | | | | | | | | | | | This avoids the SkDraw path and renders the distance field glyphs directly from GrDistanceFieldTextContext. It also disables LCD, subpixel and autohinting, and removes the supporting code when rendering DF fonts. R=reed@google.com, bsalomon@google.com, robertphillips@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/85653004 git-svn-id: http://skia.googlecode.com/svn/trunk@12770 2bbb7eff-a529-9590-31e7-b0007b416f81
* Apply hairline optimization only if the path renderer wants itGravatar commit-bot@chromium.org2013-11-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | Make the decision to convert thin, non-hairline paths to hairline paths at the renderer level. The current nv_path_rendering implementation does not render hairlines. Rendering the hairlines with normal renderers cause unneccessary gl program changes, which is quite slow. Changes the behavior of non-nv_path_rendering paths to always perform the optimization if the shape ends up being painted by a renderer that wants the optimization. Previously the optimization was applied only when callgraph started with SkCanvas::drawPath. Applies the optimization for GrAAHairLineRenderer and GrDefaultPathRenderer. This changes gm results for dashing3_{msaa4,gpu} and drawlooper_msaa4. R=bsalomon@google.com, jvanverth@google.com, rmistry@google.com Author: kkinnunen@nvidia.com Review URL: https://codereview.chromium.org/38573007 git-svn-id: http://skia.googlecode.com/svn/trunk@12357 2bbb7eff-a529-9590-31e7-b0007b416f81
* Hook in rough distance field support for fontsGravatar jvanverth@google.com2013-11-11
| | | | | | | | R=bsalomon@google.com Review URL: https://codereview.chromium.org/41213003 git-svn-id: http://skia.googlecode.com/svn/trunk@12229 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Do not apply hairline optimization for paths if nv_path_rendering is ↵Gravatar bsalomon@google.com2013-11-08
| | | | | | | | | | used" This reverts commit r12185. Review URL: https://codereview.chromium.org/66813002 git-svn-id: http://skia.googlecode.com/svn/trunk@12187 2bbb7eff-a529-9590-31e7-b0007b416f81
* Do not apply hairline optimization for paths if nv_path_rendering is usedGravatar commit-bot@chromium.org2013-11-08
| | | | | | | | | | | | | | | | | | | | | | | | Do not convert thin, non-hairline paths to hairline paths if nv_path_rendering is used. The current nv_path_rendering implementation does not render hairlines. Rendering the hairlines with normal renderers cause unneccessary gl program changes, which is quite slow. Changes the behavior of non-nv_path_rendering paths to always perform the optimization if the shape ends up being painted by the path-drawing code (GrContext::drawPathInternal). Previously the optimization was applied only when callgraph started with SkCanvas::drawPath. This changes drawlooper_msaa4, dashing3_msaa4 and dashing3_gpu R=bsalomon@google.com Author: kkinnunen@nvidia.com Review URL: https://codereview.chromium.org/38573007 git-svn-id: http://skia.googlecode.com/svn/trunk@12185 2bbb7eff-a529-9590-31e7-b0007b416f81
* Detect color masks, and divert to draw-sprite instead of maskblitters.Gravatar reed@google.com2013-05-02
| | | | | | Review URL: https://codereview.chromium.org/14637007 git-svn-id: http://skia.googlecode.com/svn/trunk@8967 2bbb7eff-a529-9590-31e7-b0007b416f81
* Always round text position correctly.Gravatar bungeman@google.com2013-02-25
| | | | | | | | | | | | | https://codereview.appspot.com/7383049/ Will require rebaseline of fontscaler GM. Must add SK_IGNORE_SUBPIXEL_AXIS_ALIGN_FIX to Chromium until ~150 layout tests can be rebaselined. git-svn-id: http://skia.googlecode.com/svn/trunk@7842 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2013-01-26
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@7406 2bbb7eff-a529-9590-31e7-b0007b416f81
* Result of running tools/sanitize_source_files.py (which was added in ↵Gravatar rmistry@google.com2012-08-23
| | | | | | | | | https://codereview.appspot.com/6465078/) This CL is part I of IV (I broke down the 1280 files into 4 CLs). Review URL: https://codereview.appspot.com/6485054 git-svn-id: http://skia.googlecode.com/svn/trunk@5262 2bbb7eff-a529-9590-31e7-b0007b416f81
* Pull xfer mode test out of generic draw-as-hairline test. Use coverage ↵Gravatar bsalomon@google.com2012-01-18
| | | | | | | | | | | rather than alpha to draw hairlines < 1pix wide in GPU. Review URL: http://codereview.appspot.com/5528112/ git-svn-id: http://skia.googlecode.com/svn/trunk@3070 2bbb7eff-a529-9590-31e7-b0007b416f81
* Subpixel text 3/8 of a pixel too far to the right.Gravatar bungeman@google.com2012-01-13
| | | | | | | http://codereview.appspot.com/5502097/ git-svn-id: http://skia.googlecode.com/svn/trunk@3037 2bbb7eff-a529-9590-31e7-b0007b416f81
* enable soft clipping (yikes)Gravatar reed@google.com2011-10-24
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@2515 2bbb7eff-a529-9590-31e7-b0007b416f81
* use new SkDrawTreatAsHairline method to decide when to approximate a thin-lineGravatar reed@google.com2011-09-19
| | | | | | | | | | with a hairline (and have its alpha modulated). idea is to be able to share this new function with SkGpuDevice git-svn-id: http://skia.googlecode.com/svn/trunk@2283 2bbb7eff-a529-9590-31e7-b0007b416f81
* Automatic update of all copyright notices to reflect new license terms.Gravatar epoger@google.com2011-07-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I have manually examined all of these diffs and restored a few files that seem to require manual adjustment. The following files still need to be modified manually, in a separate CL: android_sample/SampleApp/AndroidManifest.xml android_sample/SampleApp/res/layout/layout.xml android_sample/SampleApp/res/menu/sample.xml android_sample/SampleApp/res/values/strings.xml android_sample/SampleApp/src/com/skia/sampleapp/SampleApp.java android_sample/SampleApp/src/com/skia/sampleapp/SampleView.java experimental/CiCarbonSampleMain.c experimental/CocoaDebugger/main.m experimental/FileReaderApp/main.m experimental/SimpleCocoaApp/main.m experimental/iOSSampleApp/Shared/SkAlertPrompt.h experimental/iOSSampleApp/Shared/SkAlertPrompt.m experimental/iOSSampleApp/SkiOSSampleApp-Base.xcconfig experimental/iOSSampleApp/SkiOSSampleApp-Debug.xcconfig experimental/iOSSampleApp/SkiOSSampleApp-Release.xcconfig gpu/src/android/GrGLDefaultInterface_android.cpp gyp/common.gypi gyp_skia include/ports/SkHarfBuzzFont.h include/views/SkOSWindow_wxwidgets.h make.bat make.py src/opts/memset.arm.S src/opts/memset16_neon.S src/opts/memset32_neon.S src/opts/opts_check_arm.cpp src/ports/SkDebug_brew.cpp src/ports/SkMemory_brew.cpp src/ports/SkOSFile_brew.cpp src/ports/SkXMLParser_empty.cpp src/utils/ios/SkImageDecoder_iOS.mm src/utils/ios/SkOSFile_iOS.mm src/utils/ios/SkStream_NSData.mm tests/FillPathTest.cpp Review URL: http://codereview.appspot.com/4816058 git-svn-id: http://skia.googlecode.com/svn/trunk@1982 2bbb7eff-a529-9590-31e7-b0007b416f81
* merge with changes for GPU backendGravatar reed@android.com2010-12-20
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@637 2bbb7eff-a529-9590-31e7-b0007b416f81
* grab from latest androidGravatar reed@android.com2008-12-17
git-svn-id: http://skia.googlecode.com/svn/trunk@27 2bbb7eff-a529-9590-31e7-b0007b416f81