CVSROOT: /sources/classpath Module name: classpath Changes by: Sven de Marothy <smarothy> 06/06/13 15:59:36
Modified files: . : ChangeLog gnu/java/awt/peer/gtk: CairoSurface.java native/jni/gtk-peer: gnu_java_awt_peer_gtk_CairoSurface.c Log message: 2006-06-13 Sven de Marothy <[EMAIL PROTECTED]> * gnu/java/awt/peer/gtk/CairoSurface.java * native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c (create): Use stride in ints. CVSWeb URLs: http://cvs.savannah.gnu.org/viewcvs/classpath/ChangeLog?cvsroot=classpath&r1=1.7798&r2=1.7799 http://cvs.savannah.gnu.org/viewcvs/classpath/gnu/java/awt/peer/gtk/CairoSurface.java?cvsroot=classpath&r1=1.9&r2=1.10 http://cvs.savannah.gnu.org/viewcvs/classpath/native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c?cvsroot=classpath&r1=1.19&r2=1.20 Patches: Index: ChangeLog =================================================================== RCS file: /sources/classpath/classpath/ChangeLog,v retrieving revision 1.7798 retrieving revision 1.7799 diff -u -b -r1.7798 -r1.7799 --- ChangeLog 13 Jun 2006 15:17:07 -0000 1.7798 +++ ChangeLog 13 Jun 2006 15:59:35 -0000 1.7799 @@ -1,3 +1,9 @@ +2006-06-13 Sven de Marothy <[EMAIL PROTECTED]> + + * gnu/java/awt/peer/gtk/CairoSurface.java + * native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c + (create): Use stride in ints. + 2006-06-13 Keith Seitz <[EMAIL PROTECTED]> From Kyle Galloway <[EMAIL PROTECTED]>: Index: gnu/java/awt/peer/gtk/CairoSurface.java =================================================================== RCS file: /sources/classpath/classpath/gnu/java/awt/peer/gtk/CairoSurface.java,v retrieving revision 1.9 retrieving revision 1.10 diff -u -b -r1.9 -r1.10 --- gnu/java/awt/peer/gtk/CairoSurface.java 12 Jun 2006 10:32:44 -0000 1.9 +++ gnu/java/awt/peer/gtk/CairoSurface.java 13 Jun 2006 15:59:36 -0000 1.10 @@ -88,7 +88,7 @@ /** * Allocates and clears the buffer and creates the cairo surface. * @param width, height - the image size - * @param stride - the buffer row stride. + * @param stride - the buffer row stride. (in ints) */ private native void create(int width, int height, int stride); @@ -146,7 +146,7 @@ * The format will be ARGB32 with premultiplied alpha and native bit * and word ordering. */ - CairoSurface(int width, int height) + public CairoSurface(int width, int height) { super(DataBuffer.TYPE_INT, width * height); @@ -156,7 +156,7 @@ this.width = width; this.height = height; - create(width, height, width * 4); + create(width, height, width); if(surfacePointer == 0 || bufferPointer == 0) throw new Error("Could not allocate bitmap."); @@ -176,7 +176,7 @@ width = image.width; height = image.height; - create(width, height, width * 4); + create(width, height, width); if(surfacePointer == 0 || bufferPointer == 0) throw new Error("Could not allocate bitmap."); Index: native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c =================================================================== RCS file: /sources/classpath/classpath/native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c,v retrieving revision 1.19 retrieving revision 1.20 diff -u -b -r1.19 -r1.20 --- native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c 12 Jun 2006 10:32:44 -0000 1.19 +++ native/jni/gtk-peer/gnu_java_awt_peer_gtk_CairoSurface.c 13 Jun 2006 15:59:36 -0000 1.20 @@ -64,7 +64,7 @@ setNativeObject(env, obj, data, BUFFER); surface = cairo_image_surface_create_for_data - (data, CAIRO_FORMAT_ARGB32, width, height, stride); + (data, CAIRO_FORMAT_ARGB32, width, height, stride * 4); setNativeObject(env, obj, surface, SURFACE); }