Go to file
Leon Scroggins III c6e6a5f45e Simplify SkCodecs' call to SkColorSpaceXform::apply
Most SkCodec subclasses did the following to apply their
SkColorSpaceXform:
  dstFormat = select_xform_format(dstInfo.colorType());
  srcFormat = select_xform_format(<something that doesn't change>);
  xformAlphaType = select_xform_alpha(dstInfo.alphaType(),
                                      this->getInfo().alphaType());
  this->colorXform()->apply(dstFormat, dst, srcFormat, src, width,
                            xformAlphaType);

Consolidate the computation of these parameters into SkCodec and add a
new method to SkCodec that calls apply() with those parameters.

Add a SkColorSpaceXform::ColorFormat to SkCodec. This allows the new
method SkCodec::applyColorXform to supply the ColorFormat.

TBR=reed@google.com
(No change to public API.)

Change-Id: I8ea7ba4c0024be827a9f9359796c778744330f6e
Reviewed-on: https://skia-review.googlesource.com/18523
Reviewed-by: Leon Scroggins <scroggo@google.com>
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2017-06-05 20:14:57 +00:00
animations first cut at a checkbox 2009-10-21 19:41:10 +00:00
bench add testing flag to force rasterpipeline 2017-06-05 14:45:11 +00:00
bin bin/fetch-clang-format 2017-03-08 16:43:49 +00:00
debugger Get Debugger app compiling again 2017-01-06 16:18:27 +00:00
dm Remove ImmediateFlush mode 2017-06-02 17:35:18 +00:00
example Revert "Revert "Plumb the use of GrBackendRenderTarget throughout Skia"" 2017-05-01 14:14:50 +00:00
experimental move perlinenoise2 into effects 2017-05-30 20:15:37 +00:00
fuzz Revert "Revert "Delete SkGaussianEdgeShader"" 2017-05-31 14:52:12 +00:00
gm In shapes_as_paths, draw zoom from pixmaps, not images 2017-06-05 18:10:47 +00:00
gn remove unused blitters 2017-06-03 11:56:55 +00:00
include Simplify SkCodecs' call to SkColorSpaceXform::apply 2017-06-05 20:14:57 +00:00
infra Remove blacklist of unit tests on Adreno Vulkan 2017-06-05 15:59:46 +00:00
platform_tools Enable ios on Raspberry Pi 2017-04-25 16:56:41 +00:00
resources Defend against ICOs with large BMPs embedded 2017-06-05 18:28:19 +00:00
samplecode Add TiledDrawScheduler so we can concurrently draw and enque 2017-06-05 19:29:57 +00:00
site Update link to testing infrastructure. 2017-06-05 18:20:55 +00:00
src Simplify SkCodecs' call to SkColorSpaceXform::apply 2017-06-05 20:14:57 +00:00
tests Fix GrReducedClip.cpp: assertion failure surrounding tiny query bounds 2017-06-05 19:53:06 +00:00
third_party Roll ANGLE 2017-06-02 18:36:15 +00:00
tools sk_sp-ify GrResourceProvider some more 2017-06-05 18:07:05 +00:00
.clang-format Mark flatennable macros as block beginning/ending in .clang-format 2017-01-09 15:31:36 +00:00
.gitignore Refactor Vulkan support to support Fuchsia 2017-04-05 17:32:09 +00:00
.gn Basic standalone GN configs. 2016-07-21 12:25:45 -07:00
AUTHORS Added support for building for tvOS 2017-03-14 22:55:04 +00:00
BUILD.gn Replace BMP calls to new with calls to malloc 2017-06-05 15:09:40 +00:00
codereview.settings Make uploading to Gerrit the default for Skia 2016-11-09 19:07:56 +00:00
CONTRIBUTING Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
CQ_COMMITTERS Moved committer list to chrome-infra-auth and deleted it from the repo 2015-09-02 13:37:54 -07:00
DEPS Roll ANGLE DEPS 2017-06-05 12:52:31 +00:00
Doxyfile Make the housekeeper upload doxygen to a newer bucket 2016-10-04 13:23:57 -07:00
LICENSE BUG=skia:5602 2016-09-02 11:19:34 -07:00
PRESUBMIT.py Use Gerrit style format for footers in Presubmit 2017-05-23 20:44:36 +00:00
public.bzl Exclude SkJumper_stages_lowp.cpp from G3 build. 2017-06-05 15:40:38 +00:00
README Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
README.chromium Update README.chromium. 2015-06-11 13:19:24 -07:00
whitespace.txt Marker for Win AMD driver update. 2017-05-22 17:21:14 +00:00

Skia is a complete 2D graphic library for drawing Text, Geometries, and Images.

See full details, and build instructions, at https://skia.org.