Commit Graph

164 Commits

Author SHA1 Message Date
Ruiqi Mao
9a6e42ff18 added caching of SkVertices
SkVertices can now be "volatile", meaning they should not be cached.
SkVertices is volatile by default if the argument is not given.

Pulled from reverted CL: https://skia-review.googlesource.com/c/skia/+/138596

Docs-Preview: https://skia.org/?cl=139545
Bug: skia:
Change-Id: I92cf832efe1c0aaa8f432eedde2678582dd2454e
Reviewed-on: https://skia-review.googlesource.com/139545
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Ruiqi Mao <ruiqimao@google.com>
2018-07-09 20:31:28 +00:00
Ruiqi Mao
c05aa7d163 Revert "added skeletal animation support to GPU backend"
This reverts commit b6307340e8.

Reason for revert: patch/atlas failing in gold

Original change's description:
> added skeletal animation support to GPU backend
> 
> added caching of SkVertices
> 
> Docs-Preview: https://skia.org/?cl=138596
> Bug: skia:
> Change-Id: Ia750f55f5f6d0de250d9e9c5619f4d1ac856f9f5
> Reviewed-on: https://skia-review.googlesource.com/138596
> Reviewed-by: Brian Osman <brianosman@google.com>
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Ruiqi Mao <ruiqimao@google.com>

TBR=robertphillips@google.com,brianosman@google.com,reed@google.com,ruiqimao@google.com

Change-Id: Idfaf016a7ff4cdd8af2543d510706f489d04417a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/139281
Reviewed-by: Ruiqi Mao <ruiqimao@google.com>
Commit-Queue: Ruiqi Mao <ruiqimao@google.com>
2018-07-03 21:18:18 +00:00
Ruiqi Mao
b6307340e8 added skeletal animation support to GPU backend
added caching of SkVertices

Docs-Preview: https://skia.org/?cl=138596
Bug: skia:
Change-Id: Ia750f55f5f6d0de250d9e9c5619f4d1ac856f9f5
Reviewed-on: https://skia-review.googlesource.com/138596
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Ruiqi Mao <ruiqimao@google.com>
2018-07-03 16:07:44 +00:00
Ruiqi Mao
94d57c477f updated SkCanvas documentation for animation overloads of drawVertices
changed bookmaker ParserCommon::writeBlockTrim limit to 20000

disabled broken SkPaint::containsText example

Docs-Preview: https://skia.org/?cl=138862
Bug: skia:8123
Change-Id: Ib4003bf7b9603bf652f86cd56e0975cd09bcbf71
Reviewed-on: https://skia-review.googlesource.com/138862
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-07-03 13:33:43 +00:00
Cary Clark
53498e973e fix blank catalog images
Some catalog images are blank because
the image wasn't selected in the fiddle
example.

Also continue to add documentation and
examples for SkRRect

R=caryclark@google.com
NOTRY=true

Docs-Preview: https://skia.org/?cl=138382
Bug: skia:6898
Change-Id: I282a14ffcbaf2f8383294724900960f5ba40a2aa
Reviewed-on: https://skia-review.googlesource.com/138382
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-28 23:17:47 +00:00
Cary Clark
82f1f744f8 fix doc catalog
The doc catalog (the thing that allows graphical example searches)
got broken because bookmaker generated json names with linefeeds
in them.

Fix that and add an incremental update towards documenting SkRRect.

R=caryclark@google.com

Docs-Preview: https://skia.org/?cl=138020
Bug: skia:6898
Change-Id: I8e033d2d59fc9693f377be8c202bbf8ac9253b20
Reviewed-on: https://skia-review.googlesource.com/138020
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-28 13:18:16 +00:00
Cary Clark
224c700a1f sync docs up with tip of tree
Also check in work in progress for blend modes,
round rects, and a placeholder for pictures.

One minor include change to add a parameter name
for SkBlendMode function.

TBR=reed@google.com
R=caryclark@google.com

Docs-Preview: https://skia.org/?cl=134200
Bug: skia:6898
Change-Id: I5d2a9221d61edb32d9c7edbb3193401605b2b513
Reviewed-on: https://skia-review.googlesource.com/134200
Reviewed-by: Cary Clark <caryclark@google.com>
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-27 15:47:45 +00:00
Cary Clark
81abc43e6f explicitly include blurimagefilter include
Try explicitly adding
to fix the bookmaker nightly bot.

