Re: photo
Jon Stockill <[email protected]>
| Newsgroups | gmane.games.flightgear.terragear.devel |
|---|---|
| Message-ID | <Pine.LNX.4.58.0312311407440.21790@architect.internal.stockill.org.uk> |
On Wed, 31 Dec 2003, David Luff wrote: > Hi Jon, > > I've never tried playing with the specific photo-scenery creator, so I The photo program works in a similar way to genapts - it creates an seperate btg file, and a hole definition for the standard scenery. > can't comment on the differences between that and normal scenery > generation, but I have draped small areas of photos over the scenery > using the normal tools before. As you say, defining a polygon with a > custom name, and then defining the texture for that name to be the > photo, works just fine. By default, the orientation of the texture is > Northwards (I think) so most photos come out fine. Excellent, I'll give it a try. > There's a couple of undocumented helpers available for the UK though. > If you give your polygons the extension .osgb36 then the coords will > (should!) be interpreted as UK eastings and northings (meters) so eg you > could have a polygon file: > > CUSTOM_PHOTO_1 > 1 > 430000 300000 > 431000 300000 > 431000 301000 > 430000 301000 > 430000 300000 How handy :-) > Not sure of the exact format there, but you get the gist, it's much > easier to use eastings and northing for UK photos cut up along the grid > than to convert to lat, lon. > > However, the texture scaling is still based on lat, lon, so the textures > have a discontinuity every now and again (1 deg lat?). You can get > round this in the UK by specifing --useUKgrid at the construct stage > (might not propogate from the client and server tools) which causes the > textures to be tiled aligned with UK grid lines across the whole UK. > > Using --useUKgrid in conjunction with .osgb36 polygon files, it should > be quite easy to get each piece of photo in exactly the right place. > It's been a couple of years since I played with this though, so the code > (and my memory of how to use it) might have been broken by now though. > Shouldn't be too hard to fix though. Also, I was on Cygwin at the time > and using construct manually without the client - server arrangment, so > I'm not sure if the --useUKgrid option will get passed through with > them. If all else fails I'll just write a wrapper script for it so that the client tools call the wrapper, and the wrapper adds --useUKgrid and calls the real prog. I figure if we get these techniques worked out now then when things like texture paging and LOD are available we'll be able to get the scenery updated with minimal effort. -- Jon Stockill [email protected]