hey,

> I want to load a image from the memory(a point got from xmmsv_get_bin), So,
> is there a API just like
> gdk_pixbuf_loader_write<GdkPixbufLoader.html#gdk-pixbuf-loader-write>

Without more info of what you want to do, here is what i would do:

Once you have an evas:

void *data;  /* your image data */
int width;   /* width of your image */
int height   /* height of your image */

Evas_Object *o;
void *o_data; /* data of the evas object */

o = evas_object_image_add(evas);
evas_object_image_size_set(o, width, height);
evas_object_image_fill_set(o, 0, 0, width, height);
o_data = evas_object_image_data_get(o, 1);
if (!o_data)
{
   /* manage the error */
}

memcpy (o_data, data, height * width * 4);
evas_object_image_data_set(o, o_data);
evas_object_image_data_update_add(o, 0, 0, width, height);
evas_object_resize(o, width, height);

You then have to show the evas object to make it visible on the canvas.

Vincent Torri

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to