diff options
author | Axel Davy <[email protected]> | 2016-12-01 22:44:06 +0100 |
---|---|---|
committer | Axel Davy <[email protected]> | 2016-12-20 23:47:08 +0100 |
commit | a78b5f437865fc976154d226eb87b67ef2f098d2 (patch) | |
tree | 54329bcc2f761e379da675605199c1e587e32c81 /src/gallium | |
parent | 1843e36b03ed04d24a8baaac81eda3a84e676c72 (diff) |
st/nine: Implement nine_context_range_upload
Will be used to upload buffers.
Signed-off-by: Axel Davy <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/state_trackers/nine/nine_state.c | 11 | ||||
-rw-r--r-- | src/gallium/state_trackers/nine/nine_state.h | 8 |
2 files changed, 19 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/nine/nine_state.c b/src/gallium/state_trackers/nine/nine_state.c index d09dabc34c8..57a5c746642 100644 --- a/src/gallium/state_trackers/nine/nine_state.c +++ b/src/gallium/state_trackers/nine/nine_state.c @@ -2692,6 +2692,17 @@ CSMT_ITEM_NO_WAIT(nine_context_clear_render_target, context->pipe->clear_render_target(context->pipe, surf, &rgba, x, y, width, height, false); } +CSMT_ITEM_NO_WAIT_WITH_COUNTER(nine_context_range_upload, + ARG_BIND_RES(struct pipe_resource, res), + ARG_VAL(unsigned, offset), + ARG_VAL(unsigned, size), + ARG_VAL(const void *, data)) +{ + struct nine_context *context = &device->context; + + context->pipe->buffer_subdata(context->pipe, res, 0, offset, size, data); +} + struct pipe_query * nine_context_create_query(struct NineDevice9 *device, unsigned query_type) { diff --git a/src/gallium/state_trackers/nine/nine_state.h b/src/gallium/state_trackers/nine/nine_state.h index 6578be363c1..c0afbe0c8bf 100644 --- a/src/gallium/state_trackers/nine/nine_state.h +++ b/src/gallium/state_trackers/nine/nine_state.h @@ -539,6 +539,14 @@ nine_context_clear_render_target(struct NineDevice9 *device, UINT width, UINT height); +void +nine_context_range_upload(struct NineDevice9 *device, + unsigned *counter, + struct pipe_resource *res, + unsigned offset, + unsigned size, + const void *data); + struct pipe_query * nine_context_create_query(struct NineDevice9 *device, unsigned query_type); |