R=jcgregorio@google.com,caryclark@google.com

Docs-Preview: https://skia.org/?cl=137421
Bug: skia:6898
Change-Id: Iff27845e6872b885b8494e9fc236f4f05c10c301
Reviewed-on: https://skia-review.googlesource.com/137421
Reviewed-by: Cary Clark <caryclark@skia.org>
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Cary Clark <caryclark@skia.org>
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-25 20:53:25 +00:00
Ben Wagner
900b5364d1 Fix SkPaint::getTypeface() documentation.
SkPaint::getTypeface() allows the caller to borrow a pointer to its
SkTypeface, it does not affect ownership. The existing documentation would
lead a user to beleive that getTypeface() increments the reference count,
but it does not.

TBR=reed@google.com
Change-Id: Ic1a660b026e3c4295f9f0de28abfde29c3f05524
Reviewed-on: https://skia-review.googlesource.com/137183
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
2018-06-25 11:32:25 +00:00
Cary Clark
75fd449d81 fix for new fiddle compiler
New compiler is stricter, requiring
some variable initialization, braces.

A bug in SkRect was fixed, changing
debug output.

TBR=jcgregario@google.com

Docs-Preview: https://skia.org/?cl=136179
Bug: skia:6898
Change-Id: I19ef1dab2d3154778d0613e7337fdcfb340dacc7
Reviewed-on: https://skia-review.googlesource.com/136179
Commit-Queue: Cary Clark <caryclark@google.com>
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
Auto-Submit: Cary Clark <caryclark@google.com>
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Reviewed-by: Cary Clark <caryclark@google.com>
2018-06-20 17:07:48 +00:00
Cary Clark
4d75975b70 simplify confusing examples
Docs-Preview: https://skia.org/?cl=135785
Bug: skia:6898
Change-Id: Idf5e44817a86accaa628ea5d7abb47cd2b06d048
Reviewed-on: https://skia-review.googlesource.com/135785
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-06-19 19:51:19 +00:00
Cary Clark
929e436c98 fix bookmaker files
make edits compile

Next time, could you put me on the review if you are going to
edit bookmaker files? I'm happy to preflight the changes
to see if they break the bots.

Docs-Preview: https://skia.org/?cl=135703
NOTRY=true
Bug: skia:6898
Change-Id: Iae054f19b131e894f73cedda279ee98af99e8c1c
Reviewed-on: https://skia-review.googlesource.com/135703
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-06-19 13:11:30 +00:00
Ben Wagner
f08d1d0ce1 Stop using SkTSwap.
Use std::swap instead. It does not appear that any external user
specializes SkTSwap, but some may still use it. This removes all use in
Skia so that SkTSwap can later be removed in a smaller CL. After that
the <utility> include can be removed from SkTypes.h.

Change-Id: If03d4ee07dbecda961aa9f0dc34d171ef5168753
Reviewed-on: https://skia-review.googlesource.com/135578
Reviewed-by: Hal Canary <halcanary@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2018-06-19 02:06:31 +00:00
Cary Clark
63132864e9 remove SK_MaxSizeT from docs
match review.skia.org/135180

TBR=bungeman@google.com

Docs-Preview: https://skia.org/?cl=135400
Bug: skia:6898
Change-Id: I0fb50045796447b18d040be04b130cb35fdd6bdb
Reviewed-on: https://skia-review.googlesource.com/135400
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-06-18 11:48:38 +00:00
Cary Clark
5538c13906 docs fix external substitutions
explict substitutions are required to distiguish words
that preserve underscores

R=caryclark@google.com

Docs-Preview: https://skia.org/?cl=134841
Bug: skia:6898
Change-Id: Id1a5669c180e03e048de3c0251882bd06b297283
Reviewed-on: https://skia-review.googlesource.com/134841
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-14 16:54:47 +00:00
Greg Daniel
5f4b09d523 Allow caller to specify if the want mip maps in makeTextureImage call.
Since Ganesh no longer will allocate mips late, this gives the clients a
way to tell skia that they want the texture they will be using to have mips.
It also supports allowing a client to take a non mipped texture backed
image and turn it into a new image which is mipped and texture backed.

Bug: chromium:834837
Change-Id: I1781ce618c22023b6309f248e7ee49e69bd3c6df
Reviewed-on: https://skia-review.googlesource.com/134323
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Eric Karl <ericrk@chromium.org>
Reviewed-by: Cary Clark <caryclark@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2018-06-13 13:55:56 +00:00
Cary Clark
27dddae313 rebase
This reverts commit 32a4910e57.

