Commit Graph

584 Commits

Author SHA1 Message Date
borenet@google.com
4b897fa1f6 Add some debugging to buildbot_globals, sort the trybot list
R=epoger@google.com, rmistry@google.com

Review URL: https://codereview.chromium.org/99223002

git-svn-id: http://skia.googlecode.com/svn/trunk@12437 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-12-02 20:27:16 +00:00
commit-bot@chromium.org
6fcb0cdaa2 Revert of https://codereview.chromium.org/85343004/
Reason for revert: Reverting the temporary CL

TBR=
NOTREECHECKS=true
NOTRY=true

Author: rmistry@google.com

Review URL: https://codereview.chromium.org/85823002

git-svn-id: http://skia.googlecode.com/svn/trunk@12376 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-25 14:03:52 +00:00
commit-bot@chromium.org
9df6215aaf Temporary changes to test one-click revert.
(SkipBuildbotRuns)

BUG=
NOTRY=true
TBR=borenet@google.com

Author: rmistry@google.com

Review URL: https://codereview.chromium.org/85343004

git-svn-id: http://skia.googlecode.com/svn/trunk@12375 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-25 14:02:01 +00:00
commit-bot@chromium.org
32f40ee8b0 Remove mutex around image decoding in skpdiff.
I removed the mutex to investigate BUG=skia:1803, and I get no
crashes. The crashes may have been related to other multithreading
issues.

Removing the mutex will allow skpdiff to run faster.

R=djsollen@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/61603008

git-svn-id: http://skia.googlecode.com/svn/trunk@12339 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-21 15:22:18 +00:00
epoger@google.com
591469b1e9 rebaseline_server: clean up thread locks
followup to https://codereview.chromium.org/66803004/ ('rebaseline_server: improve thread locks to allow read access during updates')
(SkipBuildbotRuns)

R=jcgregorio@google.com

Review URL: https://codereview.chromium.org/64273011

git-svn-id: http://skia.googlecode.com/svn/trunk@12323 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-20 19:58:06 +00:00
commit-bot@chromium.org
c32ce49df8 Remove unused kMaxPOI.
BUG=
R=djsollen@google.com

Author: mtklein@google.com

Review URL: https://codereview.chromium.org/62333026

git-svn-id: http://skia.googlecode.com/svn/trunk@12307 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-18 21:01:29 +00:00
commit-bot@chromium.org
da4d7cfa58 Remove unnecessary includes.
R=djsollen@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/68893028

git-svn-id: http://skia.googlecode.com/svn/trunk@12304 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-18 17:27:16 +00:00
commit-bot@chromium.org
a1a097ee81 increase coverage of SkPath.cpp, remove unused code
Using Mike Klein's excellent coverage tool, increase the
unit testing of SkPath.cpp from 70% to 95%.

Along the way, determined that these functions were not
maintained or used:

SkPath::pathTo
SkPath::contains

as well as a large block of SkPath::cheapGetDirection().

Changed SkPath::validate() to permit infinities in
the path data points.

Fixed errors in preserving direction.
Fixed error setting direction when convexity is unknown.

Added missing conic to moveTo only detector.

BUG=
R=bsalomon@google.com, reed@google.com

Author: caryclark@google.com

Review URL: https://codereview.chromium.org/65493004

git-svn-id: http://skia.googlecode.com/svn/trunk@12291 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-14 16:53:22 +00:00
robertphillips@google.com
cb3b615af7 Address some more valgrind issues
R=borenet@google.com

Review URL: https://codereview.chromium.org/59713010

git-svn-id: http://skia.googlecode.com/svn/trunk@12286 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-14 14:47:56 +00:00
djsollen@google.com
efc51b79a2 fix multithread related crashes in skpdiff
BUG=skia:1798
R=mtklein@google.com, scroggo@google.com

Review URL: https://codereview.chromium.org/60833002

