Implement stencil-based path/region clipping
This patch is primarily focused on API and correctness.
The implementation is not fully optimized. The API is
marked as \internal, since it does expose implementation
details, and there are significant limitations. One
inherent limitation is that stencil clipping cannot
support antialiasing.
The stencil is treated more like a render
target, so save/restore does not affect stencil clipping.
Multiple stencil clipping draws will be intersected, and
painter transforms are respected.
Path clipping supports both winding and even-odd fill
rules, but all sub-paths need to be convex, since no
actual triangulation is performed.
Change-Id: Ia6a1f322f3100f9efc822473479dba58b55743c6
Reviewed-by: Owais Akhtar <owais.akhtar@qt.io>
Reviewed-by: Kaj Grönholm <kaj.gronholm@qt.io>