Reason for revert: SkMatrix::toString use has been removed from flutter
and has been picked up in fuchsia

Additionally some bookmaker changes take into account recent
additions of typedef comments and the generated header comment.

Original change's description:
> Revert "remove toString"
>
> This reverts commit 5191880cbf.
>
> Reason for revert: broke flutter
>
> Original change's description:
> > remove toString
> >
> > toString may have been used by obsolete debugger only
> > find out if that is so
> >
> > R=​brianosman@google.com,bsalomon@google.com
> >
> > Docs-Preview: https://skia.org/?cl=119894
> > Bug:830651
> > Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd
> > Reviewed-on: https://skia-review.googlesource.com/119894
> > Commit-Queue: Cary Clark <caryclark@google.com>
> > Reviewed-by: Brian Salomon <bsalomon@google.com>
>
> TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org
>
> Change-Id: I9f81de6c3615ee0608bcea9081b77239b4b8816c

TBR=bsalomon@google.com,brianosman@google.com

# Not skipping CQ checks because original CL landed > 1 day ago.

Reviewed-on: https://skia-review.googlesource.com/129623
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@google.com>
Docs-Preview: https://skia.org/?cl=133583
Bug: 830651
Change-Id: If8499e796be63580ad419e150e94d43e8b89de1b
Reviewed-on: https://skia-review.googlesource.com/133583
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-08 20:36:53 +00:00
Cary Clark
b94f6da248 fix define comments
add generated comment for includes

R=caryclark@google.com

Docs-Preview: https://skia.org/?cl=132924
Bug: skia:6898
Change-Id: I42034e2753ed079dd0d0e3ae99f976d32ffaf77a
Reviewed-on: https://skia-review.googlesource.com/132924
Reviewed-by: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
2018-06-08 16:31:02 +00:00
Cary Clark
ae957c4f9d switch fiddle examples to call MakeFromTexture with RGBA
R=brianosman@google.com

Docs-Preview: https://skia.org/?cl=133063
Bug: skia:6898
Change-Id: I4fe3c8a2bdf71c851109f01f1b3c121f63421339
NOTRY=true
Reviewed-on: https://skia-review.googlesource.com/133063
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-07 22:08:36 +00:00
Cary Clark
0d225395fa generate SkColor include
bookmaker can now generate SkColor.h
This required adding support for #define, typedef,
global constexpr, and fixing various bugs, like
forward declared structs between comments.

Docs-Preview: https://skia.org/?cl=131260
Bug: skia:6898
TBR=caryclark@google.com
Change-Id: I6bee0c6f5c3a6820b04472a318abde8a2523dbbb
Reviewed-on: https://skia-review.googlesource.com/131260
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-06-07 14:22:38 +00:00
Cary Clark
31cb864fdb work around bug 8051
turn off the example that generates the failing fiddle

Docs-Preview: https://skia.org/?cl=132401
Bug: skia:8051
NOTRY=true
Change-Id: Ic018dbf9ba4f3b7d948660ca2946291ec37f3555
Reviewed-on: https://skia-review.googlesource.com/132401
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-06-06 12:33:06 +00:00
Cary Clark
89ad31e97c Revert "Reland "remove toString""
This reverts commit 92e37b6d79.

Reason for revert: toString still used by flutter

Original change's description:
> Reland "remove toString"
> 
> This reverts commit 32a4910e57.
> 
> Reason for revert: SkMatrix::toString use has been removed from flutter and has been picked up in fuchsia
> 
> Original change's description:
> > Revert "remove toString"
> > 
> > This reverts commit 5191880cbf.
> > 
> > Reason for revert: broke flutter
> > 
> > Original change's description:
> > > remove toString
> > > 
> > > toString may have been used by obsolete debugger only
> > > find out if that is so
> > > 
> > > R=​brianosman@google.com,bsalomon@google.com
> > > 
> > > Docs-Preview: https://skia.org/?cl=119894
> > > Bug:830651
> > > Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd
> > > Reviewed-on: https://skia-review.googlesource.com/119894
> > > Commit-Queue: Cary Clark <caryclark@google.com>
> > > Reviewed-by: Brian Salomon <bsalomon@google.com>
> > 
> > TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org
> > 
> > Change-Id: I9f81de6c3615ee0608bcea9081b77239b4b8816c
> > No-Presubmit: true
> > No-Tree-Checks: true
> > No-Try: true
> > Bug: 830651
> > Reviewed-on: https://skia-review.googlesource.com/129340
> > Reviewed-by: Cary Clark <caryclark@google.com>
> > Commit-Queue: Cary Clark <caryclark@google.com>
> 
> TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org
> 
> # Not skipping CQ checks because original CL landed > 1 day ago.
> 
> Bug: 830651
> Change-Id: Ida8725b6051132d8c46faf99358a8fcc1bcabf34
> Reviewed-on: https://skia-review.googlesource.com/129623
> Reviewed-by: Cary Clark <caryclark@skia.org>
> Reviewed-by: Cary Clark <caryclark@google.com>
> Commit-Queue: Cary Clark <caryclark@google.com>

TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org

Change-Id: Iafc59ffc1b3db67c520ba31bf12d68e1b46c0ea2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 830651
Reviewed-on: https://skia-review.googlesource.com/131082
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
2018-05-31 12:27:44 +00:00
Cary Clark
92e37b6d79 Reland "remove toString"
This reverts commit 32a4910e57.

Reason for revert: SkMatrix::toString use has been removed from flutter and has been picked up in fuchsia

Original change's description:
> Revert "remove toString"
> 
> This reverts commit 5191880cbf.
> 
> Reason for revert: broke flutter
> 
> Original change's description:
> > remove toString
> > 
> > toString may have been used by obsolete debugger only
> > find out if that is so
> > 
> > R=​brianosman@google.com,bsalomon@google.com
> > 
> > Docs-Preview: https://skia.org/?cl=119894
> > Bug:830651
> > Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd
> > Reviewed-on: https://skia-review.googlesource.com/119894
> > Commit-Queue: Cary Clark <caryclark@google.com>
> > Reviewed-by: Brian Salomon <bsalomon@google.com>
> 
> TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org
> 
> Change-Id: I9f81de6c3615ee0608bcea9081b77239b4b8816c
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: 830651
> Reviewed-on: https://skia-review.googlesource.com/129340
> Reviewed-by: Cary Clark <caryclark@google.com>
> Commit-Queue: Cary Clark <caryclark@google.com>

TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: 830651
Change-Id: Ida8725b6051132d8c46faf99358a8fcc1bcabf34
Reviewed-on: https://skia-review.googlesource.com/129623
Reviewed-by: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
2018-05-31 11:43:13 +00:00
Cary Clark
137b874855 generate include comments
- formalize how aliases and substitutions work together
- add constexpr, #define, typedef support
- check for correct description order
- write short enum, struct members

R=caryclark@google.com

Docs-Preview: https://skia.org/?cl=129455
Bug: skia:6898
Change-Id: Id60fc2ed02f38a7ba4e5cad5ef493d8c674e6183
Reviewed-on: https://skia-review.googlesource.com/129455
Commit-Queue: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-05-30 13:46:38 +00:00
Brian Salomon
75bf216c03 Move SkYUVAIndex and SkImageSourceChannel to SkImageInfoPriv.h until used in public API
Change-Id: Ib75be2b6e9eb9b80f1f9e738bc8e3300ddc08f22
Reviewed-on: https://skia-review.googlesource.com/129927
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Cary Clark <caryclark@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2018-05-24 14:14:43 +00:00
Weiliang Chen
bed9d5ec3e Add usage of SkYUVAIndex as pre-step to transfer to new YUVA API
The plan foward is to have a new API on SkImage to make from YUVA
textures which a combination of array of textures and array of
SkYUVAIndex struct indicating which texture and channel to read for
each plane. This is a pre-step to let the old API use these ideas.

Bug: skia: 7903
Change-Id: I6a696db31a574247eb2abff60f2186a74b640142
Reviewed-on: https://skia-review.googlesource.com/128601
Commit-Queue: Weiliang Chen <weiliangc@chromium.org>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2018-05-23 18:50:53 +00:00
Brian Salomon
969be1c98b Remove mask-filters and aa from SkPaint in SkCanvas for nine-patch/lattice.
Remove GPU fallback code which would have applied AA and mask filter
separately to each lattice cell.