git-svn-id: http://skia.googlecode.com/svn/trunk@12252 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-12 18:29:17 +00:00
scroggo@google.com
086364b8e6 Changes to make SkPDiff more robost.
bitmap_to_cielab now returns a boolean. Instead of asserting that the
config is 8888, copy to 8888 (and return false on failure). This allows
skpdiff to work on Index8 bitmaps (without changing the code that does
the real work). If it returns false, do not attempt to create a pmetric.

In pmetric, exit early if maxLevels is <= 2, since this would crash later
in the function (creation of an ImageL3D if maxLevels is 0, and then the
creation of an array of a negative number of entries). maxLevels is small
if the width or height of the image is small (i.e. a bitmap with width 1
has maxLevels of 0).

R=djsollen@google.com

Review URL: https://codereview.chromium.org/65253002

git-svn-id: http://skia.googlecode.com/svn/trunk@12239 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-12 14:41:20 +00:00
robertphillips@google.com
d6bea606c6 Silence another valgrind leak
https://codereview.chromium.org/68523006/



git-svn-id: http://skia.googlecode.com/svn/trunk@12236 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-12 14:05:15 +00:00
robertphillips@google.com
6acc8f473d Add another FontConfig suppression to valgrind suppressions
https://codereview.chromium.org/69403002/



git-svn-id: http://skia.googlecode.com/svn/trunk@12226 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-11 20:04:28 +00:00
borenet@google.com
43a385240f Specify --patchlevel 0 to trychange.py
For some reason, trychange.py creates patches with level 0, even from a git
repo. We were assuming that the patch level was 1 from a git repo, so patches
were failing to apply.

BUG=skia:1669
R=rmistry@google.com

Review URL: https://codereview.chromium.org/61733011

git-svn-id: http://skia.googlecode.com/svn/trunk@12212 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-11 13:43:22 +00:00
djsollen@google.com
2761b30dfe fix broken build on mac due to compiler warning
R=epoger@google.com

Review URL: https://codereview.chromium.org/64423004

git-svn-id: http://skia.googlecode.com/svn/trunk@12175 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-07 19:40:35 +00:00
djsollen@google.com
513a7bffd3 update skpdiff visualization (image magnification with alpha mask)
R=epoger@google.com

Review URL: https://codereview.chromium.org/29103005

git-svn-id: http://skia.googlecode.com/svn/trunk@12174 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-07 19:24:06 +00:00
reed@google.com
2bd8b81005 move SkImage::ColorType into SkColorType
objective -- move clients over to SkImage

tasks
- use SkImageInfo instead of SkBitmap::Config
- add support for colortables to SkImage
- add drawImage to SkCanvas
- return SkImage from readPixels

This CL works towards the first task

R=robertphillips@google.com

Review URL: https://codereview.chromium.org/54363008

git-svn-id: http://skia.googlecode.com/svn/trunk@12077 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-11-01 13:46:54 +00:00
bsalomon@google.com
bc0dbdc169 svndiff for the windows
R=epoger@google.com

Review URL: https://codereview.chromium.org/49323006

git-svn-id: http://skia.googlecode.com/svn/trunk@11995 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-29 13:55:29 +00:00
bensong@google.com
4a28f598ec Changes bench_graph_svg.py test to check_bench_regressions.py test; deletes deprecated chunks in syn_bucket_subdir.
Review URL: https://codereview.chromium.org/27377002

git-svn-id: http://skia.googlecode.com/svn/trunk@11952 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-24 18:08:45 +00:00
scroggo@google.com
5187c4313c More work to integrate skimage with rebaseline tools.
tools/skimage_main.cpp:
Add the ability to write the results to checksum based filenames,
much like GM uses. This will allow using the skpdiff server to
rebaseline images.
Write the keys in the JSON file as <original image>_<pref config>.png,
so it matches gm_json.IMAGE_FILENAME_PATTERN. Also replace '_' with
'-' in the original file name, to avoid confusing the pattern matcher.
The '_' to '-' replacement also happens on the output filename.
Read the keys in a similar manner.
In make_outname, no longer remove a suffix. This fixes a bug where
subset decoding writes multiple subsets to the same file.

