Re: problem displaying rgb images on window



On Wed, Jul 26, 2006 at 09:35:25AM +0530, sachin kamat wrote:
...
> while(!feof(fp))
> {
>     decode(); //decodes one frame of mp4 data to yuv format
>     convert_yuv_to_rgb(); //converts one frame of decoded  yuv data to rgb format
> 
>     /* Iam using the following code to render the rgb data on display window */
> 
>     pixbuf = gdk_pixbuf_new_from_data(rgb_buffer, 0, 0, 8, width, height, width, NULL, NULL);
> 
>     gtk_image_set_from_pixbuf(image_display, pixbuf);
> 
>     gtk_widget_show_all(display_window); //image_display is contained in this window
> 
>     g_object_unref(pixbuf);
> 
     /* have you tried adding this? */
     while(  gtk_events_pending() )
         gtk_main_iteration();
> }

sort of hard to tell what's going on because "fp" isn't used.  is fp a
global that decode() reads?

- Anna




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]