GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Wed Apr 23, 2014 5:43 pm

All times are UTC




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: Problem in gif image color
PostPosted: Wed Aug 07, 2013 1:15 pm 
Offline
Familiar Face

Joined: Wed Jan 23, 2013 5:18 pm
Posts: 23
Hi,

I am trying to display a gif image on lcd screen with gtk application but for some reason the colors are not coming up as expected.
when i try to display the .xpm format image the images are perfect with right colors on display, but still i need a gif file to run my animation.

My code snippet :
Code:
GtkImage *image1;
GtkImage *image2;
GdkPixbufAnimation * animation;

/*gif image display in image1*/
animation = gdk_pixbuf_animation_new_from_file ("my.gif", NULL);
gtk_image_set_from_animation (GTK_IMAGE(image1), animation);

/*xpm image display in image2*/
gtk_image_set_from_file(image2, "icon.xpm");

image2(icon.xpm) has the right colors on display and image1(my.gif) comes with wrong colors and also blank for some colors.

I also tried changing the RGB format of gif file to BGR , BRG, GBR ,GRB using irfan view tool, but no luck.

I am using GTK 2.14.19 with framebuffer backend in my target.
Please let me know where I am wrong in my code

_________________
Thanks,
Arief.
None of us is stronger than all of us


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group