aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
Commit message (Collapse)AuthorAge
* SkScaledBitmapSampler: fix memory overwrittenGravatar zoran.jovanovic2015-04-16
| | | | | | | | | | | | | | | | | | | Memory will be overwritten while downsampling some interlaced gif images, most commonly with odd sizes, when index of destination row stores in the current line computed from GifInterlaceIter meets: X is an integer in [0..height-1] and (X < height) && ((X - sampleSize/2) % sampleSize == 0) && ((X - sampleSize/2)/sampleSize >= height/sampleSize) Signed-off-by: Lu Tong <lu.x.tong@sonymobile.com> BUG=skia: Review URL: https://codereview.chromium.org/1085253002
* Add ReverseIter to GrTRecorderGravatar cdalton2015-04-16
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1035083004
* Revert of remove unused (by clients) SkPathUtils (patchset #1 id:1 of ↵Gravatar jcgregorio2015-04-16
| | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1088383003/) Reason for revert: This change is causing the DEPS roll to fail: http://build.chromium.org/p/tryserver.chromium.linux/builders/android_chromium_gn_compile_rel/builds/78771/steps/gn/logs/stdio Original issue's description: > remove unused (by clients) SkPathUtils > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/aab35d91b8b80acd1902594bbf542083fdfa4bb7 TBR=scroggo@google.com,reed@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1060703003
* Don't serialize anything for SkEmptyShader.Gravatar mtklein2015-04-16
| | | | | | BUG=skia:3735 Review URL: https://codereview.chromium.org/1097433002
* remove unused (by clients) SkPathUtilsGravatar reed2015-04-16
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1088383003
* Zero jpeg_decompress_struct before calling jpeg_calc_output_dimensions().Gravatar mtklein2015-04-16
| | | | | | | | | | https://uberchromegw.corp.google.com/i/client.skia/builders/Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-Valgrind/builds/38/steps/dm/logs/stdio (Must have been https://codereview.chromium.org/1076923002 ?) BUG=skia: Review URL: https://codereview.chromium.org/1094603002
* remove older version of cubic->coeffGravatar reed2015-04-15
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/1084623004
* Speeup hairline curves (quads and cubics) (patchset #7 id:120001 of ↵Gravatar reed2015-04-15
| | | | | | | | | | | | | https://codereview.chromium.org/1078413003/)" ah ha! Check for the define *after* we pull in SkUserConfig.h (indirectly) This reverts commit 639a82855b94b93c4fa45560e67df8ec4a8bbb3a. BUG=skia: TBR= Review URL: https://codereview.chromium.org/1084283003
* Revert of make blitAntiH2 virtual, to prep for larger change (patchset #1 ↵Gravatar reed2015-04-15
| | | | | | | | | | | | | | | | | | | | | | | | | id:1 of https://codereview.chromium.org/1048323005/) Reason for revert: end of test Original issue's description: > make blitAntiH2 virtual, to prep for larger change > > testing... > > BUG=skia: > TBR= > > Committed: https://skia.googlesource.com/skia/+/33afdaa5213cf118b3ca290bb343253c8593756d TBR= NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1086293002
* make blitAntiH2 virtual, to prep for larger changeGravatar reed2015-04-15
| | | | | | | | | testing... BUG=skia: TBR= Review URL: https://codereview.chromium.org/1048323005
* Revert of Speeup hairline curves (quads and cubics) (patchset #7 id:120001 ↵Gravatar reed2015-04-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of https://codereview.chromium.org/1078413003/) Reason for revert: Crazy failings in chrome tests http://build.chromium.org/p/client.skia/builders/Linux%20Tests/builds/1862 Original issue's description: > Speeup hairline curves (quads and cubics) > > /skia/trunk> cat ../old.txt > maxrss loops min median mean max stddev samples config bench > 9M 1 4.28ms 4.32ms 4.36ms 4.67ms 3% ▄▁▁▃▂▂▁▁▂█ 8888 path_hairline_small_AA_cubic > 9M 1 743µs 767µs 770µs 825µs 4% ▃▃▇▃▁▁▅▁█▁ 8888 path_hairline_small_AA_conic > 9M 1 533µs 606µs 598µs 680µs 9% ▁▂▂█▆▇▇▄▂▂ 8888 path_hairline_small_AA_quad > 9M 1 451µs 452µs 456µs 495µs 3% ▁▁▁▁█▁▁▁▁▁ 8888 path_hairline_small_AA_line > > /skia/trunk> cat ../new.txt > maxrss loops min median mean max stddev samples config bench > 9M 1 827µs 827µs 831µs 869µs 2% ▁▁▁▁▁▁▁█▁▁ 8888 path_hairline_small_AA_cubic > 9M 1 515µs 517µs 517µs 518µs 0% ▇█▆▅▃▃▁▁▁▅ 8888 path_hairline_small_AA_conic > 9M 1 310µs 311µs 315µs 332µs 2% ▂▁█▆▁▁▁▁▁▁ 8888 path_hairline_small_AA_quad > 9M 1 254µs 254µs 258µs 276µs 3% ▁▁▁▁▁▁▁█▇▂ 8888 path_hairline_small_AA_line > > Edited revert of https://codereview.chromium.org/1085013003 > > TBR= > > Expectations: > - no effect on chrome, as it is guarded > - lots of tiny rebaselines for skia TBR= NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1092483003
* Don't draw if SkShader::asNewFragmentProcessor fails.Gravatar bsalomon2015-04-15
| | | | | | BUG=chromium:473156 Review URL: https://codereview.chromium.org/1089063002
* Fix LCD text and add path fix for Mali.Gravatar jvanverth2015-04-15
| | | | | | | | | dFdy(st.y) produces negative values, so we need to take abs() to get the right inverse scale. BUG=skia:3528 Review URL: https://codereview.chromium.org/1086183002
* Speeup hairline curves (quads and cubics)Gravatar reed2015-04-15
| | | | | | | | | | | | | | | | | | | | | | /skia/trunk> cat ../old.txt maxrss loops min median mean max stddev samples config bench 9M 1 4.28ms 4.32ms 4.36ms 4.67ms 3% ▄▁▁▃▂▂▁▁▂█ 8888 path_hairline_small_AA_cubic 9M 1 743µs 767µs 770µs 825µs 4% ▃▃▇▃▁▁▅▁█▁ 8888 path_hairline_small_AA_conic 9M 1 533µs 606µs 598µs 680µs 9% ▁▂▂█▆▇▇▄▂▂ 8888 path_hairline_small_AA_quad 9M 1 451µs 452µs 456µs 495µs 3% ▁▁▁▁█▁▁▁▁▁ 8888 path_hairline_small_AA_line /skia/trunk> cat ../new.txt maxrss loops min median mean max stddev samples config bench 9M 1 827µs 827µs 831µs 869µs 2% ▁▁▁▁▁▁▁█▁▁ 8888 path_hairline_small_AA_cubic 9M 1 515µs 517µs 517µs 518µs 0% ▇█▆▅▃▃▁▁▁▅ 8888 path_hairline_small_AA_conic 9M 1 310µs 311µs 315µs 332µs 2% ▂▁█▆▁▁▁▁▁▁ 8888 path_hairline_small_AA_quad 9M 1 254µs 254µs 258µs 276µs 3% ▁▁▁▁▁▁▁█▇▂ 8888 path_hairline_small_AA_line Edited revert of https://codereview.chromium.org/1085013003 TBR= Review URL: https://codereview.chromium.org/1078413003
* SkPDF/Device/ImageFilter: Fix ImageFilter fallback codeGravatar halcanary2015-04-15
| | | | | | | | | | Broken in https://chromium.googlesource.com/skia/+/76033be I have confirmed that this fixes 470083. BUG=470083 Review URL: https://codereview.chromium.org/1080923004
* Real fix for the Mali bug.Gravatar jvanverth2015-04-15
| | | | | | | | | The dFdy(st.y) computation seems to be better than the dFdx(st.x) computation on the Mali, so using that. The end result should be about the same. BUG=skia:3528 Review URL: https://codereview.chromium.org/1082913006
* add blitter api for aa-hairlinesGravatar reed2015-04-15
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/1088143002
* Change tessellator sweep direction to depend on path aspect ratio.Gravatar senorblanco2015-04-15
| | | | | | | | | | | | | The tessellating path renderer uses several sweep-line algorithms, whose sweep direction can be either in X or Y. It is currently set to in-X at compile time, but a better approach is to make it runtime-configurable, and use the path aspect ratio as a heuristic to determine the optimal sweep direction. BUG=skia:3725 Review URL: https://codereview.chromium.org/1089073002
* SkJpegCodecGravatar msarett2015-04-15
| | | | | | | | | | | | Enables basic decoding for jpegs Includes rewinding 565, YUV, and Jpeg encoding are not yet implemented BUG=skia:3257 Review URL: https://codereview.chromium.org/1076923002
* Revert of add new blit2 methods in support of antialiased hairlines guard ↵Gravatar jcgregorio2015-04-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | flag SK_SUPPORT_LEGACY_BLITANTIH2V2 (patchset #2 id:20001 of https://codereview.chromium.org/1060153003/) Reason for revert: DEPS roll is failing, one such example: http://build.chromium.org/p/tryserver.chromium.win/builders/win8_chromium_rel/builds/73847/steps/ash_unittests%20%28with%20patch%29/logs/stdio More here: https://codereview.chromium.org/1091483003 This CL was the only CL in the roll when things started to fail. Original issue's description: > add new blit2 methods in support of antialiased hairlines > > before: > 9M 1 528µs 530µs 539µs 607µs 5% ▁▁▁▁▁▁▁▁█▂ 8888 path_hairline_small_AA_quad > > after: > 9M 1 355µs 356µs 358µs 375µs 2% ▂▁▁▁▁▁▁▁▁█ 8888 path_hairline_small_AA_quad > > BUG=skia: > > does require new baselines (bug chrome is guarded) > > Committed: https://skia.googlesource.com/skia/+/dd83031b98db4c6d3d0de2353bf115152a7d1464 TBR=caryclark@google.com,reed@chromium.org,reed@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1085013003
* Return cropBitmapGravatar zoran.jovanovic2015-04-15
| | | | | | | | | | | cropBitmap returns 'true' on success and 'false' on failure. Propagate its return value so that cascading failures can be avoided. Signed-off-by: Mykola Kondratenko <mykola.kondratenko@sonymobile.com> BUG=skia: Review URL: https://codereview.chromium.org/1088093003
* Convert BitmapTextBatch from STArray to AutoSTMallocGravatar joshualitt2015-04-15
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1088533002
* add new blit2 methods in support of antialiased hairlinesGravatar reed2015-04-14
| | | | | | | | | | | | | | before: 9M 1 528µs 530µs 539µs 607µs 5% ▁▁▁▁▁▁▁▁█▂ 8888 path_hairline_small_AA_quad after: 9M 1 355µs 356µs 358µs 375µs 2% ▂▁▁▁▁▁▁▁▁█ 8888 path_hairline_small_AA_quad BUG=skia: does require new baselines (bug chrome is guarded) Review URL: https://codereview.chromium.org/1060153003
* Convert BitmapTextBlob from using STArray to AutoSTMallocGravatar joshualitt2015-04-14
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1083703002
* Sk4h and Sk8h for SSEGravatar mtklein2015-04-14
| | | | | | | | | | These will underly the SkPMFloat-like class for uint16_t components. Sk4h will back a single-pixel version, and Sk8h any larger number than that. BUG=skia: Review URL: https://codereview.chromium.org/1088883005
* Start canonicalizing color for all A8 textblobsGravatar joshualitt2015-04-14
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1076593002
* Rename SkNi to SkNb.Gravatar mtklein2015-04-14
| | | | | | | | | | | | | | | | As used today, SkNi is used in bool-y contexts. This keeps that, but under a new name, SkNb. This makes room for a new SkNi that's focused on integer-y things like loads, stores, arithmetic, etc. The main reason to split these is that we want different specializations for each use case: for bools, it's important for us to specialize 32- and 64-bit to support efficient float- and double- comparisons, but for integer work we're more likely to be looking at 8- and 16- bit lanes. Keeping these use cases siloed helps me manage the compexity of the backend NEON and SSE code. BUG=skia: Review URL: https://codereview.chromium.org/1083123002
* change hairline procs to take array of pointsGravatar reed2015-04-14
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1085883002
* Enable tessellating GPU path renderer.Gravatar senorblanco2015-04-13
| | | | | | | | | | | | | This also contains a fix to remove recursion from the sorted_merge() step. This was essentially tail-recursion, and was causing stack exhaustion on some platforms. Making it iterative fixes the issue. Note: this CL will affect a large number of GPU GM results. R=bsalomon@google.com BUG= Review URL: https://codereview.chromium.org/1080113004
* Set resScale on stroker when stroking path on gpu.Gravatar egdaniel2015-04-13
| | | | | | BUG=skia:3686 Review URL: https://codereview.chromium.org/1048333003
* Fix minor undercounting in SkRecord::bytesUsed().Gravatar mtklein2015-04-13
| | | | | | | | | | | | | | | | | | When an SkRecord has more than kInlineRecords ops in it (today, 5 or more), the current logic undercounts the bytes used by the SkRecord by sizeof(Record) * kInlineRecords, i.e. 32 bytes. This isn't a huge deal... by the time you've recorded 5 ops, we're typically up around 1KB anyway, and it's only ever off by that constant 32 bytes, so somewhere between 3% to 0% error as the picture grows. But now that I've noticed, we might as well fix it. Basically, this is a reminder that the inline space used to store those first kInlineRecords ops goes to waste once we pass that threshold. In contrast, fInlineAlloc, the space we preallocate for the SkVarAlloc, never goes to waste. It always holds the first few ops' data even when we grow past it. BUG=skia: Review URL: https://codereview.chromium.org/1081433002
* Make GrContext::freeGpuResources() purge the resource cacheGravatar bsalomon2015-04-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1082783002
* fix valgrind uninitialized issueGravatar caryclark2015-04-13
| | | | | | | R=mtklein@google.com BUG=skia:3654 Review URL: https://codereview.chromium.org/1082753002
* Revert "Enable tessellating GPU path renderer."Gravatar Stephen White2015-04-13
| | | | | | | | | | | This reverts commit c185019d009dbfcc8d07f267b0fd72ba1ce673d9. Reason for revert: Causing errors in DM runs. BUG=skia: TBR=bsalomon@google.com Review URL: https://codereview.chromium.org/1087563002
* Enable tessellating GPU path renderer.Gravatar senorblanco2015-04-13
| | | | | | | | | Note: this will affect a large number of GPU GM results. R=bsalomon@google.com BUG= Review URL: https://codereview.chromium.org/1084573003
* Start caching masks / stroke fills for textblobsGravatar joshualitt2015-04-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1065293003
* Avoid regenerating cached textblobs on integer scrollsGravatar joshualitt2015-04-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1062863002
* use fast/inline SkRect::set(p0, p1) for 2 pointsGravatar reed2015-04-12
| | | | | | | | | | 10% speedup for clipped haircubics BUG=skia: TBR= NOTRY=True Review URL: https://codereview.chromium.org/1079343002
* setDrawFilter needs to trigger any deferred savesGravatar reed2015-04-11
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/1077353002
* change hairline procs to take SkPoint by value, more efficient on SSE and NEONGravatar reed2015-04-10
| | | | | | | | | precursor for https://codereview.chromium.org/1074313002/ BUG=skia: TBR= Review URL: https://codereview.chromium.org/1084433002
* Ammend font table data experiment on Mac.Gravatar bungeman2015-04-10
| | | | | | | | | | | Calling CGFontCopyTableForTag did not affect the runtime results, so try to actually access the data to see if that makes a difference. TBR=reed1 This is a test change, allow data to be collected. Review URL: https://codereview.chromium.org/1076183004
* Implementing filling for SkBmpCodecGravatar msarett2015-04-10
| | | | | | | | | | | | | | | The bmp codec currently returns kIncompleteInput when the stream is truncated, which we treat as a partial success. However, we neglect the fill the remaining pixels in the image, leaving these uninitialized. This CL addresses this problem by initializing the remaining pixels in the image to default values. BUG=skia:3257 Review URL: https://codereview.chromium.org/1075243003
* Add serialization of SkBitmapSource's new filterQuality member variableGravatar robertphillips2015-04-10
| | | | | | Missed this in https://codereview.chromium.org/1072603002/ (Add GM to repro crbug.com/472795) Review URL: https://codereview.chromium.org/1078113002
* trivial fix for TextBlobCacheGravatar joshualitt2015-04-10
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1076193003
* The TextBlobCache needs the ability to trigger a flush because otherwise its ↵Gravatar joshualitt2015-04-10
| | | | | | | | | entire budget can be used up, but it will not be able to free up any space due to blobs being stuck in the GrInOrderDrawBuffer. This was causing a segfault. After this CL the cache will try to purge, and then flush if it cannot purge enough. It will not purge the most recent addition to the cache. TBR=bsalomon@google.com BUG=skia: Review URL: https://codereview.chromium.org/1071333002
* Replace NEON assembly memset16 and memset32 with intrinsic versions.Gravatar mtklein2015-04-10
| | | | | | | | | | | According to bench/MemsetBench.cpp, I've got them somewhere between 10% slower and a percent or two faster than the old assembly. BUG=skia: CQ_EXTRA_TRYBOTS=client.skia.android:Test-Android-GCC-Nexus5-CPU-NEON-Arm7-Debug-Trybot Review URL: https://codereview.chromium.org/1075003002
* Rewrite memset benches, then use results to add a small-N optimization.Gravatar mtklein2015-04-09
| | | | | | | | | | | | | | | The benches for N <= 10 get around 2x faster on my N7 and N9. I believe this is because of the reduced function-call-then-function-pointer-call overhead on the N7, and additionally because it seems autovectorization beats our NEON code for small N on the N9. My desktop is unchanged, though that's probably because N=10 lies well within a region where memset's performance is essentially constant: N=100 takes only about 2x as long as N=1 and N=10, which perform nearly identically. BUG=skia: Review URL: https://codereview.chromium.org/1073863002
* SkPDF: ResourceDict replaced by factory functionGravatar halcanary2015-04-09
| | | | | | | | | Motivation: Having a class here was unnecessary, since the only thing that set this class apart was how it is created, not how it behaves. BUG=skia:3585 Review URL: https://codereview.chromium.org/1068343003
* ***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
* Avoid sending empty bitmaps through proxy canvasGravatar tomhudson2015-04-09
| | | | | | | | | | Some back ends may crash when asked to draw an empty bitmap, so we filter it out here. BUG=skia:3692 R=djsollen@google.com,reed@google.com Review URL: https://codereview.chromium.org/1072033002