Jump to content
Sign in to follow this  
Guest

Panel bitmap

Recommended Posts

Guest

bumping this so I'll have a chance someone will look at the pics before they get deleted.

Share this post


Link to post
Share on other sites
Guest

>My gauges are appearing on the vc panel stretched >horizontally. I know you said that the dimensions of the >geometric plane does not matter, that it can be a circle if >you want, but when I resize my panel (rectangular plane) it >_appears_ that this affects the asepct ratio of the gauges. >I am seeing things? >>My vc texture is 512 x 512. Steve,I apologize for not replying sooner, but I've been a bit preoccupied and just missed your question...There are five sets of dimensions that come into play here:1) size/shape of the planar surface (projection surface), can be anything you want that fits the available shape/space/special needs.2) the UVW map for the projection screen must be square, but the physical size is not critical, so long as the entire projection surface is covered.3) the $dummytexture.bmp must be square, and a power of 2; i.e., 256.256; 512,512; 1024,1024.4) the defined size of the background "image" (pixel_size=) used in the vcockpit section of the panel.cfg must be square, and match the dimensions of the $dummytexture.bmp declared in item #3.5) the size parameter in mm must be the same as item #4, or else size_ratio must be used to define the relationship.For example, in one of the sub-panels of the TB20GT you will note the following entry:{Vcockpit04}file=panel_P4_background.BMP Background_color=0,0,0 size_mm=256,256visible=0pixel_size=256,256texture=$bdvc_04gauge00=TB20GT!Gear Lever, 206,9,37,23gauge01=TB20GT!Gyro Suction, 82,4,35,331) In the .mdl, the planar surface is a small rectangle about 18"x5.2" that is sized to fit the space on the panel for the two gauges I need to display.2) The UVW map is therefore 18"x18" square3) The $bdvc_04.bmp file is 256x256 pixels4) The pixel_size=256,2565) The size_mm=256,256This last entry ensures that there is an exact 1:1 relationship between pixels and mm. This is critical, because the display engine in FS2k2 uses mm in it's calculations for gauge drawing!Note also, that in this particular case, I've chosen to apply the panel's texture using the file=panel_P4_background.BMP option in the panel.cfg, instead of applying it in GMax... either way will work, but I just happened to find this more convenient for this part of the panel... :)I hope these notes will help! I suspect that you don't have a size_mm= parameter defined in your vcockpit section, or possibly it is incorrect. That is the usual cause of 'pixel stretching.'

Share this post


Link to post
Share on other sites
Guest

Panel cfg is{VCockpit01}size_mm=512,512pixel_size=512,512texture=$civic_1background_color=0,0,0visible=0Looking at the dummy texture applied in gmax, $civic_1.bmp, it is 512 x 512 24 bit color.The "plane" floats in front of the real panel.I do not use a texture file.I think I will check the UVW Map. Never thought of that. Okay, the panel was from a simple experiment, so it never got a UVW Map applied, just textured with the dummy texture.Hmm, once applied, I can see the UVW map wire frame outline around the dimesions of my planar shape. If I go back to adjust the width I notice it does not inherit through to the mapping. I can then adjust the UVW map frame and watch it move outward until it equals the new panel width.I'll test now.Steve

Share this post


Link to post
Share on other sites
Guest

Is it required to UVW map and UVW Unwrap the panel? After several tries to get the gauges in correct aspect ratio I thought what if I adjusted the UVW map using the Edit button and the Edit UVW's dialog. By squeezing the outline of the panel against my square graphic I was able to get the gauges to display in almost their normal aspect ratio. Apparently FS displays these in the virtual cockpit with some kind of perspective adjustment because at 50% zoom they look correct, but closer they show a little bit of horizontal stretching. I did this by eye, so it is no surprise the aspect ratio is not perfect.So the gauges are almost square, but now they seem to tile across the panel, i.e. I see double gauges beyond the panel and I have not had any wine either.You can see what it looks like in the Edit UVW window.Steve

Share this post


Link to post
Share on other sites
Guest

>So the gauges are almost square, but now they seem to tile >across the panel, i.e. I see double gauges beyond the panel >and I have not had any wine either. >>You can see what it looks like in the Edit UVW window. >>Steve No, do not use UVW Unwrap at all. You've made this way more complicated than it needs to be... :)The following picture shows how I've created two planar surfaces, P1 & P2 to overlay the panel area in the new Beriev. There are two UVW maps of identical size that are used to 'map' the two surfaces, and $P1.bmp and $P2.bmp are applied to their respective surfaces.Take note of how I positioned and sized the maps to exactly cover the entire panel's surface from edge to edge, and aligned them with the top of the panel.The areas where there is no 'surface' will therefore be totally invisible. IOW, only the 'black areas' will show up in FS2k2 and act as projection screens.Because the UVW maps are perfectly square, I am then free to use whatever size image I want. In this case, both $Px.bmp files are 512,512.BTW, do NOT use 24 bit images anywhere in the VC. Use only 8 bit indexed graphics. FS2k2 just doesn't like 24 bit RGB texture files in the VC or interior at all...

