Re: XForms: Flickering & pausing

Steve Lamont (spl@szechuan.ucsd.edu)
Mon, 20 Jul 98 07:26:24 PDT

# To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :

> 1) I am implementing some of the helicopter controls as free objects,
> and they seem to flicker.
>
> They are being redrawn at ten Hz, which is fast enough, but I would like
> to eliminate the flickering. I tried using double buffering for the
> form, but it slowed my app down by a factor of five, which is unacceptable.

You might try fl_freeze_form()/fl_unfreeze_form().

> 2) I am working on a LAN, and I would like to be able to display some of
> the forms on one monitor, and some on another, but it seems you can only
> set the display in the call to fl_initialize(...), which can only be
> called once, right?

Right. The only alternative is to spawn another process and use
interprocess communication to talk between them.

> 3) This is a problem I cannot live with. When the pilot lands the
> simulator, I need to be able to display some performance statistics.
> Currently I have a seperate form that I create at startup, but do not
> display. Then when the pilot lands, I simply fill in the values, and
> then call fl_show_form(...). The problem is that when I call
> fl_show_form, it blocks my app for almost a second, causing the graphics
> to freeze, which is very unsettling for a pilot under a VR headset, who
> expects the landing gear to react.

I'm surprised it's that slow -- is it a very complicated form or does
it have a Canvas object in it? If it has a Canvas, the canvas must be
recreated. I'd suggest not using fl_hide_form() and fl_show_form() to
manage the visibility of the form but to devolve to raw Xlib. Use
XUnmapWindow() and XMapWindow() -- this should work quite quickly. Of
course, you'll have to deal with initializing the form to start with
using fl_show_form() but it's a hit you'll only have to take once.

spl
_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuf2.usuhs.mil or see
http://bob.usuf2.usuhs.mil/mailserv/xforms.html
XForms Home Page: http://bragg.phys.uwm.edu/xforms
List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/