tools/rebaseline.py:
Since the filenames written to json files now match
gm_json.IMAGE_FILENAME_PATTERN, enable the option to match based
on configs/tests when rebaselining skimage.

test json files:
Update to match the new format of output.

gm/gm_expectations:
Add a constructor that takes a BitmapAndDigest as input.

tools/tests/skimage_self_test.py:
Test that reading the expectations file just created by skimage with
the same file actually compares to the original file (rather than just
succeeding because expectations were missing).

Change the expectations files to match the new format.

Will require a buildbot change to use the new flag: https://codereview.chromium.org/27389002/

BUG=1466
R=epoger@google.com

Review URL: https://codereview.chromium.org/26297004

git-svn-id: http://skia.googlecode.com/svn/trunk@11902 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-22 00:42:46 +00:00
djsollen@google.com
cbbf1ca304 add initial support ofr multi-threaded execution
Review URL: https://codereview.chromium.org/27541003

git-svn-id: http://skia.googlecode.com/svn/trunk@11823 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-16 18:36:49 +00:00
bsalomon@google.com
46484ec5bf Add --add-ignored option to rebaseline.py
R=senorblanco@chromium.org, epoger@google.com
BUG=skia:1600

Review URL: https://codereview.chromium.org/27517002

git-svn-id: http://skia.googlecode.com/svn/trunk@11809 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-16 15:10:45 +00:00
djsollen@google.com
1e391b5870 Update skpdiff to include a name with each file.
R=caryclark@google.com

Review URL: https://codereview.chromium.org/27512002

git-svn-id: http://skia.googlecode.com/svn/trunk@11808 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-16 15:00:11 +00:00
scroggo@google.com
36c5bdb097 Truly ignore failures in skimage.
If the expectation is set to ignore failures, do not return a
negative 1 (indicating a failure) when a successful decode
does not match the expectation.

If the file could not be decoded at all, report this to the
user depending on the input expectations file:

No expectations:
Report failure. The user wanted to know if the file could be
decoded.

Expectations expected a valid result:
Report failure. The decode should have matched the result.

Empty expectations:
Print a message that the expectation was missing, but still
return success from skimage, since this is a newly added file
(i.e. it has no expectation yet).

Ignore failure:
Return success from skimage, since it is a known failure.

Update the self tests to ensure these behaviors.

R=epoger@google.com

Review URL: https://codereview.chromium.org/22293006

git-svn-id: http://skia.googlecode.com/svn/trunk@11790 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-15 20:29:37 +00:00
robertphillips@google.com
8b169311b5 Second wave of Win64 warning cleanup
https://codereview.chromium.org/27343002/



git-svn-id: http://skia.googlecode.com/svn/trunk@11778 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-15 17:47:36 +00:00
bensong@google.com
e209a70d1e Suppresses failing test due to change of bench_graph_svg. Will fix later.
Review URL: https://codereview.chromium.org/26894004

git-svn-id: http://skia.googlecode.com/svn/trunk@11766 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-15 00:35:18 +00:00
robertphillips@google.com
adacc7067a Start cleaning up 64bit Win warnings
https://codereview.chromium.org/27192003/



git-svn-id: http://skia.googlecode.com/svn/trunk@11764 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-14 21:53:24 +00:00
halcanary@google.com
04b57f87ab Runtime configuration setting for suppressing JPEG decoder errors.
Add new runtime config variable, images.jpeg.suppressDecoderErrors
which defaults to false in Debug and true otherwise.  When Jpeg errors
are suppressed and an error happens, SkJPEGImageDecoder::onDecode()
will return silently false (Consequently, so will SkImageDecoder's
DecodeFile() and DecodeMemory() functions).

Also, the test_image_decoder program now respects runtime
configuration settings.

BUG=skia:1680
R=scroggo@google.com

Review URL: https://codereview.chromium.org/27230002

