Re: gtkmm 3.4.0 (gtk 3.4.2) multithread app graphic deterioration
- From: Chris Vine <chris cvine freeserve co uk>
- To: Giuseppe Penone <giuspen gmail com>
- Cc: Gtkmm list <gtkmm-list gnome org>
- Subject: Re: gtkmm 3.4.0 (gtk 3.4.2) multithread app graphic deterioration
- Date: Sun, 8 Jul 2012 09:25:54 +0100
On Sun, 8 Jul 2012 08:53:28 +0200
Giuseppe Penone <giuspen gmail com> wrote:
> Thank you Chris, I'll read more about this Glib::Dispatcher, in the
> past I already took a look but then discouraged and used gdk lock
> that I already was able to use.
The main problem you will come across using Glib::Dispatcher is passing
data to the callback. For that, it is best to use an asynchronous
queue.
In another posting you said your program does a lot of input-output.
You don't need threads just for that: you can set up a watch on a
file descriptor for the main GUI thread using
Glib::signal_io().connect(). GIO/giomm also has a wide range of
asynchronous IO functions where all the hard work is done for you.
Chris
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]