Sign in to follow this  
GaryGB

Adding a real photo object to a specific location in FSX

Recommended Posts

Greetings!Long-time FS user, but total noob to scenery creation ...Is it possible to use an edited digital photograph to create a scenery object that can be placed at a specific location in FSX, to be viewed from a specific angle on the ground?I'll explain: Let's say that I create a private airstrip in an otherwise featureless area of scenery. I'll say that this airstrip is on property that I own in rural Colorado. Near one end of the runway, I want to place a building, and this building is the house that I built on the property. I have a good photo of the house, and I know how to use PhotoShop to remove all the background stuff from this photo, leaving only the actual structure itself.I don't expect to be able to see a 3D view of the house from the air, only to see it when I land and taxi to the end of the runway. Can this be done by a novice? If there's already a tutorial, commercial program, etc, please feel free to point me in the right direction.Thanks,-z-

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

So you want something like this? Just a flat image that can be seen from the end of the runway. http://img295.imageshack.us/my.php?image=housefq4.jpgTo do this you would need to know how to use gmax and how to put the scenery object in FSX. If you want you can send me the picture.(png) with the background erased and I could put it in FSX where you want. It would only take about 10 mins at most.Also this is a great forum for anything that has to do with designing in FS.http://www.fsdeveloper.com/forum/

Share this post


Link to post
Share on other sites

Good Morning Z:Take a look at the following tutorial:Two indispensable tools for preparing photographs for flightsim textures . The secret of great-looking photo-quality building textures is preparation. With a reasonable digital camera we can take all the pictures we want, but that's only the start. Converting the photos into textures requires a lot of work, so anything which can make this quicker and easier is very welcome.. You'll find it at...http://www.scenery.org/tutorials.htmIn the GMAX section.Good LuckTom G, Sr.

Share this post


Link to post
Share on other sites

You can avoid the GMAX completely and create an EFFECTS file with a few lines of code. This effect would place an image of your house wherever you want it, and it would turn it towards observer no matter where the observer was on the ground (this would avoid you seeing a straight line edge of the image when viewed sideways)

Share this post


Link to post
Share on other sites

Hi Misho:Where would we find an example of coding an effect to display a bitmap as a single plane/non-3D "rotate-to-viewer" object as in the specific example you just mentioned? Thanks for any further clarification you would share with us on this!:-) GaryGB

Share this post


Link to post
Share on other sites

GaryGB,I'll whip up one for ya ;)The following is the code to place a MS-default picture of an upright bullet (from one of their fx texture files, fx_3.bmp)The content of the "fx_bullet.fx": (replace curved braces with square)(Library Effect)Lifetime=5Version=2.00Display Name=Placard DemoRadius=10000Priority=0(Properties)Spot=1Tower=1Map=1(Emitter.0)Lifetime=1.00, 1.00Delay=0.00, 0.00Bounce=0.00No Interpolate=1Rate=0.50, 0.50X Emitter Velocity=0.00, 0.00Y Emitter Velocity=0.00, 0.00Z Emitter Velocity=0.00, 0.00Drag=0.00, 0.00X Particle Velocity=0.00, 0.00Y Particle Velocity=0.00, 0.00Z Particle Velocity=0.00, 0.00X Rotation=0.00, 0.00Y Rotation=0.00, 0.00Z Rotation=0.00, 0.00X Offset=0.00, 0.00Y Offset=0.00, 0.00Z Offset=0.00, 0.00Pitch=0.00, 0.00Bank=0.00, 0.00Heading=0.00, 0.00(Particle.0)Lifetime=0.00, 0.00Type=19X Scale=5.00, 5.00Y Scale=5.00, 5.00Z Scale=0.00, 0.00X Scale Rate=0.00, 0.00Y Scale Rate=0.00, 0.00Z Scale Rate=0.00, 0.00Drag=0.00, 0.00Color Rate=0.00, 0.00X Offset=0.00, 0.00Y Offset=0.00, 0.00Z Offset=0.00, 0.00Fade In=0.00, 0.00Fade Out=0.00, 0.00Rotation=0.00, 0.00Static=1Face=0, 0, 1(ParticleAttributes.0)Blend Mode=1Texture=fx_3.bmpBounce=0.00Color Start=255, 255, 255, 255Color End=255, 255, 255, 255Jitter Distance=0.00Jitter Time=0.00uv1=0.25, 0.25uv2=0.50, 0.50X Scale Goal=0.00Y Scale Goal=0.00Z Scale Goal=0.00Extrude Length=0.00Extrude Pitch Max=0.00Extrude Heading Max=0.00And the following is the content of the "Bullet.xml", which will compile into Bullet.bgl:<?xml version="1.0" encoding="ISO-8859-1"?>Some notes:"Face=0,0,1" parameters will set the orientation towards the viewer only in the Z axis. If looked from above, the object will appear as a line. To get the object to face the viewer in all axes, set the parameter to "Face=1,1,1". This makes sense only for objects that look the same from all directions, such as shrubs or generally round rocks...Usually, the origin of the object is the middle of the defined image area, making it half buried in the ground. Adjust the altitude parameter in XML file to shift it up.Obviously, you can use your own imagery and adjust uv1 and uv2 params... if using the whole image (of the house, as initially requested), uv params would be:uv1=0.00, 1.00uv2=0.00, 1.00Notice the format of the image used and make sure that the same format is applied to the replacement image. The best thing to do is to use Photoshop, create a black background and a layer on top of it, with the image. The image can have transparency which will be recognized as alpha channel. Then, simply turn OFF the black background, save as Photoshop image and open PS image in Imagetool (Imagetool likes photoshop files)...save as 16 bit (444) and you are done!The location of the bullet is defined in the LAT LONG values in XML file. If compiling as is, just slew to that loc in FS and look for it there.To make the object larger, increase the scale x y values in the Particle.0 section.Hope this helps,

Share this post


Link to post
Share on other sites

Hi Misho:Thanks for your detailed reply! :-) I'll try this out and see if I can get my own bitmap to work.One related question, is there a way to set the distance from the effect placement coordinates at which the effect will be triggered and thereby visible to the viewer which considers the angle of viewer approach?I suspect that the Effects File "LOD = 0/1" and Controller File Type=3 "Distance=0" parameters generally determine this.But I was wondering in this regard if the effect can be triggered from all directions, regardless of approaching viewer altitude above or below the effect placement coordinates and elevation AGL, and whether triggering of display can be further restricted to only certain angles and vectors of viewer approach?Then, assuming display and rotation is triggered, can the effect be seen in all directions regardless of approaching viewer altitude above or below the effect placement coordinates and elevation AGL, and if so, can it be further restricted to display only via certain angles/vectors of viewer approach ?Thanks again for any insights you might share on this. ;-) GaryGB

Share this post


Link to post
Share on other sites

Hey Gary,RE:Distance: try the "Radius=10000" variable and play with the values there...although I never had much luck with it. This is for visibility, and as I understand, you need a trigger distance.Not sure about the second part of your q - honestly, I don't think that MS provided THAT much of control over it...

Share this post


Link to post
Share on other sites

Hi Misho:I was curious about that parameter in the SDK (under-)documentation; it does appear as if it is almost like a visibility extent parameter for an object, except that it may set a "domain for operation" of the effect as well; I'll check that out. ;-) Thanks again for your help! :-) GaryGB

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