Now, that we are subsetting, fX0 is not necessarily less than
fSrcWidth (since fSrcWidth is really the subset width).
Ex: We may want a 10 pixel subset starting twenty pixels from the
left edge. In that case, fX0=20 and fSrcWidth=10.
Let's rename the width as fSubsetWidth to avoid confusion
and remove the check.
BUG=skia:
Review URL: https://codereview.chromium.org/1407603003
Iterating through the 903K skps that represent the
imagable 1M top web pages triggers a number of
bugs, some of which are addressed here.
Some web pages trigger intersecting cubic
representations of arc with their conic
counterparts. This exposed a flaw in coincident
detection that caused an infinite loop. The loop
alternatively extended the coincident section and,
determining the that the bounds of the curve pairs
did not overlap, deleted the extension.
Track the number of times the coincident detection
is called, and if it exceeds an empirically found
limit, assume that the curves are coincident and
force it to be so.
The loop count limit can be determined by enabling
DEBUG_T_SECT_LOOP_COUNT and running all tests. The
largest count is reported on completion.
Another class of bugs was caused by concident
detection duplicating nearly identical points that
had been merged earlier. To track these bugs, the
'handle coincidence' code was duplicated as a
const debug variety that reported if one of a
dozen or so irregularities are present; then it is
easier to see when a block of code that fixes one
irregularity regresses another.
Creating the debug const code version exposed some
non-debug code that could be const, and some that
was experimental and could be removed. Set
DEBUG_COINCIDENCE to track coincidence health and
handling.
For running on Chrome, DEBUG_VERIFY checks the
result of pathops against the same operation
using SkRegion to verify that the results are
nearly the same.
When visualizing the pathops work using
tools/pathops_visualizer.htm, set
DEBUG_DUMP_ALIGNMENT to see the curves after
they've been aligned for coincidence.
Other bugs fixed include detecting when a
section of a pair of curves have devolved into
lines and are coincident.
TBR=reed@google.com
Review URL: https://codereview.chromium.org/1394503003
This is a follow up to:
https://codereview.chromium.org/1401283003/
Supply separate flags for onBuildTileIndex
Since png and jpeg's implementations of onBuildTileIndex rely on
modifications to their underlying libraries, rather than whether we are
running on Android, use separate flags that can be disabled
independently.
This will allow us to easily turn off the feature. It also is a step
towards building and running on other platforms for testing (e.g.
valgrind/ASAN to find memory leaks etc).
BUG=skia:
Committed: https://skia.googlesource.com/skia/+/fc06e9c0e621744654e231ae6fa4460d88c0e27e
Review URL: https://codereview.chromium.org/1402783008
Passing &SkGoodHash to SkTHashMap and SkTHashSet doesn't guarantee that it's actually instantiated. Using a functor does.
BUG=skia:
Review URL: https://codereview.chromium.org/1405053002
This is required to build Chromium's ui_base target with -fmodules, but it
seems like a good change regardless. Including a header in a namespace is
weird.
BUG=chromium:543704
Review URL: https://codereview.chromium.org/1398843007
Fix blaze compilation errors. The default compilation options for blaze require that the initialization list must list fields in initialization order. Also deal with differing versions of libjpeg.
The BUILD changes were started by melanielc in google3 cl/102860957.
BUG=skia:
Review URL: https://codereview.chromium.org/1401883005
- Remove --images '' to renable image benchmarking
- Add a flag to disable testing JPEG's buildTileIndex, since it also leaks memory
- Do not run images on GPU
- Do not run large interlaced images on 32 bit bots
- When buildTileIndex is not being used in the subset benches, do not use it for BRD
BUG=skia:3418
BUG=skia:4469
BUG=skia:4471
BUG=skia:4360
Review URL: https://codereview.chromium.org/1396113002
SkPictureShader had an invalid use of SkMax32 on two SkScalars which
ended up converting the result to an integer which caused us to lose
necessary floating point data.
BUG=473166
Review URL: https://codereview.chromium.org/1401743004
Reason for revert:
Missing an important line.
Original issue's description:
> Supply separate flags for onBuildTileIndex
>
> This is a follow up to:
> https://codereview.chromium.org/1401283003/
>
> Supply separate flags for onBuildTileIndex
>
> Since png and jpeg's implementations of onBuildTileIndex rely on
> modifications to their underlying libraries, rather than whether we are
> running on Android, use separate flags that can be disabled
> independently.
>
> This will allow us to easily turn off the feature. It also is a step
> towards building and running on other platforms for testing (e.g.
> valgrind/ASAN to find memory leaks etc).
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/fc06e9c0e621744654e231ae6fa4460d88c0e27eTBR=scroggo@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:
Review URL: https://codereview.chromium.org/1394433005
This is a follow up to:
https://codereview.chromium.org/1401283003/
Supply separate flags for onBuildTileIndex
Since png and jpeg's implementations of onBuildTileIndex rely on
modifications to their underlying libraries, rather than whether we are
running on Android, use separate flags that can be disabled
independently.
This will allow us to easily turn off the feature. It also is a step
towards building and running on other platforms for testing (e.g.
valgrind/ASAN to find memory leaks etc).
BUG=skia:
Review URL: https://codereview.chromium.org/1402783008
Since png and jpeg's implementations of onBuildTileIndex rely on
modifications to their underlying libraries, rather than whether we are
running on Android, use separate flags that can be disabled
independently.
This will allow us to easily turn off the feature. It also is a step
towards building and running on other platforms for testing (e.g.
valgrind/ASAN to find memory leaks etc).
Review URL: https://codereview.chromium.org/1401283003
This method is different from MatrixFilter, in that MatrixFilter does not require a pre-existing
filter, but LocalM does. Also change the comment to be more general, as there is no promise that
we return a different subclass, and certainly not a specific subclass.
This pattern of obj->newWithModifiers() also more closely matches the pattern in SkImage (newSubset).
BUG=skia:
Review URL: https://codereview.chromium.org/1402133002
At draw time, this filter simply concatenates the given matrix to the
CTM, and recurses on its input. The matrix is thus applied to any
upstream filter parameters and crop rects.
BUG=skia:
Review URL: https://codereview.chromium.org/1392833005
Fix a crash in dm when run with Chromium command buffer driver.
Also removes glCopyTextureCHROMIUM, it does not seem to be used.
This is removed on the grounds that it would need similar change,
if it was used. The variable fCopyTextureCHROMIUM does not seem to
be populated in the Chromium side, either.
BUG=skia:2992
Review URL: https://codereview.chromium.org/1389213004
This CL allows the SkScanlineDecoder to decode partial
scanlines.
This is a first step in efficiently implementing subsetting
in SkScaledCodec.
BUG=skia:4209
Review URL: https://codereview.chromium.org/1390213002
At the end of TightRunBounds, glyphPosX cannot exceed the start of the
next run. But glyphPosY is running ahead of glyphPosX (for
kFull_Positioning) => the glyphPosY assert is incorrect.
Since the two pointers advance in lock-step, there isn't much value in
the glyphPosY assert anyway - we might as well remove it.
BUG=chromium:542643
R=reed@google.com,bungeman@google.com
Review URL: https://codereview.chromium.org/1405463004
Result:
- clients can get a filtered version of an image without having to setup a temp drawing environment
- for some cases, the process is more efficient even than (deprecated) drawSprite, since there is no need to draw/copy the result
Impl:
- made Proxy virtual so we don't need to have an existing device to use it
This, in conjunction with LocalMatrixImageFilter, should allow us to simplify and optimize ApplyImageFilter() in cc/output/gl_renderer.cc
BUG=skia:
Review URL: https://codereview.chromium.org/1390913005
Migrating the flag to embedder defines (Chromium already guarded).
Also augment gradient-focused GMs to generate both dithered/undithered
results.
BUG=skia:4436
R=reed@google.com,robertphillips@google.com
Review URL: https://codereview.chromium.org/1400813006