aboutsummaryrefslogtreecommitdiffhomepage
path: root/samplecode
Commit message (Collapse)AuthorAge
* resources: orgainize directory.Gravatar Hal Canary2017-12-08
| | | | | | | | | Should make it easier to ask just for images. Change-Id: If821743dc924c4bfbc6b2b2d29b14affde7b3afd Reviewed-on: https://skia-review.googlesource.com/82684 Commit-Queue: Hal Canary <halcanary@google.com> Reviewed-by: Leon Scroggins <scroggo@google.com>
* CCPR: Eliminate texel buffersGravatar Chris Dalton2017-12-05
| | | | | | | | | | | | | | | | | | Points cost 8 bytes and indices cost 4. If a point is accessed twice, it's a wash whether we duplicate it or index. This change eliminates texel buffers by duplicating points across instance arrays. This reduces our dependence on extensions as well as getting rid of our indirect memory access pattern in vertex shaders. As a result of this change, memory usage by GPU buffers will only be a fraction larger at worst, and slightly better at best. Bug: skia: Cq-Include-Trybots: skia.primary:Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-SKNX_NO_SIMD Change-Id: I3c7f03772edd4f850d5fdd7b55552647335c1b52 Reviewed-on: https://skia-review.googlesource.com/79185 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Add analytic clip FPs that read from the CCPR atlasGravatar Chris Dalton2017-12-05
| | | | | | | | Bug: skia:7190 Change-Id: Ie31d368f52910e6917efdeb1b024370b06fc11ee Reviewed-on: https://skia-review.googlesource.com/77160 Commit-Queue: Chris Dalton <csmartdalton@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* turn on extended Clang warnings on Windows tooGravatar Chris Dalton2017-12-04
| | | | | | | | | | Plus some small rearrangements of the various warning lists. Change-Id: Ied58f940341d69ddab971a529fd01b1e96b65641 Reviewed-on: https://skia-review.googlesource.com/67720 Commit-Queue: Chris Dalton <csmartdalton@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Fix SVGPong slide crash in ViewerGravatar Florin Malita2017-12-03
| | | | | | | | | | SVGPong relies on onOnceBeforeDraw() to initialize, but when switching slides via Viewer's UI, onAnimate() is fired before the first paint. Change-Id: I7be133072ec635975f7463538cd42edb69696b3f Reviewed-on: https://skia-review.googlesource.com/79424 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Remove more views code, just to simplify thingsGravatar Brian Osman2017-12-01
| | | | | | | | Bug: skia: Change-Id: Ie31a3c764e4f88f2b08f4198bd253841a2d8c264 Reviewed-on: https://skia-review.googlesource.com/79100 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Delete even more unused views codeGravatar Brian Osman2017-11-29
| | | | | | | | Bug: skia: Change-Id: I41480aa89dfcd8cb7e016e477cbabe354f35ce8a Reviewed-on: https://skia-review.googlesource.com/75480 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove a huge pile of views codeGravatar Brian Osman2017-11-22
| | | | | | | | | | | | | All of this is dead when not using the old SkWindow framework. TBR=reed@google.com Bug: skia: Change-Id: I0f6ab18987a98469bfd367d5bc10967300dfd3ca Reviewed-on: https://skia-review.googlesource.com/75384 Reviewed-by: Brian Osman <brianosman@google.com> Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Fix XferDemo by sending push button events directly to parentGravatar Brian Osman2017-11-22
| | | | | | | | Bug: skia: Change-Id: I3141dd34a9a04c7a660000cba9e483191f28ef03 Reviewed-on: https://skia-review.googlesource.com/75362 Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove SampleApp and convert HelloWorld to sk_appGravatar Brian Osman2017-11-21
| | | | | | | | | | | | | There is still a large amount of views code that could be trimmed down, but which is used to implement samples (in viewer). Seemed simpler to remove some of this code in pieces. Bug: skia: Change-Id: Ia3415060d03c8de604a154e3dc38379b754daab6 Reviewed-on: https://skia-review.googlesource.com/72801 Commit-Queue: Brian Osman <brianosman@google.com> Reviewed-by: Jim Van Verth <jvanverth@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Remove clutter from experimentalGravatar Brian Osman2017-11-21
| | | | | | | | | | | | | SkMatrix has the canonical version of setPolyToPoly, we don't need three other copies sitting around. SkBorder appears to be useless. Bug: skia: Change-Id: Ie747ff7af6cf1d03e6276e8d7fe57e9b3e4ad411 Reviewed-on: https://skia-review.googlesource.com/74141 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Revert "Use int when possible to calculate atlas indices in shaders."Gravatar Jim Van Verth2017-11-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 999ec57291dc7cf1d8e3a745627670e6cadc1c12. Reason for revert: Causing issues with NexusPlayer Vulkan. Original change's description: > Use int when possible to calculate atlas indices in shaders. > > On certain iOS devices half has a mantissa of only 10 bits, which is not > enough to perform the floating point trickery to get the lower bits > out of the "texture coordinates". Instead we use int if available, and > float if not available. > > Also re-enables multitexturing for iOS and adds a sample which > stresses the issue. > > Bug: skia:7285 > Change-Id: I365532c7cbbcca7c7753af209bef46e05be49e11 > Reviewed-on: https://skia-review.googlesource.com/71181 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Jim Van Verth <jvanverth@google.com> TBR=jvanverth@google.com,bsalomon@google.com,robertphillips@google.com Change-Id: I82801a73a2a8067588049b213f010ff25f4014f3 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia:7285 Reviewed-on: https://skia-review.googlesource.com/74001 Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Enable tonal color for shadows by default.Gravatar Jim Van Verth2017-11-20
| | | | | | | | | | This change swaps the sense of the tonal color shadow flag, so tonal color will always be on unless explicitly disabled. Change-Id: I56ce4228022cf59b570cd7461327628cf7fe7173 Reviewed-on: https://skia-review.googlesource.com/73900 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Use int when possible to calculate atlas indices in shaders.Gravatar Jim Van Verth2017-11-20
| | | | | | | | | | | | | | | | On certain iOS devices half has a mantissa of only 10 bits, which is not enough to perform the floating point trickery to get the lower bits out of the "texture coordinates". Instead we use int if available, and float if not available. Also re-enables multitexturing for iOS and adds a sample which stresses the issue. Bug: skia:7285 Change-Id: I365532c7cbbcca7c7753af209bef46e05be49e11 Reviewed-on: https://skia-review.googlesource.com/71181 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Alloc glyph image correctly for SkMask::k3D_Format.Gravatar Ben Wagner2017-11-14
| | | | | | | | | | | | | | | | | | | | | | Re-enable the code to test the emboss mask filter, updating it to use the new emboss mask filter factory. Add a test to ensure that embossed text is drawn correctly, as before glyphs did not allocate the proper amount of memory for the k3D_Format which the emboss mask filter produces. Fixes SkEmbossMask::Emboss to write the whole of the mul and add planes to avoid pixel differences and MemorySanitizer errors. Update the GPU to understand the k3D_Format and use just the alpha plane, ignoring the mul and add plane which it currently cannot support. Change-Id: I90edf34a918c06b0c6b24bfc43ce7031419eca41 Reviewed-on: https://skia-review.googlesource.com/70260 Reviewed-on: https://skia-review.googlesource.com/70962 Reviewed-on: https://skia-review.googlesource.com/71282 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Revert "Alloc glyph image correctly for SkMask::k3D_Format."Gravatar Brian Osman2017-11-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 1662257bdaaaf26b016bf2a3e329c34f7f5ed581. Reason for revert: Android still using this API Original change's description: > Alloc glyph image correctly for SkMask::k3D_Format. > > Remove the no longer used outside Skia SK_SUPPORT_LEGACY_EMBOSSMASKFILTER > define, and either delete the code it guards or update it to use the new > emboss mask filter factory. > > Re-enable the code to test the emboss mask filter. > > Add a test to ensure that embossed text is drawn correctly, as before > glyphs did not allocate the proper amount of memory for the k3D_Format > which the emboss mask filter produces. > > Fixes SkEmbossMask::Emboss to write the whole of the mul and add planes > to avoid pixel differences and MemorySanitizer errors. > > Update the GPU to understand the k3D_Format and use just the alpha > plane, ignoring the mul and add plane which it currently cannot support. > > Change-Id: Icac1a3f37d6e8c6be3151df570f5e14111e18585 > Reviewed-on: https://skia-review.googlesource.com/70260 > Reviewed-by: Herb Derby <herb@google.com> > Reviewed-on: https://skia-review.googlesource.com/70962 > Commit-Queue: Ben Wagner <bungeman@google.com> TBR=djsollen@google.com,bungeman@google.com,herb@google.com Change-Id: Id6625bae8d3bd70ce7aa3045348c04fdd146c637 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/71183 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Alloc glyph image correctly for SkMask::k3D_Format.Gravatar Ben Wagner2017-11-14
| | | | | | | | | | | | | | | | | | | | | | | | Remove the no longer used outside Skia SK_SUPPORT_LEGACY_EMBOSSMASKFILTER define, and either delete the code it guards or update it to use the new emboss mask filter factory. Re-enable the code to test the emboss mask filter. Add a test to ensure that embossed text is drawn correctly, as before glyphs did not allocate the proper amount of memory for the k3D_Format which the emboss mask filter produces. Fixes SkEmbossMask::Emboss to write the whole of the mul and add planes to avoid pixel differences and MemorySanitizer errors. Update the GPU to understand the k3D_Format and use just the alpha plane, ignoring the mul and add plane which it currently cannot support. Change-Id: Icac1a3f37d6e8c6be3151df570f5e14111e18585 Reviewed-on: https://skia-review.googlesource.com/70260 Reviewed-by: Herb Derby <herb@google.com> Reviewed-on: https://skia-review.googlesource.com/70962 Commit-Queue: Ben Wagner <bungeman@google.com>
* Revert "Alloc glyph image correctly for SkMask::k3D_Format."Gravatar Ben Wagner2017-11-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 6b26deb8d6067589ce9b7853ab8e8d39de1a45de. Reason for revert: GPU bots failing Original change's description: > Alloc glyph image correctly for SkMask::k3D_Format. > > This removes the no longer used outside Skia > SK_SUPPORT_LEGACY_EMBOSSMASKFILTER define, and either deletes the code > it guards or updates it to use the new emboss mask filter factory. This > re-enables the code to test the emboss mask filter. Also added is a test > to ensure that embossed text is drawn correctly, as before this glyphs > did not allocate the proper amount of memory for the k3D_Format which > this mask filter produces. This also fixes SkEmbossMask::Emboss to write > the whole of the mul and add planes to avoid pixel differences and > MemorySanitizer errors. > > Change-Id: Ib492c72a19d6a27d140e3cd48179a3ca9ce313f5 > Reviewed-on: https://skia-review.googlesource.com/70260 > Commit-Queue: Ben Wagner <bungeman@google.com> > Reviewed-by: Herb Derby <herb@google.com> TBR=djsollen@google.com,bungeman@google.com,herb@google.com,reed@google.com Change-Id: I8a9db6c00e0cb84bdd4833474a9ffffa6ecc606c No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/70920 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Alloc glyph image correctly for SkMask::k3D_Format.Gravatar Ben Wagner2017-11-13
| | | | | | | | | | | | | | | | | This removes the no longer used outside Skia SK_SUPPORT_LEGACY_EMBOSSMASKFILTER define, and either deletes the code it guards or updates it to use the new emboss mask filter factory. This re-enables the code to test the emboss mask filter. Also added is a test to ensure that embossed text is drawn correctly, as before this glyphs did not allocate the proper amount of memory for the k3D_Format which this mask filter produces. This also fixes SkEmbossMask::Emboss to write the whole of the mul and add planes to avoid pixel differences and MemorySanitizer errors. Change-Id: Ib492c72a19d6a27d140e3cd48179a3ca9ce313f5 Reviewed-on: https://skia-review.googlesource.com/70260 Commit-Queue: Ben Wagner <bungeman@google.com> Reviewed-by: Herb Derby <herb@google.com>
* move parts of SkPoint to SkPointPrivGravatar Cary Clark2017-11-08
| | | | | | | | | | | | Move specialized SkPoint methods to SkPointPriv. Use constexpr and inline initialization where possible. R=reed@google.com,bsalomon@google.com Bug: skia: 6898 Change-Id: I01ec5186f010f2dc80c068c70d9cc352f3221338 Reviewed-on: https://skia-review.googlesource.com/68700 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Ravi Mistry <rmistry@google.com>
* Add clipping options to path text bench and samplesGravatar Chris Dalton2017-11-07
| | | | | | | | Bug: skia: Change-Id: I632a2fa5627ef1438d9ab451318a42d12c61b802 Reviewed-on: https://skia-review.googlesource.com/67683 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* clean up cruft about --portableFonts and --resourceFontsGravatar Mike Klein2017-11-06
| | | | | | | | | | --portableFonts exists but does nothing. --resourceFonts doesn't even exist. Change-Id: I7880208de4aaa9674ba720b9e70c34c145561ac0 Reviewed-on: https://skia-review.googlesource.com/67800 Commit-Queue: Ben Wagner <bungeman@google.com> Reviewed-by: Ben Wagner <bungeman@google.com>
* -= to control width of fatbits line widthGravatar Mike Reed2017-11-02
| | | | | | | | Bug: skia: Change-Id: Id100ac5c22f5cc878d782d53557c6b37370a2989 Reviewed-on: https://skia-review.googlesource.com/66621 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Convert geometry shaders to operate in Skia device spaceGravatar Chris Dalton2017-10-25
| | | | | | | | | | | | | Defers the transformation to normalized window coordinates until after the geometry shader. Merges vertex and a geometry shader builders into a single compilation unit with a common base class. Updates CCPR geometry shaders accordingly. Bug: skia: Change-Id: If93c90e978b1fdc7120febd05cfb05810fd496b5 Reviewed-on: https://skia-review.googlesource.com/62980 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Print measure info before closeWindowGravatar Yuqian Li2017-10-23
| | | | | | | | | | | The closeWindow function does not guarantee the calling of ~SampleWindow (in Windows and Mac). So we print the info earlier. Bug: skia: Change-Id: Ib8b11cac4fb2fc7b62a02c7fb7f3aaaa48df2da6 Reviewed-on: https://skia-review.googlesource.com/63140 Reviewed-by: Mike Klein <mtklein@chromium.org> Commit-Queue: Yuqian Li <liyuqian@google.com>
* SampleAAGeometry tweaksGravatar Chris Dalton2017-10-20
| | | | | | | | | | | | - Use capital letters avoid conflict with built-in commands, particularly zoom-window ('z') and toggle-backend ('d'). - Increase kHitToleranace for touch screens. Bug: skia: Change-Id: I6feaabd8aa06600bdeb4623ab081d973369c4841 Reviewed-on: https://skia-review.googlesource.com/52528 Commit-Queue: Chris Dalton <csmartdalton@google.com> Reviewed-by: Cary Clark <caryclark@google.com>
* Add a SampleApp flag to automate keystrokes on startupGravatar Chris Dalton2017-10-18
| | | | | | | | | | | | | This is a quick-and-dirty solution to select color mode, backend, etc. from the command line. e.g. 'out/Debug/SampleApp --keys CCd' for opengl and srgb Bug: skia: Change-Id: I61f9e0fd4209a5fadb585c02c71984398f2f0860 Reviewed-on: https://skia-review.googlesource.com/61482 Reviewed-by: Yuqian Li <liyuqian@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Remove redundant parentheses.Gravatar Ben Wagner2017-10-17
| | | | | | | | | | | | | | | | Recent clang versions produce output like ../../samplecode/SampleAll.cpp:306:27: error: redundant parentheses surrounding declarator [-Werror,-Wredundant-parens] Remove these to clean up the code a bit. Change-Id: Ib099201f23f83cd712487c238b6a508290e667a7 Reviewed-on: https://skia-review.googlesource.com/60822 Commit-Queue: Ben Wagner <bungeman@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Refactor CCPR coverage shaders for a vertex implGravatar Chris Dalton2017-10-16
| | | | | | | | | | | | | Decouples geometry generation and analytic coverage. This paves the way for a vertex shader implementation. TBR=egdaniel@google.com Bug: skia: Change-Id: I2a183401bfe70b9f14b9b1cf035de6020a2135fa Reviewed-on: https://skia-review.googlesource.com/60103 Reviewed-by: Chris Dalton <csmartdalton@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Revert "Refactor CCPR coverage shaders for a vertex impl"Gravatar Eric Boren2017-10-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit e501033bbdc9143848edde3c3e3b7282169bc11e. Reason for revert: Broke several bots Original change's description: > Refactor CCPR coverage shaders for a vertex impl > > Decouples geometry generation and analytic coverage. This paves the > way for a vertex shader implementation. > > Bug: skia: > Change-Id: I23b79d4397db22bd8fc063b8dfca58ab00037292 > Reviewed-on: https://skia-review.googlesource.com/59200 > Commit-Queue: Chris Dalton <csmartdalton@google.com> > Reviewed-by: Greg Daniel <egdaniel@google.com> TBR=egdaniel@google.com,csmartdalton@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: skia: Change-Id: I314bf03fa6cbeceb1c527d4d9464147b2e8464c6 Reviewed-on: https://skia-review.googlesource.com/59821 Reviewed-by: Eric Boren <borenet@google.com> Commit-Queue: Eric Boren <borenet@google.com>
* Refactor CCPR coverage shaders for a vertex implGravatar Chris Dalton2017-10-15
| | | | | | | | | | | Decouples geometry generation and analytic coverage. This paves the way for a vertex shader implementation. Bug: skia: Change-Id: I23b79d4397db22bd8fc063b8dfca58ab00037292 Reviewed-on: https://skia-review.googlesource.com/59200 Commit-Queue: Chris Dalton <csmartdalton@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Add a tooling flag for path mask cachingGravatar Chris Dalton2017-10-13
| | | | | | | | | | | Adds the flag and a disables caching on the CCPR bots. Bug: skia: Change-Id: Icb85e77f89634dda1d419dacac5b8a93340723f0 Reviewed-on: https://skia-review.googlesource.com/59740 Reviewed-by: Eric Boren <borenet@google.com> Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Remove trailing whitespace.Gravatar Ben Wagner2017-10-09
| | | | | | | | | | | Also adds a presubmit to prevent adding trailing whitespace to source code in the future. Change-Id: I41a4df81487f6f00aa19b188f0cac6a3377efde6 Reviewed-on: https://skia-review.googlesource.com/57380 Reviewed-by: Ravi Mistry <rmistry@google.com> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Mark ~LuaView as override.Gravatar Ben Wagner2017-10-09
| | | | | | | | | | | | | Newer clang versions report ../../samplecode/SampleLua.cpp:44:13: error: '~LuaView' overrides a destructor but is not marked 'override' [-Werror,-Winconsistent-missing-destructor-override] Change-Id: I6f3e69482a79e9580e51b957fff06e6d4d270735 Reviewed-on: https://skia-review.googlesource.com/57164 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Revert[4] "guard old apis for querying byte-size of a bitmap/imageinfo/pixmap"Gravatar Mike Reed2017-10-03
| | | | | | | | | | This reverts commit 5a2e50edc51006ce91366e177a9d21a16775d7fd. Bug: skia: Change-Id: I8d28b5c07d90130e5a1653923740eaf189ecb954 Reviewed-on: https://skia-review.googlesource.com/53900 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Revert "Revert "Revert "guard old apis for querying byte-size of a ↵Gravatar Mike Reed2017-10-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bitmap/imageinfo/pixmap""" This reverts commit cd284c532376d16fcc4ed75baf3da65c3e4a2e95. Reason for revert: assert fired in SkMallocPixelRef.cpp:61: fatal error: "assert(info.computeByteSize(rowBytes) == info.getSafeSize(rowBytes))" google3 thinks it was from surface_rowbytes Original change's description: > Revert "Revert "guard old apis for querying byte-size of a bitmap/imageinfo/pixmap"" > > This reverts commit 809cbedd4b252be221b2ac3b4269d312fd8f53a0. > > Bug: skia: > Change-Id: I680d8daeeeeb15526b44c1305d8fb0c6bfa38e1d > Reviewed-on: https://skia-review.googlesource.com/52665 > Commit-Queue: Mike Reed <reed@google.com> > Reviewed-by: Florin Malita <fmalita@chromium.org> TBR=fmalita@chromium.org,reed@google.com Change-Id: I41e3f7a3f791cc8183291847e783ed8a53bc91d2 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/53802 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Revert "Revert "guard old apis for querying byte-size of a ↵Gravatar Mike Reed2017-10-02
| | | | | | | | | | | | bitmap/imageinfo/pixmap"" This reverts commit 809cbedd4b252be221b2ac3b4269d312fd8f53a0. Bug: skia: Change-Id: I680d8daeeeeb15526b44c1305d8fb0c6bfa38e1d Reviewed-on: https://skia-review.googlesource.com/52665 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org>
* Add width and height option to SampleAppGravatar Yuqian Li2017-09-29
| | | | | | | | | | | So we can benchmark with given width/height dimensions. Bug: skia: Change-Id: I881c9f054cdcecc3e0b2bfb600afd778e1c57d95 Reviewed-on: https://skia-review.googlesource.com/51246 Reviewed-by: Mike Reed <reed@google.com> Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Yuqian Li <liyuqian@google.com>
* Miscellaneous dynamic atlas fixes.Gravatar Jim Van Verth2017-09-28
| | | | | | | | | | | | | Make Chinese fling sample closer to Android test. Fix a bug in GrDrawOpAtlas::compact(), where the atlas generation wasn't incremented so the client didn't know it changed. Add some debug info for GrDrawOpAtlas. Add a comment in GrDrawOpAtlas::setLastUseTokenBulk. Change-Id: I79192a017870541a79731b1a22f665ec5deeff09 Reviewed-on: https://skia-review.googlesource.com/52761 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Add svg support to pathfinder toolGravatar Chris Dalton2017-09-28
| | | | | | | | Bug: skia: Change-Id: I9302491c983fae5e2e84edc4ee135a917b099a42 Reviewed-on: https://skia-review.googlesource.com/52360 Commit-Queue: Chris Dalton <csmartdalton@google.com> Reviewed-by: Jim Van Verth <jvanverth@google.com>
* Revert "guard old apis for querying byte-size of a bitmap/imageinfo/pixmap"Gravatar Jim Van Verth2017-09-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 88757dacd4f532a0f647c02ae0ee596d31ab5c68. Reason for revert: Still seems to be failing Chromium "telemetry_perf_unittests (with patch) on Android" on android_n5x_swarming_rel. Original change's description: > guard old apis for querying byte-size of a bitmap/imageinfo/pixmap > > Now with legacy behavior for allocpixels > > This was reverted, so the current CL is a "fix" on top of ... > https://skia-review.googlesource.com/c/skia/+/50980 > > Related update to Chrome (in preparation for this change) > https://chromium-review.googlesource.com/c/chromium/src/+/685719 > > Bug: skia: > Change-Id: I4b370ee7e95083ab27421f008132219c9c7b86e9 > Reviewed-on: https://skia-review.googlesource.com/51341 > Reviewed-by: Florin Malita <fmalita@chromium.org> > Commit-Queue: Mike Reed <reed@google.com> TBR=fmalita@chromium.org,reed@google.com Change-Id: I827a0ca1d1e3909e648fde3342cdb8601d34da8d No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/52381 Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* guard old apis for querying byte-size of a bitmap/imageinfo/pixmapGravatar Mike Reed2017-09-27
| | | | | | | | | | | | | | | | Now with legacy behavior for allocpixels This was reverted, so the current CL is a "fix" on top of ... https://skia-review.googlesource.com/c/skia/+/50980 Related update to Chrome (in preparation for this change) https://chromium-review.googlesource.com/c/chromium/src/+/685719 Bug: skia: Change-Id: I4b370ee7e95083ab27421f008132219c9c7b86e9 Reviewed-on: https://skia-review.googlesource.com/51341 Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Mike Reed <reed@google.com>
* Revert "guard old apis for querying byte-size of a bitmap/imageinfo/pixmap"Gravatar Greg Daniel2017-09-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 98a6216b18b57c2f7a0d58f542c60503686aed69. Reason for revert: breaking the chrome roll. Looks like they may be writing data to create an image across all the row bytes and thus writing to unalloced data on the last row. Link to example failing bot: https://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/539960 Original change's description: > guard old apis for querying byte-size of a bitmap/imageinfo/pixmap > > Previously we had size_t and uint64_t variations. > > The new (simpler) API always.. > - returns size_t, or 0 if the calculation overflowed > - returns the trimmed size (does not include rowBytes padding for the last row) > > Bug: skia: > Change-Id: I05173e877918327c7b207d2f7f1ab0db36892e2e > Reviewed-on: https://skia-review.googlesource.com/50980 > Commit-Queue: Mike Reed <reed@google.com> > Reviewed-by: Florin Malita <fmalita@chromium.org> > Reviewed-by: Leon Scroggins <scroggo@google.com> TBR=mtklein@google.com,herb@google.com,scroggo@google.com,fmalita@chromium.org,reed@google.com Change-Id: I726f6ab1b36b14979ba6f37105e0a469b3f0dbc0 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/51262 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Remove unused functions get_preferred_sizeGravatar Yuqian Li2017-09-26
| | | | | | | | | | Bug: skia: Change-Id: I6a5b5d96ad48b84b07d2e56fbabb870a90c62a97 Reviewed-on: https://skia-review.googlesource.com/51460 Reviewed-by: Yuqian Li <liyuqian@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Yuqian Li <liyuqian@google.com>
* guard old apis for querying byte-size of a bitmap/imageinfo/pixmapGravatar Mike Reed2017-09-26
| | | | | | | | | | | | | | | Previously we had size_t and uint64_t variations. The new (simpler) API always.. - returns size_t, or 0 if the calculation overflowed - returns the trimmed size (does not include rowBytes padding for the last row) Bug: skia: Change-Id: I05173e877918327c7b207d2f7f1ab0db36892e2e Reviewed-on: https://skia-review.googlesource.com/50980 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org> Reviewed-by: Leon Scroggins <scroggo@google.com>
* CCPR: Remove kCombinedTriangleHullsAndEdgesGravatar Chris Dalton2017-09-26
| | | | | | | | | | | | | | Removes the mode that generates edge and hull geometry simultaneously from the geometry shader. Perf was hit and miss and it's not compatible with vertex shaders. We can revisit if geometry shaders still show promise on some platforms after a vertex shader impl is finished. Bug: skia: Change-Id: I984231e9a5bb60fe31d3ba280c7390a74aa5bc27 Reviewed-on: https://skia-review.googlesource.com/51300 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Add animated cowboy sample from WebKit tests, and fix.Gravatar Jim Van Verth2017-09-25
| | | | | | | | Bug: chromium:712455 Change-Id: Ic9bb9b862abe01f112cc41d28589733460b15bc1 Reviewed-on: https://skia-review.googlesource.com/50181 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Add measurement command line args to SampleAppGravatar Yuqian Li2017-09-25
| | | | | | | | | | | | | | | | | This way, we may be able to use SampleApp as a performance benchmark tool that's closer to real-world use cases than nanobench. For example, we can now run ./out/Release/SampleApp --slide Chart --backendTiles 8 --measureMS 2000 to test the threaded backend. Bug: skia: Change-Id: I92b177624bc8d16c5b4d3ad122319882e8783101 Reviewed-on: https://skia-review.googlesource.com/50801 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Yuqian Li <liyuqian@google.com>
* Use shader based blending to clamp kPlus mode w/F16Gravatar Brian Osman2017-09-20
| | | | | | | | Bug: skia:6173 Change-Id: I21042d484d9a7b3eee04aa3301d9793d00ad6908 Reviewed-on: https://skia-review.googlesource.com/48183 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Minor cleanups for CCPRGravatar Chris Dalton2017-09-12
| | | | | | | | Bug: skia: Change-Id: Ic4838f0e242ded0c3d0cb5c86715ed67d8152f5c Reviewed-on: https://skia-review.googlesource.com/44520 Commit-Queue: Chris Dalton <csmartdalton@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>