|
GdkPixmap* mPixmap = ::gdk_pixmap_new(window, mWidth, mHeight, 32);
GdkPixbuf* pixbuf =
::gdk_pixbuf_get_from_drawable(NULL, mPixmap,
::gdk_colormap_get_system(),
x, y, 0, 0, width, height); //到这一步程序crash
unsigned char* pixels = ::gdk_pixbuf_get_pixels(pixbuf);
memset(pixels, 0, width*height);
请问还有其他办法吗?多谢 |
|