• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

Compass tape not showing SOLVED

Messages
35
Country
ca-quebec
SOLVED: 24bit BMP mask file using 1,1,1 as fill colour.

Hi,

My first time trying to make a tape shift. Any idea why the compass remains a black box with only the white line in the center?

Code:
<Gauge Name="Compass" Version="1.0">
  <Image Name="Compassbackground.bmp"/>

  <!-- Size = 102 x 42, black BMP -->

  <Element>
    <Position X="1" Y="1"/>
    <Image Name="CompassStrip.bmp">

    <!-- Size = 520 x 40, white text on black BMP -->

      <Nonlinearity>
        <Item Value="0" X="440" Y="0"/>
        <Item Value="359" X="81" Y="0"/>
      </Nonlinearity>
    </Image>
    <MaskImage Name="CompassWindow.bmp">

    <!-- Size = 100 x 40, black BMP -->

     <Axis X="50" Y="0"/>
    </MaskImage>
    <Shift>
      <Value>(L:KK_Compass,number)</Value>
    </Shift>
  </Element>

  <Element>
    <Position X="50" Y="0"/>
    <Image Name="CompassLine.bmp">

    <!-- Size = 2 x 40, white BMP -->

    </Image>
  </Element>
</Gauge>



LUA displays 58 degrees onscreen (taken from offset x2B00 and rounded), this matches the existing compass reading.

Robert


P.S.: The size lines were added as comments to help here, they are not part of my source.
 
Last edited:
Hum, I had seen that requirement on AVSIM and had filled the mask with 1,1,1 using Paint, but it didn't hold.

I just tried using PSP XI and same thing, can't select 1,1,1.

I'm not doing something right with the paint programs apparently. Maybe the wrong type of BMP file?


EDIT: Paint saves it as a 256 colour BMP, is that right? I keep trying to add 1,1,1 to custom colours but it's not holding when I fill the window. It remains 0,0,0.
 
That's the problem. 256 color won't allow 1,1,1
You need to get Paint to save it as 24 bit bitmap.
Uh... that's not right. Gauges don't use 24-bit bitmaps.

I think the actual problem is Paint. I don't know if anyone uses it to make images for FS.
 
What? I use 24 bit textures in gauges all the time. Never caused a problem.
 
Ed's stuck with 8bit textures for C/C++ type gauges. XML "gauge scripts" will gleefully take either 8bit, 24bit or even 32bit (RGBA) bitmaps. :wave:
 
I suspect your 24bit imagery is being converted on-the-fly by the sim. A quick test of the memory of any given bitmap load by the panel system shows me that they're all running in 8-bit format.
 
D'oh, I'm an idiot.

I clicked Like on your post, forgot I did, then read "You like this" below your post and thought it was your sig.

That was one of the in-game taunts in Unreal Tournament. :)
 
Back
Top