Added GrMeshDrawOp::WriteVertexData

This is a utility to make vertex generation code in ops simpler and more
consistent. Some existing ops use tricks that may not translate well,
but most will. It enforces writing in-order, leverages templates to
handle sizing and variable numbers of arguments.

For now, I used it to update three ops, showing a relatively simple
case, and a more thorough refactor (of the CircleOp). I think this makes
a stronger case for the GP changes that make stride fast enough for
non-debug use -- most ops won't even need a struct anymore, they can ask
the GP for stride, then use the WriteVertexData utility to write out
data matching the attribute layout.

Bug: skia:
Change-Id: Iec649803181ec5064b4fb9692ae68e6424758944
Reviewed-on: https://skia-review.googlesource.com/c/169340
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
4 files changed