Change-Id: I43d50f337d24bb34b94f3d0ea6cca686a2e11a50
Reviewed-on: https://skia-review.googlesource.com/129318
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
2018-05-21 19:10:08 +00:00
Greg Daniel
6d138bf681 Reland "Remove GrBackendObject and all related functions from Skia."
This is a reland of ccd4cfc23e

Original change's description:
> Remove GrBackendObject and all related functions from Skia.
> 
> Bug: skia:
> Change-Id: I59434b7477c0bc26fd982bd81eb97ab94bbba073
> Reviewed-on: https://skia-review.googlesource.com/125822
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Greg Daniel <egdaniel@google.com>

Bug: skia:
Change-Id: Ibd1b9bd04b36840d9d872e2f0970dd6bac378bc9
Reviewed-on: https://skia-review.googlesource.com/129380
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2018-05-21 18:25:38 +00:00
Cary Clark
32a4910e57 Revert "remove toString"
This reverts commit 5191880cbf.

Reason for revert: broke flutter

Original change's description:
> remove toString
> 
> toString may have been used by obsolete debugger only
> find out if that is so
> 
> R=​brianosman@google.com,bsalomon@google.com
> 
> Docs-Preview: https://skia.org/?cl=119894
> Bug:830651
> Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd
> Reviewed-on: https://skia-review.googlesource.com/119894
> Commit-Queue: Cary Clark <caryclark@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>

TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org

Change-Id: I9f81de6c3615ee0608bcea9081b77239b4b8816c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 830651
Reviewed-on: https://skia-review.googlesource.com/129340
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
2018-05-20 23:15:48 +00:00
Cary Clark
5191880cbf remove toString
toString may have been used by obsolete debugger only
find out if that is so

R=brianosman@google.com,bsalomon@google.com

Docs-Preview: https://skia.org/?cl=119894
Bug:830651
Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd
Reviewed-on: https://skia-review.googlesource.com/119894
Commit-Queue: Cary Clark <caryclark@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2018-05-20 21:16:37 +00:00
Cary Clark
dbc90e4387 fix bookmaker typo
Fix one character and update the web documentation.

Docs-Preview: https://skia.org/?cl=128938
TBR=robertphillips@google.com
Bug: skia:6898
Change-Id: I4525ef8d3bae85ef1d63f84ff414a32b9935ae0e
Reviewed-on: https://skia-review.googlesource.com/128938
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-05-18 16:18:24 +00:00
Robert Phillips
8f8d481b44 Add SkIRect::adjust method
Change-Id: Ib18d1a82944524e20d5d72912d8db7a823c470de
Reviewed-on: https://skia-review.googlesource.com/128884
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Cary Clark <caryclark@google.com>
2018-05-18 14:53:45 +00:00
Cary Clark
8f288d9399 fix setBoundsNoCheck example
fix setBoundsNoCheck example

R=caryclark@google.com

Docs-Preview: https://skia.org/?cl=129000
Bug: skia:6898
Change-Id: Ic7ad412089bf21fd4de93f3acbeb50c7efc30a81
Reviewed-on: https://skia-review.googlesource.com/129000
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-05-17 19:43:13 +00:00
Cary Clark
ffb3d688b0 Color Documentation
- treat Color, ARGB, etc as things not requiring definitions
- fix links to Anti-alias, RGB-565
- finish everything marked incomplete, color and elsewhere
- add #Code blocks for #Typedef

R=caryclark@google.com
Docs-Preview: https://skia.org/?cl=128547
Bug: skia:6898
Change-Id: Icf12fe70bc2bf1a8b1a5b31380b2454610949f23
Reviewed-on: https://skia-review.googlesource.com/128547
Reviewed-by: Cary Clark <caryclark@skia.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
2018-05-17 16:45:13 +00:00
Cary Clark
c06754b046 mapRect should not fiddle with nonfinite values.
Docs-Preview: https://skia.org/?cl=128682
Bug: skia:7967
Change-Id: Ic43387b7705ee8385b8df2430886484ff856077c
Reviewed-on: https://skia-review.googlesource.com/128682
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2018-05-17 14:02:43 +00:00
Cary Clark
682c58da48 Documentation refresh
- add links to types within methods
- add check to see that all references and definitions match
- add style to tables to make them easier to read
- use https everywhere
- remove trailing spaces
- move overview inside class
- split class and struct in summary tables
- add missing #Line
- clean up SkImageInfo constant documentation
- work on SkColor documentation
- allow common phrases to take different parameters
- add more flexibility to generated tables
- tighten token parent requirements
- generalize deprecated and example interfaces
- detect inner constructors

