SimpleOtw refactoring

33 views
Skip to first unread message

Elias Tarasov

unread,
May 1, 2016, 5:07:33 PM5/1/16
to OpenEaagles
I've almost finished it.
Only a couple of issues remain.
I hope to send final code on the next week.

Elias Tarasov

unread,
May 2, 2016, 8:13:51 AM5/2/16
to OpenEaagles
Here is source code (with the Portland VisualDB): https://drive.google.com/file/d/0ByDDImhSolf6LU1fbXJIaE5rYlU/view?usp=sharing
And here is video how it looks when run: https://drive.google.com/file/d/0ByDDImhSolf6LVo5ZFE4SnY4bFU/view?usp=sharing
This example can also be used to illustrate how to integrate OE and OSG.

Adrian

unread,
May 26, 2016, 11:58:58 AM5/26/16
to OpenEaagles
Dear Elias,

I am trying to reproduce your example.  I have installed and run OE and OEexamples and they are now working.   For example the mainSim3  produces the artificial horizon.   I am using the pre-built binaries and so my compiler is set to VS2013.

I have followed the SimpleOtw install video which shows 2 projects in the SimpleOtw solution but with the latest version that I have installed and opened the basic project is missing.  when I try to build it 

I have tried to use the executable "Binary executable of Simple OTW" I can down load and run it.   I get the error message:Failed to load title (0,0,1).

Might you know what this error message means?
What would you recommend for reproducing your example using the binary or fixing the vs solution?

Adrian

Elias Tarasov

unread,
May 27, 2016, 3:18:47 AM5/27/16
to OpenEaagles
Hi, Adrian!
The video you followed were for the old version of SimpleOtw.
That's why you got the error,
To run modren version you need to compile OpenSceneGraph (or download prebuilt files for it) in addition to OE and OE examples.
Then, you need to add OSG files to your PATH and SimpleOtw project.
After that you shuld be able to successfully run SimpleOtw example. 

Adrian

unread,
May 27, 2016, 3:51:27 AM5/27/16
to OpenEaagles
Thanks Elias,

I will try that and let you know how I get on.
Adrian

Elias Tarasov

unread,
May 27, 2016, 4:35:17 AM5/27/16
to OpenEaagles
Addition:
Try to compile or download modern OSG (i use 3.5.2)

Adrian

unread,
May 27, 2016, 5:36:49 AM5/27/16
to OpenEaagles
I have set osg 3.4.0 building before seeing your advice! That is the most up to date stable release.  Do you recommend I stop that and find 3.5.2 or will 3.4.0 be close enough?
If you do, where can I find 3.5.2 for it is not on developer release page here:

Thanks again,
Adrian

Elias Tarasov

unread,
May 27, 2016, 6:28:14 AM5/27/16
to OpenEaagles
3.4.0 is also ok. Just don't use those libs from the old SimpleOtw prebuild download.
Now add .h and .lib files to your SimpleOtw project, setup your PATH to .dll then compile and try to run.

Doug

unread,
May 27, 2016, 9:48:26 AM5/27/16
to opene...@googlegroups.com

I'll be integrating simple otw into examples soon.  I've been busting my tail working on framework, doing mostly clean up of codebase (in examples).

I downloaded VS 15 preview 2 and everything compiles and looks good.  Also tried compiling with CLang++ (in VS) and it works as well.  I was pleasantly surprised to see that examples compiled with clang seamlessly linked to libs generated by VS compiler!

Really excited about project overall.  I have a student that will be writing 'intelligent' agents using SOAR soon -- so I'll be bring in an interface for that (after next release).

Next release is targeted at VS 2013 and VS 2015 -- nothing older.  Qt has moved that direction.  Need to stay current with project, and doing this will really help mature the codebase in a few areas such as use of atomics (i.e., spinlocks), timers (chrono), and threads.  I'll hold off on going crazy with HLA support until after release.  In the long term, I do think HLA support is important.

Thanks to all helping answer questions, it's noticed, appreciated, and really helps out - thanks again!

Doug

Adrian

unread,
May 27, 2016, 10:01:48 AM5/27/16
to OpenEaagles
Hi Elias,
I built openSceneGraph and have run the osgviewer.exe cessna.osg in a command line window and have been rewarded with a picture of a cessna!

