http://openig.compro.net
https://www.compro.net/openig_forum/

How to load a different .flt
https://www.compro.net/openig_forum/viewtopic.php?f=10&t=10
Page 1 of 1

Author:  baggiodlb [ Wed May 27, 2015 5:46 am ]
Post subject:  How to load a different .flt

Dear OpenIG developers,

what is the procedure to load a different .flt than the demo one?

I see there is a default.txt file that seems to be running some script that loads .osg files.

Is there a how to on how to setup loading .flts?

Thanks in advance,
congratulations for OpenIG!

Author:  trajce.nikolov.nick [ Wed May 27, 2015 6:08 am ]
Post subject:  Re: How to load a different .flt

Hi baggiodlb,

you found the right place for setting up the scene. You can do it from within a script, like the default.txt is, or programatically with

ig->addEntity(the_entity_ID, the_file_name, optional_options);

If you are doing it from the default.txt, you can also use optional string to offset your database (this was introduced for visual databases that have large coordinates to avoid precision errors in the rendering). For example, in the provided code and sample dataset to be used, this is how the terrain is added:

addentity 0 /usr/local/database/terrain/OPEN_IG_Demo_NO_UTM31N_r5/master.flt.osg 0 0 0 0 0 0 -1.20639e+06,-5.099e+06,0

Here -1.20639e+06,-5.099e+06,0 is the offset string, to make the specified location to show at the origin (0,0,0).

If you are new user of OpenIG then maybe you spend some time wondering around in the provided Demo application code to understand the ID concept for models for the scene.

Also, OpenFlight is good for visual content creation and exchange, however we advice for much better performances to use the native OSG .osgb format. The OSG distribution provides utility for conversion, osgconv, so we advice you to convert your visual database. NOTE: The next distribution of OpenIG will have it's own tools for this purpose

Please give it a try, and if any issues please ping us again !!

Cheers & Thanks !

Nick

Author:  kabeck [ Wed May 27, 2015 9:58 am ]
Post subject:  Re: How to load a different .flt

Hello Mr. Baggio,

The steps that Nick provided are correct.

Here is a little more on the general process we use:


If your Openflight database is not too big you can load by calling the master.flt directly from the default.txt as Nick pointed out above. (need to get offset correct as well)


However,  if it is a large area then the tiles will over-run your memory.  To overcome this we make the the openflight tiles "page-able".

In addition to page-able we choose to make the OSG Binaries (.osgb) so the speed is also optimized.

All this is done with a script.  In the script you run against the directory with the openflight database and it will step through each .flt and make an .osgb.  Then it converts the Master.flt to make a master.flt.osg.


Now your database can be loaded by calling the master.flt.osg and it will tile just like the old terrapage format.

At this time, the script runs on linux so if you have a linux box. I can make a quick movie to show the steps as well.  If you do not have access to Linux box then I can offer to convert for you if you can ftp to us and I will have it converted to demo on Tuesday.

Hope this helps.

Keith

Author:  baggiodlb [ Tue Jun 02, 2015 1:41 pm ]
Post subject:  Re: How to load a different .flt

Thanks for the info, it worked fine :)

Thanks Nick, thanks Keith.

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/