R=caryclark@google.com
Docs-Preview: https://skia.org/?cl=121799
Bug: skia:6898
Change-Id: Ia75a23740b80259460916890b310e2a9f024962a
Reviewed-on: https://skia-review.googlesource.com/121799
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-05-16 11:35:24 +00:00
Cary Clark
cc45cc7c17 remove typedef Info
typedef SkImageInfo Info saves a little typing at the cost of
obfuscating the parameter type. It's only used in a couple of
places so remove it.

The documentation catalog has gotten a bit stale, so update
that as well.

Docs-Preview: https://skia.org/?cl=128400
Bug: skia:6898
Change-Id: I621743a2b2d9a78d5f62742501eebf5f4327efa0
Reviewed-on: https://skia-review.googlesource.com/128400
Commit-Queue: Cary Clark <caryclark@skia.org>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2018-05-15 22:04:23 +00:00
Brian Osman
a0ca909142 Revert "Remove GrBackendObject and all related functions from Skia."
This reverts commit ccd4cfc23e.

Reason for revert: Fuchsia not building again. (Flutter roll may have been reverted?)

Original change's description:
> Remove GrBackendObject and all related functions from Skia.
> 
> Bug: skia:
> Change-Id: I59434b7477c0bc26fd982bd81eb97ab94bbba073
> Reviewed-on: https://skia-review.googlesource.com/125822
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Greg Daniel <egdaniel@google.com>

TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com

Change-Id: Ie2c518b84b0c9513c0c622082de2831088b1ad8d
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/127480
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-05-10 22:04:20 +00:00
Greg Daniel
ccd4cfc23e Remove GrBackendObject and all related functions from Skia.
Bug: skia:
Change-Id: I59434b7477c0bc26fd982bd81eb97ab94bbba073
Reviewed-on: https://skia-review.googlesource.com/125822
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2018-05-10 14:44:55 +00:00
Ben Wagner
d813f9cdc7 Remove SkPaint::Flags::kDevKernFlag.
It isn't used any more.

Change-Id: I79fbbac13bb2595da0ae0cea7e42bca8fcccd8e8
Reviewed-on: https://skia-review.googlesource.com/127127
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2018-05-09 21:27:11 +00:00
Herb Derby
fcac00f2f1 Reland "Remove devKerning"
This is a reland of c86c5c0144

Original change's description:
> Remove devKerning
> 
> Dev kerning is not supported by any scalers. This is
> mostly removed. The remaining fields fRsbDelta and
> fLsbDelta are kept to keep Android compiling.
> 
> Change-Id: If1a9ee9bb599d4e1bdf4b3751ac0c65246350809
> Reviewed-on: https://skia-review.googlesource.com/124921
> Reviewed-by: Ben Wagner <bungeman@google.com>
> Commit-Queue: Herb Derby <herb@google.com>

Change-Id: Ibf5fac5f1442c7e62392d5146ad460da27b10d5c
Reviewed-on: https://skia-review.googlesource.com/125300
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2018-05-02 15:15:08 +00:00
Herb Derby
efe39bcfb8 Take sk_sp<SkDevice> instead of SkDevice*
Change-Id: I0b296bf5b80adc19758a3dc99160be9d2ed05680
Reviewed-on: https://skia-review.googlesource.com/125160
Commit-Queue: Herb Derby <herb@google.com>
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Auto-Submit: Herb Derby <herb@google.com>
2018-05-02 14:46:17 +00:00
Mike Klein
c76e26a6bb Revert "Remove devKerning"
This reverts commit c86c5c0144.

Reason for revert: 4 of 5

Original change's description:
> Remove devKerning
> 
> Dev kerning is not supported by any scalers. This is
> mostly removed. The remaining fields fRsbDelta and
> fLsbDelta are kept to keep Android compiling.
> 
> Change-Id: If1a9ee9bb599d4e1bdf4b3751ac0c65246350809
> Reviewed-on: https://skia-review.googlesource.com/124921
> Reviewed-by: Ben Wagner <bungeman@google.com>
> Commit-Queue: Herb Derby <herb@google.com>

TBR=bungeman@google.com,herb@google.com,reed@google.com

