aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/codec/SkCodecPriv.h
Commit message (Collapse)AuthorAge
...
* Scanline decoding for bmpGravatar msarett2015-08-31
| | | | | | | | | | | | | Redesigns SkScanlineDecoder.h to indicate the ordering in which the scanlines are provided Refactors SkSwizzler::Fill() to include the zeroInit check and to actually be correct. BUG=skia:3257 BUG=skia:4198 Review URL: https://codereview.chromium.org/1287423002
* Style Change: NULL->nullptrGravatar halcanary2015-08-27
| | | | | | DOCS_PREVIEW= https://skia.org/?cl=1316233002 Review URL: https://codereview.chromium.org/1316233002
* Support more swizzles to 565 in SkCodecGravatar scroggo2015-08-14
| | | | | | | | | | | | | | | | | | | | | | | Add more swizzling functions for swizzling to 565. Much of this code was revived from crrev.com/1055743003 (for BMP). Also added swizzling functions for WBMP. Consolidate the static function conversion_possible. In SkCodec::getPixels, check that the alphatype corresponds to the colorType. This prevents requesting 565 + non-opaque. In SkIcoCodec, report that the image is unpremul (instead of whatever the largest embedded codec thinks), but modify the requested info to have the alpha type expected/required by the embedded codec. Add tests for decoding to 565. BUG=skia:3257 BUG=skia:3683 Review URL: https://codereview.chromium.org/1277213002
* Split SkBmpCodec into three separate classesGravatar msarett2015-08-06
| | | | | | | | | | | | | | Will regress behavior on gold on test32bfv4.bmp, where we will no longer fix transparent decodes. TODO: Start fixing transparent decodes again, or decide that we don't want to fix them and remove isTransparent from SkSwizzler. I think this may become more clear when I start implementing the scanline decoder. BUG=skia: Review URL: https://codereview.chromium.org/1258863008
* Scanline decoding for wbmpGravatar msarett2015-08-05
| | | | | | | | | | | | | | | We are also changing the wbmp to use SkSwizzler. This will allow us to take advantage of the sampling routines that are being implemented in SkSwizzler. The image in this upload came from: https://commons.wikimedia.org/wiki/File:Android_robot.png It is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license. BUG=skia: Review URL: https://codereview.chromium.org/1254483004
* Remove sk_memcpy32Gravatar mtklein2015-07-27
| | | | | | | | | | | | | | | | | | | | | | | | It's only implemented on x86, where the exisiting benchmark says memcpy() is faster for all cases: Timer overhead: 24ns curr/maxrss loops min median mean max stddev samples config bench 10/10 MB 1 35.9µs 36.2µs 36.2µs 36.6µs 1% ▁▂▄▅▅▃█▄▄▅ nonrendering sk_memcpy32_100000 10/10 MB 13 2.27µs 2.28µs 2.28µs 2.29µs 0% █▄▃▅▃▁▃▅▁▄ nonrendering sk_memcpy32_10000 11/11 MB 677 91.6ns 95.9ns 94.5ns 99.4ns 3% ▅▅▅▅▅█▁▁▁▁ nonrendering sk_memcpy32_1000 11/11 MB 1171 20ns 20.9ns 21.3ns 23.4ns 6% ▁▁▇▃▃▃█▇▃▃ nonrendering sk_memcpy32_100 11/11 MB 1952 14ns 14ns 14.3ns 15.2ns 3% ▁▁██▁▁▁▁▁▁ nonrendering sk_memcpy32_10 11/11 MB 5 33.6µs 33.7µs 34.1µs 35.2µs 2% ▆▇█▁▁▁▁▁▁▁ nonrendering memcpy32_memcpy_100000 11/11 MB 18 2.12µs 2.22µs 2.24µs 2.39µs 5% ▂█▄▇█▄▇▁▁▁ nonrendering memcpy32_memcpy_10000 11/11 MB 1112 87.3ns 87.3ns 89.1ns 93.7ns 3% ▄██▄▁▁▁▁▁▁ nonrendering memcpy32_memcpy_1000 11/11 MB 2124 12.8ns 13.3ns 13.5ns 14.8ns 6% ▁▁▁█▃▃█▇▃▃ nonrendering memcpy32_memcpy_100 11/11 MB 3077 9ns 9.41ns 9.52ns 10.2ns 4% ▃█▁█▃▃▃▃▃▃ nonrendering memcpy32_memcpy_10 (Why? One fewer thing to port to SkOpts.) BUG=skia:4117 Review URL: https://codereview.chromium.org/1256763003
* Requires a minor API change to pass the color table to getScanlineDecoder, ↵Gravatar msarett2015-04-29
| | | | | | | | as we do with getPixels(). BUG=skia:3722 Review URL: https://codereview.chromium.org/1061713007
* Use a wrapper for SkDebugf in SkCodec.Gravatar scroggo2015-03-26
| | | | | | | | | | | It can be silenced or not with one flag. Always print when building for the android framework. Also remove the meaningless define of override to override. BUG=skia:3257 Review URL: https://codereview.chromium.org/1032093004
* Adding swizzles for bmp:Gravatar msarett2015-03-18
| | | | | | | | | | We now support kN32 and kRGB_565 color types. Additionally, we support premul, unpremul, and opaque alpha types. Unpremul is currently untested as we cannot currently draw to unpremul. BUG=skia: Review URL: https://codereview.chromium.org/1013743003
* Revert "Revert of fix for invalid for loop syntax broke build (patchset #1 ↵Gravatar msarett2015-03-16
| | | | | | | | | | | | | | | | id:1 of https://codereview.chromium.org/1007373003/)" This reverts commit d18475854ce232de71c5463e0654f459d4abfd43. Revert "Revert "Implementation of image decoding for bmp files, in accordance with the new API."" This reverts commit dfdec78a5d02e8690998741a9fe5b71a08ca3232. BUG=skia: TBR= Review URL: https://codereview.chromium.org/1016443003
* Revert "Implementation of image decoding for bmp files, in accordance with ↵Gravatar msarett2015-03-16
| | | | | | | | | | | | | the new API." This reverts commit 3675874468de7228944ce21922e6ec863f5f2310. BUG=skia: NOTREECHECKS=true NOTRY=true TBR= Review URL: https://codereview.chromium.org/1012873002
* Implementation of image decoding for bmp files, in accordance with the new API.Gravatar msarett2015-03-16
Currently decodes to opaque and unpremul. Tested on local test suite. BUG=skia:3257 Review URL: https://codereview.chromium.org/947283002