aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
Commit message (Collapse)AuthorAge
...
* In SkPDFDocument::emitPDF(), stop pre-calculating file offsets.Gravatar halcanary2015-01-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add Streamer utility class which measures the current pdf offset by calling SkWStream::bytesWritten(). Calls SkPDFCatalog::setFileOffset() and SkPDFObject::emit() at the same time to guarantee that everything works out. * SkPDFCatalog::setFileOffset() no longer calculates the object's size. * SkPDFCatalog::setSubstituteResourcesOffsets() removed. * SkPDFCatalog::emitSubstituteResources() removed and getSubstituteList() made public in its place. * Remove SkPDFPage::getPageSize and SkPDFPage::emitPage. Replace with SkPDFPage::getContentStream(). * SkPDFObject::getOutputSize no longer virtual, only used in unit tests. All SkPDFObject subclasses getOutputSize() overrides removed. * SkPDFObject::getIndirectOutputSize removed. * PDFPrimitivesTest updated for new functions. Review URL: https://codereview.chromium.org/846023003
* Change function signature of SkPDFObject::emitObject.Gravatar halcanary2015-01-12
| | | | | | | | | | | | | Replace virutal SkPDFObject::emitObject(s, c, true) with non-virtual SkPDFObject::emitIndirectObject(s, c), since none of the subclasses do (or should do) anything different. Replace object->emitObject(s, c, false) with object->emitObject(s, c) This is one step in simplifying the SkPDFObject interface to allow for the next step in refactoring. Review URL: https://codereview.chromium.org/827733004
* Fix up all the easy virtual ... SK_OVERRIDE cases.Gravatar mtklein2015-01-09
| | | | | | | | | | | | This fixes every case where virtual and SK_OVERRIDE were on the same line, which should be the bulk of cases. We'll have to manually clean up the rest over time unless I level up in regexes. for f in (find . -type f); perl -p -i -e 's/virtual (.*)SK_OVERRIDE/\1SK_OVERRIDE/g' $f; end BUG=skia: Review URL: https://codereview.chromium.org/806653007
* Remove SkTileGrid (except for TileGridInfo).Gravatar mtklein2015-01-09
| | | | | | | | TBR=reed@google.com BUG=skia:3085 Review URL: https://codereview.chromium.org/845623002
* add ImageGenerator::NewFromData to porting layerGravatar reed2015-01-07
| | | | | | BUG=skia:3275 Review URL: https://codereview.chromium.org/834633006
* Remove macros that make it look like it's a good idea to not be able to flatten.Gravatar mtklein2015-01-07
| | | | | | | | | | | | | | | | | There are only a handful of SkFlattenables that are not flattenable. That there are any seems highly illogical. To make this look less like a normal thing, this removes both macros that marked SkFlattenables as non-flattenable (in slightly different ways). The handful of SkFlattenables in our codebase that can't be flattened now assert violently that they can't be flattened. They're internal or part of animator... places where we'll never actually flatten them. TestLooper and DummyRasterizer were so trivial that I just made them flattenable. BUG=skia: Review URL: https://codereview.chromium.org/841753002
* Rename SkDrawPictureCallback to SkPicture::AbortCallbackGravatar robertphillips2015-01-07
| | | | | | Committed: https://skia.googlesource.com/skia/+/7ef197255deb4e2fa64c03c7130d56ddf164e83c Review URL: https://codereview.chromium.org/829983003
* Revert of Rename SkDrawPictureCallback to SkPicture::AbortCallback (patchset ↵Gravatar reed2015-01-06
| | | | | | | | | | | | | | | | | | #2 id:20001 of https://codereview.chromium.org/829983003/) Reason for revert: speculative revert to unblock DEPS roll Original issue's description: > Rename SkDrawPictureCallback to SkPicture::AbortCallback > > Committed: https://skia.googlesource.com/skia/+/7ef197255deb4e2fa64c03c7130d56ddf164e83c TBR=reed@google.com,robertphillips@google.com NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/824013004
* Rename SkDrawPictureCallback to SkPicture::AbortCallbackGravatar robertphillips2015-01-06
| | | | Review URL: https://codereview.chromium.org/829983003
* Require explicit disabling of cross process pictureimagefiltersGravatar robertphillips2015-01-06
| | | | | | | | This is to allow capturing .skp files with their pictureimagefilters intact. This is a companion to https://codereview.chromium.org/810933004/ (Provide a way of allowing cross process pictureimagefilters). Review URL: https://codereview.chromium.org/834673006
* Remove SkPath::asRectGravatar robertphillips2015-01-05
| | | | | | | | | | AFAICT the asRect entry point is not needed. Greg: GPU Reed: API Cary: Path Review URL: https://codereview.chromium.org/833193002
* Cleanup isRect variantsGravatar robertphillips2015-01-05
| | | | Review URL: https://codereview.chromium.org/832083002
* Revert of Revert of move remaining virtual draw methods to onDraw (patchset ↵Gravatar reed2015-01-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | #1 id:1 of https://codereview.chromium.org/835913002/) Reason for revert: test to see if it wasn't this CL that broke chromeos Original issue's description: > Revert of move remaining virtual draw methods to onDraw (patchset #5 id:80001 of https://codereview.chromium.org/817723005/) > > Reason for revert: > did this cause chromeos heap corruption on skp? > > Original issue's description: > > move remaining virtual draw methods to onDraw > > > > BUG=skia: > > > > Committed: https://skia.googlesource.com/skia/+/2e0f7d53bba5438c9bf11ee5ccae2c301e348419 > > TBR=robertphillips@google.com,djsollen@google.com,bsalomon@google.com,mtklein@google.com > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/e87e383351e1547b21d96d02bcd0c3cbbe0837f1 TBR=robertphillips@google.com,djsollen@google.com,bsalomon@google.com,mtklein@google.com,reed@chromium.org NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/831253002
* Clean up dead clear() code in SkRecord.Gravatar mtklein2015-01-05
| | | | | | | | | | | | | This removes the SkRecords::Clear struct and everything that refers to it. Notice there is nothing actually creating a Clear, which means this is all dead code. Now that all ops obey the clip, I don't think we need the weird inflate-empty-to-epsilon hack for BBH queries. BUG=skia: Review URL: https://codereview.chromium.org/835813002
* Revert of move remaining virtual draw methods to onDraw (patchset #5 ↵Gravatar reed2015-01-05
| | | | | | | | | | | | | | | | | | | | | id:80001 of https://codereview.chromium.org/817723005/) Reason for revert: did this cause chromeos heap corruption on skp? Original issue's description: > move remaining virtual draw methods to onDraw > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/2e0f7d53bba5438c9bf11ee5ccae2c301e348419 TBR=robertphillips@google.com,djsollen@google.com,bsalomon@google.com,mtklein@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/835913002
* move remaining virtual draw methods to onDrawGravatar reed2015-01-04
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/817723005
* remove unused drawDataGravatar reed2015-01-02
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/830083002
* change API contract: disallow zero-sized images or surfacesGravatar reed2014-12-31
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/830033003
* Add a simpler key type for scratch resource keys.Gravatar bsalomon2014-12-30
| | | | | | BUG=skia:2889 Review URL: https://codereview.chromium.org/815833004
* Fix bound returned by SkPath::isRect when the path contains a trailing moveToGravatar robertphillips2014-12-29
| | | | | | | | | | | | | | | | | | Oddly enough this was fixed in: https://codereview.chromium.org/16950021/ (add rect-output parameter to isRect, allowing us to return the correct bounds even if a rectagular path has a trailing moveTo) but was reverted here: https://skia.googlesource.com/skia/+/8fd160350ca5f57fbb1b2e03383c5778414a9b48 since it appeared to be crashing Chrome's trybots. I think it just fell through the cracks after that. If this sticks I will land a follow on patch for the stroke issue reported in the original bug (crbug.com/247770). BUG=247770,445368 Review URL: https://codereview.chromium.org/834483002
* Add device space skshader GM to test kDevice_GrCoordSetGravatar bsalomon2014-12-29
| | | | Review URL: https://codereview.chromium.org/816003002
* add testing flag to ignore saveLayer boundsGravatar reed2014-12-22
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/819123003
* Rename GrGpuGL -> GrGLGpuGravatar jvanverth2014-12-22
| | | | Review URL: https://codereview.chromium.org/824753002
* Add toString methods to SkImageFilter-derived classesGravatar robertphillips2014-12-19
| | | | | | This isn't definitive but at least makes something show up in the debugger. Review URL: https://codereview.chromium.org/789163006
* add const to encodePixels pixel parameterGravatar reed2014-12-19
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/788143007
* Enable new gradients + suppress gms for nowGravatar reed2014-12-19
| | | | | | | | | This reverts commit 2c770271e612376508c18793c7067598378a00d9. BUG=skia: TBR= Review URL: https://codereview.chromium.org/811753003
* Cleanup: Remove a bunch of SkFontHost.h includes (unused).Gravatar tfarina2014-12-18
| | | | | | | | | | Nobody that is including SkFontHost is using SkFontHost API, so lets remove this includes, since the API per se is deprecated. BUG=None R=reed@google.com Review URL: https://codereview.chromium.org/803733006
* One more pass at getting half float texture configs correct.Gravatar jvanverth2014-12-18
| | | | | | | | | Added in check for sized internal format. Made choice between RED and ALPHA orthogonal to HALF_FLOAT and HALF_FLOAT_OES. Enabled rendertarget support on ES 2.0. Review URL: https://codereview.chromium.org/805033002
* Stop creating GrODS for stencilPath commands.Gravatar bsalomon2014-12-17
| | | | Review URL: https://codereview.chromium.org/816513003
* use conicsGravatar reed2014-12-17
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/455043002
* SkMatrix44(const SkMatrix&) needs to initialize the type maskGravatar fs2014-12-16
| | | | Review URL: https://codereview.chromium.org/791723006
* Fix layer hoisting image filter corner casesGravatar robertphillips2014-12-16
| | | | | | | | | | | | | | | | | | | | | | | | | | This CL fixes 5 bugs related to hoisting image filters: For image filters the src layer (the one prior to filtering) often needs to be smaller then the final layer. This requires the saveLayer's optional bounds to be stored (in SkLayerInfo.h and SkRecordDraw.cpp) and then used in compute_source_rect and carried around in GrCachedLayer. The image filters can add an extra offset to the final draw operation. This is now computed in GrLayerHoister::FilterLayer and carried around in GrCachedLayer. Filtered layers must use exact matches. This is now done in GrLayerCache::lock. The filter cache requires a valid matrix so it can compute the correct offset. This is now done in GrLayerHoister::FilterLayer. Filtered layers need to be drawn with drawSprite while unfiltered (and therefore hopefully atlased) layers can be drawn with drawBitmap. This is now done in draw_replacement_bitmap. Committed: https://skia.googlesource.com/skia/+/702eb9622102599d94ab6798e6227cf29f48c2d3 Review URL: https://codereview.chromium.org/803183003
* Revert of Fix layer hoisting image filter corner cases (patchset #3 id:40001 ↵Gravatar robertphillips2014-12-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of https://codereview.chromium.org/803183003/) Reason for revert: Breaking DM Original issue's description: > Fix layer hoisting image filter corner cases > > This CL fixes 5 bugs related to hoisting image filters: > > For image filters the src layer (the one prior to filtering) often needs to be > smaller then the final layer. This requires the saveLayer's optional bounds > to be stored (in SkLayerInfo.h and SkRecordDraw.cpp) and then used in > compute_source_rect and carried around in GrCachedLayer. > > The image filters can add an extra offset to the final draw operation. > This is now computed in GrLayerHoister::FilterLayer and carried around in > GrCachedLayer. > > Filtered layers must use exact matches. This is now done in GrLayerCache::lock. > > The filter cache requires a valid matrix so it can compute the correct offset. > This is now done in GrLayerHoister::FilterLayer. > > Filtered layers need to be drawn with drawSprite while unfiltered (and therefore > hopefully atlased) layers can be drawn with drawBitmap. This is now done in > draw_replacement_bitmap. > > Committed: https://skia.googlesource.com/skia/+/702eb9622102599d94ab6798e6227cf29f48c2d3 TBR=bsalomon@google.com NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/790643009
* Rename GrGpuGL to GrGLGpu for consistencyGravatar bsalomon2014-12-16
| | | | Review URL: https://codereview.chromium.org/808593003
* Fix layer hoisting image filter corner casesGravatar robertphillips2014-12-16
| | | | | | | | | | | | | | | | | | | | | | | | This CL fixes 5 bugs related to hoisting image filters: For image filters the src layer (the one prior to filtering) often needs to be smaller then the final layer. This requires the saveLayer's optional bounds to be stored (in SkLayerInfo.h and SkRecordDraw.cpp) and then used in compute_source_rect and carried around in GrCachedLayer. The image filters can add an extra offset to the final draw operation. This is now computed in GrLayerHoister::FilterLayer and carried around in GrCachedLayer. Filtered layers must use exact matches. This is now done in GrLayerCache::lock. The filter cache requires a valid matrix so it can compute the correct offset. This is now done in GrLayerHoister::FilterLayer. Filtered layers need to be drawn with drawSprite while unfiltered (and therefore hopefully atlased) layers can be drawn with drawBitmap. This is now done in draw_replacement_bitmap. Review URL: https://codereview.chromium.org/803183003
* Revert of Use SkPaint::getFontBounds() for text bounding boxes in pictures. ↵Gravatar mtklein2014-12-16
| | | | | | | | | | | | | | | | | | | | | | | | | | (patchset #1 id:1 of https://codereview.chromium.org/805983003/) Reason for revert: Test-Win7-ShuttleA-HD2000-x86-Debug-GDI Original issue's description: > Use SkPaint::getFontBounds() for text bounding boxes in pictures. > > Now that SkTextBlobs have landed, this is a perf no-op, but it at least lets us eliminate a bunch of questionable hacks. > > CQ_EXTRA_TRYBOTS=client.skia:Test-Win7-ShuttleA-HD2000-x86-Debug-Trybot,Test-Mac10.8-MacMini4.1-GeForce320M-x86_64-Debug-Trybot > > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/02d2b9831579173e783569530ab7bae08de907e9 TBR=reed@google.com,mtklein@chromium.org NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/789793004
* Use SkPaint::getFontBounds() for text bounding boxes in pictures.Gravatar mtklein2014-12-16
| | | | | | | | | | Now that SkTextBlobs have landed, this is a perf no-op, but it at least lets us eliminate a bunch of questionable hacks. CQ_EXTRA_TRYBOTS=client.skia:Test-Win7-ShuttleA-HD2000-x86-Debug-Trybot,Test-Mac10.8-MacMini4.1-GeForce320M-x86_64-Debug-Trybot BUG=skia: Review URL: https://codereview.chromium.org/805983003
* There can be only one (SkRandom)!Gravatar scroggo2014-12-15
| | | | | | | | | | | | | | | | | | | | | Remove SkLCGRandom. We already decided the new one was better, which is why we wrote the new SkRandom. Convert GMs that were using SkLCGRandom to use the improved SkRandom. Motivated by the fact that these GMs draw differently on some runs. We believe this to be a result of using the old SkLCGRandom. Add each of the tests that were using SkLCGRandom to ignore-tests.txt, since we expect they'll draw differently using SkRandom. Move a trimmed down version of SkLCGRandom into SkDiscretePathEffect. In order to preserve the old behavior, trim down SkLCGRandom to only the methods used by SkDiscretePathEffect, and hide it in SkDiscretePathEffect's cpp file. BUG=skia:3241 Review URL: https://codereview.chromium.org/805963002
* Fix rrects that are large enough that we lose/gain a bit when we add the ↵Gravatar reed2014-12-15
| | | | | | | | | | radius to a bounds coordinate. add test that triggers assert in addRRect BUG=skia:3239 Review URL: https://codereview.chromium.org/803153003
* Remove SkCanvas::isDrawingToLayerGravatar junov2014-12-15
| | | | | | BUG=3245 Review URL: https://codereview.chromium.org/803913005
* ensure 4-byte alignment for storage, as SkWriterBuffer requires itGravatar reed2014-12-15
| | | | | | BUG=skia:3244 Review URL: https://codereview.chromium.org/805803002
* add get9 and set9 to matrix, to aid in making keysGravatar reed2014-12-13
| | | | | | | | BUG=skia: TBR= NOTREECHECKS=True Review URL: https://codereview.chromium.org/806543002
* GLPrograms leak fixGravatar joshualitt2014-12-13
| | | | | | | | NOTREECHECKS=True TBR= BUG=skia: Review URL: https://codereview.chromium.org/799063005
* DM warning-free on win64Gravatar bsalomon2014-12-12
| | | | Review URL: https://codereview.chromium.org/805543002
* Even more win64 warning fixesGravatar bsalomon2014-12-12
| | | | Review URL: https://codereview.chromium.org/800993002
* Handle SkBitmaps which have no pixels in SkPDFImage.Gravatar jbroman2014-12-12
| | | | | | | | A test that ensures this no longer crashes has been added. BUG=skia:3232 Review URL: https://codereview.chromium.org/802713002
* Cull pushCull and popCull from Skia.Gravatar mtklein2014-12-12
| | | | | | | | These calls are unused and going away. Waiting on crrev.com/796083002. BUG=skia: Review URL: https://codereview.chromium.org/794263002
* SkRecord: increase min block to 512B, remove max.Gravatar mtklein2014-12-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we added the 64K allocation cap, the bots showed we took a perf hit on some large .skps like desk_pokemonwiki.skp, despite not seeing a local effect. I'm still not seeing that locally, but I'd like to try removing the cap on the bots to see what happens. For big monolithic pictures, really packing into memory tightly is probably not as important as it is for tiny ones. Similarly, we're probably being too cautious about making tiny allocations. Today we start at 16 bytes, which isn't really enough to record anything. Even the smallest picture, say, save clipRect drawRect restore requires ~200 bytes, so we might as well move our minimum block size up near there. I don't know if 16 bytes is too small to start for GrTextStrikes, so I've left the behavior the same (though the max is still gone). Local recording performance is neutral-to-positive: tabl_deviantart.skp 126us -> 129us 1.02x tabl_nytimes.skp 110us -> 112us 1.02x tabl_cuteoverload.skp 521us -> 530us 1.02x desk_mobilenews.skp 673us -> 682us 1.01x desk_chalkboard.skp 843us -> 854us 1.01x desk_sfgate.skp 528us -> 535us 1.01x desk_silkfinance.skp 68.2us -> 69us 1.01x desk_youtube.skp 623us -> 629us 1.01x desk_blogger.skp 472us -> 475us 1.01x desk_jsfiddlehumperclip.skp 42.2us -> 42.5us 1.01x desk_espn.skp 255us -> 256us 1.01x desk_ebay.skp 174us -> 174us 1x desk_twitter.skp 454us -> 455us 1x tabl_pravda.skp 200us -> 201us 1x desk_wordpress.skp 782us -> 784us 1x desk_samoasvg.skp 762us -> 761us 1x tabl_mozilla.skp 1.58ms -> 1.58ms 1x tabl_slashdot.skp 107us -> 107us 1x tabl_techmeme.skp 102us -> 102us 0.99x tabl_gamedeksiam.skp 729us -> 724us 0.99x tabl_nofolo.skp 65.3us -> 64.7us 0.99x desk_gmailthread.skp 339us -> 336us 0.99x tabl_sahadan.skp 91us -> 90us 0.99x desk_yahooanswers.skp 144us -> 142us 0.99x tabl_cnet.skp 143us -> 141us 0.99x tabl_googleblog.skp 206us -> 203us 0.99x tabl_cnn.skp 160us -> 158us 0.99x tabl_frantzen.skp 50.5us -> 49.6us 0.98x desk_linkedin.skp 328us -> 323us 0.98x tabl_digg.skp 790us -> 769us 0.97x desk_jsfiddlebigcar.skp 40.6us -> 39.5us 0.97x desk_mapsvg.skp 1.57ms -> 1.52ms 0.97x tabl_gmail.skp 19.4us -> 18.6us 0.96x tabl_hsfi.skp 9.81us -> 9.11us 0.93x BUG=skia: Review URL: https://codereview.chromium.org/793033002
* Fix float and half float support on mobile.Gravatar jvanverth2014-12-12
| | | | | | | It's unclear what params should be used for half float alpha rendertargets, so they are disabled for the moment. Review URL: https://codereview.chromium.org/799593002
* Fix GpuLayerCacheTest compile errorGravatar kkinnunen2014-12-12
| | | | | | | | | | | Fix GpuLayerCacheTest compile error: GpuLayerCacheTest.cpp:120:34: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] gcc --version gcc (Ubuntu/Linaro 4.6.4-1ubuntu1~12.04) 4.6.4 Review URL: https://codereview.chromium.org/794003003