summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r600/r600_texture.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/r600/r600_texture.h')
-rw-r--r--src/gallium/drivers/r600/r600_texture.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/gallium/drivers/r600/r600_texture.h b/src/gallium/drivers/r600/r600_texture.h
index a4424161eb..9bc08d6b04 100644
--- a/src/gallium/drivers/r600/r600_texture.h
+++ b/src/gallium/drivers/r600/r600_texture.h
@@ -26,21 +26,28 @@
#include <pipe/p_state.h>
struct r600_texture {
- struct pipe_texture tex;
+ struct u_resource b;
unsigned long offset[PIPE_MAX_TEXTURE_LEVELS];
unsigned long pitch[PIPE_MAX_TEXTURE_LEVELS];
unsigned long stride[PIPE_MAX_TEXTURE_LEVELS];
unsigned long layer_size[PIPE_MAX_TEXTURE_LEVELS];
unsigned long stride_override;
unsigned long size;
- struct pipe_buffer *buffer;
+ struct pipe_resource *buffer;
};
+struct pipe_resource *r600_texture_create(struct pipe_screen *screen,
+ const struct pipe_resource *templ);
unsigned long r600_texture_get_offset(struct r600_texture *rtex, unsigned level, unsigned zslice, unsigned face);
+struct pipe_resource *r600_texture_from_handle(struct pipe_screen *screen,
+ const struct pipe_resource *base,
+ struct winsys_handle *whandle);
void r600_init_screen_texture_functions(struct pipe_screen *screen);
-boolean r600_get_texture_buffer(struct pipe_screen *screen,
- struct pipe_texture *texture,
- struct pipe_buffer **buffer,
- unsigned *stride);
+
+/* This should be implemented by winsys. */
+boolean r600_buffer_get_handle(struct radeon *rw,
+ struct pipe_resource *buf,
+ struct winsys_handle *whandle);
+
#endif