blender/source/gameengine
Benoit Bolsee 386122ada6 BGE performance, 4th round: logic
This commit extends the technique of dynamic linked list to the logic
system to eliminate as much as possible temporaries, map lookup or 
full scan. The logic engine is now free of memory allocation, which is
an important stability factor. 

The overhead of the logic system is reduced by a factor between 3 and 6
depending on the logic setup. This is the speed-up you can expect on 
a logic setup using simple bricks. Heavy bricks like python controllers
and ray sensors will still take about the same time to execute so the
speed up will be less important.

The core of the logic engine has been much reworked but the functionality
is still the same except for one thing: the priority system on the 
execution of controllers. The exact same remark applies to actuators but
I'll explain for controllers only:

Previously, it was possible, with the "executePriority" attribute to set
a controller to run before any other controllers in the game. Other than
that, the sequential execution of controllers, as defined in Blender was
guaranteed by default.

With the new system, the sequential execution of controllers is still 
guaranteed but only within the controllers of one object. the user can
no longer set a controller to run before any other controllers in the
game. The "executePriority" attribute controls the execution of controllers
within one object. The priority is a small number starting from 0 for the
first controller and incrementing for each controller.

If this missing feature is a must, a special method can be implemented
to set a controller to run before all other controllers.

Other improvements:
- Systematic use of reference in parameter passing to avoid unnecessary data copy
- Use pre increment in iterator instead of post increment to avoid temporary allocation
- Use const char* instead of STR_String whenever possible to avoid temporary allocation
- Fix reference counting bugs (memory leak)
- Fix a crash in certain cases of state switching and object deletion
- Minor speed up in property sensor
- Removal of objects during the game is a lot faster
2009-05-10 20:53:58 +00:00
..
BlenderRoutines BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
Converter BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
Expressions BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
GameLogic BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
GamePlayer added Geometry as a BGE module, removed its dependency on gen_utils.c 2009-04-30 12:45:13 +00:00
Ketsji BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
Network BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
Physics BGE: work around a problem with DBVT culling when graphic objects are rescaled. This happens when objects with very diverse scale are instantiated with dupligroup. The problem remains when the objects are rescaled during the game. The effect of the problem is an inefficient culling: objects can have a bounding box larger than needed. Patch to fix the problem is filed at Bullet forum. 2009-05-01 19:02:23 +00:00
PyDoc deprecate controller.getActuator(name) and controller.getSensor(name) for 2009-05-10 01:48:14 +00:00
Rasterizer BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
SceneGraph BGE performance, 4th round: logic 2009-05-10 20:53:58 +00:00
VideoTexture BGE performance, 3rd round: culling and rasterizer. 2009-05-07 09:13:01 +00:00
CMakeLists.txt VideoTexture module. 2008-10-31 22:35:52 +00:00
Makefile Makefile fixes for compiling with new videotexture code. 2008-11-02 18:12:45 +00:00
SConscript Building the game engine with Solid/Sumo is now optional for scons using WITH_BF_SOLID. 2009-02-25 12:07:51 +00:00