Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Issue 1695473002: Fix colorType/alphaType checks in SkCodec (Closed)

Created:
4 years, 10 months ago by msarett
Modified:
4 years, 10 months ago
Reviewers:
scroggo
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

Fix colorType/alphaType checks in SkCodec Make getPixels() and startScanlineDecode() behave consistently. Require that kGray8 decodes are opaque. Assert that creating the swizzler succeeds. BUG=skia:4203 GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1695473002 Committed: https://skia.googlesource.com/skia/+/c7578b6cdd03b61f076ffc7956efd952d6c301c0 Committed: https://skia.googlesource.com/skia/+/b30d6984e6dfc185bf1eebf927343563057a7bb3

Patch Set 1 #

Patch Set 2 : Fix bot errors #

Total comments: 2

Patch Set 3 : Consistently require that kGray8 decodes be opaque #

Total comments: 8

Patch Set 4 : Fix kGray8 case in SkCodecPriv #

Patch Set 5 : #

Patch Set 6 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -68 lines) Patch
M src/codec/SkBmpMaskCodec.h View 1 2 3 4 5 1 chunk +0 lines, -1 line 0 comments Download
M src/codec/SkBmpMaskCodec.cpp View 1 2 3 4 5 1 chunk +4 lines, -17 lines 0 comments Download
M src/codec/SkBmpStandardCodec.h View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M src/codec/SkBmpStandardCodec.cpp View 1 2 3 4 5 4 chunks +5 lines, -13 lines 0 comments Download
M src/codec/SkCodec.cpp View 1 2 3 4 5 1 chunk +0 lines, -9 lines 0 comments Download
M src/codec/SkCodecPriv.h View 1 2 3 4 1 chunk +6 lines, -1 line 0 comments Download
M src/codec/SkGifCodec.h View 1 chunk +1 line, -1 line 0 comments Download
M src/codec/SkGifCodec.cpp View 1 chunk +4 lines, -7 lines 0 comments Download
M src/codec/SkJpegCodec.cpp View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M src/codec/SkWbmpCodec.cpp View 1 2 3 4 5 6 chunks +19 lines, -18 lines 0 comments Download

Messages

Total messages: 35 (15 generated)
msarett
4 years, 10 months ago (2016-02-11 18:10:37 UTC) #3
scroggo
lgtm
4 years, 10 months ago (2016-02-11 18:39:53 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1695473002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1695473002/1
4 years, 10 months ago (2016-02-11 18:40:00 UTC) #6
commit-bot: I haz the power
Try jobs failed on following builders: Build-Mac-Clang-x86_64-Release-Trybot on client.skia.compile (JOB_FAILED, http://build.chromium.org/p/client.skia.compile/builders/Build-Mac-Clang-x86_64-Release-Trybot/builds/192)
4 years, 10 months ago (2016-02-11 18:40:52 UTC) #8
msarett
PTAL The trybots caught a non-trivial error with wbmp. https://codereview.chromium.org/1695473002/diff/20001/src/codec/SkWbmpCodec.cpp File src/codec/SkWbmpCodec.cpp (right): https://codereview.chromium.org/1695473002/diff/20001/src/codec/SkWbmpCodec.cpp#newcode37 src/codec/SkWbmpCodec.cpp:37: ...
4 years, 10 months ago (2016-02-11 19:13:45 UTC) #9
msarett
4 years, 10 months ago (2016-02-11 23:51:23 UTC) #10
msarett
Added code to consistently require that kGray8 decodes be opaque. Also removed redundant code from ...
4 years, 10 months ago (2016-02-12 16:46:26 UTC) #11
scroggo
-lgtm at patch set 3 https://codereview.chromium.org/1695473002/diff/20001/src/codec/SkWbmpCodec.cpp File src/codec/SkWbmpCodec.cpp (right): https://codereview.chromium.org/1695473002/diff/20001/src/codec/SkWbmpCodec.cpp#newcode37 src/codec/SkWbmpCodec.cpp:37: case kGray_8_SkColorType: On 2016/02/11 ...
4 years, 10 months ago (2016-02-12 17:13:55 UTC) #13
scroggo
On 2016/02/12 17:13:55, scroggo wrote: > -lgtm at patch set 3 > > https://codereview.chromium.org/1695473002/diff/20001/src/codec/SkWbmpCodec.cpp > ...
4 years, 10 months ago (2016-02-12 17:14:03 UTC) #14
scroggo
On 2016/02/12 17:14:03, scroggo wrote: > On 2016/02/12 17:13:55, scroggo wrote: > > -lgtm at ...
4 years, 10 months ago (2016-02-12 17:14:23 UTC) #15
msarett
Changing the commit message as well https://codereview.chromium.org/1695473002/diff/40001/src/codec/SkCodec.cpp File src/codec/SkCodec.cpp (left): https://codereview.chromium.org/1695473002/diff/40001/src/codec/SkCodec.cpp#oldcode171 src/codec/SkCodec.cpp:171: if (!SkColorTypeValidateAlphaType(info.colorType(), info.alphaType(), ...
4 years, 10 months ago (2016-02-12 17:41:31 UTC) #16
scroggo
Maybe we should move SkColorTypeValidateAlphaType into conversion_possible? lgtm https://codereview.chromium.org/1695473002/diff/40001/src/codec/SkCodec.cpp File src/codec/SkCodec.cpp (left): https://codereview.chromium.org/1695473002/diff/40001/src/codec/SkCodec.cpp#oldcode171 src/codec/SkCodec.cpp:171: if ...
4 years, 10 months ago (2016-02-12 17:59:00 UTC) #18
msarett
I would lean toward doing the checking in conversion_possible (vs doing it in getPixels() and ...
4 years, 10 months ago (2016-02-12 18:22:02 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1695473002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1695473002/60001
4 years, 10 months ago (2016-02-12 18:22:20 UTC) #21
commit-bot: I haz the power
Try jobs failed on following builders: Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-Shared-Trybot on client.skia (JOB_FAILED, http://build.chromium.org/p/client.skia/builders/Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-Shared-Trybot/builds/6082)
4 years, 10 months ago (2016-02-12 18:27:26 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1695473002/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1695473002/80001
4 years, 10 months ago (2016-02-12 20:40:07 UTC) #26
commit-bot: I haz the power
Committed patchset #5 (id:80001) as https://skia.googlesource.com/skia/+/c7578b6cdd03b61f076ffc7956efd952d6c301c0
4 years, 10 months ago (2016-02-12 21:07:18 UTC) #28
msarett
A revert of this CL (patchset #5 id:80001) has been created in https://codereview.chromium.org/1694023002/ by msarett@google.com. ...
4 years, 10 months ago (2016-02-12 22:59:51 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1695473002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1695473002/100001
4 years, 10 months ago (2016-02-15 17:57:10 UTC) #33
commit-bot: I haz the power
4 years, 10 months ago (2016-02-15 18:18:49 UTC) #35
Message was sent while issue was closed.
Committed patchset #6 (id:100001) as
https://skia.googlesource.com/skia/+/b30d6984e6dfc185bf1eebf927343563057a7bb3

Powered by Google App Engine
This is Rietveld 408576698