Change-Id: If865f702868192a1b72cd811baa996dd1282bbce
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/125263
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2018-05-02 13:54:54 +00:00
Herb Derby
c86c5c0144 Remove devKerning
Dev kerning is not supported by any scalers. This is
mostly removed. The remaining fields fRsbDelta and
fLsbDelta are kept to keep Android compiling.

Change-Id: If1a9ee9bb599d4e1bdf4b3751ac0c65246350809
Reviewed-on: https://skia-review.googlesource.com/124921
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2018-05-01 21:12:15 +00:00
Cary Clark
36122e74c1 remove GrBackendObject from example fiddles
R=robertphillips@google.com

Docs-Preview: https://skia.org/?cl=123930
Bug: skia:6898
Change-Id: If579d0e0c0323a86d6ab86056b36f8660cbbde6f
Reviewed-on: https://skia-review.googlesource.com/123930
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Cary Clark <caryclark@skia.org>
2018-04-26 21:11:53 +00:00
Cary Clark
d98f78cd01 alternative no anonymous enums
Anonymous enums play havoc with documentation;
there's no name to refer to. It may be that all
enums may either be named or replaced with constexpr
without breaking anything. Try replacing all
anonymous enums in include/core to see what happens.

This names SkCanvas::SaveLayerFlagsSet but leaves
SkCanvas::SaveLayerFlags as a uint32_t, to reduce
risk as compared to review.skia.org/123584.

There's also some chance that external linkage will
break if some client refers to anonymous enum in a way
that could require its address: see
https://stackoverflow.com/questions/22867654/enum-vs-constexpr-for-actual-static-constants-inside-classes
(This CL does not require definitions + declarations)

Brought bookmaker docs in line with this change.
This also tripped over missing code in bookmaker
handling constexpr so added that as well.

R=reed@google.com,bsalomon@google.com

Docs-Preview: https://skia.org/?cl=123920
Docs-Preview: https://skia.org/?cl=123584
Bug: skia:6898
Change-Id: I14a342edcfd59e139ef9e4501f562417c4c60391
Reviewed-on: https://skia-review.googlesource.com/123920
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Cary Clark <caryclark@skia.org>
2018-04-26 17:11:53 +00:00
Mike Reed
910ca0fd01 Experiment to track coverage in a layer
Bug: skia:
Change-Id: I5ed334f63e64991944394dc8103092a2c6280546
Reviewed-on: https://skia-review.googlesource.com/122000
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2018-04-25 17:34:27 +00:00
Ben Wagner
d234afdc2e Remove SkPaint::kGenA8FromLCD_Flag.
The original intent of this flag is now handled by SkPixelGeomety on
SkSurfaceProps on SkSurface.

BUG=skia:7515

Change-Id: I54bb1be072b5b5b2164a59196bfeacac254823c7
Reviewed-on: https://skia-review.googlesource.com/121346
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2018-04-16 21:11:10 +00:00
Cary Clark
2d4bf5f288 document SkColor.h
SkColor.h uses #define liberally, and has many global symbols,
two things bookmaker hasn't seen in other includes.

Revised .h -> .bmh converter to work with SkColor.h as well
as updating how .bmh indices are built.

Generated SkColor_Reference.bmh for globals, and
SkColor4f_Reference.bmh for class.

Other than the existing comments, this doesn't update the
documentation or add new examples.

Docs-Preview: https://skia.org/?cl=118985
TBR=caryclark@google.com
Bug: skia:6898
Change-Id: I5978257ee0e51319823efbe8dfc467a08c99ffe0
Reviewed-on: https://skia-review.googlesource.com/118985
Commit-Queue: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-04-16 16:26:20 +00:00
Greg Daniel
7444c3c518 Revert "Delete getRenderTargetHandle call on SkSurface."
This reverts commit c828109ebd.

Reason for revert: Need to fix flutter

Original change's description:
> Delete getRenderTargetHandle call on SkSurface.
> 
> All clients and internal code should be switched (once changes land soon)
> to the new getBackendRenderTarget call instead.
> 
> Bug: skia:
> Change-Id: I6f490b6d26a72f37f97216be04e541483206510d
> Reviewed-on: https://skia-review.googlesource.com/121103
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Greg Daniel <egdaniel@google.com>

TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: skia:
Change-Id: I571298f839757fcdedcd8117519e740ac7ef1344
Reviewed-on: https://skia-review.googlesource.com/121480
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2018-04-14 18:08:12 +00:00