I investigated a little more about that updating issue. This is what
I have a amd64 box at home, but I'm running 320bit linux on it. VXL
compiles, runs and does everything else fine. I went to the
vgui/examples directory, ran the example_idle_processing executable. It
At work, I use a Pentium4 3.2GHz machine with HT enabled. Similar
software configuration, same linux distro, same compiler, same libs,
except the kernel is a SMP kernel (for taking advantage of SMP). That
example does NOT work. Idle processing never starts.
Any idea if hyperthreading is causing this problem?
Junaed Sattar wrote:
> Hi Amitha,
> I spent the afternoon trying different approaches to do what I wanted.
> I tried Brendan's suggestion, without success. As far as using an idle
> handler, I tried that too. This is what I did:
> 1. From my previous snippet, I overrode the virtual bool handle(e)
> method in my EventManager class, and put the code for grabbing and
> displaying images there.
> 2. I have a menu option that I plan to use for starting and stopping
> the streaming video from the cam. When clicked the first time, it
> toggles a flag and calls post_idle_request() for the EventManager class.
> 3. The idea I had in mind was, looking at the flag set in step one,
> the idle() method would either return true or false.
> Again, that didn't work. On another note, from the documentation for
> "Return false once your idle processing is complete, or if you have no
> need for more idle processing. Return true if you need more idle
> processing time."
> I think this is what you meant, mistakenly got the cases swapped. Or
> is this wrong?
> I'm using gtk2 for my app. I found one example
> (example_idle_processing) in the vgui/examples directory. I ran that
> code (I'm home now), and it works. I'll check with the hardware
> tomorrow and let you know.
> I wonder how many VXL users are actually using it, IMHO VGUI is a
> pretty cool tool to design apps with. Great work. I just wish things
> were working smoothly. I'd love to get into hacking VXL, unfortunately
> now isn't a good time for me, I have a thesis deadline coming up!
> Thanks for all the help!
> Amitha Perera wrote:
>> From your description, it sounds like idle-time update of the image
>> is exactly what you want. So, if you put your image updating code in
>> the place where you handle the vgui_IDLE event (either a monolithic
>> handler or in the (overridden) idle() method, things should work. You
>> need to call post_idle_request() initially somewhere to start off the
>> If your idle handler returns false, it'll continue to receive idle
>> events. Return true when you are done with idle events. (In your
>> case, that would be when you no longer want to update the image.)
>> The the documentation of post_idle_request and idle in vgui_tableau.h
>> Also: it may be the that the idle processing is not implemented with
>> GTK1. If this is the case, could you test with GTK2? If it works
>> then, I can try to implement it for GTK1. (Or better, send me a patch
>> that implements it for GTK1!)
>> SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
>> from IBM. Find simple to follow Roadmaps, straightforward articles,
>> informative Webcasts and more! Get everything you need to get up to
>> speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
>> Vxl-users mailing list