Re: problems with WinXP, Dev-Cpp and GTK+



I have developped Gtk+ app on Linux and MSWins.
On Linux, I did not have any big problems even threads.
On Win32, I had some trial and errors because I was a newbie on MSwin programming.
Now DevCpp is fine but to me win32 Gtk+ have bugs.

I found g_idle_add() and posted it Apr/13/2004 but still Gtk+ is not updated as I know.

multi_vdo_display()
{

.....
  gdk_threads_enter();
  gdk_draw_rgb_image();
  gdk_threads_leave();
....
}

Thread_vdo_display()
{

.....
 g_idle_add (multi_vdo_display, data);
....
}

main()
{
gtk_init();
...
 functions to build buttons
...

 for (i=0; i<20; i++)
   pthread_create (.., Thread_vdo_display, ..);

 gdk_threads_enter();
 gtk_main();
 gdk_threads_leave();

}

It does not have thread problems but consumes 99 % of CPU computing
powers and leaks memory spaces as if I did not do free().
I knew by process administrator (Ctrl + Alt + Del keying on window).
Also the responses of button toggling are so slow.

What did I do wrong?
May I say that the function g_idle_add() on MSWindows has bugs?
Really Win32 Gtk+ is not for multiple video displaying yet?

Please let me know where I can get the Gtk+ source and how to compile on Win32.
I prefer Gtk+1.2 but Gtk+2.x are fine.


I would say Dev-Cpp and Gtk+ both of them are not perfect but we can make better.

How about g_idle_add() on Win32 Gtk+ 1.2 or 2.x?


bkna.




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