World Simulator: Difference between revisions
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
== Live simulations == | |||
It would be cool to be able setup a situation where a car is following a series of rules, and you can play God and add or subtract parts of the world while the system is live and watch how it behaves. (Saving changes...) | |||
I'd like to be able to add barriers, or stop signs, or whatever and test how the driving engine handles it. | |||
== Networking == | == Networking == | ||
I'd like to be able to have different robots race on different computers. This would be a nice feature for the world simulator in about 6 months :-) | I'd like to be able to have different robots race on different computers. This would be a nice feature for the world simulator in about 6 months :-) |
Revision as of 23:31, 1 July 2008
Live simulations
It would be cool to be able setup a situation where a car is following a series of rules, and you can play God and add or subtract parts of the world while the system is live and watch how it behaves. (Saving changes...)
I'd like to be able to add barriers, or stop signs, or whatever and test how the driving engine handles it.
Networking
I'd like to be able to have different robots race on different computers. This would be a nice feature for the world simulator in about 6 months :-)
Torcs in C#
Preliminary tasks:
- Compile torcs as a library, with very high interface: TorcsLaunch().
- Make a C# wrapper to it.
- Launch torcs from Mono.
(see linux/main.cpp)
Secondary tasks:
- Start plugging in other engines with C# APIs
New Physics Engine?
http://www.ode.org/ode-latest-userguide.html
ode.net
Torcs 3D Engine.
Reasons to throw away Torcs 3-d Engine
Here is the list of improvements we can get, mainly by making use of OpenGL 2.0 features (Shaders, Buffers Objects).
Without too much work we can achieve:
- Per-pixel lighting [1]
- Phong
- Fake sky reflections on coachwork and metallic parts (my personal algorithm) [2]
- Bump-mapping
- High-quality illumination model
Big work:
New engine
Modular architecture already make this possible. The 3D engine implements an interface (defined in interfaces/graphic.h), it is given the high-level information about the track and cars and have to build and display its own geometry from this.
Make it in C# ? For now making a C# wrapper for the renderer would imply calling C# from C, is that possible? If possible, the whole src/interfaces headers have to be wrapped to C# then. (Cf Torcs in C#)
Notes by Jeko for Jeko
It's almost pure OpenGL, so very easy to tweak.
Main work is done in src/modules/graphic/ssggraph/grmain.cpp
It builds a list of "screens" (main screen, mirrors, etc)
Each screen set up the opengl parameters he like and render track, then cars, etc..
Rendering of the car is done here: src/modules/graphic/ssggraph/grcar.cpp, grDrawCar()