[Xastir] Trail refresh speed for fast movers

Curt, WE7U curt.we7u at gmail.com
Mon Jun 4 13:03:35 EDT 2012


On Mon, 4 Jun 2012, Darren Long wrote:

> I've noticed that when I'm receiving new positions for a fast moving
> aircraft, Xastir shows a dense sequence of position icons for quite a
> while before condensing them into an extension of the trail, although if
> I nudge the map view a bit, then the trail extends immediately and the
> historic position icons go away, leaving only the latest as expected.
>
> My bodged feed does produce dupes of reports, as it dumps  all aircraft
> that are in the  database which were seen in the last 10 seconds, every
> 5 secs into Xastir, but I guess Xastir dedupes inbound traffic anyway,
> so it seems to be a drawing matter rather than a position update issue.
>
> Are there any tweaks that I can make to speed this up?  I don't mind
> taking a higher CPU hit from Xastir, as it is way less resource hungry
> than Google Earth.

Look at src/main.c, this function:

   void UpdateTime( XtPointer clientData, /*@unused@*/ XtIntervalId id ) {

In there you'll see this code:

                 } else {
                     if (!pending_ID_message)
                         redraw_symbols(w);
                 }

                 redraw_on_new_data = 0;
                 next_redraw = current_time+60; // redraw every minute
                 last_redraw = current_time;

Change that "60" to something smaller and compile/install.  I think that will do it.  If not we'll try again.

You'll see "redraw_on_new_data" used in many places in the code too.  It's a flag that tells how fast we need to update things.  A value of 2 signifies that Xastir needs to do an immediate screen update.

-- 
Curt, WE7U.        http://www.eskimo.com/~archer
Closed-minded about open (-source)...



More information about the Xastir mailing list