aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/images
Commit message (Collapse)AuthorAge
* Delete SkPageFlipperGravatar msarett2016-03-25
| | | | | | | BUG=skia:5132 GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1832083002 Review URL: https://codereview.chromium.org/1832083002
* Delete SkDecodingImageGeneratorGravatar msarett2016-02-11
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1692053002 Review URL: https://codereview.chromium.org/1692053002
* remove SkInstCntGravatar mtklein2015-06-26
| | | | | | | | | | | | | | It's been outclassed by Valgrind and leak sanitizer, and it seems to be causing problems for external folks building Skia. I'm not sure why our own builds seem unaffected. Latest thread: https://groups.google.com/forum/#!topic/skia-discuss/oj9FsQwwSF0 BUG=skia: Review URL: https://codereview.chromium.org/1217573002
* Label some unused static vars as SK_UNUSEDGravatar fmalita2015-06-10
| | | | | | | | | | | | Makes my gcc 5.1.1 much happier. R=mtklein@google.com,scroggo@google.com [ mtklein mischief below here ] No public API changes. TBR=reed@google.com Review URL: https://codereview.chromium.org/1170863006
* Make SkStream *not* ref counted.Gravatar scroggo2015-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SkStream is a stateful object, so it does not make sense for it to have multiple owners. Make SkStream inherit directly from SkNoncopyable. Update methods which previously called SkStream::ref() (e.g. SkImageDecoder::buildTileIndex() and SkFrontBufferedStream::Create(), which required the existing owners to call SkStream::unref()) to take ownership of their SkStream parameters and delete when done (including on failure). Switch all SkAutoTUnref<SkStream>s to SkAutoTDelete<SkStream>s. In some cases this means heap allocating streams that were previously stack allocated. Respect ownership rules of SkTypeface::CreateFromStream() and SkImageDecoder::buildTileIndex(). Update the comments for exceptional methods which do not affect the ownership of their SkStream parameters (e.g. SkPicture::CreateFromStream() and SkTypeface::Deserialize()) to be explicit about ownership. Remove test_stream_life, which tested that buildTileIndex() behaved correctly when SkStream was a ref counted object. The test does not make sense now that it is not. In SkPDFStream, remove the SkMemoryStream member. Instead of using it, create a new SkMemoryStream to pass to fDataStream (which is now an SkAutoTDelete). Make other pdf rasterizers behave like SkPDFDocumentToBitmap. SkPDFDocumentToBitmap delete the SkStream, so do the same in the following pdf rasterizers: SkPopplerRasterizePDF SkNativeRasterizePDF SkNoRasterizePDF Requires a change to Android, which currently treats SkStreams as ref counted objects. Review URL: https://codereview.chromium.org/849103004
* Remove SkImageRef and related functionality.Gravatar Hal Canary2014-06-04
| | | | | | | | From here on out, use SkDecodingImageGenerator+SkDiscardablePixelRef. R=scroggo@google.com Review URL: https://codereview.chromium.org/100183002
* Move SkDecodingImageGenerator.h to include/Gravatar commit-bot@chromium.org2014-05-27
| | | | | | | | | | | | | | | This will allow Android to access it and remove SkImageRef. Depends on https://codereview.chromium.org/293283002/ BUG=skia:2389 R=reed@google.com, djsollen@google.com, halcanary@google.com Author: scroggo@google.com Review URL: https://codereview.chromium.org/228613003 git-svn-id: http://skia.googlecode.com/svn/trunk@14891 2bbb7eff-a529-9590-31e7-b0007b416f81
* Refactor read and write buffers.Gravatar commit-bot@chromium.org2014-01-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Eliminates SkFlattenable{Read,Write}Buffer, promoting SkOrdered{Read,Write}Buffer a step each in the hierarchy. What used to be this: SkFlattenableWriteBuffer -> SkOrderedWriteBuffer SkFlattenableReadBuffer -> SkOrderedReadBuffer SkFlattenableReadBuffer -> SkValidatingReadBuffer is now SkWriteBuffer SkReadBuffer -> SkValidatingReadBuffer Benefits: - code is simpler, names are less wordy - the generic SkFlattenableFooBuffer code in SkPaint was incorrect; removed - write buffers are completely devirtualized, important for record speed This refactoring was mostly mechanical. You aren't going to find anything interesting in files with less than 10 lines changed. BUG=skia: R=reed@google.com, scroggo@google.com, djsollen@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/134163010 git-svn-id: http://skia.googlecode.com/svn/trunk@13245 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert "Revert "Revert of https://codereview.chromium.org/110593003/"""Gravatar reed@google.com2014-01-06
| | | | | | | | | | This reverts commit aaa89649590323fe40f52439d9a9a3376bb3b8ae. BUG= Review URL: https://codereview.chromium.org/123223007 git-svn-id: http://skia.googlecode.com/svn/trunk@12910 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert "Revert of https://codereview.chromium.org/110593003/""Gravatar reed@google.com2014-01-06
| | | | | | | | | | This reverts commit 0fef787f33aa38109a0c8427e0098d997efdd5ff. failed in chrome: https://codereview.chromium.org/124503002/ Review URL: https://codereview.chromium.org/105523008 git-svn-id: http://skia.googlecode.com/svn/trunk@12906 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert of https://codereview.chromium.org/110593003/"Gravatar reed@google.com2014-01-03
| | | | | | | | | | | | This reverts commit c7abb25b25ba8b97948371d2bf0a2e3e78468f73. and fixes the ashmem break BUG= Review URL: https://codereview.chromium.org/119753010 git-svn-id: http://skia.googlecode.com/svn/trunk@12887 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of https://codereview.chromium.org/110593003/Gravatar commit-bot@chromium.org2014-01-03
| | | | | | | | | | | | | | | | Reason for revert: SkImageRef_ashmem doesn't compile R=halcanary@google.com, scroggo@google.com TBR=halcanary@google.com, scroggo@google.com NOTREECHECKS=true NOTRY=true BUG= Author: reed@google.com Review URL: https://codereview.chromium.org/119753009 git-svn-id: http://skia.googlecode.com/svn/trunk@12884 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add onNewLockPixels, that returns rowbytes and relies on info in pixelrefGravatar reed@google.com2014-01-03
| | | | | | | | | | | This reverts commit 890a6ec633c1f54891104a072a8964b4c2c81af9. BUG= R=scroggo@google.com Review URL: https://codereview.chromium.org/110593003 git-svn-id: http://skia.googlecode.com/svn/trunk@12883 2bbb7eff-a529-9590-31e7-b0007b416f81
* Update all callsites to use info for pixelrefsGravatar reed@google.com2013-12-13
| | | | | | | | | | | #define SK_SUPPORT_LEGACY_PIXELREF_CONSTRUCTOR in chrome to keep old API signature (for now) BUG= R=scroggo@google.com Review URL: https://codereview.chromium.org/100723005 git-svn-id: http://skia.googlecode.com/svn/trunk@12677 2bbb7eff-a529-9590-31e7-b0007b416f81
* Reverting r12665 & r12666 (Remove duplicate impl for SkImageInfo flattening) ↵Gravatar robertphillips@google.com2013-12-13
| | | | | | | | | | due to Chromium/Blink compilation errors https://codereview.chromium.org/112603003/ git-svn-id: http://skia.googlecode.com/svn/trunk@12667 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remvoe duplicate impl for SkImageInfo flatteningGravatar reed@google.com2013-12-13
| | | | | | | | | | | | Add onNewLockPixels This reverts commit bb8eff6a70c52b7644391cfd4f4d21bf7294a6bf. BUG= Review URL: https://codereview.chromium.org/111323005 git-svn-id: http://skia.googlecode.com/svn/trunk@12665 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "remvoe duplicate impl for SkImageInfo flattening"Gravatar reed@google.com2013-12-11
| | | | | | | | | | | | Reason: breaks chrome_mac_tests which still have non-imageinfo constructors This reverts commit a06b8cf60b39bda93e9ef1a73579007b2b930d29. BUG= Review URL: https://codereview.chromium.org/103033005 git-svn-id: http://skia.googlecode.com/svn/trunk@12631 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert of https://codereview.chromium.org/108773003/"Gravatar reed@google.com2013-12-11
| | | | | | | | | | This reverts commit 947e6a3142af66b750f1247ef933b11ed8455dd4. BUG= Review URL: https://codereview.chromium.org/112963003 git-svn-id: http://skia.googlecode.com/svn/trunk@12630 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of https://codereview.chromium.org/108773003/Gravatar commit-bot@chromium.org2013-12-11
| | | | | | | | | | | | | | Reason for revert: breaks chrome-mac-tests TBR= NOTREECHECKS=true NOTRY=true Author: reed@google.com Review URL: https://codereview.chromium.org/113193003 git-svn-id: http://skia.googlecode.com/svn/trunk@12629 2bbb7eff-a529-9590-31e7-b0007b416f81
* remvoe duplicate impl for SkImageInfo flatteningGravatar reed@google.com2013-12-11
| | | | | | | | | | | | Revert "Revert "PixelRef now returns (nearly) everything that is currently in SkBitmap. The goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap."""""" This reverts commit eabd6b2ed4e494b323c08f32358f45950a0368c3. BUG= Review URL: https://codereview.chromium.org/108773003 git-svn-id: http://skia.googlecode.com/svn/trunk@12624 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "PixelRef now returns (nearly) everything that is currently in ↵Gravatar reed@google.com2013-12-11
| | | | | | | | | | | | SkBitmap. The goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap.""""" This reverts commit d08eca87a0bef10112a211de540f89656a80b86a. BUG= Review URL: https://codereview.chromium.org/108303003 git-svn-id: http://skia.googlecode.com/svn/trunk@12623 2bbb7eff-a529-9590-31e7-b0007b416f81
* PixelRef now returns (nearly) everything that is currently in SkBitmap. The ↵Gravatar reed@google.com2013-12-11
| | | | | | | | | | goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap."""" BUG= Review URL: https://codereview.chromium.org/110503003 git-svn-id: http://skia.googlecode.com/svn/trunk@12622 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert "Revert "PixelRef now returns (nearly) everything that is ↵Gravatar reed@google.com2013-12-06
| | | | | | | | | | | | | | currently in SkBitmap. The goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap.""" This reverts commit 5f035e90d6dea0139a4f204b634e7b7b3b4976d7. Reverting because it breaks chrome/blink due to new SkPixelRef constructor arg. BUG= Review URL: https://codereview.chromium.org/108993002 git-svn-id: http://skia.googlecode.com/svn/trunk@12551 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert "PixelRef now returns (nearly) everything that is currently ↵Gravatar reed@google.com2013-12-06
| | | | | | | | | | | | in SkBitmap. The goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap."" This reverts commit 4174afb18a9746bbad2a06c0ec2d4ad35f72d790. BUG= Review URL: https://codereview.chromium.org/108723003 git-svn-id: http://skia.googlecode.com/svn/trunk@12547 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "PixelRef now returns (nearly) everything that is currently in ↵Gravatar reed@google.com2013-12-06
| | | | | | | | | | | | SkBitmap. The goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap." This reverts commit 154e08b2f5904ef533da694e3510befcb9a3f3e2. revert due to warnings Review URL: https://codereview.chromium.org/108513003 git-svn-id: http://skia.googlecode.com/svn/trunk@12538 2bbb7eff-a529-9590-31e7-b0007b416f81
* PixelRef now returns (nearly) everything that is currently in SkBitmap. The ↵Gravatar reed@google.com2013-12-06
| | | | | | | | | | goal is to refactor bitmap later to remove redundancy, and more interestingly, remove the chance for a disconnect between the actual (pixelref) rowbytes and config, and the one claimed by the bitmap. R=mtklein@google.com, scroggo@google.com Review URL: https://codereview.chromium.org/68973005 git-svn-id: http://skia.googlecode.com/svn/trunk@12537 2bbb7eff-a529-9590-31e7-b0007b416f81
* Change SkImageDecoders to take an SkStreamRewindable.Gravatar scroggo@google.com2013-09-25
| | | | | | | | | | | | | | | | | | | | Only affects factories, static functions that will use the factories, and subset decoding, which all require rewinding. The decoders themselves continue to take an SkStream. This is merely documentation stating which functions will possibly rewind the passed in SkStream. This is part of the general change to coordinate SkStreams with Android's streams, which don't necessarily support rewinding in all cases. Update callers to use SkStreamRewindable. BUG=skia:1572 R=bungeman@google.com, reed@google.com Review URL: https://codereview.chromium.org/23477009 git-svn-id: http://skia.googlecode.com/svn/trunk@11460 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixes for JPEG subset decoding.Gravatar scroggo@google.com2013-08-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure that the stream passed to JPEG for subset decoding is neither deleted before it is no longer needed nor deleted an extra time. src/images/SkJpegUtility.h: src/images/SkJpegUtility.cpp: Always ref and unref the stream provided to skjpeg_source_mgr. Add some comments explaining how skjpeg_source_mgr's members handle ownership. Fix a warning comparing signed and unsigned numbers, converting to size_t which is more appropriate for measuring bytes. Remove dead code referring to fMemoryBase and fMemoryBaseSize, which are never used. src/images/SkImageDecoder_libjpeg.cpp: Call the new constructor for skjpeg_source_mgr, which no longer takes a boolean to determine ownership. include/images/SkBitmapRegionDecoder.h src/images/SkBitmapRegionDecoder.cpp: This small shim has been removed, since it is not needed to use Skia's image decoders. Its functionality will be folded into Android. Required for the merge to Android. R=djsollen@google.com Review URL: https://codereview.chromium.org/21561002 git-svn-id: http://skia.googlecode.com/svn/trunk@10483 2bbb7eff-a529-9590-31e7-b0007b416f81
* Separate core and images project.Gravatar scroggo@google.com2013-05-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 Review URL: https://codereview.chromium.org/15806010 git-svn-id: http://skia.googlecode.com/svn/trunk@9364 2bbb7eff-a529-9590-31e7-b0007b416f81
* add encodeData() to SkImageEncoder, and add encoding to SkImageGravatar reed@google.com2013-05-20
| | | | | | | | | BUG= R=scroggo@google.com Review URL: https://codereview.chromium.org/15002004 git-svn-id: http://skia.googlecode.com/svn/trunk@9193 2bbb7eff-a529-9590-31e7-b0007b416f81
* Provide a function to print the name of a Format.Gravatar scroggo@google.com2013-05-15
| | | | | | | | | | Also use SkToU32 instead of a flat cast. R=djsollen@google.com Review URL: https://codereview.chromium.org/14565005 git-svn-id: http://skia.googlecode.com/svn/trunk@9139 2bbb7eff-a529-9590-31e7-b0007b416f81
* Test region decoding in skimage, plus fixes.Gravatar scroggo@google.com2013-05-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add tests in skimage to perform region decoding. Write out a PNG of the region as well as a bitmap obtained with extractSubset for comparison. Rename decodeRegion to decodeSubset, so it will not be confused with SkRegion. (Leave a function called decodeRegion which calls decodeSubset.) Clean up some comments. Use png_set_interlaced_pass instead of modifying pass directly. Make some changes to region decoding to fix problems I discovered during testing: Only call getAddr within a valid range. Check for a NULL fInputStream. Return a boolean for whether cropBitmap succeeded. In cropBitmap, do not attempt to draw to a bitmap to an Index8 bitmap, which crashes. Use extractSubset instead. Remove an assert. R=djsollen@google.com Review URL: https://codereview.chromium.org/14567011 git-svn-id: http://skia.googlecode.com/svn/trunk@8996 2bbb7eff-a529-9590-31e7-b0007b416f81
* Updates to skimage tool to use it for testing.Gravatar scroggo@google.com2013-04-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | skimage_main.cpp: More changes in the interest of testing our decoders. force_all_opaque before writing PNG files. Test reencoding the image to its original type (if possible), and then test redecoding it (to make sure the encoding was successful). Add an option to turn off this behavior. Merge decodeFileAndWrite with decodeFile. SkImageDecoder: Add kUnknown_Type to SkImageEncoder::Types. Add a static function to get the Format of an SkStream. In getFormatName(), remove an incorrect assert. When calling the flavor of DecodeStream that returns the Format, check the stream if the decoder returns kUnknown_Format. BUG=https://code.google.com/p/skia/issues/detail?id=1241 Review URL: https://codereview.chromium.org/14363003 git-svn-id: http://skia.googlecode.com/svn/trunk@8862 2bbb7eff-a529-9590-31e7-b0007b416f81
* ARGB image encoder for checksums.Gravatar bungeman@google.com2013-04-23
| | | | | | | https://codereview.chromium.org/14267031/ git-svn-id: http://skia.googlecode.com/svn/trunk@8831 2bbb7eff-a529-9590-31e7-b0007b416f81
* Updates to images project.Gravatar scroggo@google.com2013-04-17
| | | | | | | | | | | | | | | | | | | | | | Use the SkImageEncoder_Factory on all platforms. On Windows and Mac, register the platform's image encoder as an option for SkImageEncoder::Create. Also add more types that can be decoded. Update comments for SkImageDecoder to be more accurate. Add more types to SkImageEncoder::Type, and return the correct type of encoder, if it exists. Use a custom version of SkImageDecoder::Factory on Windows and Mac to check the stream for registered decoders before defaulting to the platform's version. Share code with the existing SkImageDecoder::Factory method. Preparation for testing decoders and encoders: BUG=https://code.google.com/p/skia/issues/detail?id=1241 Review URL: https://codereview.chromium.org/14298010 git-svn-id: http://skia.googlecode.com/svn/trunk@8730 2bbb7eff-a529-9590-31e7-b0007b416f81
* Upstream changes from Android for decoding jpeg images.Gravatar djsollen@google.com2013-03-20
| | | | | | Review URL: https://codereview.chromium.org/12438025 git-svn-id: http://skia.googlecode.com/svn/trunk@8267 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove unused declarationGravatar djsollen@google.com2013-03-20
| | | | | | Review URL: https://codereview.chromium.org/12704017 git-svn-id: http://skia.googlecode.com/svn/trunk@8257 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix window's build errorsGravatar commit-bot@chromium.org2013-03-14
| | | | | | | | | | Author: djsollen@google.com Reviewed By: bsalomon@google.com,borenet@google.com,reed@google.com Review URL: https://chromiumcodereview.appspot.com/12668007 git-svn-id: http://skia.googlecode.com/svn/trunk@8158 2bbb7eff-a529-9590-31e7-b0007b416f81
* Upstream Android modifications to the image encoders/decoders.Gravatar commit-bot@chromium.org2013-03-14
| | | | | | | | | | | | | | This CL does not update the libjpeg as that change is large enough to warrant its own CL. Author: djsollen@google.com Reviewed By: reed@google.com,robertphillips@google.com,scroggo@google.com Review URL: https://chromiumcodereview.appspot.com/12604006 git-svn-id: http://skia.googlecode.com/svn/trunk@8155 2bbb7eff-a529-9590-31e7-b0007b416f81
* Create SkLazyPixelRef which performs lazy decoding.Gravatar scroggo@google.com2013-02-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new pixel ref behaves similarly to SkImageRef, with some key differences: It does not depend on the images project. It requires an SkImageCache, which handles allocation and caching of the pixel memory. It takes a function signature for decoding which decodes into already allocated pixel memory rather than into an SkBitmap. Add two implementations of SkImageCache: SkLruImageCache and SkAshmemImageCache. Replace SkSerializationHelpers::DecodeBitmap with SkPicture::InstallPixelRefProc, and update sites that referenced it. SkBitmapFactory now sets the pixel ref to a new object of the new class SkLazyPixelRef, provided it has an SkImageCache for caching. Provide an option to do lazy decodes in render_pictures and bench_pictures. SkPicture: Eliminate the default parameters in the constructor. If a proc for decoding bitmaps is installed, use it to decode any encoded data in subpictures. When parsing deserializing subpictures, check for success. When serializing subpictures, pass the picture's bitmap encoder to the subpicture's call to serialize. Update BitmapFactoryTest to test its new behavior. BUG=https://code.google.com/p/skia/issues/detail?id=1008 BUG=https://code.google.com/p/skia/issues/detail?id=1009 Review URL: https://codereview.appspot.com/7060052 git-svn-id: http://skia.googlecode.com/svn/trunk@7835 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix android errors when unflattening an SkImageRef_ashmem object.Gravatar djsollen@google.com2013-02-01
| | | | | | Review URL: https://codereview.appspot.com/7228071 git-svn-id: http://skia.googlecode.com/svn/trunk@7514 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2013-01-26
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@7406 2bbb7eff-a529-9590-31e7-b0007b416f81
* kill unused SkFlipPixelRefGravatar reed@google.com2012-12-13
| | | | | | Review URL: https://codereview.appspot.com/6949043 git-svn-id: http://skia.googlecode.com/svn/trunk@6781 2bbb7eff-a529-9590-31e7-b0007b416f81
* Create a factory to decode an SkBitmap from an SkData.Gravatar scroggo@google.com2012-11-29
| | | | | | | | | | | | | | | | Add a test and a GM for the factory, and a PNG file for it to decode. The PNG file is copyright-free, obtained from http://openclipart.org/detail/29213/paper-plane-by-ddoo In cmykjpeg, do not attempt to decode in the constructor, since it currently crashes on Mac (if you provide the correct resource path). Even when we fix this crash there is no need to do it in the constructor, since we create all of the gms in order to get their names (to determine whether to run them). Review URL: https://codereview.appspot.com/6847122 git-svn-id: http://skia.googlecode.com/svn/trunk@6618 2bbb7eff-a529-9590-31e7-b0007b416f81
* Extract transform_scanline_XXXX functions into transform_scanline.h for ↵Gravatar epoger@google.com2012-11-16
| | | | | | | | code-sharing Review URL: https://codereview.appspot.com/6849065 git-svn-id: http://skia.googlecode.com/svn/trunk@6468 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add the ability to provide function pointers to SkPicture serializationGravatar scroggo@google.com2012-10-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | and deserialization for encoding and decoding bitmaps. Remove kForceFlattenBitmapPixels_Flag, which is no longer used. When an SkOrderedReadBuffer needs to read a bitmap, if it does not have an image decoder, use a dummy bitmap. In GM, add a tolerance option for color differences, used when testing picture serialization, so it can assume two images are the same even though PNG encoding/decoding may have resulted in small differences. Create dummy implementations for SkImageDecoder and SkImageEncoder functions in SkImageDecoder_empty so that a project that does not want to include the images project it can still build. Allow ports to build without images project. In Mac's image encoder, copy 4444 to 8888 before encoding. Add SkWriter32::reservePad, to provide a pointer to write non 4 byte aligned data, padded with zeroes. In bench_ and render_ pictures, pass decode function to SkPicture creation from a stream. BUG=https://code.google.com/p/skia/issues/detail?id=842 Review URL: https://codereview.appspot.com/6551071 git-svn-id: http://skia.googlecode.com/svn/trunk@5818 2bbb7eff-a529-9590-31e7-b0007b416f81
* Result of running tools/sanitize_source_files.py (which was added in ↵Gravatar rmistry@google.com2012-08-23
| | | | | | | | | https://codereview.appspot.com/6465078/) This CL is part I of IV (I broke down the 1280 files into 4 CLs). Review URL: https://codereview.appspot.com/6485054 git-svn-id: http://skia.googlecode.com/svn/trunk@5262 2bbb7eff-a529-9590-31e7-b0007b416f81
* Expanded distribution of instance countingGravatar robertphillips@google.com2012-06-21
| | | | | | | | http://codereview.appspot.com/6300114/ git-svn-id: http://skia.googlecode.com/svn/trunk@4291 2bbb7eff-a529-9590-31e7-b0007b416f81
* Cleanup code related to SkFlattenable::flatten()Gravatar djsollen@google.com2012-03-29
| | | | | | | | | | | | | | | | | The following changes were made by this CL: 1. Make flatten() a protected method as callers should use SkFlattenableWriteBuffer to flatten an object 2. Make flatten a const method (including subclasses) 3. Mark subclass implementation of flatten with SK_OVERRIDE 4. Ensure overridden flatten impls call their parent 5. Remove no-op implementations of flatten from subclasses Additionally, if necessary the unflattening constructor was also moved to the protected section of the subclasses header if it was not already there. git-svn-id: http://skia.googlecode.com/svn/trunk@3540 2bbb7eff-a529-9590-31e7-b0007b416f81
* Consolidate PixelRef flattables with the standard implGravatar djsollen@google.com2012-03-28
| | | | | | | | | | The flatten method on these functions can no longer be const as SkFlattenables declaration is not const and would result in the const methods only being called when the reference to the object was const. Review URL: https://codereview.appspot.com/5941043 git-svn-id: http://skia.googlecode.com/svn/trunk@3533 2bbb7eff-a529-9590-31e7-b0007b416f81