• 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.

How do I improve the resolution of the gauge?

  • Thread starter Thread starter B21
  • Start date Start date

B21

Messages
149
Country
unitedkingdom
I've designed an XML gauge with a 1024x1024 background bitmap, and I'm drawing polygons onto it. The panel has the gauge defined as 105x105 mm across so the gauge gets correctly scaled into this area.

*But* even if I zoom into the 3D panel, both the gauge background and the polygons seem to be drawn at maybe 105x105 pixels.

I don't get it - am I doing something wrong, or is the texture on the gauge not rendered at its full resolution simply scaled into the 3D panel?

I was hoping using polygons that this would keep the full resolution designed into the gauge no matter what size it was being rendered, but this doesn't seem to be the case either.

Am I missing something simple?

thanks,

B21
 
Hey B21,

Sounds like you just need to reset your panel config window resolution to 1024. It might be at 256X256, or 512X512 instead of 1024X1024. Go to your panel.cfg file and check the window section of your gauge and ensure its at 1024 and you should be good to go.



Bill
LHC
 
Designing a gauge at 1024x1024 is a recipie for horrible performance, not to mention the poor appearance in the sim.

While a certain amount of 'rescaling' is reasonable, asking for >10 pixels to be replaced by one pixel is more that a bit unreasonable... :)

Typically, I will design a gauge to be display at its "native size" that I intend to use in the sim.
 
Last edited:
I'm sorry I didn't make myself clear - the bit I don't get is why a 100mm wide instrument has to be at a very low resolution (e.g. 100x100) even though the bitmap of the *gauge* background is 1024x1024. I would have expected if you zoom in to the gauge so it fills the screen on a 1600x1200 display, you would be able to see the hi-res background, not a blown-up version of the bitmap scaled down to 100x100 pixels.

Is it because the whole 3D panel has to be at the same resolution?

I.e. you have a *panel* bitmap of 1024x1024 and you put in the panel setting that says (e.g.) this represents 1024x1024mm (so you get a 1m-wide 3D panel). Now you can place any gauge accurate to one millimeter - i.e. the gaugeXX statement might have:
gauge00=mygauge!gauge, 250,250,100,100
which would place the gauge a quarter in from the top-left corner, scaled to fit a 100mmx100mm area. Will the gauge only be displayed to a resolution of 100x100 pixels regardless of the size of the gauge on the user screen? It seems that way to me but I'm a gauge noob. In this case I certainly wouldn't design a gauge at 1024x1024 - you might as well work out what resolution it's going to be displayed in (100x100 in this case) and design the gauge for that.

For a complex LCD digital instrument (even with a 90mm dial) that doesn't give a lot of pixels to work with though! I was hoping using polygons would get round the pixellation at high zoom levels but this isn't the case *at all*.

Among other things I'm drawing LCD numbers on the screen - the 'Quartz' font isn't really up to the job (at least that scales with the zoom but at 'normal' zoom the font is very hard to read, even though a readable font is achievable at that size if a bitmap is tried instead) and bitmap image alternatives for the numbers are suffering from fairly horrible aliasing. Trying to draw a variable 39-segment 'fan' LCD display in an area on the gauge of maybe 40x40 pixels is a bit of a struggle.

Please excuse the noob questions but I'm in that early learning process presumably we all have to go through.

So n4gix I guess the recommended approach is just plan for a 100x100 pixel (say) gauge resolution at any zoom level and design for it?

B21
 
Under normal conditions (i.e., the panel.cfg is correctly set up), there is a 1:1 ratio between mm and pix. Hence, a 105x105 area is indeed limited to 105 pix in both dimensions.

This is a constraint on gauge design, as anything larger is rescaled in memory, and only then is it drawn at the reduced resolution.

Note: The following discussion assumes that either (a) you are modeling the aircraft's vc yourself, or (b) the modeler will build the vc to your specifications. :mischievo

My approach to gauge design is to design the gauges for the sizes that I want the gauges to be on the $vc template.

