Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2009-08-102.5: Sound branch merge!Joerg Mueller
See mailing list for additional information.
2009-08-04svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r22130:22205Campbell Barton
2009-08-03* remove unused member of KX_Scene - m_objecttreeCampbell Barton
* implicit declaration of getenv in glutil.c
2009-07-31svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r21908:22075Campbell Barton
2009-07-26ReplaceMesh Actuator option to replace the physics mesh and display mesh + ↵Campbell Barton
python api options. When the mesh field is left blank and Physics option is enabled, it reinstances the physics mesh from the existing mesh. like calling gameOb.reinstancePhysicsMesh() from python.
2009-06-29BGE Py API using python3 c/api calls. include bpy_compat.h to support py2.xCampbell Barton
2009-06-28BGE Python APICampbell Barton
Remove the last of the odd C++/python wrapper code from http://www.python.org/doc/PyCPP.html (~1998) * Use python subclasses rather then having fake subclassing through get/set attributes calling parent types. * PyObject getset arrays are created while initializing the types, converted from our own attribute arrays. This way python deals with subclasses and we dont have to define getattro or setattro functions for each type. * GameObjects and Scenes no longer have attribute access to properties. only dictionary style access - ob['prop'] * remove each class's get/set/dir functions. * remove isA() methods, can use PyObject_TypeCheck() in C and issubclass() in python. * remove Parents[] array for each C++ class, was only used for isA() and wasnt correct in quite a few cases. * remove PyTypeObject that was being passed as the last argument to each class (the parent classes too). TODO - * Light and VertexProxy need to be converted to using attributes. * memory for getset arrays is never freed, not that bad since its will only allocates once.
2009-06-092.50:Brecht Van Lommel
svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender -r19820:HEAD Notes: * Game and sequencer RNA, and sequencer header are now out of date a bit after changes in trunk. * I didn't know how to port these bugfixes, most likely they are not needed anymore. * Fix "duplicate strip" always increase the user count for ipo. * IPO pinning on sequencer strips was lost during Undo.
2009-06-05bpy.config.sequenceMemCacheLimit is the only way to set the memcache in ↵Campbell Barton
background mode and it didnt work. removed some unused vars from KX_Scene
2009-05-14BGE Py APICampbell Barton
scene.active_camera can now be set so you can more easily set the current camera from python scripts without using an actuator. ConvertPythonToCamera utility function to get a camera from a python string or KX_Camera type.
2009-05-11BGE performance, 4th round: logicBenoit Bolsee
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-04BGE performance: second round of scenegraph improvement.Benoit Bolsee
Use dynamic linked list to handle scenegraph rather than dumb scan of the whole tree. The performance improvement depends on the fraction of moving objects. If most objects are static, the speed up is considerable. The following table compares the time spent on scenegraph before and after this commit on a scene with 10000 objects in various configuratons: Scenegraph time (ms) Before After (includes culling) All objects static, 8.8 1.7 all visible but small fraction in the view frustrum All objects static, 7,5 0.01 all invisible. All objects moving, 14.1 8.4 all visible but small fraction in the view frustrum This tables shows that static and invisible objects take no CPU at all for scenegraph and culling. In the general case, this commit will speed up the scenegraph between 2x and 5x. Compared to 2.48a, it should be between 4x and 10x faster. Further speed up is possible by making the scenegraph cache-friendly. Next round of performance improvement will be on the rasterizer: use the same dynamic linked list technique for the mesh slots.
2009-04-28BGE PyAPICampbell Barton
- renamed generic attribute "isValid" to "invalid" since BL_Shader already uses isValid. - Moved deprecation warnings from CValue - removed unused KX_Scene::SetProjectionMatrix and KX_Scene::GetViewMatrix - Added KX_Scene attributes "lights", "cameras", "objects_inactive", to allow access to objects in unseen layers (before the AddObject actuator adds them) - KX_Camera deprecated cam.enableViewport(bool) for cam.isViewport which can be read as well.
2009-04-27Lower the vertex welding threshold, for removing duplicate/nearby vertices ↵Erwin Coumans
for soft bodies (this broke susanne softbody regression test)
2009-04-21BGE Python APICampbell Barton
Separate getting a normal attribute and getting __dict__, was having to do too a check for __dict__ on each class (multiple times per getattro call from python) when its not used that often.
2009-04-202.50: svn merge https://svn.blender.org/svnroot/bf-blender/trunk/blender ↵Brecht Van Lommel
-r19323:HEAD Notes: * blenderbuttons and ICON_SNAP_PEEL_OBJECT were not merged.
2009-04-18Added m_zombie to the base python class (PyObjectPlus), when this is set all ↵Campbell Barton
the subclasses will raise an error on access to their members. Other small changes... - KX_Camera and KX_Light didnt have get/setitem access in their PyType definition. - CList.from_id() error checking for a long was checking for -1 against an unsigned value (own fault) - CValue::SpecialRelease was incrementing an int for no reason. - renamed m_attrlist to m_attr_dict since its a PyDict type. - removed custom getattro/setattro functions for KX_Scene and KX_GameObject, use py_base_getattro, py_base_setattro for all subclasses of PyObjectPlus. - lowercase windows.h in VideoBase.cpp for cross compiling.
2009-04-14BGE: Occlusion culling and other performance improvements.Benoit Bolsee
Added occlusion culling capability in the BGE. More info: http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.49/Game_Engine#BGE_Scenegraph_improvement MSVC, scons, cmake, Makefile updated. Other minor performance improvements: - The rasterizer was computing the openGL model matrix of the objects too many times - DBVT view frustrum culling was not properly culling behind the near plane: Large objects behind the camera were sent to the GPU - Remove all references to mesh split/join feature as it is not yet functional
2009-04-12BGE Python APICampbell Barton
Support for assigning any Type to a KX_GameObject so you can do... gameOb.follow = otherGameOb gameOb[otherGameOb] = distanceTo gameOb["path"] = [(x,y,x), (x,y,x)] del gameOb[mesh] * types that cannot be converted into CValue types are written into the KX_GameObject dict * the KX_GameObject dict is only initialized when needed * Python properties in this dict cannot be accessed by logic bricks * dir(ob) and ob.getPropertyNames() return items from both CValue and Py dictionary properties. Also found that CType was converting python lists to CType Lists but very buggy, would crash after printing the list most times. Use python lists instead since logic bricks dont deal with lists.
2009-04-12BGE Python APICampbell Barton
added defines PY_SET_ATTR_FAIL, PY_SET_ATTR_MISSING and PY_SET_ATTR_SUCCESS This is useful when objects that have user defined attributes (GameObject and Scene) When calling setattr on the parent, a return value of PY_SET_ATTR_FAIL means the attribute exists but failed to be set, so don't set the custom attribute.
2009-04-12BGE Py APICampbell Barton
- setting the scene attributes would always add to the scenes custom dictionary. - new CListValue method from_id(id) so you can store a Game Objects id and use it to get the game object back. ob_id = id(gameOb) ... gameOb = scene.objects.from_id(ob_id) This is useful because names are not always unique.
2009-04-08BGE Scenegraph and View frustrum culling improvement.Benoit Bolsee
This commit contains a number of performance improvements for the BGE in the Scenegraph (parent relation between objects in the scene) and view frustrum culling. The scenegraph improvement consists in avoiding position update if the object has not moved since last update and the removal of redundant updates and synchronization with the physics engine. The view frustrum culling improvement consists in using the DBVT broadphase facility of Bullet to build a tree of graphical objects in the scene. The elements of the tree are Aabb boxes (Aligned Axis Bounding Boxes) enclosing the objects. This provides good precision in closed and opened scenes. This new culling system is enabled by default but just in case, it can be disabled with a button in the World settings. There is no do_version in this commit but it will be added before the 2.49 release. For now you must manually enable the DBVT culling option in World settings when you open an old file. The above improvements speed up scenegraph and culling up to 5x. However, this performance improvement is only visible when you have hundreds or thousands of objects. The main interest of the DBVT tree is to allow easy occlusion culling and automatic LOD system. This will be the object of further improvements.
2009-04-03Python BGE APICampbell Barton
- Initialize python types with PyType_Ready, which adds methods to the type dictionary. - use Pythons get/setattro (uses a python string for the attribute rather then char*). Using basic C strings seems nice but internally python converts them to python strings and discards them for most functions that accept char arrays. - Method lookups use the PyTypes dictionary (should be faster then Py_FindMethod) - Renamed __getattr -> py_base_getattro, _getattr -> py_getattro, __repr -> py_base_repr, py_delattro, py_getattro_self etc. From here is possible to put all the parent classes methods into each python types dictionary to avoid nested lookups (api has 4 levels of lookups in some places), tested this but its not ready yet. Simple tests for getting a method within a loop show this to be between 0.5 and 3.2x faster then using Py_FindMethod()
2009-04-03BGE PythonCampbell Barton
- Bugfix for running dir() on all BGE python objects. was not getting the immediate methods and attributes for each class. - Use attributes for KX_Scene (so they are included with dir()) - Override __dict__ attributes for KX_Scene and KX_GameObject so custom properties are included with a dir()
2009-03-01BGE patch #18309 commited: Add an addObject() method to KX_Scene.Benoit Bolsee
2009-02-28BGE Python APICampbell Barton
* Scene's and GameObjects can now be printed (raised an exception) * Added GameLogic.getSceneList()
2009-02-23BGE Python APICampbell Barton
* fixed segfaults in CListValue.index(val) and CListValue.count(val) when the pyTypes could not be converted into a CValue. * added scene.objects to replace scene.getObjectList() * added function names to PyArg_ParseTuple() so errors will include the function names * removed cases of PyArg_ParseTuple(args,"O",&pyobj) where METH_O ensures a single argument. * Made PyObjectFrom use ugly python api rather then Py_BuildValue(), approx %40 speedup for functions that return Python vector and matrix types like ob.orientation.
2009-02-19BGE Python APICampbell Barton
Use 'const char *' rather then the C++ 'STR_String' type for the attribute identifier of python attributes. Each attribute and method access from python was allocating and freeing the string. A simple test with getting an attribute a loop shows this speeds up attribute lookups a bit over 2x.
2008-09-05Merge of first part of changes from the apricot branch, especiallyBrecht Van Lommel
the features that are needed to run the game. Compile tested with scons, make, but not cmake, that seems to have an issue not related to these changes. The changes include: * GLSL support in the viewport and game engine, enable in the game menu in textured draw mode. * Synced and merged part of the duplicated blender and gameengine/ gameplayer drawing code. * Further refactoring of game engine drawing code, especially mesh storage changed a lot. * Optimizations in game engine armatures to avoid recomputations. * A python function to get the framerate estimate in game. * An option take object color into account in materials. * An option to restrict shadow casters to a lamp's layers. * Increase from 10 to 18 texture slots for materials, lamps, word. An extra texture slot shows up once the last slot is used. * Memory limit for undo, not enabled by default yet because it needs the .B.blend to be changed. * Multiple undo for image painting. * An offset for dupligroups, so not all objects in a group have to be at the origin.
2008-08-21BGE bug #17491 fixed: BGE, Dupli instance with different scale, massive ↵Benoit Bolsee
slowdown. The root cause of this bug is the fact that Bullet shapes are shared between duplicated game objects. As the physics object scale is stored in the shape, all duplicas must have the same scale otherwise the physics representation is incorrect. This fix introduces a mechanism to duplicate shapes at runtime so that Bullet shapes are not shared anymore. The drawback is an increased memory consuption. A reference count mechanism will be introduced in a later revision to keep Bullet shape shared between duplicas that have the same scale.
2008-07-18BGE patch: support for partial hierarchy in dupligroup instantiation; ↵Benoit Bolsee
removal of links that point to inactive objects during group instantiation. This situation corresponds to a group containing only a portion of a parent hierarchy (the Apricot team needed that to avoid logic duplication). The BGE will instantiate only the children that are in the group so that it follows the 3D view more closely. As a result, the logic links to the objects in the portion of the hierarchy that was not replicated will point to inactive objects (if the groups are stored in inactive layers as they should be). To keep the logic system consistent, these links are automatically removed. This last part of the patch is a general fix that could go in 2.47 but as this situation does not normally occurs in pre-2.47 games, it is not needed.
2008-07-16BGE patch: DUPLIGROUP option supported in BGE.Benoit Bolsee
Blender duplicates groups in the 3D view at the location of objects having the DUPLIGROUP option set. This feature is now supported in the BGE: the groups will be instantiated as in the 3D view when the scene is converted. This is useful to populate a scene with multiple enemies without having to actually duplicate the objects in the blend file. Notes: * The BGE applies the same criteria to instantiate the group as Blender to display them: if you see the group in the 3D view, it will be instantiated in the BGE. * Groups are instantiated as if the object having the DUPLIGROUP option (usually an empty) executed an AddObject actuator on the top objects of the group (objects without parent). * As a result, only intra-group parent relationship is supported: the BGE will not instantiate objects that have parents outside the group. * Intra-group logic bricks connections are preserved between the duplicated objects, even between the top objects of the group. * For best result, the state engine of the objects in the group should be self-contained: logic bricks should only have intra-group connections. Use messages to communicate with state engines outside the group. * Nested groups are supported: if one or more objects in the group have the DUPLIGROUP option set, the corresponding groups will be instantiated at the corresponding position and orientation. * Nested groups are instantiated as separate groups, not as one big group. * Linked groups are supported as well as groups containing objects from the active layers. * There is a difference in the way Blender displays the groups in the 3D view and how BGE instantiates them: Blender does not take into account the parent relationship in the group and displays the objects as if they were all children of the object having the DUPLIGROUP option. That's correct for the top objects of the group but not for the children. Hence the orientation of the children objects may be different in the BGE. * An AddGroup actuator will be added in a future release.
2008-07-10Sync with Apricot Game EngineBrecht Van Lommel
============================= * Clean up and optimizations in skinned/deformed mesh code. * Compatibility fixes and clean up in the rasterizer. * Changes related to GLSL shadow buffers which should have no effect, to keep the code in sync with apricot.
2008-04-17Patch from GSR that a) fixes a whole bunch of GPL/BL licenseChris Want
blocks that were previously missed; and b) greatly increase my ohloh stats!
2008-03-24Commit patch #8724:Benoit Bolsee
This patch modifies the BL_ConvertMesh method from the data conversion module in order to reduce the number of polygon material objects that are created. Normally, there should be only one material object for each material bucket(the group of meshes that are rendered together with a single material). However, the number of materials that are created right now in the converter is much higher and eats a lot of memory in scenes with large polygon counts. This patch deletes those material objects(KX_BlenderMaterial) that are used only temporarily in the converter(and are now deleted only when the converter is destroyed, at the end of the game). For a cube that's subdivided 7 times(90+ k polygons) I get 200 MB usage in the game engine in 2.45 and 44 MB with a svn build with this patch applied if the "Use Blender Materials" option is activated in the Game menu.
2008-03-10BGE fix: game object to controller links consistancy maintained regardless ↵Benoit Bolsee
of order of deletion AddObject actuator forces last created object to hang in memory even after object is removed from scene => bad link between object and physic controller that causes Blender to crash in case a python script tries to use it (bad programming anyway). This patch avoids the crash by maintaining consistent links at all time.
2008-03-10BGE memleak fixed: mesh/material not deleted when switching sceneBenoit Bolsee
2008-03-01Various mem leaks related to CValue reference count fixedBenoit Bolsee
2008-02-16patch 8235 8218 8211 added: various gameengine improvements, fixed windows ↵Benoit Bolsee
project files
2006-05-23-added basic support for GameActuator 'load game', relative paths were ↵Erwin Coumans
broken, just load file into memory and load blend from memory. -near sensor support - python binding for PhysicsConstraints.setNumTimeSubSteps (dividing the physics timestep to tradeoff quality for performance)
2006-01-06Sorry to break the cvs-closed status, so if you really need to make a new ↵Erwin Coumans
2.40 build, just disable the game engine if it doesn't compile for a platform. Again, sorry if this breaks non-windows platforms, but I hope people help to get this amazing fix working for all platforms. Armature-fixing contribution from Snailrose. Also lots of cool things from Snailrose and Lagan. Armatures are back Split screen Double sided lightning Ambient lighting Alpha test Material IPO support (one per object atm) Blender materials GLSL shaders - Python access Up to three texture samplers from the material panel ( 2D & Cube map ) Python access to a second set of uv coordinates See http://www.elysiun.com/forum/viewtopic.php?t=58057
2005-12-18applying Volker Mische engine patchJean-Luc Peurière
correct bug #3594
2005-03-25Big patches:Kester Maddock
Erwin Coumans: Abstract the physics engine Charlie C: Joystick fixes Me: Moved the ray cast (shadows, mouse sensor & ray sensor)
2005-01-23Added Joystick sensor (from snailrose)Kester Maddock
2004-11-22Fix for bugs: 1788 (forces) and 1799 (python delattr on game objects)Kester Maddock
Use Polytope collision for faster mesh intersection tests, so SOLID can actually use that qhull lib now.
2004-10-16Switch fixed time system. Logic updates should now happen at 30Hz, physics ↵Kester Maddock
at 60Hz. (By default, use Python to set.) Some actuators still run at framerate (IPO, Action) for nice smooth animation, and an excuse to buy high end hardware. Keyboard sensors can now hook escape key. Ctrl-Break can be used from within blender if you've forgotten an end game actuator. Fixed a stupid bug preventing some actuators working (like TrackTo).
2004-07-17Port Python updates from Tuhopuu2:Kester Maddock
getType/setType to action/sound actuator (sgefant) Use a more generic python -> math conversion.
2004-06-26Minor Fixes:Kester Maddock
Better use of booleans for python #include fixes for Windows Python Doc fixes Use the farthest vertex as the face position when z sorting faces. (Camera is on -z axis!)
2004-06-07Python updates:Kester Maddock
Added scene module
2004-05-16Frustum Culling.Kester Maddock
- tests every object against the view frustum. - Tree based culling is there, need to build tree.