XImage *XCreateImage(display, visual, depth, format, offset, data, width, height, bitmap_pad,
bytes_per_line)
Display *display;
Visual *visual;
unsigned int depth;
int format;
int offset;
char *data;
unsigned int width;
unsigned int height;
int bitmap_pad;
int bytes_per_line;
display | Specifies the connection to the X server. |
visual | Specifies the Visual structure. |
depth | Specifies the depth of the image. |
format | Specifies the format for the image. You can pass XYBitmap, XYPixmap, or ZPixmap. |
offset | Specifies the number of pixels to ignore at the beginning of the scanline. |
data | Specifies the image data. |
width | Specifies the width of the image, in pixels. |
height | Specifies the height of the image, in pixels. |
bitmap_pad | Specifies the quantum of a scanline (8, 16, or 32). In other words, the start of one scanline is separated in client memory from the start of the next scanline by an integer multiple of this many bits. |
bytes_per_line | Specifies the number of bytes in the client image between the start of one scanline and the start of the next. |
Note that when the image is created using XCreateImage(), XGetImage(), or XSubImage(), the destroy procedure that the XDestroyImage() function calls frees both the image structure and the data pointed to by the image structure.