What this means is that the first step is to gather up photos and/or drawings of all the gauges to be used in the vc, and then using Photoshop (or similar) to play a bit of what I call "gauge shuffleboard" trying to find the optimum arrangement of the gauges on the fewest number of $vc templates.

For those gauges that will be "most in your face" in the VC, i.e., those closest to the pilot's eyepoint, I try to allow the maximum pixel space I reasonably can.

In the sample below, I've allocated 488x600 pixels for both the PFD and MFD glass displays, including their 'frame.' This means that if I then program the gauge to that exact size, I will then get a 1:1 drawing (full size) in the sim. No rescale required... ;)

BTW, the gauges shown below are the original 'bitmap versions,' and have since been replaced with GDI+ versions. However, the main point is that no rescaling by the sim is required, so the gauges will be displayed at their full resolution. This screenshot from FS Panel Studio is rather "fuzzy." In the sim it is much more crisp... :)

So, once I've decided on a layout, it is then easier for me to design the actual gauges to the precise sizes specified in the [VCockpitxx] sections of the panel.cfg file...

vcglassef5.jpg

Shot at 2008-07-05
 
Last edited:
actually, while we're on the subject... what is the 3D panel background bitmap for anyway? Surely the 3D panel is being textured with whatever was put into the gmax model of the panel?? (I know there's the '$...' textures which seem configurable in the panel.cfg but I don't think I'm talking about these.)

Many thanks... B21
 
<---- druels over those fantastic glass panel gauges....

Nicely done Fr. Bill!


B21,

You would either have hovering polygons over the panel that have the 'vc gauge' material mapped to them, or you have have actual 3 dimensional objects with the vc gauge material mapped to them.


Bill
Gauge Kindergardner
 
actually, while we're on the subject... what is the 3D panel background bitmap for anyway? Surely the 3D panel is being textured with whatever was put into the gmax model of the panel?? (I know there's the '$...' textures which seem configurable in the panel.cfg but I don't think I'm talking about these.)

Many thanks... B21

These panel background bitmaps are specified in the [VCockpitxx] section, and they will texture the $vc gauge polys.

//--------------------------------------------------------
[Vcockpit02]
file=vc_glass.bmp // adds texture to the dynamic bitmap
Background_color=0,0,0
size_mm=1024,1024
visible=0
pixel_size=1024,1024
texture=$vc_glass // creates dynamic bitmap

Actually, there are two reasons for them:

1. As a aid in gauge placement during the design process

2. Provides background texture for transparent gauges. One of the chief "problems" is that when backlighting gauge polys, if there is a "transparent" area in the gauge, the poly will turn black whenever the lights are on. This is very, very ugly... :eek:

The vc_glass.bmp file must be in the ..\panel folder and must be 24bit .bmp format
 
Last edited:
<---- druels over those fantastic glass panel gauges....

Nicely done Fr. Bill!

So far, in nearly three years, not one single person has ever reported noticing the "seatbelt/no smoking" sign in the pax cabin. The respective symbol illuminates based on the pax safety switch position in the cockpit...

OFF
No Smoking
Fasten Seat Belts & No Smoking
 
So far, in nearly three years, not one single person has ever reported noticing the "seatbelt/no smoking" sign in the pax cabin. The respective symbol illuminates based on the pax safety switch position in the cockpit...

OFF
No Smoking
Fasten Seat Belts & No Smoking

I am sure some noticed and smiled a big grin at the high level of detail. You just didnt hear about it.


A point you made once to me years ago was that pixels resolution is only so much.. Bottom line. We can try to make resolutions more refined and crisp, but they are still going to be the same size of tiny pixel blocks. Wish it was possible, but its not... arrghh.. I do note that making gauges bigger and then scaling them down in their panel placement 'does' help out alot and bring in some good crisp resolution.


Bill
 
Last edited:
sorry to drag this out, but given that someone is also designing the 3D panel specifically to support this instrument, I can simply have a [Vcockpit01] section *just* for the one high-resolution instrument with a higher pixels/mm, and have all the other instruments on another [VCockpit02] section with 1pixel/mm?

