Pixbuff::get_pixels() image format.
- From: "Evgeny Repekto" <repekto argosoft gmail com>
- To: gtkmm-list gnome org
- Subject: Pixbuff::get_pixels() image format.
- Date: Mon, 4 Sep 2006 14:55:11 +0500
For more efficiency I wished to put raw image data to the Pixbuff directly.
I have raw image data in this format:
"RGBRGBRGB..." - stirng of unsigned char, the length of the string is
(image height)x(image width)x3I guess it's famous type of image storing.
I used memcpy function to put my image to the pixbuff. I got the pointer to
the raw image data of Pixbuff by using get_pizels() method of Pixbuff.
But after I have shown the Pixbuff I saw strange image. After some time
of exploring, I got the idea, that I should put image this way
for (unsigned int i=0; i<mPicHeight; i++)
What is this strange amount of information (i*4*3)? What for it?
I tried to found the image format but I could not. As it said in the
"guint8* Gdk::Pixbuf::get_pixels ()const
Queries a pointer to the pixel data of a pixbuf.
Returns:A pointer to the pixbuf's pixel data. Please see <xref
linkend="image-data"/> for information about how the pixel data is
stored in memory. "
What this means <xref linkend="image-data"/>?
Please, answer who knows, or has any ideas. I need to know the format for sure.
] [Thread Prev