Commit Graph

7 Commits

Author SHA1 Message Date
Brian Salomon
f9a1fdf01f Reland "Add flush() to SkImage."
This reverts commit 693bc2bae5.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Revert "Add flush() to SkImage."
>
> This reverts commit d0503a72ac.
>
> Reason for revert: <INSERT REASONING HERE>
>
> Original change's description:
> > Add flush() to SkImage.
> >
> > This allows a client to ensure all uses of a texture-backed image have
> > been flushed.
> >
> > Does nothing if the image isn't texture-backed.
> >
> > The implementation adds support for triggering a flush if any of a set
> > of proxies are used rather than just a single proxy.
> >
> > Change-Id: I358882d9737e63c6e69b924c0767f49b8f8f36ec
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212405
> > Commit-Queue: Brian Salomon <bsalomon@google.com>
> > Reviewed-by: Robert Phillips <robertphillips@google.com>
>
> TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com
>
> Change-Id: Ie376bf4225307f45b8fb3eb4a63bf84702365797
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212884
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Brian Salomon <bsalomon@google.com>

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

Change-Id: Idcba378ce2e3af0af9d0eef35737670055539ec5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212960
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-05-09 15:07:51 +00:00
Brian Salomon
693bc2bae5 Revert "Add flush() to SkImage."
This reverts commit d0503a72ac.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Add flush() to SkImage.
> 
> This allows a client to ensure all uses of a texture-backed image have
> been flushed.
> 
> Does nothing if the image isn't texture-backed.
> 
> The implementation adds support for triggering a flush if any of a set
> of proxies are used rather than just a single proxy.
> 
> Change-Id: I358882d9737e63c6e69b924c0767f49b8f8f36ec
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212405
> Commit-Queue: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Robert Phillips <robertphillips@google.com>

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

Change-Id: Ie376bf4225307f45b8fb3eb4a63bf84702365797
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212884
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2019-05-09 13:48:08 +00:00
Brian Salomon
d0503a72ac Add flush() to SkImage.
This allows a client to ensure all uses of a texture-backed image have
been flushed.

Does nothing if the image isn't texture-backed.

The implementation adds support for triggering a flush if any of a set
of proxies are used rather than just a single proxy.

Change-Id: I358882d9737e63c6e69b924c0767f49b8f8f36ec
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212405
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-05-09 13:36:07 +00:00
Brian Salomon
b0d8b76c4f Make finish flush procs work with GL.
This will be required for async readback support.

This is implemented using sync objects when available and otherwise
calls glFinish.

Relaxes the unit test requirement that providing a callback with no
work to flush always calls the proc immediately.

Bug: skia:8962
Change-Id: Ieefcab6dccc3924e50260343f01904e7303bb12b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/212198
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-05-07 10:35:38 +00:00
Mike Klein
c0bd9f9fe5 rewrite includes to not need so much -Ifoo
Current strategy: everything from the top

Things to look at first are the manual changes:

   - added tools/rewrite_includes.py
   - removed -Idirectives from BUILD.gn
   - various compile.sh simplifications
   - tweak tools/embed_resources.py
   - update gn/find_headers.py to write paths from the top
   - update gn/gn_to_bp.py SkUserConfig.h layout
     so that #include "include/config/SkUserConfig.h" always
     gets the header we want.

No-Presubmit: true
Change-Id: I73a4b181654e0e38d229bc456c0d0854bae3363e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/209706
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Hal Canary <halcanary@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2019-04-24 16:27:11 +00:00
Greg Daniel
e6bfb7daf0 Add struct to wrap all the gpu flush options.
Bug: skia:8802
Change-Id: Ia92807034a8f54067cead59e29c233f91e11f175
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/208674
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-04-17 20:03:29 +00:00
Greg Daniel
a3aa75ab29 Add callback to flush for knowing when gpu is finished work.
Bug: skia:8802
Change-Id: I093c2a4e879b635b169a849d9af3e9f7a3d84a88
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/207870
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-04-15 13:52:28 +00:00