python: Raw tile access to surface.
authorJosé Fonseca <jrfonseca@tungstengraphics.com>
Mon, 14 Jul 2008 13:26:40 +0000 (22:26 +0900)
committerJosé Fonseca <jrfonseca@tungstengraphics.com>
Mon, 14 Jul 2008 13:26:40 +0000 (22:26 +0900)
src/gallium/state_trackers/python/gallium.i

index f616037..60f8e50 100644 (file)
@@ -55,6 +55,7 @@
 %}
 
 %include "carrays.i"
+%array_class(unsigned char, ByteArray);
 %array_class(int, IntArray);
 %array_class(float, FloatArray);
 
@@ -406,6 +407,16 @@ error1:
    void unmap( void );
 
    void
+   get_tile_raw(unsigned x, unsigned y, unsigned w, unsigned h, unsigned char *p, unsigned stride) {
+      pipe_get_tile_raw($self, x, y, w, h, p, stride);
+   }
+
+   void
+   put_tile_raw(unsigned x, unsigned y, unsigned w, unsigned h, const unsigned char *p, unsigned stride) {
+      pipe_put_tile_raw($self, x, y, w, h, p, stride);
+   }
+
+   void
    get_tile_rgba(unsigned x, unsigned y, unsigned w, unsigned h, float *p) {
       pipe_get_tile_rgba($self, x, y, w, h, p);
    }