git-svn-id: http://skia.googlecode.com/svn/trunk@11763 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-14 20:08:48 +00:00
commit-bot@chromium.org
5e00989a28 Add SkPDFDeviceFlatenner which extends SkPDFDevice to add support to flatten the path and the text when we have perspective.
prepare to deprecate SkPDFDevice constructor, and route gm and render_pdfs to use SkDocument::Create pdf interface instead. - controlled by a flag
add comments where we are supposed to flatten other features (paint, shaders, ... )

R=reed@google.com, bungeman@google.com, scroggo@google.com, vandebo@chromium.org, bsalomon@google.com

Author: edisonn@google.com

Review URL: https://codereview.chromium.org/24811002

git-svn-id: http://skia.googlecode.com/svn/trunk@11751 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-14 13:42:12 +00:00
bungeman@google.com
16b2dd05f0 Add stdio include to skdiff_image.
git-svn-id: http://skia.googlecode.com/svn/trunk@11740 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-11 19:19:10 +00:00
robertphillips@google.com
8ec502b416 Add valgrind suppressions for driver bugs
https://codereview.chromium.org/27019005/



git-svn-id: http://skia.googlecode.com/svn/trunk@11736 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-11 18:28:18 +00:00
scroggo@google.com
d23e683c51 Add ability to rebaseline skimage to rebaseline.py
Skip pattern matching for skimage, since the skimage results do not
match the pattern.

Automatically fill in expectations_root and actuals_base_url when
--skimage is specified.

Requires a change to move the expectations files to the right place.
Depends on https://codereview.chromium.org/26734006

(SkipBuildBotRuns)

BUG=skia:1466
R=epoger@google.com

Review URL: https://codereview.chromium.org/26666004

git-svn-id: http://skia.googlecode.com/svn/trunk@11717 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-10 21:09:24 +00:00
robertphillips@google.com
1b440d1574 Add leak to valgrind.supp
https://codereview.chromium.org/26869002/



git-svn-id: http://skia.googlecode.com/svn/trunk@11700 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-10 17:04:14 +00:00
bungeman@google.com
cc5fd0a95a Use the modified path, not the original path for the platform prefix.
Fixes regression introduced in r11642.


git-svn-id: http://skia.googlecode.com/svn/trunk@11693 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-10 14:16:23 +00:00
commit-bot@chromium.org
dac4a1d518 Allow sampling GIF images during decode.
SkScaledBitmapSampler:
Add a mode for sampling rows out of order, used by GIF decoder for
interlaced images.
Add a getter for the X sampling rate.

SkImageDecoder_libgif:
Respect the sampleSize set on SkImageDecoder.

skimage_main:
Provide an option to set a sample size.

BUG=https://b.corp.google.com/issue?id=8999690
R=reed@google.com, djsollen@google.com, halcanary@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/25354004

git-svn-id: http://skia.googlecode.com/svn/trunk@11659 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-08 19:40:18 +00:00
robertphillips@google.com
6187abe776 Update valgrind suppressions
https://codereview.chromium.org/26465007/



git-svn-id: http://skia.googlecode.com/svn/trunk@11650 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-08 15:37:19 +00:00
mtklein@google.com
9f3b0e462e skia/trunk changes for generic sanitizer gyp flag.
BUG=
R=borenet@google.com

Review URL: https://codereview.chromium.org/25564003

git-svn-id: http://skia.googlecode.com/svn/trunk@11648 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-08 15:16:36 +00:00
bungeman@google.com
575e82ad5d Document how to get a specific revision when rebaselining.
This is helpful when using the trybots.

R=epoger@google.com

Review URL: https://codereview.chromium.org/25653008

git-svn-id: http://skia.googlecode.com/svn/trunk@11643 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-07 20:32:18 +00:00
bungeman@google.com
3c8d9cb8a7 Make svndiff.py work on Windows and with svn 1.7.
R=epoger@google.com

Review URL: https://codereview.chromium.org/25447003