That would mean the fancy gauge could display at (say) 512x512 pixels in a 90x90mm area, while the other gauges are workable at the lower resolution?

Is having a single gauge at 512x512 (or for that matter 1024x1024) really that expensive at run-time? I appreciate this would be pretty major if it applied to to the whole panel.

thanks - B21
 
That would mean the fancy gauge could display at (say) 512x512 pixels in a 90x90mm area, while the other gauges are workable at the lower resolution?

Is having a single gauge at 512x512 (or for that matter 1024x1024) really that expensive at run-time? I appreciate this would be pretty major if it applied to to the whole panel.

A 1024x1024 would be very expensive at run time if it is displayed at full-resolution.

As for the VCockpitnn sections, all of them should be a 1mm:1pix ratio. It would be silly to do anything else.

Perhaps a picture would help explain what words aren't making clear enough. On the left in the image below is a 258x258 bitmap.

On the right is the same gauge that has been "rescaled by the sim" to fit in a 90mmx90mm area (90px90p). I've "enlarged the image" by 300% so you can see what happens...

...it's pretty :censored: ugly!

graphicsrescaling01qp0.jpg

Shot at 2008-07-06

That is why I insist that (a) the gauge be designed to the exact size/resolution that will be specified for the $pan dynamic texture, and (b) that there be precisely a 1mm=1pix ratio on the VCockpitnn sections.

I'll leave to your imagination what would have happened had the original bitmap been 512x512 instead of 258x258! :yikes:
 
Last edited:
B21, here's an idea:

You could design your VC as n4gix suggested, but in the mouse detection code for each gauge, get it to open a special 2D panel showing the gauge detail that is on the gauge the mouse pointer is currently on. Like a pop-up zoom.

You wouldn't need a seperate panel for each gauge popup, you could write a master gauge containing the bitmaps and display code for all your gauges and display accordingly. You can then turn the gauge off when the mouse leaves the VC gauge area.

But I'm a bit confused as to why you'd need such high resolution. If the pilot's got so poor eyesight that he has to zoom so far in that it displays at 1024 square then he probably shouldn't be flying in the first place! :)

Si
 
Thanks for your help guys - the comments have all been very useful and I've learned a lot. I'll see where I can get to with the gauge!

Cheers - B21
 
This isn't intended to be a necro, but I still see posts asking "why is my gauge at low-res" years on after I had the issue.

The correct answer to this question is:

(1) Your panel texture does indeed limit the resolution of individual gauges, i.e. a 1024x1024 texture across an aircraft cockpit means individual gauges might be about 100x100 pixels.

(2) As written in the thread, if you have no control over the model, then you should design your gauges so they display at their 'native' resolution on the panel, as that gives you the best chance of finessing the laughably small bitmap dimensions you're working with. E.g. use 100x100 gauge backgrounds. The goal would be to not need to specify the size on the panel.

(3) The best solution is to create additional panel textures so you don't try and cover the entire potential virtual cockpit viewable area with a single 1024x1024 panel texture. If you have a gauge with a particular requirement, it is worth placing a new panel texture just in the area where that gauge is going to go (even 256x256 would make a huge difference, and might be optimal for most 90mm gauges)

(4) Performance concerns are wrong, as far as I can tell having programmed this. Having an additional 1024x1024 panel texture, with a higher resolution gauge on it, makes no difference whatsoever to FS performance. I'm assuming you're displaying needles, numbers and moving bitmaps around, not rendering video.

B21
 
It was kind of you to "bump" this back into view, as there's quite a bit of very good information that unfortunately and inevitably get's "lost" in the forest of posts as a forum ages... ;)

The end goal of any virtual cockpit project must be to display the dynamic bits at the best possible resolution using the absolute minimum number of [VCockpitnn] sections as possible.

Static bits of the 3d panel can achive the best and highest resolution through use of the bitmaps from a ..\texture folder.

Achieving the best balance between these two concepts requires careful pre-planning! :teacher:
 
Back
Top