From: José Fonseca Date: Mon, 14 Jul 2008 02:44:21 +0000 (+0900) Subject: python: Surface clears. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f07ad529af96b903e7b19fa26c3372d16b507bf1;p=mesa.git python: Surface clears. --- diff --git a/src/gallium/state_trackers/python/gallium.i b/src/gallium/state_trackers/python/gallium.i index 6e355b79757..f616037ec2f 100644 --- a/src/gallium/state_trackers/python/gallium.i +++ b/src/gallium/state_trackers/python/gallium.i @@ -367,7 +367,7 @@ error1: $self->pipe->surface_fill($self->pipe, dst, x, y, width, height, value); } - void clear(struct pipe_surface *surface, unsigned value) { + void surface_clear(struct pipe_surface *surface, unsigned value = 0) { $self->pipe->clear($self->pipe, surface, value); } diff --git a/src/gallium/state_trackers/python/samples/simple.py b/src/gallium/state_trackers/python/samples/simple.py index 6e90eec28ae..10742db0dc0 100644 --- a/src/gallium/state_trackers/python/samples/simple.py +++ b/src/gallium/state_trackers/python/samples/simple.py @@ -142,6 +142,8 @@ def test(dev): #fs.dump() ctx.set_fragment_shader(fs) + ctx.surface_clear(surface, 0x00ff0000) + if 0: nverts = 4 nattrs = 1