FlightGear WorldTerrain SkyBox Server: Difference between revisions
Chriscalef (talk | contribs) |
Chriscalef (talk | contribs) |
||
Line 48: | Line 48: | ||
The application is still under heavy development, but the current version uses a custom networking class called "dataSource", which is responsible for opening and maintaining the socket connection, and sending a basic packet of information, and "worldDataSource" which inherits dataSource and handles all the real work. | The application is still under heavy development, but the current version uses a custom networking class called "dataSource", which is responsible for opening and maintaining the socket connection, and sending a basic packet of information, and "worldDataSource" which inherits dataSource and handles all the real work. | ||
This structure is still up for debate and it is very likely that it will be discarded in the future in favor of more general networking | This structure is still up for debate and it is very likely that it will be discarded in the future in favor of a more general networking base class, probably from SimGear. | ||
Revision as of 01:39, 5 March 2015
This article describes content/features that may not yet be available in the latest stable version of FlightGear (2020.3). You may need to install some extra components, use the latest development (Git) version or even rebuild FlightGear from source, possibly from a custom topic branch using special build settings: .This feature is scheduled for FlightGear (unknown). If you'd like to learn more about getting your own ideas into FlightGear, check out Implementing new features for FlightGear. |
This article is a stub. You can help the wiki by expanding it. |
Started in | 03/2013 |
---|---|
Description | FlightGear-based SkyBox server |
Contributor(s) |
|
Status | Under active development as of 03/2015 |
Topic branches: | |
$FG_SRC | [1] |
Website | garagegames.com |
Related |
---|
IPC & RPC |
Scene to Texture |
FlightGear Server |
IG |
Objective
Notes from the author (Chris Calef) March 04, 2015:
The purpose of this project is to make FlightGear's extensive library of world data, weather & environment logic, and map editing tools, available for the realtime use of other applications over a socket connection, either locally or over a network.
The initial driving application for this ability is a first person game engine. When this project was initiated in 2013, the Unity engine was chosen for the flagship demo, but we have since switched back to T3D in order to maintain complete source access and a totally open license (and in recognition of the impressive work being done by the Torque3D steering committee and community).
At present, only two types of data are transferred from FlightGear to the client game engine, skybox images and terrain data. A custom camera group has been created (skybox-cameras.xml) which creates a set of five images capable of being mapped to a skybox in the client (there is no bottom image currently). Meanwhile, as the player moves around the world, the terrainPager class in T3D sends requests for terrain data, which are answered in flightgear by the creation of binary float array files for heights and integer array files for texture reference. These are named with the protocol "hght.(coordinates).bin" and "text.(coordinates).bin" respectively.
The application is still under heavy development, but the current version uses a custom networking class called "dataSource", which is responsible for opening and maintaining the socket connection, and sending a basic packet of information, and "worldDataSource" which inherits dataSource and handles all the real work.
This structure is still up for debate and it is very likely that it will be discarded in the future in favor of a more general networking base class, probably from SimGear.
(Apologies, but the rest of this page is a group of somewhat random quotes on this subject, mostly from myself, helpfully assembled by Hooray who also created this page. I will attempt to make this a more organized presentation of the project at some point in the future.)
My ultimate goal here is a real-world-terrain-based MMO game using Unity for the FPS engine and FlightGear as a backend Skybox (video games) server.
|
Status
my skybox is working pretty well now, and I have the FG textures also imported into my Unity terrain, so if I can find a quick way to determine which texture goes where in flightgear when I load a new terrain, I will be a big step forward in the process of replicating my FG experience on the Unity terrain.
— chriscalef (Sat Apr 13). Easy way to find texcoords or texture for given lat/long?.
(powered by Instant-Cquotes) |
I'm in the process of retrofitting the above described prototype so as to allow it to save out an array of finished Unity terrains and skyboxes, using the data provided once by flightgear during development, and then page through this precompiled data at runtime. This way the end user never has to have flightgear or terragear installed, they just run the Unity game, and only the developer has to deal with the flightgear side of things.
— chriscalef (Fri Jul 26). Re: Reporting back on some LiDAR research....
(powered by Instant-Cquotes) |
I'm still working on my "FlightGear World Server", and the current mission is to replace my (achingly slow) skybox generator. My previous method was to rotate the camera via PropertyTree changes, and save screenshots at each cardinal direction. I finally got through the literature on CameraGroups and Cameras, however, and managed to hook up a set of five cameras which simultaneously record all five desired directions, with the correct field of view.
— chriscalef (Mon May 20). Anybody got any handy OSG image manipulation tips?.
(powered by Instant-Cquotes) |
Gallery
Approach
There may be some overlap when it comes to objects - I may end up converting some of the .ac files in flightgear into FBX or collada, so I can load them into Unity, but more often I think I'll be going the other way and adding my FBX game models into flightgear, ala this thread.
|
Implementation
Demo using Python
Using the Python code available at [2], the following snippet of code can be used to display a FlightGear-based SkyBox using Python: