aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu
Commit message (Collapse)AuthorAge
* Improve caching of dashed paths in GrStencilAndCoverPathRendererGravatar kkinnunen2015-05-18
| | | | | | | | | | | | | | | | Improve caching of dashed paths in GrStencilAndCoverPathRenderer. Look up the (NVPR specific) GrGLPath based on GrStrokeInfo and the original path. Use unique keys for all GrPaths. Dash the path with Skia dash stroker and use that path geometry for NVPR path. NVPR internal dashing stroke is not used, because the dashing implementation of NVPR does not match Skia implementation. Review URL: https://codereview.chromium.org/1116123003
* Improve NVPR stroke accuracy to fix thick strokesGravatar kkinnunen2015-05-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set the "path stroke error bound" path parameter to 0.02 for all paths. This means that the stroked path area will be within 98% of the stroke width in path space. This should fix many cases where NVPR stroked paths were visibly different to Skia stroked paths. One such path is in dashcubics gm. This increases the amount of subdivisions the path object creation will make for paths that need it. This in turn will increase gpu object space requirements sligthly. Both of these effects should be unnoticeable. GL_NV_path_rendering.txt: """ Every path object has a stroke approximation bound parameter (PATH_STROKE_BOUND_NV) that is a floating-point value /sab/ clamped between 0.0 and 1.0 and set and queried with the PATH_STROKE_BOUND_NV path parameter. Exact determination of samples swept an orthogonal centered line segment along cubic Bezier segments and rational quadratic Bezier curves (so non-circular partial elliptical arcs) is intractable for real-time rendering so an approximation is required; /sab/ intuitively bounds the approximation error as a percentage of the path object's stroke width. Specifically, this path parameter requests the implementation to stencil any samples within /sweep/ object space units of the exact sweep of the path's cubic Bezier segments or partial elliptical arcs to be sampled by the stroke where sweep = ((1-sab)*sw)/2 where /sw/ is the path object's stroke width. The initial value of /sab/ when a path is created is 0.2. In practical terms, this initial value means the stencil sample positions coverage within 80% (100%-20%) of the stroke width of cubic and rational quadratic stroke segments should be sampled. """ BUG=skia:2049 Review URL: https://codereview.chromium.org/1124423007
* Make GrStrokeInfo inherit from SkStrokeRecGravatar kkinnunen2015-05-18
| | | | | | | | | | | | | | | | | | | Make the code more readable by inheriting GrStrokeInfo from SkStrokeRec. This should avoid the long .getStrokeRec() and .getStrokeRecPtr(). These were a bit cumbersome especially in cases where an alias variable was created for these, and then the reader had to keep track to which StrokeInfo member the StrokeRec alias was pointing. Removes SkStrokeRec::SkStrokeRec(const SkStrokeRec&). It was memcpying. Try to play it safe wrt compiler using the possible padding of superclass for subclass members. Instead, let the compiler generate the copy constructor. Assignment operator was already compiler-generated, so at least in that way this is consistent. Renames GrStrokeInfo::applyDash to applyDashToPath for consistency with superclass applyToPath. Review URL: https://codereview.chromium.org/1128113008
* Revert of Sketch splitting SkPicture into an interface and SkBigPicture. ↵Gravatar mtklein2015-05-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (patchset #25 id:480001 of https://codereview.chromium.org/1112523006/) Reason for revert: win_chromium_compile_dbg_ng FAILED: ninja -t msvc -e environment.x86 -- E:\b\build\goma/gomacc "E:\b\depot_tools\win_toolchain\vs2013_files\VC\bin\amd64_x86\cl.exe" /nologo /showIncludes /FC @obj\third_party\skia\src\core\skia.SkBitmapHeap.obj.rsp /c ..\..\third_party\skia\src\core\SkBitmapHeap.cpp /Foobj\third_party\skia\src\core\skia.SkBitmapHeap.obj /Fdobj\skia\skia.cc.pdb e:\b\build\slave\win\build\src\third_party\skia\include\core\skpicture.h(176) : error C2487: 'CURRENT_PICTURE_VERSION' : member of dll interface class may not be declared with dll interface Original issue's description: > Sketch splitting SkPicture into an interface and SkBigPicture. > > Adds small pictures for drawRect(), drawTextBlob(), and drawPath(). > These cover about 89% of draw calls from Blink SKPs, > and about 25% of draw calls from our GMs. > > SkPicture handles: > - serialization and deserialization > - unique IDs > > Everything else is left to the subclasses: > - playback(), cullRect() > - hasBitmap(), hasText(), suitableForGPU(), etc. > - LayerInfo / AccelData if applicable. > > The time to record a 1-op picture improves a good chunk > (2 mallocs to 1), and the time to record a 0-op picture > greatly improves (2 mallocs to none): > > picture_overhead_draw: 450ns -> 350ns > picture_overhead_nodraw: 300ns -> 90ns > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/c92c129ff85b05a714bd1bf921c02d5e14651f8b > > Latest blink_linux_rel: > > http://build.chromium.org/p/tryserver.blink/builders/linux_blink_rel/builds/61248 > > Committed: https://skia.googlesource.com/skia/+/15877b6eae33a9282458bdb904a6d00440eca0ec TBR=reed@google.com,robertphillips@google.com,fmalita@chromium.org,mtklein@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1130283004
* Sketch splitting SkPicture into an interface and SkBigPicture.Gravatar mtklein2015-05-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds small pictures for drawRect(), drawTextBlob(), and drawPath(). These cover about 89% of draw calls from Blink SKPs, and about 25% of draw calls from our GMs. SkPicture handles: - serialization and deserialization - unique IDs Everything else is left to the subclasses: - playback(), cullRect() - hasBitmap(), hasText(), suitableForGPU(), etc. - LayerInfo / AccelData if applicable. The time to record a 1-op picture improves a good chunk (2 mallocs to 1), and the time to record a 0-op picture greatly improves (2 mallocs to none): picture_overhead_draw: 450ns -> 350ns picture_overhead_nodraw: 300ns -> 90ns BUG=skia: Committed: https://skia.googlesource.com/skia/+/c92c129ff85b05a714bd1bf921c02d5e14651f8b Latest blink_linux_rel: http://build.chromium.org/p/tryserver.blink/builders/linux_blink_rel/builds/61248 Review URL: https://codereview.chromium.org/1112523006
* Don't do discards when on Adreno4xx due to driver bug.Gravatar egdaniel2015-05-18
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1126423006
* Revert of Move copy-surface-as-draw fallback to GrGLGpu. (patchset #12 ↵Gravatar mtklein2015-05-18
| | | | | | | | | | | | | | | | | | | id:220001 of https://codereview.chromium.org/1144433002/) Reason for revert: Many GMs changed, some totally busted. Original issue's description: > Move copy-surface-as-draw fallback to GrGLGpu. > > Committed: https://skia.googlesource.com/skia/+/5df6fee929823f50c55cc50f7c882a309c1b1de9 TBR=joshualitt@google.com,egdaniel@google.com,bsalomon@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1142003003
* Move copy-surface-as-draw fallback to GrGLGpu.Gravatar bsalomon2015-05-18
| | | | Review URL: https://codereview.chromium.org/1144433002
* remove localmatrix from GrGeometryProcessor base classGravatar joshualitt2015-05-15
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1131513005
* Remove high ref count tracker from GrFakeRefObjGravatar bsalomon2015-05-14
| | | | | | TBR=robertphillips@google.com Review URL: https://codereview.chromium.org/1139803003
* Remove viewmatrix from GrGeometryProcessor base classGravatar joshualitt2015-05-14
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1127953003
* Tesellating path renderer: typecast cleanup; logging build fix.Gravatar senorblanco2015-05-14
| | | | | | | | | | | Use SkPoint* for all vertex data. (It was void* to support two different vertex data formats, which we no longer need.) Assert that vertex stride == sizeof(SkPoint). Fix build when LOGGING_ENABLED=1. BUG=skia: Review URL: https://codereview.chromium.org/1128083004
* Revert of Defer glClear to just before draw call (patchset #2 id:20001 of ↵Gravatar robertphillips2015-05-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1113003005/) Reason for revert: This CL seems to be triggering the assert: src/gpu/SkGpuDevice.cpp:319: failed assertion "!fNeedClear" on, at least, Mac & Ubuntu. Original issue's description: > Defer glClear to just before draw call > > Remove some DO_DEFERRED_CLEAR call to avoid call glClear separately, like this: > glBindFramebuffer(1) > glClear > glBindFramebuffer(2) > glClear > glBindFramebuffer(1) > glDrawXXX > glBindFramebuffer(2) > glDrawXXX > > These call sequences may need read and write memory back and forth. > > If we call DO_DEFERRED_CLEAR just before draw call, we can bind, clear and draw in one go. > e.g. > glBindFramebuffer(1) > glClear > glDrawXXX > glBindFramebuffer(2) > glClear > glDrawXXX > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/c3c06a13e69b90d4cc1d543853504072d363ae8b TBR=bsalomon@google.com,joel.liang@arm.com,wasim.abbas@arm.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1136393005
* Defer glClear to just before draw callGravatar wasim.abbas2015-05-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | Remove some DO_DEFERRED_CLEAR call to avoid call glClear separately, like this: glBindFramebuffer(1) glClear glBindFramebuffer(2) glClear glBindFramebuffer(1) glDrawXXX glBindFramebuffer(2) glDrawXXX These call sequences may need read and write memory back and forth. If we call DO_DEFERRED_CLEAR just before draw call, we can bind, clear and draw in one go. e.g. glBindFramebuffer(1) glClear glDrawXXX glBindFramebuffer(2) glClear glDrawXXX BUG=skia: Review URL: https://codereview.chromium.org/1113003005
* Revert of Refactor GrBufferAllocPools to use resource cache (patchset #9 ↵Gravatar robertphillips2015-05-14
| | | | | | | | | | | | | | | | | | | id:160001 of https://codereview.chromium.org/1139753002/) Reason for revert: Perf Regression for some bot/skp combinations Original issue's description: > Refactor GrBufferAllocPools to use resource cache > > Committed: https://skia.googlesource.com/skia/+/c5f1c5414fc8f73cbefadcc1b24ec794056fa203 TBR=bsalomon@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1129863008
* remove color from GrGeometryProcessorGravatar joshualitt2015-05-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1140983002
* Don't issue texture barriers for RT's with separate storageGravatar cdalton2015-05-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1137663004
* removing equality / compute invariant loops from GrGeometryProcessorsGravatar joshualitt2015-05-13
| | | | | | | | BUG=skia: Committed: https://skia.googlesource.com/skia/+/ef292a0901205b9785a30daae2c036aa34a970ca Review URL: https://codereview.chromium.org/1111603004
* fix for angle botGravatar joshualitt2015-05-13
| | | | | | | TBR= BUG=skia: Review URL: https://codereview.chromium.org/1137333004
* fix for blur large glyphs problemsGravatar joshualitt2015-05-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1131023006
* Keep Big Glyph coordinates in float in GrAtlasTextContextGravatar joshualitt2015-05-13
| | | | | | | TBR=jvanverth@google.com BUG=skia: Review URL: https://codereview.chromium.org/1132853004
* Refactor GrBufferAllocPools to use resource cacheGravatar robertphillips2015-05-13
| | | | Review URL: https://codereview.chromium.org/1139753002
* Revert of Revert of Revert of Remove workaround to for lower glsl support ↵Gravatar egdaniel2015-05-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for qualcomm (patchset #1 id:1 of https://codereview.chromium.org/1138013004/) Reason for revert: still broken :( Original issue's description: > Revert of Revert of Remove workaround to for lower glsl support for qualcomm (patchset #1 id:1 of https://codereview.chromium.org/1135393003/) > > Reason for revert: > trying once more > > Original issue's description: > > Revert of Remove workaround to for lower glsl support for qualcomm (patchset #1 id:1 of https://codereview.chromium.org/1133543004/) > > > > Reason for revert: > > breaks many qualcomm gms > > > > Original issue's description: > > > Remove workaround to for lower glsl support for qualcomm > > > > > > BUG=skia: > > > > > > Committed: https://skia.googlesource.com/skia/+/9770bdce776f45367c419b8dd82219eece26ca5c > > > > TBR=bsalomon@google.com > > NOPRESUBMIT=true > > NOTREECHECKS=true > > NOTRY=true > > BUG=skia: > > > > Committed: https://skia.googlesource.com/skia/+/0cfe1242ee284290bde1ebe3f48626c555fdac51 > > TBR=bsalomon@google.com > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/b72f920ef581e9cf50a6c1afc80ed04bb086488e TBR=bsalomon@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1130413006
* Remove GrGLVertexArray from GrGpuResource hierarchy.Gravatar bsalomon2015-05-13
| | | | Review URL: https://codereview.chromium.org/1137093002
* GLProgramsTest 3.0Gravatar joshualitt2015-05-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1139743002
* Revert of Revert of Remove workaround to for lower glsl support for qualcomm ↵Gravatar egdaniel2015-05-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (patchset #1 id:1 of https://codereview.chromium.org/1135393003/) Reason for revert: trying once more Original issue's description: > Revert of Remove workaround to for lower glsl support for qualcomm (patchset #1 id:1 of https://codereview.chromium.org/1133543004/) > > Reason for revert: > breaks many qualcomm gms > > Original issue's description: > > Remove workaround to for lower glsl support for qualcomm > > > > BUG=skia: > > > > Committed: https://skia.googlesource.com/skia/+/9770bdce776f45367c419b8dd82219eece26ca5c > > TBR=bsalomon@google.com > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/0cfe1242ee284290bde1ebe3f48626c555fdac51 TBR=bsalomon@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1138013004
* fix bounds for BW lines, AA HairlinesGravatar joshualitt2015-05-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1123253003
* Fix assert in GrBatchAtlas.Gravatar jvanverth2015-05-13
| | | | | | Stops this assert from triggering on the iOS build. Review URL: https://codereview.chromium.org/1131003004
* Revert of Remove workaround to for lower glsl support for qualcomm (patchset ↵Gravatar egdaniel2015-05-13
| | | | | | | | | | | | | | | | | | | | | | #1 id:1 of https://codereview.chromium.org/1133543004/) Reason for revert: breaks many qualcomm gms Original issue's description: > Remove workaround to for lower glsl support for qualcomm > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/9770bdce776f45367c419b8dd82219eece26ca5c TBR=bsalomon@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1135393003
* Remove workaround to for lower glsl support for qualcommGravatar egdaniel2015-05-13
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1133543004
* Fix SkStrokeRec == to report true for all fillsGravatar kkinnunen2015-05-13
| | | | | | | Fix SkStrokeRec == to report true for all fills, regardless of the stale stroking data the object might contain. Review URL: https://codereview.chromium.org/1130153002
* Add check in GrGpu createTexture to make sure we don't create multisampled ↵Gravatar egdaniel2015-05-12
| | | | | | | | textures. BUG=skia: Review URL: https://codereview.chromium.org/1138223003
* add option to supress prints on contextGravatar joshualitt2015-05-12
| | | | | | | | BUG=skia: Committed: https://skia.googlesource.com/skia/+/55661337667a8305ebb100e36af23d34c2fb83ba Review URL: https://codereview.chromium.org/1128903008
* Fix valgrind bug in Porter Duff LCD.Gravatar egdaniel2015-05-12
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1135283002
* Revert of Revert of stop calling SkScalarDiv (patchset #1 id:1 of ↵Gravatar reed2015-05-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1138263002/) Reason for revert: android patched, blink has rolled Original issue's description: > Revert of stop calling SkScalarDiv (patchset #4 id:60001 of https://codereview.chromium.org/1135053002/) > > Reason for revert: > need to wait for Blink roll (and patch android) > > Original issue's description: > > stop calling SkScalarDiv > > > > BUG=skia: > > TBR= > > > > Committed: https://skia.googlesource.com/skia/+/67d71c898249a7af3523b16c6a69895a63bfae0a > > TBR= > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/2629697933b5cc975e45d2a45c48f803fc6cbcec TBR= NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1135693003
* Revert of stop calling SkScalarDiv (patchset #4 id:60001 of ↵Gravatar reed2015-05-12
| | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1135053002/) Reason for revert: need to wait for Blink roll (and patch android) Original issue's description: > stop calling SkScalarDiv > > BUG=skia: > TBR= > > Committed: https://skia.googlesource.com/skia/+/67d71c898249a7af3523b16c6a69895a63bfae0a TBR= NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1138263002
* stop calling SkScalarDivGravatar reed2015-05-12
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/1135053002
* Revert of add option to supress prints on context (patchset #5 id:80001 of ↵Gravatar joshualitt2015-05-12
| | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1128903008/) Reason for revert: breaks windows rollbots Original issue's description: > add option to supress prints on context > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/55661337667a8305ebb100e36af23d34c2fb83ba TBR=bsalomon@google.com,robertphillips@google.com,joshualitt@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1125193006
* add option to supress prints on contextGravatar joshualitt2015-05-12
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1128903008
* Make Porter Duff LCD XP its own XferProcessorGravatar egdaniel2015-05-12
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1134093003
* Fix blur on large glyphs in runs < SkGlyphCache::maxGravatar joshualitt2015-05-11
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1135113002
* fix for cached textblobs look garbledGravatar joshualitt2015-05-11
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1135813007
* Add virtual destructor for GrDrawTargetCapsGravatar bsalomon2015-05-11
| | | | | | TBR=jvanverth@google.com Review URL: https://codereview.chromium.org/1134043004
* Add assignment op to enum bitfield opsGravatar cdalton2015-05-11
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1139513002
* Add function for logging blend info on XP.Gravatar bsalomon2015-05-11
| | | | Review URL: https://codereview.chromium.org/1132373003
* convex path renderer unit testsGravatar joshualitt2015-05-11
| | | | | | | TBR=bsalomon@google.com BUG=skia: Review URL: https://codereview.chromium.org/1134753002
* Add unit tests to text contextGravatar joshualitt2015-05-11
| | | | | | | TBR=bsalomon@google.com BUG=skia: Review URL: https://codereview.chromium.org/1128153005
* Add unit tests for stroke rects and drawVerticesGravatar joshualitt2015-05-11
| | | | | | | TBR=bsalomon@google.com BUG=skia: Review URL: https://codereview.chromium.org/1133613004
* AADistanceFieldPathRenderer unit testsGravatar joshualitt2015-05-11
| | | | | | | TBR=bsalomon@google.com BUG=skia: Review URL: https://codereview.chromium.org/1129083005
* print on unused uniforms in debug buildsGravatar joshualitt2015-05-11
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1136803002