git-svn-id: http://skia.googlecode.com/svn/trunk@11642 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-07 19:57:35 +00:00
scroggo@google.com
de09af3fd8 In skimage, copy to 8888 if encoding fails.
When writing the bitmap for visual comparison, rather than special
casing A8, depend on the fact that the encoder will fail, and try
copying to 8888 and encoding that if so.

R=reed@google.com

Review URL: https://codereview.chromium.org/25964003

git-svn-id: http://skia.googlecode.com/svn/trunk@11633 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-07 16:56:01 +00:00
djsollen@google.com
64f031c278 revert unintentional checkin of svndiff.py
Review URL: https://codereview.chromium.org/26162004

git-svn-id: http://skia.googlecode.com/svn/trunk@11628 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-07 14:02:58 +00:00
djsollen@google.com
d7df6b6452 Rebaseline Android Xoom and Nexus10
Review URL: https://codereview.chromium.org/26257002

git-svn-id: http://skia.googlecode.com/svn/trunk@11627 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-07 13:50:45 +00:00
halcanary@google.com
d8854adf1c Fix iOS build of test_image_decoder
Use tool_main() function.

Review URL: https://codereview.chromium.org/26008002

git-svn-id: http://skia.googlecode.com/svn/trunk@11600 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-04 13:37:24 +00:00
halcanary@google.com
fed3037217 Make image decoding more fault resistant, less verbose.
This change address what happens when a jpeg is partially downloaded
before failing.  Many browsers will render it anyway: we want Skia to
do the same.  The JpegTest takes a perfectly cromulent jpeg file and
only passes into the ImageDecoder the first half of the image.  We
then verify that the image decoder returns a valid bitmap of the
correct dimensions.

We also fixed some png library errors, including issue 1691.

Also, suppressed the majority of warnings from using libpng and
libjpeg.  By default, most warnings are *not* suppressed in debug mode.
If you have a debug binary and wish to suppress warnings, set the
following environment variables to true
    skia_images_png_suppressDecoderWarnings
    skia_images_jpeg_suppressDecoderWarnings
or from within a program that links to Skia:
    #if defined(SK_DEBUG)
    #include "SkRTConf.h"
    SK_CONF_SET("images.jpeg.suppressDecoderWarnings", true);
    SK_CONF_SET("images.png.suppressDecoderWarnings", true);
    #endif

I tested this, before (control) and after these changes (test), on
364,295 skps from the cluster telemetry.
-   number of errors+warnings in control = 2804
-   number of errors+warnings fixed = 2283
-   number of PNG verbosity fixed =  2152
-   number of PNG error fixed = 4
-   number of PNG segfault fixed = 3
-   number of PNG errors changed to warnings = 62
-   number of JPG verbosity fixed =  26
-   number of JPG error fixed = 91
Not all errors and warning have been fixed.

These numbers were generated using the find_bad_images_in_skps.py
program.  This program may be useful going forward for testing
image-decoding libraries on skp files from the cluster telemetry.
find_bad_images_in_skps.py depends on the test_image_decoder program,
which simply executes the SkImageDecoder::DecodeFile function and uses
its exit status to report success or failure.

BUG=skia:1649
BUG=skia:1691
BUG=skia:1680
R=scroggo@google.com

Review URL: https://codereview.chromium.org/24449003

git-svn-id: http://skia.googlecode.com/svn/trunk@11597 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-04 12:46:45 +00:00
commit-bot@chromium.org
608ea6508a Use SkPicture::ExtractBitmap callback in pdf too, there is no need for a specialized function pointer for pdf only only to pass a rectangle, when we can use subseted bitmaps.
R=scroggo@google.com, reed@google.com, vandebo@chromium.org, bsalomon@google.com

Author: edisonn@google.com

Review URL: https://codereview.chromium.org/25054002

git-svn-id: http://skia.googlecode.com/svn/trunk@11591 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-03 19:29:21 +00:00
commit-bot@chromium.org
546f70c823 Fixes for decoding to A8.
src/images/SkImageDecoder_libpng.cpp:
A8 images are not opaque, so do not set the opaque flag.
This fixes a bug where copyTo does not work as expected (when
copying an A8 decoded image to ARGB_8888), leading to
a bitmap hash that does not represent the image correctly
(in skimage).

