aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
Commit message (Collapse)AuthorAge
* SkPDF: SkPDFStream takes a unique_ptrGravatar halcanary2016-07-27
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2188623004 Review-Url: https://codereview.chromium.org/2188623004
* Fix ParseConfigs_ViaParsing test when skia_angle=1Gravatar brianosman2016-07-27
| | | | | | | | | | | | | | | | The handling of angle-gl changes with SK_ANGLE. We don't have any bots that test this particular combination, but I see it all the time while running DM for other things. Previously considered changing things so that the config parsing results are consistent, regardless of GYP_DEFINES, but this is much simpler (and more consistent with the other code we already have for testing config parsing). BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2183323004 Review-Url: https://codereview.chromium.org/2183323004
* fuzz wednesdayGravatar caryclark2016-07-27
| | | | | | | | | | | | | Add debug 'skip assert' access to SkCoincidentSpans. That permits suppressing asserts to make it easier to detect when this fuzz data generates unparsable data. TBR=reed@google.com BUG=631564, 631992 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2186973002 Review-Url: https://codereview.chromium.org/2186973002
* Clean up some unused atomic routines.Gravatar mtklein2016-07-27
| | | | | | | | | | | AtomicTest was the only use of sk_atomic_add(). AtomicInc64 bench was the only use of sk_atomic_inc(int64_t*). BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2183473005 CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-TSAN-Trybot,Test-Ubuntu-GCC-Golo-GPU-GT610-x86_64-Release-TSAN-Trybot Review-Url: https://codereview.chromium.org/2183473005
* add unittests for roundtripping premulGravatar reed2016-07-26
| | | | | | | BUG=skia:5579 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2179123005 Review-Url: https://codereview.chromium.org/2179123005
* Reduce usage of MakeRenderTargetDirectGravatar robertphillips2016-07-26
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2187573002 Review-Url: https://codereview.chromium.org/2187573002
* Remove SkSurfaceProps gamma-correctness flag entirely.Gravatar brianosman2016-07-26
| | | | | | | | | | | | | This is no longer required - gamma-correctness is now just based on the presence or absence of a color space. Public API change is just removal of (unused) flag. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2188463002 TBR=bsalomon@google.com Review-Url: https://codereview.chromium.org/2188463002
* fix fuzz bugsGravatar caryclark2016-07-26
| | | | | | | | | | | | | | | Add ability for intersection template to detect that the test contains bounded numbers so that extra asserts can trigger. Add some exit points for out of range numbers in those templates. TBR=reed@google.com BUG=631383,631374,631360 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2185703002 Review-Url: https://codereview.chromium.org/2185703002
* Always supply a color space (sRGB for now) with F16Gravatar brianosman2016-07-26
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2177193004 Review-Url: https://codereview.chromium.org/2177193004
* Add test for typeface style round trip.Gravatar bungeman2016-07-25
| | | | | | | | This also fixes the CG and GDI ports so they pass the test. GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2171163002 Review-Url: https://codereview.chromium.org/2171163002
* SkPDF: re-work SkPDFUtils::FloatToDecimalGravatar halcanary2016-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * do a lot less floating-point math by converting to an integer as early as possible [faster]. * round rather than truncate. * use 8 significant digits rather than 9 when possible. * remove trailing zeros in fractions. before: 0.12 ! PDFScalar nonrendering after: 0.07 ! PDFScalar nonrendering Accuracy guaranteed by existing unit test. Example diffs: -/Shading <</Function <</C0 [.321568638 .333333343 .321568638] +/Shading <</Function <</C0 [.32156864 .33333334 .32156864] -/C1 [.258823543 .270588248 .258823543] +/C1 [.25882354 .27058825 .25882354] -1 0 0 -1 20 120.394500 Tm +1 0 0 -1 20 120.394501 Tm -1 0 0 -1 20 184.789001 Tm +1 0 0 -1 20 184.789 Tm -291.503997 0 l +291.504 0 l BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146103004 Review-Url: https://codereview.chromium.org/2146103004
* fix fuzzGravatar caryclark2016-07-25
| | | | | | | | | | | | Extreme inputs trigger asserts intended for in range data. Return an error without asserting unless the test signals otherwise. TBR=reed@google.com BUG=630736 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2178923002 Review-Url: https://codereview.chromium.org/2178923002
* lockPixelsAreWritable is deprecatedGravatar reed2016-07-24
| | | | | | | | | BUG=skia:4328 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2177063002 TBR= Review-Url: https://codereview.chromium.org/2177063002
* Fix misdetection of rectangles in SkPath::IsSimpleClosedRect.Gravatar bsalomon2016-07-24
| | | | | | | BUG=chromium:630369 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2175923002 Review-Url: https://codereview.chromium.org/2175923002
* limit number of searched rootsGravatar caryclark2016-07-22
| | | | | | | | | | | | | | Extreme numbers can generate more than three found cubic roots when the roots are found through a binary search. Fail in this case. TBR=reed@google.com BUG=630649 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2176733002 Review-Url: https://codereview.chromium.org/2176733002
* Allow GrReducedClip to take non-integer query boundsGravatar csmartdalton2016-07-22
| | | | | | | | | | | Fixes places where AA bloat was being conflated with geometric boundaries and updates GrReducedClip to work with non-integer query bounds. This allows for better clip reduction with AA shared edges. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2160093002 Review-Url: https://codereview.chromium.org/2160093002
* Fix SkClipStack bug with inverse-filled difference elementsGravatar csmartdalton2016-07-22
| | | | | | | | | | | | | | Previously, SkClipStack would call "setEmpty" on itself when an inverse-filled difference element made the stack empty. This was a problem because setEmpty would forget the element had an inverse fill, yet leave the op as "difference". This change modifies it to manually update the clip bounds and set the gen-ID to kEmptyGenID, rather than calling setEmpty. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2175493002 Review-Url: https://codereview.chromium.org/2175493002
* Update SkImage_NewFromTexture test, to just test releaseGravatar brianosman2016-07-22
| | | | | | | | | | | | procs of SkImage::MakeFromTexture. Previous code included an old pattern, and may be responsible for intermittent Mac bot failure BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2168933002 Review-Url: https://codereview.chromium.org/2168933002
* conic fuzz fixGravatar caryclark2016-07-22
| | | | | | | | | | | | | | | If no closest section is found in conic intersection (which can happen if the numbers are out of range) abort the intersection. Also suppress assert fired in this case so it only checks intersections with in-range values. TBR=reed@google.com BUG=630378 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2166813006 Review-Url: https://codereview.chromium.org/2166813006
* Add SkColorSpace to GrDrawContextGravatar brianosman2016-07-21
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2164363002 Review-Url: https://codereview.chromium.org/2164363002
* let line/cubic intersect at four spotsGravatar caryclark2016-07-21
| | | | | | | | | With this, let's update the fuzzer. R=kjlubick@google.com GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2169983002 Review-Url: https://codereview.chromium.org/2169983002
* Remove unnecessary getColorSpace() API from SkCodecGravatar msarett2016-07-21
| | | | | | | | | | Not needed since now we can get it from the SkImageInfo. TBR=reed@google.com BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2170793004 Review-Url: https://codereview.chromium.org/2170793004
* allow curves on side of lines to be very smallGravatar caryclark2016-07-21
| | | | | | | | | | | | | | Increase the precision of the 'all on one side' pathops angle test to reduce the number of unorderable segments found by the cubics_d3 test. This allows pathsops_unittest release build with -v -V -x to run without error. TBR=reed@google.com GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2168163002 Review-Url: https://codereview.chromium.org/2168163002
* Creating framework for drawShadowedPictureGravatar vjiaoblack2016-07-21
| | | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146073003 Committed: https://skia.googlesource.com/skia/+/0ae097d116f4332be02a135ffc99c162473dee6a Review-Url: https://codereview.chromium.org/2146073003
* limit the number of points in SkDashPathEffect::asPointsGravatar lsalzman2016-07-21
| | | | | | | | | | | | | | | | | | | If the length of a line path is sufficiently long relative to the dash interval, it is possible to cause SkDashPathEffect::asPoints to produce so many points that it overflows the amount that can fit in an int type, or otherwise produce non-finite values, i.e. path from (0,0) to (0,9e15) with a dash interval of 1. This fixes that by capping the amount of points to a sane limit - in this case, 1mil, since that limit is also used in utils/SkDashPath.cpp and has precedent. Downstream Firefox bug report: https://bugzilla.mozilla.org/show_bug.cgi?id=1287515 BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2165013002 Review-Url: https://codereview.chromium.org/2165013002
* Remove SkGrPixelRefGravatar robertphillips2016-07-21
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2167173002 Review-Url: https://codereview.chromium.org/2167173002
* Revert of Creating framework for drawShadowedPicture (patchset #14 id:260001 ↵Gravatar vjiaoblack2016-07-21
| | | | | | | | | | | | | | | | | | | | | | | of https://codereview.chromium.org/2146073003/ ) Reason for revert: Decided to re-wait for a final LGTM. Already found a bug in variable naming to fix. Original issue's description: > Creating framework for drawShadowedPicture > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146073003 > > Committed: https://skia.googlesource.com/skia/+/0ae097d116f4332be02a135ffc99c162473dee6a TBR=reed@google.com,robertphillips@google.com,bsalomon@google.com,jvanverth@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review-Url: https://codereview.chromium.org/2167223002
* Creating framework for drawShadowedPictureGravatar vjiaoblack2016-07-21
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146073003 Review-Url: https://codereview.chromium.org/2146073003
* fix builder fuzzGravatar caryclark2016-07-21
| | | | | | | | | Fix ASAN_heap-use-after-free crash R=kjlubick GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2168963002 Review-Url: https://codereview.chromium.org/2168963002
* Deprecate SkDevice::accessBitmap methodGravatar robertphillips2016-07-21
| | | | | | | | | | Relies on https://codereview.chromium.org/2162423003/ (Add SK_SUPPORT_LEGACY_ACCESSBITMAP Skia guard) landing in Chromium first. Calved off: https://codereview.chromium.org/2163323002/ (Add desired width & height to drawContext (as opposed to using the width & height of the RT)) GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2168483003 Review-Url: https://codereview.chromium.org/2168483003
* Adding color space to SkSpecialImageGravatar brianosman2016-07-21
| | | | | | | | | | Mostly means that GPU backed special images need to be supplied (and store) a color space object. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2163343002 Review-Url: https://codereview.chromium.org/2163343002
* Refactor parsing and storage of SkGammasGravatar msarett2016-07-21
| | | | | | | | | | | | | | | | | Benefits: (1) Parses and stores gamma tags in a single allocation. (2) Recognizes equal gamma tags to skip parsing work and save memory. Non-Benefits: (1) Not less complicated. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2117773002 Committed: https://skia.googlesource.com/skia/+/2ea944c2b710caf29d4795ac953bad14224796f7 Committed: https://skia.googlesource.com/skia/+/959ccc1f3f49e1ddeb51c32c30ac4a2d94653856 Review-Url: https://codereview.chromium.org/2117773002
* fix fuzzer bugGravatar caryclark2016-07-21
| | | | | | | | | | | | | | | | | Fix another fuzzer bug. Some PathOps asserts only make sense if the incoming data is well-behaved. Well-behaved tests set debugging state to trigger these additional asserts. Formalize this by creating macros similar to SkASSERT that check to see if the assert should be skipped. TBR=reed@google.com BUG=629962 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2169863002 Review-Url: https://codereview.chromium.org/2169863002
* Correct sRGB <-> linear everywhere.Gravatar mtklein2016-07-20
| | | | | | | | | | | | | | | | | | | | | | This trims the SkPM4fPriv methods down to just foolproof methods. (Anything trying to build these itself is probably wrong.) Things like Sk4f srgb_to_linear(Sk4f) can't really exist anymore, at least not efficiently, so this refactor is somewhat more invasive than you might think. Generally this means things using to_4f() are also making a misstep... that's gone too. It also does not make sense to try to play games with linear floats with 255 bias any more. That hack can't work with real sRGB coding. Rather than update them, I've removed a couple of L32 xfermode fast paths. I'd even rather drop it entirely... BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2163683002 CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Review-Url: https://codereview.chromium.org/2163683002
* Revert of Refactor parsing and storage of SkGammas (patchset #8 id:280001 of ↵Gravatar msarett2016-07-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/2117773002/ ) Reason for revert: Tests failing Original issue's description: > Refactor parsing and storage of SkGammas > > Benefits: > (1) Parses and stores gamma tags in a single allocation. > (2) Recognizes equal gamma tags to skip parsing work and > save memory. > > Non-Benefits: > (1) Not less complicated. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2117773002 > > Committed: https://skia.googlesource.com/skia/+/2ea944c2b710caf29d4795ac953bad14224796f7 > Committed: https://skia.googlesource.com/skia/+/959ccc1f3f49e1ddeb51c32c30ac4a2d94653856 TBR=reed@google.com,brianosman@google.com,mtklein@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2171623002
* Refactor parsing and storage of SkGammasGravatar msarett2016-07-20
| | | | | | | | | | | | | | | | Benefits: (1) Parses and stores gamma tags in a single allocation. (2) Recognizes equal gamma tags to skip parsing work and save memory. Non-Benefits: (1) Not less complicated. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2117773002 Committed: https://skia.googlesource.com/skia/+/2ea944c2b710caf29d4795ac953bad14224796f7 Review-Url: https://codereview.chromium.org/2117773002
* Revert of Refactor parsing and storage of SkGammas (patchset #7 id:220001 of ↵Gravatar msarett2016-07-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/2117773002/ ) Reason for revert: Broken bots. Original issue's description: > Refactor parsing and storage of SkGammas > > Benefits: > (1) Parses and stores gamma tags in a single allocation. > (2) Recognizes equal gamma tags to skip parsing work and > save memory. > > Non-Benefits: > (1) Not less complicated. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2117773002 > > Committed: https://skia.googlesource.com/skia/+/2ea944c2b710caf29d4795ac953bad14224796f7 TBR=reed@google.com,brianosman@google.com,mtklein@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2159253005
* Tune linear->sRGB constants to round-trip all bytes.Gravatar mtklein2016-07-20
| | | | | | | | | | | | I basically just ran a big 5-deep for-loop over the five constants here. This is the first set of coefficients I found that round trips all bytes. I suspect there are many such sets. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2162063003 CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Review-Url: https://codereview.chromium.org/2162063003
* Refactor parsing and storage of SkGammasGravatar msarett2016-07-20
| | | | | | | | | | | | | | | Benefits: (1) Parses and stores gamma tags in a single allocation. (2) Recognizes equal gamma tags to skip parsing work and save memory. Non-Benefits: (1) Not less complicated. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2117773002 Review-Url: https://codereview.chromium.org/2117773002
* re-disable save/restore peephole optimizationGravatar reed2016-07-20
| | | | | | | BUG=skia:5548, 629408 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2163283002 Review-Url: https://codereview.chromium.org/2163283002
* SkLS now accepting nullptr for diffuse shader and normal source, now ↵Gravatar dvonbeck2016-07-20
| | | | | | | | | | | accurately handling alpha This CL's base is the CL for taking in a diffuse shader into SkLS on the API side: https://codereview.chromium.org/2064153002 BUG=skia:5502,skia:5517 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2132113002 Review-Url: https://codereview.chromium.org/2132113002
* re-chop if we fail on a big-bad-cubicGravatar reed2016-07-20
| | | | | | | BUG=629455 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2159223005 Review-Url: https://codereview.chromium.org/2159223005
* Remove SkDevice::accessRenderTarget virtualGravatar robertphillips2016-07-20
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2167723002 Review-Url: https://codereview.chromium.org/2167723002
* Consolidate special case shape transformation logic in GrShapeTest.Gravatar bsalomon2016-07-20
| | | | | | | | | | Enable all tests on all geometry types. Add conversion of fill+miter-stroke->fill for rect geometries in GrShape. GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2157013003 Review-Url: https://codereview.chromium.org/2157013003
* Remove unused MakeFromTextureCopy APIGravatar brianosman2016-07-19
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2165803002 Review-Url: https://codereview.chromium.org/2165803002
* Update rounding/clamping comments on sk_linear_to_srgb().Gravatar mtklein2016-07-19
| | | | | | | | | Rounding is enough. No need for an explicit clamp if the inputs are in range. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2161223002 Review-Url: https://codereview.chromium.org/2161223002
* fix fuzzerGravatar caryclark2016-07-19
| | | | | | | | | | | | Previous spans always have a valid next pointer. The final span does not. Change the test for a valid link to take into consideration whether the links are chased forwards or backwards. TBR=reed@google.com BUG=629454 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2166543002 Review-Url: https://codereview.chromium.org/2166543002
* Improve naive SkColorXform to half floatsGravatar msarett2016-07-19
| | | | | | | | | | | | | | | | | | | | | | | | This should give us a good baseline to explore using SkRasterPipeline. A particular colorxform to half float drops from 425us to 282us on my desktop. Color Xform to Half Float (HP z620) Original 425us Trans16 (not 32) 355us Vector Trans16 378us Trans16 + Keep Halfs in Vector 335us Vector Trans16 + Keep Halfs in Vector 282us Final 282us Color Xform to Half Float (Nexus 5X) Original 556us Final 472us BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2159993003 CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Review-Url: https://codereview.chromium.org/2159993003
* Create DCs instead of textures in SRGBMipMaps testGravatar bsalomon2016-07-19
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2162973002 Review-Url: https://codereview.chromium.org/2162973002
* Simplify random_draw_context used by GLProgramsTestGravatar bsalomon2016-07-19
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2165683002 Review-Url: https://codereview.chromium.org/2165683002