summaryrefslogtreecommitdiff
path: root/src/gallium/state_trackers/python/p_context.i
diff options
context:
space:
mode:
authorJosé Fonseca <jrfonseca@tungstengraphics.com>2008-09-04 09:33:10 +0900
committerJosé Fonseca <jrfonseca@tungstengraphics.com>2008-09-04 09:38:23 +0900
commit78435d9142b4762cdf7193729bcd3148d990de3d (patch)
treeaa9770c6cb8ea0f5177e88484f0932c7b466a550 /src/gallium/state_trackers/python/p_context.i
parenta3e39a4aa950ae0f9d4c3106bdf438c6529bd63c (diff)
python: Use pipe_buffer_* inlines as much as possible.
Diffstat (limited to 'src/gallium/state_trackers/python/p_context.i')
-rw-r--r--src/gallium/state_trackers/python/p_context.i16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/gallium/state_trackers/python/p_context.i b/src/gallium/state_trackers/python/p_context.i
index 231e07cd63..1fdcec639f 100644
--- a/src/gallium/state_trackers/python/p_context.i
+++ b/src/gallium/state_trackers/python/p_context.i
@@ -225,30 +225,30 @@ struct st_context {
const float *vertices)
{
struct pipe_context *pipe = $self->pipe;
- struct pipe_winsys *winsys = pipe->winsys;
+ struct pipe_screen *screen = pipe->screen;
struct pipe_buffer *vbuf;
float *map;
unsigned size;
size = num_verts * num_attribs * 4 * sizeof(float);
- vbuf = winsys->buffer_create(winsys,
- 32,
- PIPE_BUFFER_USAGE_VERTEX,
- size);
+ vbuf = pipe_buffer_create(screen,
+ 32,
+ PIPE_BUFFER_USAGE_VERTEX,
+ size);
if(!vbuf)
goto error1;
- map = winsys->buffer_map(winsys, vbuf, PIPE_BUFFER_USAGE_CPU_WRITE);
+ map = pipe_buffer_map(screen, vbuf, PIPE_BUFFER_USAGE_CPU_WRITE);
if (!map)
goto error2;
memcpy(map, vertices, size);
- pipe->winsys->buffer_unmap(pipe->winsys, vbuf);
+ pipe_buffer_unmap(screen, vbuf);
util_draw_vertex_buffer(pipe, vbuf, prim, num_verts, num_attribs);
error2:
- pipe_buffer_reference(pipe->screen, &vbuf, NULL);
+ pipe_buffer_reference(screen, &vbuf, NULL);
error1:
;
}