diff options
author | Nicolai Hähnle <[email protected]> | 2017-10-22 17:38:47 +0200 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2017-11-09 13:58:16 +0100 |
commit | ea6df1ce37a53f039a28782114062b1ab7cebab4 (patch) | |
tree | a9c77f5a13f45f14d0c20d7d84e16071b1246449 /src/gallium/include/pipe | |
parent | e3a8013de8ca854d21225be00f123ccf63f9060f (diff) |
gallium: add PIPE_FLUSH_ASYNC and PIPE_FLUSH_HINT_FINISH
Also document some subtleties of pipe_context::flush.
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/include/pipe')
-rw-r--r-- | src/gallium/include/pipe/p_context.h | 8 | ||||
-rw-r--r-- | src/gallium/include/pipe/p_defines.h | 2 |
2 files changed, 9 insertions, 1 deletions
diff --git a/src/gallium/include/pipe/p_context.h b/src/gallium/include/pipe/p_context.h index 087836d1c0c..d9228e4fc92 100644 --- a/src/gallium/include/pipe/p_context.h +++ b/src/gallium/include/pipe/p_context.h @@ -469,7 +469,13 @@ struct pipe_context { int clear_value_size); /** - * Flush draw commands + * Flush draw commands. + * + * This guarantees that the new fence (if any) will finish in finite time, + * unless PIPE_FLUSH_DEFERRED is used. + * + * Subsequent operations on other contexts of the same screen are guaranteed + * to execute after the flushed commands, unless PIPE_FLUSH_ASYNC is used. * * NOTE: use screen->fence_reference() (or equivalent) to transfer * new fence ref to **fence, to ensure that previous fence is unref'd diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h index ddc951464b9..776a879e0a6 100644 --- a/src/gallium/include/pipe/p_defines.h +++ b/src/gallium/include/pipe/p_defines.h @@ -352,6 +352,8 @@ enum pipe_flush_flags PIPE_FLUSH_END_OF_FRAME = (1 << 0), PIPE_FLUSH_DEFERRED = (1 << 1), PIPE_FLUSH_FENCE_FD = (1 << 2), + PIPE_FLUSH_ASYNC = (1 << 3), + PIPE_FLUSH_HINT_FINISH = (1 << 4), }; /** |