* Erik Hofman -- Thursday 15 June 2006 22:35:
> That's why I said I would copy the necessary files (all HUD related
> code) to Instrumentation/HUD and rename the class(es) and leave the old
> code to rust away.
OK. Done that. For now I've decided to make it a regular subsystem
that's registered by FGInstrumentMgr (instrumentmgr.cxx) like
"od_gauge" and "annunciator". The ::update() method is empty, and
there's a method ::draw() that is called from the renderer right
after the old fgCockpitUpdate. I think this is the best approach
for supporting the old modes (2D & 3D). Later I'd like to add
render-to-texture HUD instruments in the way "wxradar" uses "od_gauge",
by subclassing from the HUD. Those will then not be updated via
::draw() method by the renderer, but via ::update(). Or something.
First I need to make it work at all, though. :-)
I'll commit the files as soon as the basic, old functionality is
restored. The new HUD will be turned off, unless an aircraft asks
for it. (And I will make them ask for it. :-) The new XML configs
will, of course, not be fully backward compatible. Changes:
<loadfn>fn \____become <property>/path/to/somewhere...
<data_source>fn /
<data_scale> ____becomes <scale> too (both exist currently
for the same thing in different HUD elements,
which hinders abstraction)
m.
_______________________________________________
Flightgear-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/flightgear-devel