aboutsummaryrefslogtreecommitdiffhomepage
path: root/dm/DMSrcSink.h
Commit message (Collapse)AuthorAge
* DM testing for skipping and scalingGravatar msarett2015-06-11
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1175993005
* Add caps overrides to GMsGravatar bsalomon2015-05-27
| | | | Review URL: https://codereview.chromium.org/1158963002
* New CodeSrc* draw mode kScanline_Subset_ModeGravatar emmaleer2015-05-27
| | | | | | | | | kScanline_Subset_Mode decodes the image in subsets using a scanline decoder. The number of subsets can be specified by changing the constant divisor. The number of subsets is equal to divisor*divisor. Review URL: https://codereview.chromium.org/1157153003
* Do we still need this DOUBLE_LOOP feature?Gravatar mtklein2015-05-06
| | | | | | | | | If so, let's do it this way so it works for all source types and doesn't need to be chosen at compile time. BUG=skia: Review URL: https://codereview.chromium.org/1129693003
* DM: add Via abstract classGravatar mtklein2015-05-06
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1117183007
* DM: add a Via to simulate SP pictures.Gravatar mtklein2015-05-05
| | | | | | | | | | Will use this to test the other CL that adds small SkPicture implementations. Not quite sure why patch_primitive doesn't draw the same in 8888 and sp-8888, but everything else does, so I'm not going to let that hold me back for now. BUG=skia: Review URL: https://codereview.chromium.org/1126613005
* add deferred config to DMGravatar reed2015-05-05
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1113273006
* ***Disables swizzles to 565.Gravatar msarett2015-04-09
| | | | | | | | | | | | | | | | | | | | | | | We may want to enable swizzles to 565 for images that are encoded in a format similar to 565, however, we do not want to take images that decode naturally to kN32 and then convert them to 565. ***Enable swizzles to kIndex_8. For images encoded in a color table format, we suggest that they be decoded to kIndex_8. When we decode, we only allow conversion to kIndex_8 if it matches the suggested color type (except wbmp which seems good as is). ***Modify dm to test images that decode to kIndex_8. BUG=skia:3257 BUG=skia:3440 Review URL: https://codereview.chromium.org/1055743003
* Add a Via to DM that records into two pictures and draws using the second.Gravatar mtklein2015-04-07
| | | | | | | | | I'm going to start hacking on SkCanvas a bit to allow a fast reset method, and I want to have some testing checking me. BUG=skia: Review URL: https://codereview.chromium.org/1062043004
* C++11 override should now be supported by all of {bots,Chrome,Android,Mozilla}Gravatar mtklein2015-03-25
| | | | | | | | | NOPRESUBMIT=true BUG=skia: DOCS_PREVIEW= https://skia.org/?cl=1037793002 Review URL: https://codereview.chromium.org/1037793002
* Test scanline decoding in DM.Gravatar scroggo2015-03-25
| | | | | | BUG=skia:3475 Review URL: https://codereview.chromium.org/999173010
* Add copyright headers DM.Gravatar scroggo2015-03-25
| | | | Review URL: https://codereview.chromium.org/1037713003
* Run CodecSrc DM.Gravatar scroggo2015-03-19
| | | | | | | | | | | Rather than making SkCodec an option instead of SkImageDecoder, create a separate CodecSrc. This allows us to compare the two. For both CodecSrc and ImageSrc, do not decode to a gpu backend. BUG=skia:3475 Review URL: https://codereview.chromium.org/978823002
* DM: support non-fatal errorsGravatar mtklein2015-03-05
| | | | | | | | | | | | | | | | | | | | | | | | Tasks that produce a non-fatal error will bail out before writing their output to disk and hash to dm.json, but not count as failures. This also makes true failures bail out before writing their results. If the DM program failed, we probably don't want to triage that image result. We use this new feature first to skip image subset decoding when we detect it's not supported. Here's a snippet of an example run, where in this case only .webp are subset decodable: ... ( 15MB 12) 172µs 8888 subset color_wheel.jpg (skipped: Subset decoding not supported.) ( 15MB 11) 9.05ms 8888 subset randPixels.webp ( 16MB 10) 863µs 8888 subset baby_tux.png (skipped: Subset decoding not supported.) ... Only outputs corresponding to the .webp show up, both on disk and in the .json. BUG=skia: Review URL: https://codereview.chromium.org/980333002
* XPS, DM: add SkDocument::CreateXPSGravatar halcanary2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | - SkDocument::CreateXPS() function added, returns NULL on non-Windows OS. - DM: (Windows only) an XPSSink is added, fails on non-Windows OS - DM: Common code for PDFSink::draw and XPSSink::draw are factored into draw_skdocument static function. - SkDocument_XPS (Windows only) implementation of SkDocument via SkXPSDevice. - SkDocument_XPS_None (non-Windows) returns NULL for SkDocument::CreateXPS(). - gyp/xps.gyp refactored. - SkXPSDevice::drawTextOnPath removed (see http://crrev.com/925343003 ) - SkXPSDevice::drawPath supports conics via SkAutoConicToQuads. Review URL: https://codereview.chromium.org/963953002
* Revert of XPS, DM: add SkDocument::CreateXPS (patchset #8 id:310001 of ↵Gravatar halcanary2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/963953002/) Reason for revert: breaking iOS build. Original issue's description: > XPS, DM: add SkDocument::CreateXPS > > - SkDocument::CreateXPS() function added, returns NULL on non-Windows OS. > > - DM: (Windows only) an XPSSink is added, fails on non-Windows OS > > - DM: Common code for PDFSink::draw and XPSSink::draw are factored into > draw_skdocument static function. > > - SkDocument_XPS (Windows only) implementation of SkDocument via > SkXPSDevice. > > - SkDocument_XPS_None (non-Windows) returns NULL for > SkDocument::CreateXPS(). > > - gyp/xps.gyp refactored. > > - SkXPSDevice::drawTextOnPath removed (see http://crrev.com/925343003 ) > > - SkXPSDevice::drawPath supports conics via SkAutoConicToQuads. > > NOPRESUBMIT=true > > Committed: https://skia.googlesource.com/skia/+/00d39bcbfc8394a9b48b86b04ab06ec19091fa43 TBR=reed@google.com,bungeman@google.com,mtklein@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/978443002
* XPS, DM: add SkDocument::CreateXPSGravatar halcanary2015-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | - SkDocument::CreateXPS() function added, returns NULL on non-Windows OS. - DM: (Windows only) an XPSSink is added, fails on non-Windows OS - DM: Common code for PDFSink::draw and XPSSink::draw are factored into draw_skdocument static function. - SkDocument_XPS (Windows only) implementation of SkDocument via SkXPSDevice. - SkDocument_XPS_None (non-Windows) returns NULL for SkDocument::CreateXPS(). - gyp/xps.gyp refactored. - SkXPSDevice::drawTextOnPath removed (see http://crrev.com/925343003 ) - SkXPSDevice::drawPath supports conics via SkAutoConicToQuads. NOPRESUBMIT=true Review URL: https://codereview.chromium.org/963953002
* PDF: Now threadsafe!Gravatar halcanary2015-02-20
| | | | | | | | | | | | | The PDF canvas is now just as threadsafe as any other Skia canvas. DM updated to thread PDF tests. SkDocument_PDF now owns SkPDFCanon, and pointers to that canon are passed around to all classes that need access to the canon. BUG=skia:2683 Review URL: https://codereview.chromium.org/944643002
* Suggested version with 'undo'.Gravatar mtklein2015-02-17
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/931483002
* DM: don't leak the null canvas in NullSink.Gravatar mtklein2015-02-13
| | | | | | | | Also make NullSink a real boy: declared among the other Sinks, impl in .cpp. BUG=skia: Review URL: https://codereview.chromium.org/922293003
* patch from issue 886233004 at patchset 40001 ↵Gravatar mtklein2015-02-02
| | | | | | | | | | (http://crrev.com/886233004#ps40001) ... with changes proposed in the review. BUG=skia: Review URL: https://codereview.chromium.org/894013002
* SVG backend in DMGravatar mtklein2015-01-31
| | | | | | | | | | Not enabled by default, but this should get you SKPs, GMs etc for free to play with. $ out/Debug/dm -w svgs --src gm skp --config svg BUG=skia: Review URL: https://codereview.chromium.org/892693002
* Suggestions and merge in the other CL.Gravatar mtklein2015-01-30
| | | | | | | | | I had some suggestions on the subset CL, and took the opportunity to rebase it against head and merge in the other color type CL. BUG=skia: Review URL: https://codereview.chromium.org/893703002
* DM: paths as implict strings too.Gravatar mtklein2015-01-30
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/891823002
* DM::NullSinkGravatar halcanary2015-01-30
| | | | | | Motivation: The null sink can act as a control for experiments. Review URL: https://codereview.chromium.org/873723007
* Fold gmtoskp into DM, as --src gm --config skp.Gravatar mtklein2015-01-28
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/885733002
* More natural way to serialize GPU tasks and tests.Gravatar mtklein2015-01-21
| | | | | | | | | | | | | This basically takes out the Windows-only hacks and promotes them to cross-platform behavior driven by --gpu_threading. - When --gpu_threading is false (the default), this puts GPU tasks and tests together in the same GPU enclave. They all run serially. - When --gpu_threading is true, both the tests and the tasks run totally independently, just like the thread-safe CPU-bound work. BUG=skia:3255 Review URL: https://codereview.chromium.org/847273005
* Don't test pipe modes nobody uses.Gravatar mtklein2015-01-21
| | | | | | | | | | | | | SkDeferredCanvas uses a simple pipe: no cross-process, no shared-address, etc. (see src/utils/SkDeferredCanvas.cpp:306). We could just remove these modes from the bot configs, but I'd like to take the opportunity to simplify the DM code too. I'll happily volunteer to put things back should we decide we want to test these modes. BUG=skia: Review URL: https://codereview.chromium.org/861303003
* 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
* DM: Don't hold onto data longer than needed.Gravatar mtklein2015-01-18
| | | | | | | | On my laptop, this cuts peak memory usage by more than half. BUG=skia:3255 Review URL: https://codereview.chromium.org/859623002
* turn back on gpu testsGravatar mtklein2015-01-15
| | | | | | | | NOTREECHECKS=true BUG=skia:3255 Review URL: https://codereview.chromium.org/817573004
* Sketch DM refactor.Gravatar mtklein2015-01-15
| | | | | | | | | | | | | | | | | | | BUG=skia:3255 I think this supports everything DM used to, but has completely refactored how it works to fit the design in the bug. Configs like "tiles-gpu" are automatically wired up. I wouldn't suggest looking at this as a diff. There's just a bunch of deleted files, a few new files, and one new file that shares a name with a deleted file (DM.cpp). NOTREECHECKS=true Committed: https://skia.googlesource.com/skia/+/709d2c3e5062c5b57f91273bfc11a751f5b2bb88 Review URL: https://codereview.chromium.org/788243008
* Revert of Sketch DM refactor. (patchset #45 id:850001 of ↵Gravatar mtklein2015-01-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/788243008/) Reason for revert: plenty of data Original issue's description: > Sketch DM refactor. > > BUG=skia:3255 > > > I think this supports everything DM used to, but has completely refactored how > it works to fit the design in the bug. > > Configs like "tiles-gpu" are automatically wired up. > > I wouldn't suggest looking at this as a diff. There's just a bunch of deleted > files, a few new files, and one new file that shares a name with a deleted file > (DM.cpp). > > NOTREECHECKS=true > > Committed: https://skia.googlesource.com/skia/+/709d2c3e5062c5b57f91273bfc11a751f5b2bb88 TBR=bsalomon@google.com,mtklein@chromium.org NOTREECHECKS=true NOTRY=true BUG=skia:3255 Review URL: https://codereview.chromium.org/853883004
* Sketch DM refactor.Gravatar mtklein2015-01-15
BUG=skia:3255 I think this supports everything DM used to, but has completely refactored how it works to fit the design in the bug. Configs like "tiles-gpu" are automatically wired up. I wouldn't suggest looking at this as a diff. There's just a bunch of deleted files, a few new files, and one new file that shares a name with a deleted file (DM.cpp). NOTREECHECKS=true Review URL: https://codereview.chromium.org/788243008