So I downloaded your simpleOTW.zip from the link above and tried to build it

Your code has 
#include <openeaagles/base/Component.h>
 but the for me component.h is in basic not base.
My oe version is 15.07 do I need a different one?
or do I need to
 "add .h and .lib files to your SimpleOtw project, setup your PATH to .dll then compile and try to run."
as you suggested above?

Adrian

Adrian

unread,
May 27, 2016, 10:15:11 AM5/27/16
to OpenEaagles
Hello Doug,
Your effort with oe, oeExamples and oe3rdParty are very much appreciated.   They worked pretty much out of the box, and I was able to get them all going with minimal fiddling.
Thanks again,
Adrian

Doug

unread,
May 27, 2016, 10:32:22 AM5/27/16
to opene...@googlegroups.com

If there is any fiddling that I can correct, please let me know -- everything should work as smooth as possible 'out of the box'.

Thanks!
Doug

Elias Tarasov

unread,
May 27, 2016, 10:36:13 AM5/27/16
to OpenEaagles
Ah, that's because i use OE source code from the git development branch...
You may download it using git, and then compile and if you have trouble like "RTI.h is missing" then follow this: https://groups.google.com/forum/#!topic/openeaagles/an2270__uvo

Adrian

unread,
May 27, 2016, 10:58:48 AM5/27/16
to OpenEaagles
Doug,
The changes I made where purely to paths: for reasons of source control I don't tend to put things at the C: level.
I initially missed the instruction to run the makeEdl.bat file before running the examples but otherwise it was a lot easier to try than many other libraries.....

Elias,
I will check out the bleeding edge/ fresh meat oe and try that.   I usually use svn but I will try github...

Doug,
will the latest github version work with VS2013?

Thank you both again,
Adrian

Doug

unread,
May 27, 2016, 11:01:56 AM5/27/16
to OpenEaagles

Everything in next release works with Visual Studio 2013 and 2015...

Doug

Adrian

unread,
May 31, 2016, 11:14:44 AM5/31/16
to OpenEaagles
Hello Elias and Doug,
I have built latest oe, oeExamples, osg and Elias' simpleOTW latest. 
Now the examples seem to have changed so I have tried mainSim2 rather than mainSim3 with simpleOTW.
The SimpleOTW is built and runs and produces the initial view of the scene but the view never changes, where as the Artificial Horizon slowly indicates an increasing pitch down.
Can I use a keyboard as a simple input?
How can I get simpleOTW to connect correctly?

Adrian

Doug

unread,
May 31, 2016, 5:09:21 PM5/31/16
to opene...@googlegroups.com
Adrian,

The examples have changed only slightly - I combined mainSim1 and mainSim2 together as the only difference between the two was input configuration files.  The code itself was identical.

Since that happened, mainSim3 -> became -> mainSim2, and mainSim4 -> mainSim3.

Also mainSim4-qt was really just an example of how to use Qt with oe functionality, so it became mainQt1.

Sorry for the confusion, I'm trying to organize examples better for the newbie.

It should be noted that the example named 'mainIr' - which is really a test program to check some of the infrared modeling features became testInfrared to make it more clear as to purpose, intent, etc.

I'm pressing hard to clean up a few little odds and ends, then want to cut a new release.

The last major item on my plate is mainFox3 which is half broke (it works in Windows but not in Linux).  I ended up in a phone conversation today with the main Fox GUI developer Jeroen -- he definitely cleared up some confusion on my part about how event processing happens in Fox, and generally what I should be doing to make things right with fox 1.7.

As soon as the fox example is fixed, I want to get a release cut and quickly move into to including simpleOtw as a significant and important example to sort of 'see' things.  Then it's back into integrating some more AI features and uplifting HLA compatibility.

Doug

Doug

unread,
May 31, 2016, 5:21:12 PM5/31/16
to OpenEaagles

Elias,

Is the simpleOtw code you posted good to go?  Basically, can I drop it in as an example?  I have it, just didn't know if you are modifying, etc.

