July 28, 200223 yr I have read the Panel SDK and I have a few questions.1) Can I draw a line using a generic function, instead of using the MAKE_STATIC macro and(gag me) using a bitmap?2) If the answer to question 1 is something like "Always use macros, there are no generic functions to draw primatives like lines, or the like", do I always need to use a bitmap or is there a way I can use drawing primatives? If I create a 744 like PFD with the compase rose on the bottom, will I need to have a circular bitmap that rotates around a point? I know the circular bitmap would be easier than using drawing primatives, but that is just an example 3) In a gauge file...how would I go about laying down the 'framework' so that I can update variables, redraw bitmaps and(hopefully) drawing primatives and the like? Do macros always redraw themselves everytime the panel is updated?Thanks a bunch for any help you can give me!!
July 28, 200223 yr 1) The only way to do this would be to make a vector gauge. Vector gauges are drawn using the windows api instead of gauge macros. You have to have a black background and draw all of the elements of the gauge using the primitives. Obviously, this is much more difficult than using the macros. Download Dai Griffith's gauge tutorial. It has some examples of vector gauges with it.2) Just like you said, you would need to have a circular card that rotates around the center. Unless you're doing some heavy-duty gauge programming, for the most part just stick with the macros.3) The macros will automatically redraw whenever the panel is updated. If you tell the element macro which variable it should reference, it will automatically refresh that variable and draw the correct value. If not, you will have to use an Element Callback and tell the gauge what value to use for the redraw.You can see all of the bitmaps that go into a gauge here: http://www.flightsimnetwork.com/dcforum/DCForumID3/7049.htmlHope this helps! ;)Matt Matt KaprockiFor fastest support, please submit a ticket at http://support.precisionmanuals.com
July 29, 200223 yr Matt --Thanks a bunch!! That answer my questions perfectly. I downloaded that tutorial you mentioned and I have looked at the WinAPI GDI, and I am going to have my work cut out for me!!Thanks a bunchFred
July 29, 200223 yr Hi Fred,the new SDK provides a IMAGE_CREATE_DIBSECTION flag for helping out things.Hope it helps!
Create an account or sign in to comment