tools/skimage_main.cpp:
In write_bitmap, which is creating the image for visual comparison,
copy A8 to 8888, since A8 cannot be encoded.

In the section that tests reencoding, do not test reencoding A8,
which is known to not work.

R=mtklein@google.com, djsollen@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/25726004

git-svn-id: http://skia.googlecode.com/svn/trunk@11589 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-03 17:13:38 +00:00
commit-bot@chromium.org
03e3e89641 Add support to dump font cache texture for debug purposes
R=robertphillips@google.com, bsalomon@google.com

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/25736002

git-svn-id: http://skia.googlecode.com/svn/trunk@11579 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-02 18:19:17 +00:00
scroggo@google.com
8d2392487c Add an option on SkImageDecoder to skip writing 0s.
Only implemented for PNG.

Add a getter and setter, and sets the default to false in the
constructor. Also copies the setting in copyFieldsToOther.

Fix an indpendent bug where fDitherImage was not being copied in
copyFieldsToOther.

In SkScaledBitmapSampler::begin, consolidate the settings passed in
by passing a const reference to the decoder. The decoder can be
referenced for its settings of dither, unpremultiplied, and now
skipping writing zeroes. Update callers to use the new API. In png
decoder, rather than passing around a pointer to an initial
read of getDitherImage, and potentially changing it, look at the
field on the decoder itself, and modify it directly. This is a
change in behavior - now if that same decoder is used to decode
a different image, the dither setting has changed. I think this is
okay because A) the typical use case is to use a new decoder for
each decode, B) we do not make any promises that a decode does not
change the decoder and C) it makes the code in SkScaledBitmapSampler
much cleaner.

In SkScaledBitmapScampler, add new row procs for skipping zeroes. Now
that choosing the row proc has five dimensions (src config, dst config,
dither, skip writing zeroes, unpremultiplied), use a new method: each
src/dst combination has a function for choosing the right proc depending
on the decoder.

SkScaledBitmapScampler::RowProc is now public for convenience.

Remove Sample_Gray_D8888_Unpremul, which is effectively no different
from Sample_Gray_D8888.

In cases where unpremultiplied was trivial, such as 565 and when
sampling from gray, decoding may now succeed.

Add a benchmark (currently disabled) for comparing the speed of skipping
writing zeroes versus not skipping. For this particular image, which is
mostly transparent pixels, normal decoding took about 3.6 milliseconds,
while skipping zeroes in the decode took only about 2.5 milliseconds
(this is on a Nexus 4). Presumably it would be slower on an image
with a small amount of transparency, but there will be no slowdown
for an image which reports that it has no transparency.

In SkImageRef_ashmem, always skip writing zeroes, since ashmem
memory is guaranteed to be initialized to 0.

Add a flag to skip writing zeroes in skimage.

Add a regression test for choosing the rowproc to ensure I did not
change any behavior accidentally.

BUG=skia:1661
R=reed@google.com

Review URL: https://codereview.chromium.org/24269006

git-svn-id: http://skia.googlecode.com/svn/trunk@11558 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-01 17:27:15 +00:00
epoger@google.com
f9d134da93 Create HTTP-based GM results viewer.
For now, it only allows VIEWING results... next, it will allow the user to
rebaseline GM results via the web interface.

R=borenet@google.com

Review URL: https://codereview.chromium.org/24274003

git-svn-id: http://skia.googlecode.com/svn/trunk@11500 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-09-27 15:02:44 +00:00
reed@google.com
d28ba8010c promote SkImage::AlphaType to SkAlphaType
BUG=
R=bsalomon@google.com

Review URL: https://codereview.chromium.org/24130009

git-svn-id: http://skia.googlecode.com/svn/trunk@11421 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-09-20 19:33:52 +00:00