aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
Commit message (Collapse)AuthorAge
* Replace uses of GR_DEBUG by SK_DEBUG.Gravatar commit-bot@chromium.org2013-08-28
| | | | | | | | | | | BUG=None R=bsalomon@google.com, robertphillips@google.com Author: tfarina@chromium.org Review URL: https://chromiumcodereview.appspot.com/23137022 git-svn-id: http://skia.googlecode.com/svn/trunk@10978 2bbb7eff-a529-9590-31e7-b0007b416f81
* Handle SkStream::rewind properly.Gravatar scroggo@google.com2013-08-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | include/core/SkStream.h: Update documentation to state that rewinding a stream at the beginning should return true. This is important because our decoders fail if rewind returns false, assuming that the stream is not at the beginning. src/images/SkImageDecoder_libpng.cpp: If rewind fails, call png_error. src/images/SkImageDecoder_libwebp.cpp: If rewind fails, report an error and return false. src/images/SkImageRef.cpp: If rewind fails report an error and return false. FIXME: Need to handle flattening properly. Should I perhaps move writeStream into SkOrderedWriteBuffer? src/images/SkJpegUtility.cpp: Report a jpeg error on failure to rewind. BUG=https://b.corp.google.com/issue?id=8432093 R=bungeman@google.com, djsollen@google.com, reed@google.com Review URL: https://codereview.chromium.org/22861028 git-svn-id: http://skia.googlecode.com/svn/trunk@10977 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix issue on devices running an OS prior to 4.2 when the fallback font file ↵Gravatar djsollen@google.com2013-08-28
| | | | | | | | | | | was potential stored in a different location on device. BUG=chromium:183830 R=scroggo@google.com Review URL: https://codereview.chromium.org/23621002 git-svn-id: http://skia.googlecode.com/svn/trunk@10972 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-08-28
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10968 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix for 10963: Use mx instead of my where mx is wanted.Gravatar bungeman@google.com2013-08-28
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10966 2bbb7eff-a529-9590-31e7-b0007b416f81
* Clear unknown DirectWrite font metrics.Gravatar bungeman@google.com2013-08-27
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10963 2bbb7eff-a529-9590-31e7-b0007b416f81
* In image filters, apply the CTM and offset to the crop rect. This is ↵Gravatar senorblanco@chromium.org2013-08-27
| | | | | | | | | | | | | | necessary to compensate for both clipping applied by the compositor (communicated via the CTM) and for cropping applied in upstream image filters (communicated via the offset). This requires a few ugly conversions, since the crop rect is an SkIRect, and the ctm is an SkMatrix. I also had to offset the matrix passed to filter evaluation by drawSprite() and internalDrawBitmap() by the primitive position. This is the same offset that is applied when drawing the primitive, to compensate for the internal saveLayer(). Also apply the total matrix to the filter params in asNewEffect(), so that (for example) lighting params are offset by both the compositor clipping and upstream crop rects. R=reed@google.com Review URL: https://codereview.chromium.org/23295017 git-svn-id: http://skia.googlecode.com/svn/trunk@10961 2bbb7eff-a529-9590-31e7-b0007b416f81
* Only destroy huffman if build succeeded.Gravatar scroggo@google.com2013-08-27
| | | | | | | | | | | | | | The earlier code assumed that if jpeg_create_huffman_index succeeded but jpeg_build_huffman_index failed that the index would still need to be destroyed. This is not the case. Only call jpeg_destroy_huffman_index if both succeeded. BUG=http://b.corp.google.com/issue?id=10263847 Review URL: https://codereview.chromium.org/22859042 git-svn-id: http://skia.googlecode.com/svn/trunk@10954 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix _GDI::generateCharToGlyph to properly handle missing glyphs.Gravatar bungeman@google.com2013-08-27
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10945 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of r10943.Gravatar rmistry@google.com2013-08-27
| | | | | | Review URL: https://codereview.chromium.org/23626002 git-svn-id: http://skia.googlecode.com/svn/trunk@10944 2bbb7eff-a529-9590-31e7-b0007b416f81
* add SkDeviceLooper to handle larger-than-fixedpointGravatar reed@google.com2013-08-27
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/23392006 git-svn-id: http://skia.googlecode.com/svn/trunk@10943 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix issue when the family name is reused among multiple families.Gravatar djsollen@google.com2013-08-27
| | | | | | | | | BUG=chromium:274117 R=reed@google.com Review URL: https://codereview.chromium.org/23592002 git-svn-id: http://skia.googlecode.com/svn/trunk@10942 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix compiler warning/error in r10936Gravatar robertphillips@google.com2013-08-27
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10938 2bbb7eff-a529-9590-31e7-b0007b416f81
* Blur refactoringGravatar robertphillips@google.com2013-08-27
| | | | | | | | https://codereview.chromium.org/21835004/ git-svn-id: http://skia.googlecode.com/svn/trunk@10936 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix clip expansion in SkPictureRecord::recordRestoreOffsetPlaceholder()Gravatar fmalita@google.com2013-08-27
| | | | | | | | | | For operations which can expand the region, zeroing previous clip ops' restore offsets is not enough: we need to also break the chain - otherwise the next restore() will simply traverse back and reset the skip offsets. R=robertphillips@google.com Review URL: https://codereview.chromium.org/22987003 git-svn-id: http://skia.googlecode.com/svn/trunk@10934 2bbb7eff-a529-9590-31e7-b0007b416f81
* [PDF] Fix printing crashes caused by font streams that don't support ↵Gravatar vandebo@chromium.org2013-08-26
| | | | | | | | | | | | | getMemoryBase(). An apparently recently change started putting web fonts into SkStream objects that don't support getMemoryBase(). This change uses writeStream to avoid needing to call getMemoryBase(). BUG=chromium:274440 R=bungeman@google.com Review URL: https://codereview.chromium.org/23437004 git-svn-id: http://skia.googlecode.com/svn/trunk@10928 2bbb7eff-a529-9590-31e7-b0007b416f81
* Update SkLumaMaskXfermode partial coverage handling.Gravatar fmalita@google.com2013-08-26
| | | | | | | | | | | Use lerp-to-dst instead of straight coverage scaling to align the behavior with the other transfer modes. R=reed@google.com Review URL: https://codereview.chromium.org/23453004 git-svn-id: http://skia.googlecode.com/svn/trunk@10927 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove mismatched delete.Gravatar scroggo@google.com2013-08-26
| | | | | | | | | | | Use SkAutoTArray to create an array and delete it safely. BUG=https://code.google.com/p/skia/issues/detail?id=1547 R=bungeman@google.com Review URL: https://codereview.chromium.org/23068033 git-svn-id: http://skia.googlecode.com/svn/trunk@10925 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "[PDF] Fix printing crashes caused by font streams that don't support ↵Gravatar vandebo@chromium.org2013-08-26
| | | | | | | | | | getMemoryBase()." This reverts commit r10918 Review URL: https://codereview.chromium.org/23351007 git-svn-id: http://skia.googlecode.com/svn/trunk@10920 2bbb7eff-a529-9590-31e7-b0007b416f81
* [PDF] Fix printing crashes caused by font streams that don't support ↵Gravatar vandebo@chromium.org2013-08-26
| | | | | | | | | | | | | getMemoryBase(). An apparently recently change started putting web fonts into SkStream objects that don't support getMemoryBase(). This change uses writeStream to avoid needing to call getMemoryBase(). BUG=chromium:274440 R=bungeman@google.com Review URL: https://codereview.chromium.org/23414007 git-svn-id: http://skia.googlecode.com/svn/trunk@10918 2bbb7eff-a529-9590-31e7-b0007b416f81
* Implement highQualityFilter16 so GM doesn't crash when you give it resources.Gravatar mtklein@google.com2013-08-26
| | | | | | | | | | | | | | Testing consisted of: 1) ninja -C out/Debug gm && gm -i resources --match mandrill_512 -w /tmp/gm 2) notice that gm didn't segfault 3) look in /tmp/gm and see a bunch of handsome monkeys BUG=skia:1517 R=humper@google.com Review URL: https://codereview.chromium.org/22801016 git-svn-id: http://skia.googlecode.com/svn/trunk@10917 2bbb7eff-a529-9590-31e7-b0007b416f81
* Reverting r10901 (Add unpremultiply support and GM)Gravatar robertphillips@google.com2013-08-25
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10909 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add unpremultiply support and GMGravatar commit-bot@chromium.org2013-08-23
| | | | | | | | | | R=vandebo@chromium.org, edisonn@google.com Author: richardlin@chromium.org Review URL: https://chromiumcodereview.appspot.com/22831039 git-svn-id: http://skia.googlecode.com/svn/trunk@10901 2bbb7eff-a529-9590-31e7-b0007b416f81
* Only assert that conic/quad effects get created if they are to be used.Gravatar commit-bot@chromium.org2013-08-23
| | | | | | | | | | R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://chromiumcodereview.appspot.com/22891023 git-svn-id: http://skia.googlecode.com/svn/trunk@10900 2bbb7eff-a529-9590-31e7-b0007b416f81
* Use indexed extensions on ES3.Gravatar commit-bot@chromium.org2013-08-23
| | | | | | | | | | R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://chromiumcodereview.appspot.com/23359002 git-svn-id: http://skia.googlecode.com/svn/trunk@10899 2bbb7eff-a529-9590-31e7-b0007b416f81
* Refactor SkPDFImageGravatar commit-bot@chromium.org2013-08-23
| | | | | | | | | | R=vandebo@chromium.org, edisonn@google.com Author: richardlin@chromium.org Review URL: https://chromiumcodereview.appspot.com/22889020 git-svn-id: http://skia.googlecode.com/svn/trunk@10896 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add GMs for gpu Bezier shadersGravatar commit-bot@chromium.org2013-08-23
| | | | | | | | | | | BUG= R=bsalomon@google.com, jvanverth@google.com, robertphillips@google.com Author: egdaniel@google.com Review URL: https://chromiumcodereview.appspot.com/23361024 git-svn-id: http://skia.googlecode.com/svn/trunk@10892 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add luminance mask transfer modes.Gravatar commit-bot@chromium.org2013-08-23
| | | | | | | | | | | | | | | | | This adds kSrcInLum_Mode and kDstInLum_Mode, to support CSS and SVG luminance masks (http://www.w3.org/TR/css-masking/#MaskValues , http://www.w3.org/TR/SVG/masking.html#Masking ). The transfer coefficient is computed according to http://www.w3.org/TR/2011/REC-SVG11-20110816/filters.html#feColorMatrixElement "luminance-to-alpha": luma = 0.2125 * r + 0.7154 * g + 0.0721 * b R=bsalomon@google.com, reed@google.com, robertphillips@google.com, vandebo@chromium.org Author: fmalita@chromium.org Review URL: https://chromiumcodereview.appspot.com/22918012 git-svn-id: http://skia.googlecode.com/svn/trunk@10887 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-08-23
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10886 2bbb7eff-a529-9590-31e7-b0007b416f81
* Pull out Effect Shaders in GPU Path RendererGravatar commit-bot@chromium.org2013-08-22
| | | | | | | | | | | | | | | | | | Move the effects in HairLinePathRender (and eventually others into their own class called GrBezierEffects. This will allow for more sharing of code between different path renderers on GPU. BUG= Committed: http://code.google.com/p/skia/source/detail?r=10877 R=bsalomon@google.com, jvanverth@google.com, robertphillips@google.com Author: egdaniel@google.com Review URL: https://chromiumcodereview.appspot.com/23004010 git-svn-id: http://skia.googlecode.com/svn/trunk@10884 2bbb7eff-a529-9590-31e7-b0007b416f81
* Improve performance of matrix inversion.Gravatar shawnsingh@chromium.org2013-08-22
| | | | | | | | | | | | | | | The inversion of scale+translate matrices was using 6 division operations when it could be using 3. Also, general affine matrices do not need to compute perspective components of the matrix. This patch updates the matrix inversion with those optimizations, and includes benchmark code to exercise those paths. R=jvanverth@google.com Review URL: https://codereview.chromium.org/23296006 git-svn-id: http://skia.googlecode.com/svn/trunk@10883 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Pull out Effect Shaders in GPU Path Renderer"Gravatar egdaniel@google.com2013-08-22
| | | | | | This reverts commit c48a99661cb3df9baa7012c001f8d7dcf0a2f368. git-svn-id: http://skia.googlecode.com/svn/trunk@10881 2bbb7eff-a529-9590-31e7-b0007b416f81
* skia: Add SK_API to SkDiscardableMemory.Gravatar commit-bot@chromium.org2013-08-22
| | | | | | | | | | | R=scroggo@google.com, reed@google.com, bsalomon@chromium.org BUG=229120 Author: ernstm@chromium.org Review URL: https://chromiumcodereview.appspot.com/23385003 git-svn-id: http://skia.googlecode.com/svn/trunk@10878 2bbb7eff-a529-9590-31e7-b0007b416f81
* Pull out Effect Shaders in GPU Path RendererGravatar commit-bot@chromium.org2013-08-22
| | | | | | | | | | | | | | | Move the effects in HairLinePathRender (and eventually others into their own class called GrBezierEffects. This will allow for more sharing of code between different path renderers on GPU. BUG= R=bsalomon@google.com, jvanverth@google.com, robertphillips@google.com Author: egdaniel@google.com Review URL: https://chromiumcodereview.appspot.com/23004010 git-svn-id: http://skia.googlecode.com/svn/trunk@10877 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove the call to getFontMetrics from SkBBoxRecordGravatar commit-bot@chromium.org2013-08-22
| | | | | | | | | | R=reed@google.com, caryclark@google.com Author: sglez@google.com Review URL: https://chromiumcodereview.appspot.com/23001007 git-svn-id: http://skia.googlecode.com/svn/trunk@10876 2bbb7eff-a529-9590-31e7-b0007b416f81
* My clang now doesn't complain about !"foo".Gravatar mtklein@google.com2013-08-22
| | | | | | | | | BUG= R=robertphillips@google.com Review URL: https://codereview.chromium.org/22875037 git-svn-id: http://skia.googlecode.com/svn/trunk@10874 2bbb7eff-a529-9590-31e7-b0007b416f81
* Restyle SkPDFImageShader and support tiling bitmaps outside clip boundsGravatar commit-bot@chromium.org2013-08-21
| | | | | | | | | | | BUG=chromium:99458 R=edisonn@google.com, vandebo@chromium.org Author: richardlin@chromium.org Review URL: https://chromiumcodereview.appspot.com/22884013 git-svn-id: http://skia.googlecode.com/svn/trunk@10870 2bbb7eff-a529-9590-31e7-b0007b416f81
* Better error reporting when dynamic loading fails with DirectWrite.Gravatar bungeman@google.com2013-08-21
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10869 2bbb7eff-a529-9590-31e7-b0007b416f81
* Create new target to hold gpu test code, enable direct testing of GrEffects ↵Gravatar commit-bot@chromium.org2013-08-21
| | | | | | | | | | | | in GM. R=robertphillips@google.com, jvanverth@google.com, egdaniel@google.com Author: bsalomon@google.com Review URL: https://chromiumcodereview.appspot.com/23352003 git-svn-id: http://skia.googlecode.com/svn/trunk@10866 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add an empty typeface as a default-default.Gravatar bungeman@google.com2013-08-21
| | | | | | | | R=reed@google.com Review URL: https://codereview.chromium.org/22861017 git-svn-id: http://skia.googlecode.com/svn/trunk@10857 2bbb7eff-a529-9590-31e7-b0007b416f81
* Implement SkEmptyFontMgr::onLegacyCreateTypeface and make pure virtual.Gravatar bungeman@google.com2013-08-21
| | | | | | | | R=reed@google.com Review URL: https://codereview.chromium.org/22849025 git-svn-id: http://skia.googlecode.com/svn/trunk@10852 2bbb7eff-a529-9590-31e7-b0007b416f81
* allow both GDI and DW fontmgrs at the same timeGravatar bungeman@google.com2013-08-21
| | | | | | | | | | | | | BUG= R=bungeman@google.com Committed: https://code.google.com/p/skia/source/detail?r=10718 Committed: https://code.google.com/p/skia/source/detail?r=10788 Review URL: https://codereview.chromium.org/23058002 git-svn-id: http://skia.googlecode.com/svn/trunk@10851 2bbb7eff-a529-9590-31e7-b0007b416f81
* Avoid getLength in ico decoder.Gravatar scroggo@google.com2013-08-21
| | | | | | | | | | | | | | Only call getLength() if hasLength() returned true. Otherwise, copy the stream into an SkDynamicMemoryWStream and copy it into alloc'ed space. Share common code between bmp and ico. BUG=https://b.corp.google.com/issue?id=8432093 R=djsollen@google.com Review URL: https://codereview.chromium.org/23330002 git-svn-id: http://skia.googlecode.com/svn/trunk@10850 2bbb7eff-a529-9590-31e7-b0007b416f81
* Make BMP decoder not depend on call to getLength.Gravatar scroggo@google.com2013-08-21
| | | | | | | | | | | | If the decoder does not have a length, use an SkDynamicMemoryStream to copy it to contiguous memory, to be passed to BmpDecoderHelper. BUG=https://b.corp.google.com/issue?id=8432093 R=djsollen@google.com Review URL: https://codereview.chromium.org/22877020 git-svn-id: http://skia.googlecode.com/svn/trunk@10849 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove dependency on getLength from webp decoder.Gravatar scroggo@google.com2013-08-21
| | | | | | | | | | | | | | | | | In webp_parse_header, continue reading until end of stream is reached, or we have read WEBP_VP8_HEADER_SIZE bytes. Do not check to see if the stream was too short, since it may not have a way to report its length, and WEBP_VP8_HEADER_SIZE is padded slightly. Instead, depend on WebPGetFeatures to report that the stream did not have enough data. In webp_idecode, only check length if it is available. BUG=https://b.corp.google.com/issue?id=8432093 R=djsollen@google.com, vikasa@google.com Review URL: https://codereview.chromium.org/22841005 git-svn-id: http://skia.googlecode.com/svn/trunk@10848 2bbb7eff-a529-9590-31e7-b0007b416f81
* Update DirectWrite code so that it is loadable on XP.Gravatar bungeman@google.com2013-08-21
| | | | | | | | | | | This change delay loads GetUserDefaultLocaleName since it is available in Vista+. R=reed@google.com Review URL: https://codereview.chromium.org/23380002 git-svn-id: http://skia.googlecode.com/svn/trunk@10847 2bbb7eff-a529-9590-31e7-b0007b416f81
* Recognize that ES3 supports texture storage. Add workaround for apparent ↵Gravatar commit-bot@chromium.org2013-08-21
| | | | | | | | | | | | Adreno bug. R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://chromiumcodereview.appspot.com/22856006 git-svn-id: http://skia.googlecode.com/svn/trunk@10845 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-08-21
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10842 2bbb7eff-a529-9590-31e7-b0007b416f81
* Chromium's clang bots do not like the SkASSERT(!"foo") constructGravatar robertphillips@google.com2013-08-20
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@10840 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add validation check that linewidth func is present (we already call it on ES).Gravatar commit-bot@chromium.org2013-08-20
| | | | | | | | | | R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://chromiumcodereview.appspot.com/22842008 git-svn-id: http://skia.googlecode.com/svn/trunk@10839 2bbb7eff-a529-9590-31e7-b0007b416f81