I don't think most flight simulators are actually rotating a picture
to draw the needle, as you're doing. Instead, they have pre-rendered
needle images at all the orientations they care to draw (yes, there
may well be quite a few of those). This is much faster, and often
looks better too, since you can have them properly shaded and
shadowed for each angle, which you can't do when simply rotating a
picture.
I don't know. For example, both X-Plane and MS Flight Simulator only
require that you create one needle graphic (and corresponding mask)
for a gauge. Is it possible that they pre-rotate copies on startup?
I would imagine that they do the rotation using opengl and therefore
the graphics hardware is doing the work.
From you description I assume that you are using these dial controls
outside of the RB3D view and drawing them using the object2d rotation
methods. I can tell you from experience that these methods are much too
slow for real-time use. If, on the other hand you were to render your
dials within your RB3D view then the real time rotation would have an
utterly negligible performance hit.
If you can't do this then the only solution is to render the dials in
many orientations beforehand as Joe suggested. You could however do
this within the program during set up time rather than having to do it
by hand in photoshop - might make life easier, as well as reducing the
size of your programs resources.
Nick
_______________________________________________
Unsubscribe or switch delivery mode:
<http://support.realsoftware.com/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>
|