Difference between revisions of "OpenRacing"

From SpaceElevatorWiki.com
Jump to: navigation, search
Line 2: Line 2:
 
[[Image:WIP-TorcsOgre-12.jpg|thumb|500px]]
 
[[Image:WIP-TorcsOgre-12.jpg|thumb|500px]]
 
= Intro =
 
= Intro =
OpenRacing is a racing game, but it is also a simulator which aims to develop better artificial intelligence for human-driving assistance and driverless cars. The core is based on the Torcs codebase, which is widely considered the best FOSS racing game, but is being methodically re-written into C#, ported to leverage the graphics engine Ogre, the physics engine ODE, the input system OIS, the widget API MyGui (which now has C# wrappers, at our request), and extended with a more general track model.
+
OpenRacing is a racing game, but it is also a simulator which aims to develop better artificial intelligence for human-driving assistance and driverless cars. The core is based on the Torcs codebase, which is widely considered the best FOSS racing game and which already has autonomous cars. However, the codebase contains a lot of cruft.
 +
 
 +
So, it is being methodically re-written into C#, ported to leverage the graphics engine Ogre, the physics engine ODE, the input system OIS, the widget API MyGui (which now has C# wrappers, at our request), and extended with a more general track model.
  
 
Then, we will have a clean and 10x smaller codebase for building smarter autonomous vehicles which can handle the complexities of urban scenarios, and can eventually navigate via the use of a vision recognition engine and simulated sensors like radar and GPS.
 
Then, we will have a clean and 10x smaller codebase for building smarter autonomous vehicles which can handle the complexities of urban scenarios, and can eventually navigate via the use of a vision recognition engine and simulated sensors like radar and GPS.

Revision as of 11:49, 15 July 2009

WIP-TorcsOgre-12.jpg

Intro

OpenRacing is a racing game, but it is also a simulator which aims to develop better artificial intelligence for human-driving assistance and driverless cars. The core is based on the Torcs codebase, which is widely considered the best FOSS racing game and which already has autonomous cars. However, the codebase contains a lot of cruft.

So, it is being methodically re-written into C#, ported to leverage the graphics engine Ogre, the physics engine ODE, the input system OIS, the widget API MyGui (which now has C# wrappers, at our request), and extended with a more general track model.

Then, we will have a clean and 10x smaller codebase for building smarter autonomous vehicles which can handle the complexities of urban scenarios, and can eventually navigate via the use of a vision recognition engine and simulated sensors like radar and GPS.

Current Status

The work in progress is here.

OpenRacing Universal Track Interface

Using_blender_as_a_track_editor

Building OpenRacing

OpenRacing hosted in Launchpad / Bzr

Source, etc. is here: Launchpad

Install the dependencies

These instructions assume Ubuntu. If you are running something else, your steps will vary slightly. Instructions here

Compile OpenRacing

Go into openracing's directory.

./autogen.sh

The script installs a few missing files and generate the usual configure script.

Then launch configure.

$ ./configure --with-ogredotnet=/full/path/to/ogredotnet-read-only/bin \
  --with-myguinet=/full/path/to/mygui-or/Bin/Debug --with-tao=/full/path/to/tao/bin
$ make

If everything got right, an openracing script should have been generated. You can launch it immediately or install OpenRacing into the system.

$ sudo make install

And launch!

openracing

If it doesn't work, please complain to us so we can fix the bugs!

Troubleshooting

It occurs that for some mysterious reasons, mono can't load OR's libsimulator native library. Simple work-around:

Go to the data/ directory. Create the following link:

 $ ln -s ../src/libsimulator/.libs/libsimulator.so

That should work!

Using the Monodevelop project

For developers, a monodevelop project is now available, allowing to edit and launch C# parts of OpenRacing from a nice all-integrated GUI.

First, you must compile openracing as shown above. The compilation process generated for you a monodevelop.sh script.

But before to launch it there is a little hack to do...

Go to the src/ directory. A create link to Ode, OgreDotNet and MyGUI's DLLs. This is what I did on my system, please adapt it to yours:

$ ln -s /home/jeko/Sources/deps/taoframework-2.1.0/bin/Tao.Ode.dll
$ ln -s /home/jeko/Sources/deps/ogredotnet/bin/Math3D.dll   
$ ln -s /home/jeko/Sources/deps/ogredotnet/bin/OgreDotNet.dll
$ ln -s /home/jeko/Sources/deps/MyGUI-OR/Bin/Debug/MyGUI.dll

This makes sure monodevelop will find the necessary references needed to compile OpenRacing. (I tried hard to make this better, but it seems impossible)..

Then you can launch:

./monodevelop.sh

The scripts sets some environment variables (so that uninstalled shared libraries from OgreDotNet and MyGUI can be found for execution). Last hack before you're done: you must edit Config.cs file (which appears at the end of the file list):

replace:

public static string OPENRACING_DATA_PATH = "/home/jeko/Sources/openracing/data";

by:

public static string OPENRACING_DATA_PATH = "/full/path/to/openracing/data";

You're done, make sure the Debug configuration is enabled to enjoy executing OpenRacing inside a nice visual debugger.

Happy hacking!