My gut says to name it "mainOtw1" as a very simple example of getting osg to display an out-the-window view, with other maybe more sophisticated examples to follow... thoughts?

Doug

Adrian

unread,
May 31, 2016, 7:07:08 PM5/31/16
to OpenEaagles
Hi Doug, as I mentioned above I built Elias' version: it needs half a dozen dlls from open scene graph and OSG took a long time to build...
I will try to get it running properly tomorrow and let you know any tweaks.
If I write a few sentences to document my newbie experience and suggestions can I add to the db? Or do all commits go through you?
Thank again,
Adrian.

Elias Tarasov

unread,
Jun 1, 2016, 3:45:47 AM6/1/16
to OpenEaagles
Doug,
updated version of SimpleOtw is here now: https://drive.google.com/file/d/0ByDDImhSolf6ZWlxTDRXRVlfVzg/view?usp=sharing
I updated OE, OE3rdParty and OEExamples and compile them.
SimpleOtw works with these new versions as it is expected.

Elias Tarasov

unread,
Jun 1, 2016, 3:56:50 AM6/1/16
to OpenEaagles
Adrian,
I completely forgot to mention:
You must modify test0.epp file in MainSim3(now it is MainSim2) example.
Comment line //#include "otwSetupCIGI.epp".
And  leave only #include "otwSetupPC.epp" for the otw setup.
By default, if you enable otwSetupCIGI first then others "otw" setup would not work.
Also, use joustick for control MainSim3 (now it is MainSim2).
Keyboard will not work.

Sorry for the very late responce, it would be better to mention these hints earlier.

Elias Tarasov

unread,
Jun 1, 2016, 4:01:55 AM6/1/16
to OpenEaagles
I've posted the new version of SimpleOtw with some changes in the Release version.
Yes, i think mainOtw1 is a good name because it is consisted with the names of others examples.

Adrian

unread,
Jun 1, 2016, 5:14:15 AM6/1/16
to OpenEaagles
Good morning Elias,
I have updated to your latest otw and modified:
paths in test.edl and test.epp in otw

I have commented out and added:
//#include "otwSetupCIGI.epp"
#include "otwSetupPC.epp"

The otw cmd window shows an error:
txp::ReaderWriterTXP::getArchive<> error: archive id 1 not found: "C:\VisualDB\portland\archive.txp"

It all seems to run but without communication between them....
Any ideas how I can debug that?

Adrian

Elias Tarasov

unread,
Jun 1, 2016, 6:39:14 AM6/1/16
to OpenEaagles
1. Make sure network ports in MainSim3(2) and in SimpleOtw are setup correctly.
2. Run makeEdl.bat for modified test0.epp in MainSim3(2)
3. Run makeEdl.bat for test.epp in SimpleOtw.
4. You don't need to modified *.edl files since they are generated based on *.epp files. But once you modify *.epp you must run makeEdl.bat to produce updated *.edl.
5. Try to use netcat to listen output port for MainSim3(2). Syntax is: netcat -ul -p <port_number>. If data on <port_number> is displayed by netcat then double check step 1.

Adrian

unread,
Jun 1, 2016, 9:09:51 AM6/1/16
to OpenEaagles
Eureka!
running the .bat was the key.
Thank you again, Elias.
Thank you too, Doug.  I can imagine all sorts of possibilities with this library as a starting point.

Adrian. 

Doug

unread,
Jun 1, 2016, 6:49:54 PM6/1/16
to OpenEaagles
Commits come through me -- posting or sending a zip file works.  Some folks fork the repo, make their changes, then send me a pull request.

But for now, especially for something like a new example, just posting it works.

Doug

Doug

unread,
Jun 1, 2016, 6:53:08 PM6/1/16
to OpenEaagles

This is excellent -- I want to cut a release and get that monkey off my back (its been almost a year), then return to add this code into main branch.

The DLL requirements, and osg in general is the aspect I want to spend a little time on.... I need to compile osg for VS2013 and VS2015 (both release and debug) to properly outfit everything in Windows.

On linux, I might just add some config options to locate those dependencies.

I really need to transition to cmake, it should help with overall configuration for things like this...

Thanks again!
Doug

Reply all
Reply to author
Forward
0 new messages