diff options
author | Nicolai Hähnle <[email protected]> | 2016-01-12 09:29:18 -0500 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2016-01-14 09:41:24 -0500 |
commit | e976860638c6fb9f69b9cf3a82acaba55c08e274 (patch) | |
tree | f8a11602169358e460a607781b7c843606fbe7a8 /src/gallium/drivers/radeon/radeon_winsys.h | |
parent | 321140d563730b210e6390c5b73c09fdcf9649af (diff) |
gallium/radeon: do not reallocate user memory buffers
The whole point of AMD_pinned_memory is that applications don't have to map
buffers via OpenGL - but they're still allowed to, so make sure we don't break
the link between buffer object and user memory unless explicitly instructed
to.
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeon/radeon_winsys.h')
-rw-r--r-- | src/gallium/drivers/radeon/radeon_winsys.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeon/radeon_winsys.h b/src/gallium/drivers/radeon/radeon_winsys.h index 4af6a1877bf..ad304747eab 100644 --- a/src/gallium/drivers/radeon/radeon_winsys.h +++ b/src/gallium/drivers/radeon/radeon_winsys.h @@ -530,6 +530,14 @@ struct radeon_winsys { void *pointer, unsigned size); /** + * Whether the buffer was created from a user pointer. + * + * \param buf A winsys buffer object + * \return whether \p buf was created via buffer_from_ptr + */ + bool (*buffer_is_user_ptr)(struct pb_buffer *buf); + + /** * Get a winsys handle from a winsys buffer. The internal structure * of the handle is platform-specific and only a winsys should access it. * |