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

Issue 15806010: Separate core and images project. (Closed)

Created:
7 years, 7 months ago by scroggo
Modified:
7 years, 6 months ago
CC:
skia-review_googlegroups.com
Visibility:
Public.

Description

Separate core and images project. SkImage calls functions on SkImageDecoder and SkImageEncoder. This is desired behavior, and it is also desired to include SkImage as a part of core. In order to keep core from depending on images, update SkImageDecoder_empty.cpp to implement all of SkImageDecoder and SkImageEncoder. This file will be built by chrome (in https://codereview.chromium.org/15960015). Move force_linking from SkImageDecoder.cpp to its own file. It must be called to force linking with the image decoders if desired. Call the function in tools that need it: sk_image render_pictures render_pdfs sk_hello filter bench_pictures debugger SkImageDecoder: Derive from SkNoncopyable, instead of duplicating its hiding of constructors. skhello: Return rather than trying to write a null SkData to the stream. Revert "Hamfistedly removed core dependence on images" (commit 0f05f682a90bc125323677abf3476e1027d174f5) and "Move SkImage::encode to SkImage_Codec.cpp." (commit 83e47a954d0bf65439f3d9c0c93213063dd70da3.) These two commits were temporary fixes that this change cleans up. SkSnapshot.cpp: Check for a NULL encoder returned by SkImageEncoder::Create. BUG=https://code.google.com/p/skia/issues/detail?id=1275 R=djsollen@google.com, robertphillips@google.com Committed: https://code.google.com/p/skia/source/detail?r=9364

Patch Set 1 #

Patch Set 2 : Fixes. #

Patch Set 3 : Fixes for non-linux platforms. #

Patch Set 4 : Remove SkImageDecoder.cpp from images.gyp #

Patch Set 5 : Use SkImageDecoder_empty and avoid static initializations. #

Patch Set 6 : Leave SkImageDecoder_iOS alone. #

Total comments: 10

Patch Set 7 : Respond to comments. #

Total comments: 3

Patch Set 8 : Just a rebase #

Patch Set 9 : Change FORCE_LINKING to be more specific. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+199 lines, -682 lines) Patch
M debugger/QT/SkDebuggerGUI.cpp View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -0 lines 0 comments Download
M gyp/core.gypi View 1 2 3 4 5 6 7 2 chunks +3 lines, -1 line 0 comments Download
M gyp/gmslides.gypi View 1 2 3 4 1 chunk +0 lines, -1 line 0 comments Download
M gyp/images.gyp View 1 2 3 4 5 6 2 chunks +3 lines, -3 lines 0 comments Download
M gyp/tools.gyp View 1 1 chunk +0 lines, -1 line 0 comments Download
M include/core/SkImage.h View 1 2 3 4 5 6 3 chunks +3 lines, -10 lines 0 comments Download
A + include/core/SkImageDecoder.h View 1 2 3 4 5 6 3 chunks +2 lines, -5 lines 0 comments Download
A + include/core/SkImageEncoder.h View 1 2 3 4 5 6 0 chunks +-1 lines, --1 lines 0 comments Download
A include/images/SkForceLinking.h View 1 2 3 4 5 6 7 8 1 chunk +20 lines, -0 lines 0 comments Download
M include/images/SkImageDecoder.h View 1 2 3 4 5 6 1 chunk +0 lines, -487 lines 0 comments Download
D include/images/SkImageEncoder.h View 1 2 3 4 5 6 1 chunk +0 lines, -100 lines 0 comments Download
M src/animator/SkSnapshot.cpp View 1 chunk +4 lines, -0 lines 0 comments Download
M src/image/SkImage.cpp View 1 2 3 4 5 6 2 chunks +17 lines, -5 lines 0 comments Download
M src/image/SkImage_Codec.cpp View 1 2 3 4 5 6 2 chunks +1 line, -38 lines 0 comments Download
A src/images/SkForceLinking.cpp View 1 2 3 4 5 6 1 chunk +35 lines, -0 lines 0 comments Download
M src/images/SkImageDecoder.cpp View 1 2 3 4 1 chunk +0 lines, -24 lines 0 comments Download
M src/ports/SkImageDecoder_empty.cpp View 1 2 3 4 5 6 7 3 chunks +91 lines, -8 lines 0 comments Download
M tools/bench_pictures_main.cpp View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -0 lines 0 comments Download
M tools/filtermain.cpp View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -0 lines 0 comments Download
M tools/render_pdfs_main.cpp View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -0 lines 0 comments Download
M tools/render_pictures_main.cpp View 1 2 3 4 5 6 7 8 2 chunks +4 lines, -0 lines 0 comments Download
M tools/skhello.cpp View 1 1 chunk +3 lines, -0 lines 0 comments Download
M tools/skimage_main.cpp View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
scroggo
7 years, 6 months ago (2013-05-28 21:50:59 UTC) #1
robertphillips
lgtm + some nits & suggestions https://codereview.chromium.org/15806010/diff/11001/include/images/SkForceLinking.h File include/images/SkForceLinking.h (right): https://codereview.chromium.org/15806010/diff/11001/include/images/SkForceLinking.h#newcode13 include/images/SkForceLinking.h:13: * Call this ...
7 years, 6 months ago (2013-05-28 23:22:55 UTC) #2
scroggo
New patch up for review. I've moved SkImageDecoder.h and SkImageDecoder.h into core, to reflect that ...
7 years, 6 months ago (2013-05-29 17:34:19 UTC) #3
scroggo
Derek, do you mind taking a look at this CL too? I've moved the headers ...
7 years, 6 months ago (2013-05-30 13:31:33 UTC) #4
djsollen
lgtm, with one small nit that you can take or leave. https://codereview.chromium.org/15806010/diff/50001/include/images/SkForceLinking.h File include/images/SkForceLinking.h (right): ...
7 years, 6 months ago (2013-05-30 14:27:26 UTC) #5
robertphillips
https://codereview.chromium.org/15806010/diff/50001/include/images/SkForceLinking.h File include/images/SkForceLinking.h (right): https://codereview.chromium.org/15806010/diff/50001/include/images/SkForceLinking.h#newcode19 include/images/SkForceLinking.h:19: #define __SK__FORCE_LINKING \ SK_FORCE_IMAGE_DECODER_LINKING?
7 years, 6 months ago (2013-05-30 14:31:56 UTC) #6
scroggo
https://codereview.chromium.org/15806010/diff/50001/include/images/SkForceLinking.h File include/images/SkForceLinking.h (right): https://codereview.chromium.org/15806010/diff/50001/include/images/SkForceLinking.h#newcode19 include/images/SkForceLinking.h:19: #define __SK__FORCE_LINKING \ On 2013/05/30 14:31:56, robertphillips wrote: > ...
7 years, 6 months ago (2013-05-30 21:06:12 UTC) #7
scroggo
7 years, 6 months ago (2013-05-31 14:00:22 UTC) #8
Message was sent while issue was closed.
Committed patchset #9 manually as r9364 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698