Share this post


Link to post
Share on other sites
Guest

More about this subject.Once I had the basic mapping done for the VC, I loaded up FS2k2, adjusted the view angle, and then 'snapped a picture' of the blank panel.Now I've got a dandy background to use in FSPanel Studio (or cfgedit) to help with final placement of the gauges! :)Also, cropping the image now gives me a basic start on the 2d panel bitmap as well... :)

Share this post


Link to post
Share on other sites
Guest

It certainly was getting harder, but I was merely exploring all the possible reasons for failure as I would when debugging a program. I am unaware of any detailed documentation on making a virtual cockpit, so would not know the role played by the UVW Map, although I suppose it could be guessed at.It appears that the aspect ratio of the projected panel and its gauges is controlled by the dimensions of the UVW Map applied to the planar object. From my experimentation, I can report that if you set all three Tile factors to zero, that the gauges disappear. This may be what happened when some in this group reported their panel disappearing. So I set mine back to 1. When you do, you can see the dummy texture appear (I use a gray one with some words on it for orientation as Chris's tutorial showed, not black).Once I made a square UVW Map and enlarged it to just about the size of my panel object width (trying to keep it backed off a little so the tiled instruments do not show up), the gauges showed the correct aspect ratio.My next problem was the gauges appeared to be too big (actually they appear closer to the eye point instead of larger sometimes) or my panel too small. I thought perhaps I had underestimated the area required to fit the gauges on the panel. However, after doing some calculations in millimeters (the panel unit) I discovered my airspeed and altimeter gauges swapped from some old panel were about double their actual size. The standard opening is 57mm and these were set to 103 in then panel. Reducing the size to 57 made for a lot room!I am still a little uncertain about this, because my engine gauges are supposed to be 2" and they appear as large as the airspeed indicator. They should be close, but they look a little larger than they should by eye. I think this is due to the area surrounding the airspeed indicator being included in its width, i.e the graphic include the mounting screws, etc. where the gauge face is probably exactly 2 1/4" or 57mm, so I may have to allow for that area of the graphic outside the diameter of the face.I had to move the gauges around and resize them quite a bit to fit the virtual panel compared to the 2D locations. I suspect that for the 2D panel I had adjusted them to be readable not to be exact size of the real instrument.

Share this post


Link to post
Share on other sites
Guest

Photo of progress.Square UVW Map resulted in correct aspect ratio for gauges.I noticed that when you create a panel 'plane' in the shape of the aircraft panel (or a rectangle close in dimension) the UVW Map dimensions are the same or a retangle bounding the shape minimally. This means you must adjust the dimensions of the map until they are square. It does not default to this state.Steve

Share this post


Link to post
Share on other sites
Guest

>Photo of progress. >>Square UVW Map resulted in correct aspect ratio for gauges. >>I noticed that when you create a panel 'plane' in the shape >of the aircraft panel (or a rectangle close in dimension) >the UVW Map dimensions are the same or a retangle bounding >the shape minimally. This means you must adjust the >dimensions of the map until they are square. It does not >default to this state. That is correct, the 'bounding box' for the UVW map will try to 'fit' the largest dimension, either height or width. Take the largest value and apply it to the other axis, and you now have a square 'map.'The UVW coordinates define the relationship with the xyz coordinates of the model. That's why 'fiddling' with the UVW map size can have very unpredictable results! :(The 'color' of the $dummytexture.bmp isn't truly important, because FS2k2 will always generate the color of the dynamic map based on the values entered in the v-cockpit section.That looks much nicer now! Congratulations!

Share this post


Link to post
Share on other sites
Guest

I'm getting there. The panel (not the 'plane') is actually slanted because that is the way the picture of the Boorabee II shows the outside of the panel area. It may be slanted IRL, but that is not very good for viewing in FS, so I will have to find some way of making it vertical beneath the overhang when the front poly is deleted.Today I completed the ammeter and added a digital tachometer. That just about uses up all the room on the panel. I will have to make a seperate panel for the flaps handle.I have to decide whether to make pods for the engine guages that are hanging down below the panel or perhaps make pods on the sides in the corners.Next I have to decide how to texture the panel. Whether to tile a panel texture across the panel shape or to use a seperate panel graphic.You can probably tell there are two version of the plane. I didn't make that EIS gauge for nuthin' :)I may borrow your transponder if you will be nice enough to let me include it.I have not downloaded the Socata, but am very anxious to fly it. I hate long, start and stop downloads (that Netscape, never could download it after version 6) so have tried to avoid the rush. Will do when I have a quiet moment.Steve

Share this post


Link to post
Share on other sites
Guest

>I may borrow your transponder if you will be nice enough to >let me include it. >>I have not downloaded the Socata, but am very anxious to fly >it. I hate long, start and stop downloads (that Netscape, >never could download it after version 6) so have tried to >avoid the rush. Will do when I have a quiet moment. That's why I've stuck with Netscrape v4.78 and won't "downgrade!" :)You may use anything you wish. It's all "open source" and free for use by anyone! :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...