Another possibility for the communication between the data and render threads.
commitdb279a20818551d895b0913de06c0c48d1d93d89
authorstrange <kawk256@gmail.com>
Sun, 14 Feb 2010 04:02:38 +0000 (13 21:02 -0700)
committerstrange <kawk256@gmail.com>
Sun, 14 Feb 2010 04:02:38 +0000 (13 21:02 -0700)
treeddf62800bd89c858a0779ea7b46baaa97ab58343
parent47bbd677cd5cd4a6791f152f4ffef0491183e6a3
Another possibility for the communication between the data and render threads.

QLocal{Server,Socket} -- on UNIX systems, a "domain pipe" (according to the Qt
documentation, which is, of course, a UNIX pipe). I could potentially use a
pipe between the rendering thread and the storage thread . . . but I'm not
sure if the added overhead would be worth it. However, it is definitely a
viable option.

I have three options, now. I can do the obvious but probably very slow way,
which is using Qt signals and slots. While convenient, they are definitely not
optimal, as far as speed is concerned. I can also create two producer/
consumer-style queues that each thread maintains. However, what happens when I
have multiple rendering threads (not an unlikely possibility)? Additional
queues need to be created, which isn't exactly going to help speed or memory
usage . . .

And, of course, there's the sockets. Out of the three, I think I like the
queues most. It's fairly flexible, doesn't use an insanely large amount of
memory, and is fast enough for my purposes . . . I think.

I'll give it a try, though I doubt I'll actually end up with any better
solutions, at least not without redesigning anything else.
aesalon_overload.so [new symlink]
gui/src/session/DataRequest.cpp
gui/src/session/DataRequest.h
gui/src/session/DataThread.cpp
gui/src/session/DataThread.h
gui/src/session/GraphDataEngine.cpp [new file with mode: 0644]
gui/src/session/GraphDataEngine.h [new file with mode: 0644]
monitor/src/Initializer.cpp
overload.so [deleted symlink]