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
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-09-16 08:58:18 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-09-16 08:58:18 +0400
commit2fb82920059257fd7ac8e33bfe53de13e7ed53bd (patch)
treecb8de3a839cb9878d0869d4e436a235346109c16
parentc2a1dcf6218cbd56126a5deb1aeaf212d67e54cb (diff)
style cleanup
-rw-r--r--intern/audaspace/Python/AUD_PyAPI.cpp132
-rw-r--r--intern/audaspace/Python/AUD_PyAPI.h8
-rw-r--r--intern/audaspace/intern/AUD_PyInit.h2
-rw-r--r--intern/memutil/MEM_SmartPtr.h6
-rw-r--r--source/blender/blenkernel/intern/icons.c4
-rw-r--r--source/blender/blenkernel/intern/idprop.c4
-rw-r--r--source/blender/blenkernel/intern/mball.c16
-rw-r--r--source/blender/blenkernel/intern/sca.c8
-rw-r--r--source/blender/blenlib/intern/path_util.c2
-rw-r--r--source/blender/blenlib/intern/scanfill.c4
-rw-r--r--source/blender/blenlib/intern/storage.c2
-rw-r--r--source/blender/imbuf/intern/scaling.c2
-rw-r--r--source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp4
-rw-r--r--source/gameengine/BlenderRoutines/KX_BlenderCanvas.cpp4
-rw-r--r--source/gameengine/BlenderRoutines/KX_BlenderGL.cpp2
-rw-r--r--source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp2
-rw-r--r--source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h2
-rw-r--r--source/gameengine/Converter/BL_ActionActuator.cpp14
-rw-r--r--source/gameengine/Converter/BL_ArmatureActuator.cpp12
-rw-r--r--source/gameengine/Converter/BL_ArmatureActuator.h4
-rw-r--r--source/gameengine/Converter/BL_ArmatureChannel.cpp14
-rw-r--r--source/gameengine/Converter/BL_ArmatureChannel.h6
-rw-r--r--source/gameengine/Converter/BL_ArmatureConstraint.cpp12
-rw-r--r--source/gameengine/Converter/BL_ArmatureConstraint.h4
-rw-r--r--source/gameengine/Converter/BL_ArmatureObject.cpp8
-rw-r--r--source/gameengine/Converter/BL_ArmatureObject.h4
-rw-r--r--source/gameengine/Converter/BL_BlenderDataConversion.cpp20
-rw-r--r--source/gameengine/Converter/BL_DeformableGameObject.h2
-rw-r--r--source/gameengine/Converter/BL_MeshDeformer.cpp2
-rw-r--r--source/gameengine/Converter/BL_ModifierDeformer.cpp2
-rw-r--r--source/gameengine/Converter/BL_ModifierDeformer.h2
-rw-r--r--source/gameengine/Converter/BL_ShapeActionActuator.cpp4
-rw-r--r--source/gameengine/Converter/BL_ShapeDeformer.h2
-rw-r--r--source/gameengine/Converter/BL_SkinDeformer.cpp4
-rw-r--r--source/gameengine/Converter/BlenderWorldInfo.cpp6
-rw-r--r--source/gameengine/Converter/BlenderWorldInfo.h10
-rw-r--r--source/gameengine/Converter/KX_BlenderScalarInterpolator.cpp2
-rw-r--r--source/gameengine/Converter/KX_BlenderScalarInterpolator.h2
-rw-r--r--source/gameengine/Converter/KX_BlenderSceneConverter.cpp28
-rw-r--r--source/gameengine/Converter/KX_ConvertActuators.cpp2
-rw-r--r--source/gameengine/Converter/KX_ConvertControllers.cpp2
-rw-r--r--source/gameengine/Converter/KX_ConvertProperties.cpp2
-rw-r--r--source/gameengine/Converter/KX_ConvertSensors.cpp12
-rw-r--r--source/gameengine/Converter/KX_IpoConvert.cpp8
-rw-r--r--source/gameengine/Expressions/BoolValue.cpp2
-rw-r--r--source/gameengine/Expressions/BoolValue.h2
-rw-r--r--source/gameengine/Expressions/FloatValue.cpp2
-rw-r--r--source/gameengine/Expressions/InputParser.cpp4
-rw-r--r--source/gameengine/Expressions/IntValue.cpp2
-rw-r--r--source/gameengine/Expressions/KX_HashedPtr.h2
-rw-r--r--source/gameengine/Expressions/ListValue.cpp36
-rw-r--r--source/gameengine/Expressions/ListValue.h2
-rw-r--r--source/gameengine/Expressions/Operator2Expr.cpp6
-rw-r--r--source/gameengine/Expressions/PyObjectPlus.cpp18
-rw-r--r--source/gameengine/Expressions/PyObjectPlus.h48
-rw-r--r--source/gameengine/Expressions/StringValue.h2
-rw-r--r--source/gameengine/Expressions/Value.cpp12
-rw-r--r--source/gameengine/Expressions/Value.h26
-rw-r--r--source/gameengine/GameLogic/Joystick/SCA_Joystick.h2
-rw-r--r--source/gameengine/GameLogic/SCA_IController.cpp10
-rw-r--r--source/gameengine/GameLogic/SCA_IInputDevice.cpp4
-rw-r--r--source/gameengine/GameLogic/SCA_IInputDevice.h24
-rw-r--r--source/gameengine/GameLogic/SCA_ILogicBrick.cpp6
-rw-r--r--source/gameengine/GameLogic/SCA_ILogicBrick.h2
-rw-r--r--source/gameengine/GameLogic/SCA_IObject.cpp2
-rw-r--r--source/gameengine/GameLogic/SCA_IObject.h4
-rw-r--r--source/gameengine/GameLogic/SCA_ISensor.cpp12
-rw-r--r--source/gameengine/GameLogic/SCA_JoystickSensor.cpp22
-rw-r--r--source/gameengine/GameLogic/SCA_KeyboardManager.h2
-rw-r--r--source/gameengine/GameLogic/SCA_KeyboardSensor.cpp23
-rw-r--r--source/gameengine/GameLogic/SCA_KeyboardSensor.h2
-rw-r--r--source/gameengine/GameLogic/SCA_MouseManager.h2
-rw-r--r--source/gameengine/GameLogic/SCA_MouseSensor.cpp10
-rw-r--r--source/gameengine/GameLogic/SCA_PropertyActuator.cpp2
-rw-r--r--source/gameengine/GameLogic/SCA_PythonController.cpp14
-rw-r--r--source/gameengine/GameLogic/SCA_PythonController.h12
-rw-r--r--source/gameengine/GameLogic/SCA_PythonKeyboard.cpp8
-rw-r--r--source/gameengine/GameLogic/SCA_PythonKeyboard.h2
-rw-r--r--source/gameengine/GameLogic/SCA_PythonMouse.cpp12
-rw-r--r--source/gameengine/GameLogic/SCA_PythonMouse.h14
-rw-r--r--source/gameengine/GameLogic/SCA_RandomActuator.cpp14
-rw-r--r--source/gameengine/GameLogic/SCA_RandomActuator.h6
-rw-r--r--source/gameengine/GameLogic/SCA_RandomSensor.cpp2
-rw-r--r--source/gameengine/GameLogic/SCA_TimeEventManager.cpp2
-rw-r--r--source/gameengine/GamePlayer/common/GPC_Canvas.cpp2
-rw-r--r--source/gameengine/GamePlayer/common/GPC_Canvas.h4
-rw-r--r--source/gameengine/GamePlayer/common/GPC_MouseDevice.cpp6
-rw-r--r--source/gameengine/GamePlayer/common/GPC_RawImage.cpp2
-rw-r--r--source/gameengine/GamePlayer/common/GPC_RenderTools.cpp2
-rw-r--r--source/gameengine/GamePlayer/common/bmfont.cpp2
-rw-r--r--source/gameengine/GamePlayer/ghost/GPG_Application.cpp10
-rw-r--r--source/gameengine/GamePlayer/ghost/GPG_ghost.cpp14
-rw-r--r--source/gameengine/Ketsji/BL_Shader.cpp18
-rw-r--r--source/gameengine/Ketsji/BL_Shader.h2
-rw-r--r--source/gameengine/Ketsji/BL_Texture.cpp10
-rw-r--r--source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.cpp6
-rw-r--r--source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.h2
-rw-r--r--source/gameengine/Ketsji/KX_ArmatureSensor.cpp6
-rw-r--r--source/gameengine/Ketsji/KX_ArmatureSensor.h2
-rw-r--r--source/gameengine/Ketsji/KX_BlenderMaterial.cpp16
-rw-r--r--source/gameengine/Ketsji/KX_BlenderMaterial.h8
-rw-r--r--source/gameengine/Ketsji/KX_BulletPhysicsController.cpp2
-rw-r--r--source/gameengine/Ketsji/KX_Camera.cpp38
-rw-r--r--source/gameengine/Ketsji/KX_Camera.h8
-rw-r--r--source/gameengine/Ketsji/KX_CameraActuator.cpp4
-rw-r--r--source/gameengine/Ketsji/KX_CameraIpoSGController.h6
-rw-r--r--source/gameengine/Ketsji/KX_ConstraintActuator.cpp6
-rw-r--r--source/gameengine/Ketsji/KX_ConstraintActuator.h2
-rw-r--r--source/gameengine/Ketsji/KX_ConstraintWrapper.cpp8
-rw-r--r--source/gameengine/Ketsji/KX_ConstraintWrapper.h2
-rw-r--r--source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp4
-rw-r--r--source/gameengine/Ketsji/KX_Dome.cpp58
-rw-r--r--source/gameengine/Ketsji/KX_FontObject.cpp2
-rw-r--r--source/gameengine/Ketsji/KX_GameObject.cpp174
-rw-r--r--source/gameengine/Ketsji/KX_GameObject.h82
-rw-r--r--source/gameengine/Ketsji/KX_IInterpolator.h2
-rw-r--r--source/gameengine/Ketsji/KX_IScalarInterpolator.h2
-rw-r--r--source/gameengine/Ketsji/KX_IpoActuator.cpp10
-rw-r--r--source/gameengine/Ketsji/KX_KetsjiEngine.cpp46
-rw-r--r--source/gameengine/Ketsji/KX_KetsjiEngine.h8
-rw-r--r--source/gameengine/Ketsji/KX_Light.cpp10
-rw-r--r--source/gameengine/Ketsji/KX_Light.h4
-rw-r--r--source/gameengine/Ketsji/KX_LightIpoSGController.h6
-rw-r--r--source/gameengine/Ketsji/KX_MeshProxy.cpp24
-rw-r--r--source/gameengine/Ketsji/KX_MeshProxy.h6
-rw-r--r--source/gameengine/Ketsji/KX_MouseFocusSensor.cpp16
-rw-r--r--source/gameengine/Ketsji/KX_NavMeshObject.cpp16
-rw-r--r--source/gameengine/Ketsji/KX_ObjectActuator.cpp20
-rw-r--r--source/gameengine/Ketsji/KX_ObstacleSimulation.cpp14
-rw-r--r--source/gameengine/Ketsji/KX_ObstacleSimulation.h8
-rw-r--r--source/gameengine/Ketsji/KX_ParentActuator.cpp6
-rw-r--r--source/gameengine/Ketsji/KX_ParentActuator.h2
-rw-r--r--source/gameengine/Ketsji/KX_PhysicsObjectWrapper.cpp8
-rw-r--r--source/gameengine/Ketsji/KX_PolyProxy.cpp22
-rw-r--r--source/gameengine/Ketsji/KX_PolyProxy.h20
-rw-r--r--source/gameengine/Ketsji/KX_PolygonMaterial.cpp18
-rw-r--r--source/gameengine/Ketsji/KX_PolygonMaterial.h6
-rw-r--r--source/gameengine/Ketsji/KX_PyConstraintBinding.cpp128
-rw-r--r--source/gameengine/Ketsji/KX_PyMath.cpp18
-rw-r--r--source/gameengine/Ketsji/KX_PyMath.h20
-rw-r--r--source/gameengine/Ketsji/KX_PythonInit.cpp252
-rw-r--r--source/gameengine/Ketsji/KX_PythonInit.h14
-rw-r--r--source/gameengine/Ketsji/KX_PythonInitTypes.h6
-rw-r--r--source/gameengine/Ketsji/KX_PythonSeq.cpp12
-rw-r--r--source/gameengine/Ketsji/KX_RadarSensor.cpp2
-rw-r--r--source/gameengine/Ketsji/KX_RaySensor.cpp2
-rw-r--r--source/gameengine/Ketsji/KX_RaySensor.h2
-rw-r--r--source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp12
-rw-r--r--source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h6
-rw-r--r--source/gameengine/Ketsji/KX_SCA_DynamicActuator.cpp6
-rw-r--r--source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.cpp2
-rw-r--r--source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.h2
-rw-r--r--source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.cpp6
-rw-r--r--source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.h2
-rw-r--r--source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp16
-rw-r--r--source/gameengine/Ketsji/KX_SG_NodeRelationships.h12
-rw-r--r--source/gameengine/Ketsji/KX_Scene.cpp51
-rw-r--r--source/gameengine/Ketsji/KX_Scene.h40
-rw-r--r--source/gameengine/Ketsji/KX_SceneActuator.cpp4
-rw-r--r--source/gameengine/Ketsji/KX_SceneActuator.h2
-rw-r--r--source/gameengine/Ketsji/KX_SoundActuator.cpp20
-rw-r--r--source/gameengine/Ketsji/KX_SoundActuator.h12
-rw-r--r--source/gameengine/Ketsji/KX_SteeringActuator.cpp32
-rw-r--r--source/gameengine/Ketsji/KX_SteeringActuator.h12
-rw-r--r--source/gameengine/Ketsji/KX_TouchSensor.cpp4
-rw-r--r--source/gameengine/Ketsji/KX_TouchSensor.h2
-rw-r--r--source/gameengine/Ketsji/KX_TrackToActuator.cpp12
-rw-r--r--source/gameengine/Ketsji/KX_TrackToActuator.h4
-rw-r--r--source/gameengine/Ketsji/KX_VehicleWrapper.cpp34
-rw-r--r--source/gameengine/Ketsji/KX_VertexProxy.cpp52
-rw-r--r--source/gameengine/Ketsji/KX_VertexProxy.h30
-rw-r--r--source/gameengine/Ketsji/KX_WorldIpoController.h6
-rw-r--r--source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.h2
-rw-r--r--source/gameengine/Network/NG_NetworkScene.h4
-rw-r--r--source/gameengine/Physics/Bullet/CcdGraphicController.h2
-rw-r--r--source/gameengine/Physics/Bullet/CcdPhysicsController.cpp14
-rw-r--r--source/gameengine/Physics/Bullet/CcdPhysicsController.h4
-rw-r--r--source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp27
-rw-r--r--source/gameengine/Physics/common/PHY_DynamicTypes.h12
-rw-r--r--source/gameengine/Physics/common/PHY_IController.h2
-rw-r--r--source/gameengine/Physics/common/PHY_IMotionState.h2
-rw-r--r--source/gameengine/Physics/common/PHY_IPhysicsEnvironment.h2
-rw-r--r--source/gameengine/Rasterizer/RAS_2DFilterManager.cpp4
-rw-r--r--source/gameengine/Rasterizer/RAS_BucketManager.cpp4
-rw-r--r--source/gameengine/Rasterizer/RAS_Deformer.h2
-rw-r--r--source/gameengine/Rasterizer/RAS_FramingManager.cpp14
-rw-r--r--source/gameengine/Rasterizer/RAS_FramingManager.h8
-rw-r--r--source/gameengine/Rasterizer/RAS_IRasterizer.h2
-rw-r--r--source/gameengine/Rasterizer/RAS_IRenderTools.h30
-rw-r--r--source/gameengine/Rasterizer/RAS_MaterialBucket.cpp8
-rw-r--r--source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp4
-rw-r--r--source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h2
-rw-r--r--source/gameengine/SceneGraph/SG_Controller.h8
-rw-r--r--source/gameengine/SceneGraph/SG_IObject.cpp2
-rw-r--r--source/gameengine/SceneGraph/SG_IObject.h8
-rw-r--r--source/gameengine/SceneGraph/SG_Node.cpp2
-rw-r--r--source/gameengine/SceneGraph/SG_Node.h18
-rw-r--r--source/gameengine/SceneGraph/SG_ParentRelation.h2
-rw-r--r--source/gameengine/SceneGraph/SG_Spatial.cpp4
-rw-r--r--source/gameengine/SceneGraph/SG_Spatial.h12
-rw-r--r--source/gameengine/VideoTexture/BlendType.h13
-rw-r--r--source/gameengine/VideoTexture/FilterBase.cpp10
-rw-r--r--source/gameengine/VideoTexture/FilterBase.h12
-rw-r--r--source/gameengine/VideoTexture/FilterBlueScreen.cpp10
-rw-r--r--source/gameengine/VideoTexture/FilterColor.cpp12
-rw-r--r--source/gameengine/VideoTexture/FilterNormal.cpp10
-rw-r--r--source/gameengine/VideoTexture/ImageBase.cpp44
-rw-r--r--source/gameengine/VideoTexture/ImageBase.h36
-rw-r--r--source/gameengine/VideoTexture/ImageBuff.cpp16
-rw-r--r--source/gameengine/VideoTexture/ImageMix.cpp4
-rw-r--r--source/gameengine/VideoTexture/ImageRender.cpp22
-rw-r--r--source/gameengine/VideoTexture/ImageViewport.cpp18
-rw-r--r--source/gameengine/VideoTexture/ImageViewport.h12
-rw-r--r--source/gameengine/VideoTexture/PyTypeList.cpp8
-rw-r--r--source/gameengine/VideoTexture/PyTypeList.h14
-rw-r--r--source/gameengine/VideoTexture/Texture.cpp18
-rw-r--r--source/gameengine/VideoTexture/Texture.h8
-rw-r--r--source/gameengine/VideoTexture/VideoBase.cpp29
-rw-r--r--source/gameengine/VideoTexture/VideoBase.h28
-rw-r--r--source/gameengine/VideoTexture/VideoFFmpeg.cpp12
-rw-r--r--source/gameengine/VideoTexture/VideoFFmpeg.h2
-rw-r--r--source/gameengine/VideoTexture/blendVideoTex.cpp16
222 files changed, 1480 insertions, 1471 deletions
diff --git a/intern/audaspace/Python/AUD_PyAPI.cpp b/intern/audaspace/Python/AUD_PyAPI.cpp
index 238249bc7c8..dd58e5a7398 100644
--- a/intern/audaspace/Python/AUD_PyAPI.cpp
+++ b/intern/audaspace/Python/AUD_PyAPI.cpp
@@ -80,7 +80,7 @@ typedef enum
// ====================================================================
-static PyObject* AUDError;
+static PyObject *AUDError;
static const char* device_not_3d_error = "Device is not a 3D device!";
@@ -92,7 +92,7 @@ Factory_dealloc(Factory* self)
if(self->factory)
delete reinterpret_cast<AUD_Reference<AUD_IFactory>*>(self->factory);
Py_XDECREF(self->child_list);
- Py_TYPE(self)->tp_free((PyObject*)self);
+ Py_TYPE(self)->tp_free((PyObject *)self);
}
static PyObject *
@@ -139,7 +139,7 @@ PyDoc_STRVAR(M_aud_Factory_sine_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_sine(PyTypeObject* type, PyObject* args)
+Factory_sine(PyTypeObject* type, PyObject *args)
{
float frequency;
double rate = 44100;
@@ -179,7 +179,7 @@ PyDoc_STRVAR(M_aud_Factory_file_doc,
"playback of that factory.");
static PyObject *
-Factory_file(PyTypeObject* type, PyObject* args)
+Factory_file(PyTypeObject* type, PyObject *args)
{
const char* filename = NULL;
@@ -218,7 +218,7 @@ PyDoc_STRVAR(M_aud_Factory_lowpass_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_lowpass(Factory* self, PyObject* args)
+Factory_lowpass(Factory* self, PyObject *args)
{
float frequency;
float Q = 0.5;
@@ -232,7 +232,7 @@ Factory_lowpass(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -260,7 +260,7 @@ PyDoc_STRVAR(M_aud_Factory_delay_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_delay(Factory* self, PyObject* args)
+Factory_delay(Factory* self, PyObject *args)
{
float delay;
@@ -273,7 +273,7 @@ Factory_delay(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -301,7 +301,7 @@ PyDoc_STRVAR(M_aud_Factory_join_doc,
"(channels and samplerate).");
static PyObject *
-Factory_join(Factory* self, PyObject* object)
+Factory_join(Factory* self, PyObject *object)
{
PyTypeObject* type = Py_TYPE(self);
@@ -346,7 +346,7 @@ PyDoc_STRVAR(M_aud_Factory_highpass_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_highpass(Factory* self, PyObject* args)
+Factory_highpass(Factory* self, PyObject *args)
{
float frequency;
float Q = 0.5;
@@ -360,7 +360,7 @@ Factory_highpass(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -388,7 +388,7 @@ PyDoc_STRVAR(M_aud_Factory_limit_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_limit(Factory* self, PyObject* args)
+Factory_limit(Factory* self, PyObject *args)
{
float start, end;
@@ -401,7 +401,7 @@ Factory_limit(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -432,7 +432,7 @@ PyDoc_STRVAR(M_aud_Factory_pitch_doc,
":attr:`Handle.pitch` instead.");
static PyObject *
-Factory_pitch(Factory* self, PyObject* args)
+Factory_pitch(Factory* self, PyObject *args)
{
float factor;
@@ -445,7 +445,7 @@ Factory_pitch(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -474,7 +474,7 @@ PyDoc_STRVAR(M_aud_Factory_volume_doc,
":attr:`Handle.volume` instead.");
static PyObject *
-Factory_volume(Factory* self, PyObject* args)
+Factory_volume(Factory* self, PyObject *args)
{
float volume;
@@ -487,7 +487,7 @@ Factory_volume(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -517,7 +517,7 @@ PyDoc_STRVAR(M_aud_Factory_fadein_doc,
".. note:: Before the fade starts it plays silence.");
static PyObject *
-Factory_fadein(Factory* self, PyObject* args)
+Factory_fadein(Factory* self, PyObject *args)
{
float start, length;
@@ -530,7 +530,7 @@ Factory_fadein(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -561,7 +561,7 @@ PyDoc_STRVAR(M_aud_Factory_fadeout_doc,
"the length of the factory is not altered.");
static PyObject *
-Factory_fadeout(Factory* self, PyObject* args)
+Factory_fadeout(Factory* self, PyObject *args)
{
float start, length;
@@ -574,7 +574,7 @@ Factory_fadeout(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -603,7 +603,7 @@ PyDoc_STRVAR(M_aud_Factory_loop_doc,
":attr:`Handle.loop_count` instead.");
static PyObject *
-Factory_loop(Factory* self, PyObject* args)
+Factory_loop(Factory* self, PyObject *args)
{
int loop;
@@ -616,7 +616,7 @@ Factory_loop(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -644,7 +644,7 @@ PyDoc_STRVAR(M_aud_Factory_mix_doc,
"(channels and samplerate).");
static PyObject *
-Factory_mix(Factory* self, PyObject* object)
+Factory_mix(Factory* self, PyObject *object)
{
PyTypeObject* type = Py_TYPE(self);
@@ -692,7 +692,7 @@ Factory_pingpong(Factory* self)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -731,7 +731,7 @@ Factory_reverse(Factory* self)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -795,7 +795,7 @@ PyDoc_STRVAR(M_aud_Factory_square_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_square(Factory* self, PyObject* args)
+Factory_square(Factory* self, PyObject *args)
{
float threshold = 0;
@@ -808,7 +808,7 @@ Factory_square(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -842,10 +842,10 @@ PyDoc_STRVAR(M_aud_Factory_filter_doc,
":rtype: :class:`Factory`");
static PyObject *
-Factory_filter(Factory* self, PyObject* args)
+Factory_filter(Factory* self, PyObject *args)
{
- PyObject* py_b;
- PyObject* py_a = NULL;
+ PyObject *py_b;
+ PyObject *py_a = NULL;
Py_ssize_t py_a_len;
Py_ssize_t py_b_len;
@@ -868,7 +868,7 @@ Factory_filter(Factory* self, PyObject* args)
}
std::vector<float> a, b;
- PyObject* py_value;
+ PyObject *py_value;
float value;
for(Py_ssize_t i = 0; i < py_b_len; i++)
@@ -911,7 +911,7 @@ Factory_filter(Factory* self, PyObject* args)
if(parent != NULL)
{
Py_INCREF(self);
- parent->child_list = (PyObject*)self;
+ parent->child_list = (PyObject *)self;
try
{
@@ -1040,7 +1040,7 @@ Handle_dealloc(Handle* self)
{
if(self->handle)
delete reinterpret_cast<AUD_Reference<AUD_IHandle>*>(self->handle);
- Py_TYPE(self)->tp_free((PyObject*)self);
+ Py_TYPE(self)->tp_free((PyObject *)self);
}
PyDoc_STRVAR(M_aud_Handle_pause_doc,
@@ -1135,7 +1135,7 @@ Handle_get_position(Handle *self, void* nothing)
}
static int
-Handle_set_position(Handle *self, PyObject* args, void* nothing)
+Handle_set_position(Handle *self, PyObject *args, void* nothing)
{
float position;
@@ -1180,7 +1180,7 @@ Handle_get_keep(Handle *self, void* nothing)
}
static int
-Handle_set_keep(Handle *self, PyObject* args, void* nothing)
+Handle_set_keep(Handle *self, PyObject *args, void* nothing)
{
if(!PyBool_Check(args))
{
@@ -1239,7 +1239,7 @@ Handle_get_volume(Handle *self, void* nothing)
}
static int
-Handle_set_volume(Handle *self, PyObject* args, void* nothing)
+Handle_set_volume(Handle *self, PyObject *args, void* nothing)
{
float volume;
@@ -1278,7 +1278,7 @@ Handle_get_pitch(Handle *self, void* nothing)
}
static int
-Handle_set_pitch(Handle *self, PyObject* args, void* nothing)
+Handle_set_pitch(Handle *self, PyObject *args, void* nothing)
{
float pitch;
@@ -1317,7 +1317,7 @@ Handle_get_loop_count(Handle *self, void* nothing)
}
static int
-Handle_set_loop_count(Handle *self, PyObject* args, void* nothing)
+Handle_set_loop_count(Handle *self, PyObject *args, void* nothing)
{
int loops;
@@ -1366,7 +1366,7 @@ Handle_get_location(Handle *self, void* nothing)
}
static int
-Handle_set_location(Handle *self, PyObject* args, void* nothing)
+Handle_set_location(Handle *self, PyObject *args, void* nothing)
{
float x, y, z;
@@ -1422,7 +1422,7 @@ Handle_get_velocity(Handle *self, void* nothing)
}
static int
-Handle_set_velocity(Handle *self, PyObject* args, void* nothing)
+Handle_set_velocity(Handle *self, PyObject *args, void* nothing)
{
float x, y, z;
@@ -1478,7 +1478,7 @@ Handle_get_orientation(Handle *self, void* nothing)
}
static int
-Handle_set_orientation(Handle *self, PyObject* args, void* nothing)
+Handle_set_orientation(Handle *self, PyObject *args, void* nothing)
{
float w, x, y, z;
@@ -1533,7 +1533,7 @@ Handle_get_relative(Handle *self, void* nothing)
}
static int
-Handle_set_relative(Handle *self, PyObject* args, void* nothing)
+Handle_set_relative(Handle *self, PyObject *args, void* nothing)
{
if(!PyBool_Check(args))
{
@@ -1591,7 +1591,7 @@ Handle_get_volume_minimum(Handle *self, void* nothing)
}
static int
-Handle_set_volume_minimum(Handle *self, PyObject* args, void* nothing)
+Handle_set_volume_minimum(Handle *self, PyObject *args, void* nothing)
{
float volume;
@@ -1646,7 +1646,7 @@ Handle_get_volume_maximum(Handle *self, void* nothing)
}
static int
-Handle_set_volume_maximum(Handle *self, PyObject* args, void* nothing)
+Handle_set_volume_maximum(Handle *self, PyObject *args, void* nothing)
{
float volume;
@@ -1702,7 +1702,7 @@ Handle_get_distance_reference(Handle *self, void* nothing)
}
static int
-Handle_set_distance_reference(Handle *self, PyObject* args, void* nothing)
+Handle_set_distance_reference(Handle *self, PyObject *args, void* nothing)
{
float distance;
@@ -1758,7 +1758,7 @@ Handle_get_distance_maximum(Handle *self, void* nothing)
}
static int
-Handle_set_distance_maximum(Handle *self, PyObject* args, void* nothing)
+Handle_set_distance_maximum(Handle *self, PyObject *args, void* nothing)
{
float distance;
@@ -1814,7 +1814,7 @@ Handle_get_attenuation(Handle *self, void* nothing)
}
static int
-Handle_set_attenuation(Handle *self, PyObject* args, void* nothing)
+Handle_set_attenuation(Handle *self, PyObject *args, void* nothing)
{
float factor;
@@ -1875,7 +1875,7 @@ Handle_get_cone_angle_inner(Handle *self, void* nothing)
}
static int
-Handle_set_cone_angle_inner(Handle *self, PyObject* args, void* nothing)
+Handle_set_cone_angle_inner(Handle *self, PyObject *args, void* nothing)
{
float angle;
@@ -1930,7 +1930,7 @@ Handle_get_cone_angle_outer(Handle *self, void* nothing)
}
static int
-Handle_set_cone_angle_outer(Handle *self, PyObject* args, void* nothing)
+Handle_set_cone_angle_outer(Handle *self, PyObject *args, void* nothing)
{
float angle;
@@ -1985,7 +1985,7 @@ Handle_get_cone_volume_outer(Handle *self, void* nothing)
}
static int
-Handle_set_cone_volume_outer(Handle *self, PyObject* args, void* nothing)
+Handle_set_cone_volume_outer(Handle *self, PyObject *args, void* nothing)
{
float volume;
@@ -2105,7 +2105,7 @@ Device_dealloc(Device* self)
{
if(self->device)
delete reinterpret_cast<AUD_Reference<AUD_IDevice>*>(self->device);
- Py_TYPE(self)->tp_free((PyObject*)self);
+ Py_TYPE(self)->tp_free((PyObject *)self);
}
static PyObject *
@@ -2201,8 +2201,8 @@ PyDoc_STRVAR(M_aud_Device_play_doc,
static PyObject *
Device_play(Device *self, PyObject *args, PyObject *kwds)
{
- PyObject* object;
- PyObject* keepo = NULL;
+ PyObject *object;
+ PyObject *keepo = NULL;
bool keep = false;
@@ -2402,7 +2402,7 @@ Device_get_volume(Device *self, void* nothing)
}
static int
-Device_set_volume(Device *self, PyObject* args, void* nothing)
+Device_set_volume(Device *self, PyObject *args, void* nothing)
{
float volume;
@@ -2449,7 +2449,7 @@ Device_get_listener_location(Device *self, void* nothing)
}
static int
-Device_set_listener_location(Device *self, PyObject* args, void* nothing)
+Device_set_listener_location(Device *self, PyObject *args, void* nothing)
{
float x, y, z;
@@ -2504,7 +2504,7 @@ Device_get_listener_velocity(Device *self, void* nothing)
}
static int
-Device_set_listener_velocity(Device *self, PyObject* args, void* nothing)
+Device_set_listener_velocity(Device *self, PyObject *args, void* nothing)
{
float x, y, z;
@@ -2559,7 +2559,7 @@ Device_get_listener_orientation(Device *self, void* nothing)
}
static int
-Device_set_listener_orientation(Device *self, PyObject* args, void* nothing)
+Device_set_listener_orientation(Device *self, PyObject *args, void* nothing)
{
float w, x, y, z;
@@ -2614,7 +2614,7 @@ Device_get_speed_of_sound(Device *self, void* nothing)
}
static int
-Device_set_speed_of_sound(Device *self, PyObject* args, void* nothing)
+Device_set_speed_of_sound(Device *self, PyObject *args, void* nothing)
{
float speed;
@@ -2670,7 +2670,7 @@ Device_get_doppler_factor(Device *self, void* nothing)
}
static int
-Device_set_doppler_factor(Device *self, PyObject* args, void* nothing)
+Device_set_doppler_factor(Device *self, PyObject *args, void* nothing)
{
float factor;
@@ -2724,7 +2724,7 @@ Device_get_distance_model(Device *self, void* nothing)
}
static int
-Device_set_distance_model(Device *self, PyObject* args, void* nothing)
+Device_set_distance_model(Device *self, PyObject *args, void* nothing)
{
int model;
@@ -2833,7 +2833,7 @@ Factory_empty()
}
Factory*
-checkFactory(PyObject* factory)
+checkFactory(PyObject *factory)
{
if(!PyObject_TypeCheck(factory, &FactoryType))
{
@@ -2862,7 +2862,7 @@ static struct PyModuleDef audmodule = {
PyMODINIT_FUNC
PyInit_aud(void)
{
- PyObject* m;
+ PyObject *m;
if(PyType_Ready(&FactoryType) < 0)
return NULL;
@@ -2878,13 +2878,13 @@ PyInit_aud(void)
return NULL;
Py_INCREF(&FactoryType);
- PyModule_AddObject(m, "Factory", (PyObject*)&FactoryType);
+ PyModule_AddObject(m, "Factory", (PyObject *)&FactoryType);
Py_INCREF(&DeviceType);
- PyModule_AddObject(m, "Device", (PyObject*)&DeviceType);
+ PyModule_AddObject(m, "Device", (PyObject *)&DeviceType);
Py_INCREF(&HandleType);
- PyModule_AddObject(m, "Handle", (PyObject*)&HandleType);
+ PyModule_AddObject(m, "Handle", (PyObject *)&HandleType);
AUDError = PyErr_NewException("aud.error", NULL, NULL);
Py_INCREF(AUDError);
diff --git a/intern/audaspace/Python/AUD_PyAPI.h b/intern/audaspace/Python/AUD_PyAPI.h
index 7a7e87ec67d..0183a2df6b2 100644
--- a/intern/audaspace/Python/AUD_PyAPI.h
+++ b/intern/audaspace/Python/AUD_PyAPI.h
@@ -46,7 +46,7 @@ typedef void AUD_Reference_AUD_IHandle;
typedef struct {
PyObject_HEAD
- PyObject* child_list;
+ PyObject *child_list;
AUD_Reference_AUD_IFactory* factory;
} Factory;
@@ -63,9 +63,9 @@ typedef struct {
PyMODINIT_FUNC
PyInit_aud(void);
-extern PyObject* Device_empty();
-extern PyObject* Factory_empty();
-extern Factory* checkFactory(PyObject* factory);
+extern PyObject *Device_empty();
+extern PyObject *Factory_empty();
+extern Factory *checkFactory(PyObject *factory);
#ifdef __cplusplus
}
diff --git a/intern/audaspace/intern/AUD_PyInit.h b/intern/audaspace/intern/AUD_PyInit.h
index 8c045e60f37..95a60cd57bb 100644
--- a/intern/audaspace/intern/AUD_PyInit.h
+++ b/intern/audaspace/intern/AUD_PyInit.h
@@ -40,7 +40,7 @@ extern "C" {
/**
* Initalizes the Python module.
*/
-extern PyObject* AUD_initPython(void);
+extern PyObject *AUD_initPython(void);
#ifdef __cplusplus
}
diff --git a/intern/memutil/MEM_SmartPtr.h b/intern/memutil/MEM_SmartPtr.h
index 722a0a8fd3b..09cf5c95854 100644
--- a/intern/memutil/MEM_SmartPtr.h
+++ b/intern/memutil/MEM_SmartPtr.h
@@ -86,7 +86,7 @@
* private :
* MEM_SmartPtr<foo> m_foo;
* }
- *
+ *
* You may also safely construct vectors of MEM_SmartPtrs and
* have the vector own stuff you put into it.
*
@@ -167,7 +167,7 @@ public :
Ref(
) const {
return *m_val;
- }
+ }
/**
* Assignment operator - ownership is transfered from rhs to lhs.
@@ -207,7 +207,7 @@ public :
Release(
) const {
T* temp = m_val;
- (const_cast<MEM_SmartPtr *>(this))->m_val = NULL;
+ (const_cast<MEM_SmartPtr *>(this))->m_val = NULL;
return temp;
}
diff --git a/source/blender/blenkernel/intern/icons.c b/source/blender/blenkernel/intern/icons.c
index 8a49cba7649..d8c3e260399 100644
--- a/source/blender/blenkernel/intern/icons.c
+++ b/source/blender/blenkernel/intern/icons.c
@@ -65,7 +65,7 @@ static void icon_free(void *val)
Icon *icon = val;
if (icon) {
- if (icon->drawinfo_free) {
+ if (icon->drawinfo_free) {
icon->drawinfo_free(icon->drawinfo);
}
else if (icon->drawinfo) {
@@ -255,7 +255,7 @@ void BKE_icon_changed(int id)
prv->changed_timestamp[i]++;
}
}
- }
+ }
}
int BKE_icon_getid(struct ID *id)
diff --git a/source/blender/blenkernel/intern/idprop.c b/source/blender/blenkernel/intern/idprop.c
index 8229df28ab8..8ceaab56f83 100644
--- a/source/blender/blenkernel/intern/idprop.c
+++ b/source/blender/blenkernel/intern/idprop.c
@@ -484,7 +484,7 @@ void IDP_ReplaceInGroup(IDProperty *group, IDProperty *prop)
BLI_remlink(&group->data.group, loop);
IDP_FreeProperty(loop);
- MEM_freeN(loop);
+ MEM_freeN(loop);
}
else {
group->len++;
@@ -679,7 +679,7 @@ IDProperty *IDP_New(const int type, const IDPropertyTemplate *val, const char *n
case IDP_DOUBLE:
prop = MEM_callocN(sizeof(IDProperty), "IDProperty float");
*(double *)&prop->data.val = val->d;
- break;
+ break;
case IDP_ARRAY:
{
/* for now, we only support float and int and double arrays */
diff --git a/source/blender/blenkernel/intern/mball.c b/source/blender/blenkernel/intern/mball.c
index 3925c3cc858..4679d8547f0 100644
--- a/source/blender/blenkernel/intern/mball.c
+++ b/source/blender/blenkernel/intern/mball.c
@@ -186,7 +186,7 @@ void BKE_mball_unlink(MetaBall *mb)
/* do not free mball itself */
void BKE_mball_free(MetaBall *mb)
{
- BKE_mball_unlink(mb);
+ BKE_mball_unlink(mb);
if (mb->adt) {
BKE_free_animdata((ID *)mb);
@@ -562,7 +562,7 @@ Object *BKE_mball_basis_find(Scene *scene, Object *basis)
basis = ob;
basisnr = obnr;
}
- }
+ }
}
}
@@ -732,7 +732,7 @@ static octal_node *find_metaball_octal_node(octal_node *node, float x, float y,
return find_metaball_octal_node(node->nodes[2], x, y, z, depth--);
else
return node;
- }
+ }
}
}
else {
@@ -762,7 +762,7 @@ static octal_node *find_metaball_octal_node(octal_node *node, float x, float y,
return find_metaball_octal_node(node->nodes[6], x, y, z, depth--);
else
return node;
- }
+ }
}
}
@@ -861,7 +861,7 @@ static void *new_pgn_element(int size)
}
BLI_freelistN(&lb);
- return NULL;
+ return NULL;
}
size = 4 * ( (size + 3) / 4);
@@ -1628,7 +1628,7 @@ static void polygonize(PROCESS *mbproc, MetaBall *mb)
for (a = 0; a < G_mb.totelem; a++) {
/* try to find 8 points on the surface for each MetaElem */
- find_first_points(mbproc, mb, a);
+ find_first_points(mbproc, mb, a);
}
/* polygonize all MetaElems of current MetaBall */
@@ -2038,7 +2038,7 @@ static void subdivide_metaball_octal_node(octal_node *node, float size_x, float
}
- /* ml belongs to the (4)5th node too */
+ /* ml belongs to the (4)5th node too */
if (ml->bb->vec[6][2] >= z) {
fill_metaball_octal_node(node, ml, 4);
}
@@ -2226,7 +2226,7 @@ static void init_metaball_octal_tree(int depth)
}
}
- /* size of first node */
+ /* size of first node */
size[0] = node->x_max - node->x_min;
size[1] = node->y_max - node->y_min;
size[2] = node->z_max - node->z_min;
diff --git a/source/blender/blenkernel/intern/sca.c b/source/blender/blenkernel/intern/sca.c
index 7d9d2f02c06..be2f1872efa 100644
--- a/source/blender/blenkernel/intern/sca.c
+++ b/source/blender/blenkernel/intern/sca.c
@@ -210,7 +210,7 @@ void unlink_controllers(ListBase *lb)
bController *cont;
for (cont= lb->first; cont; cont= cont->next)
- unlink_controller(cont);
+ unlink_controller(cont);
}
void free_controller(bController *cont)
@@ -536,7 +536,7 @@ void clear_sca_new_poins(void)
ob= G.main->object.first;
while (ob) {
clear_sca_new_poins_ob(ob);
- ob= ob->id.next;
+ ob= ob->id.next;
}
}
@@ -624,7 +624,7 @@ void set_sca_new_poins(void)
ob= G.main->object.first;
while (ob) {
set_sca_new_poins_ob(ob);
- ob= ob->id.next;
+ ob= ob->id.next;
}
}
@@ -696,7 +696,7 @@ void sca_remove_ob_poin(Object *obt, Object *ob)
if (sta->target == ob) sta->target = NULL;
}
act= act->next;
- }
+ }
}
/* ******************** INTERFACE ******************* */
diff --git a/source/blender/blenlib/intern/path_util.c b/source/blender/blenlib/intern/path_util.c
index a7a66718445..cc482e2d3d8 100644
--- a/source/blender/blenlib/intern/path_util.c
+++ b/source/blender/blenlib/intern/path_util.c
@@ -1368,7 +1368,7 @@ int BLI_testextensie(const char *str, const char *ext)
retval = 0;
}
else if (BLI_strcasecmp(ext, str + a - b)) {
- retval = 0;
+ retval = 0;
}
else {
retval = 1;
diff --git a/source/blender/blenlib/intern/scanfill.c b/source/blender/blenlib/intern/scanfill.c
index 32afaba2b5c..7ae27b83e67 100644
--- a/source/blender/blenlib/intern/scanfill.c
+++ b/source/blender/blenlib/intern/scanfill.c
@@ -211,7 +211,7 @@ ScanFillVert *BLI_scanfill_vert_add(ScanFillContext *sf_ctx, const float vec[3])
copy_v3_v3(eve->co, vec);
- return eve;
+ return eve;
}
ScanFillEdge *BLI_scanfill_edge_add(ScanFillContext *sf_ctx, ScanFillVert *v1, ScanFillVert *v2)
@@ -521,7 +521,7 @@ static int scanfill(ScanFillContext *sf_ctx, PolyFill *pf)
while (eve) {
printf("vert: %x co: %f %f\n", eve, eve->xy[0], eve->xy[1]);
eve = eve->next;
- }
+ }
eed = sf_ctx->filledgebase.first;
while (eed) {
printf("edge: %x verts: %x %x\n", eed, eed->v1, eed->v2);
diff --git a/source/blender/blenlib/intern/storage.c b/source/blender/blenlib/intern/storage.c
index 0fccd91fc02..0d3f6aee30f 100644
--- a/source/blender/blenlib/intern/storage.c
+++ b/source/blender/blenlib/intern/storage.c
@@ -34,7 +34,7 @@
#include <sys/types.h>
#include <stdio.h>
-#include <stdlib.h>
+#include <stdlib.h>
#ifndef WIN32
#include <dirent.h>
diff --git a/source/blender/imbuf/intern/scaling.c b/source/blender/imbuf/intern/scaling.c
index 389c3c42b6d..527f334d6a4 100644
--- a/source/blender/imbuf/intern/scaling.c
+++ b/source/blender/imbuf/intern/scaling.c
@@ -1051,7 +1051,7 @@ static ImBuf *scaledowny(struct ImBuf *ibuf, int newy)
sample -= 1.0f;
}
- }
+ }
if (do_rect) {
// printf("%ld %ld\n", (uchar *)rect - ((uchar *)ibuf->rect), rect_size);
diff --git a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
index 62bfc31b96a..5cfa97e2e7e 100644
--- a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
+++ b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
@@ -552,7 +552,7 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c
ketsjinextframestate.draw_letterbox = draw_letterbox;
pynextframestate.state = &ketsjinextframestate;
- pynextframestate.func = &BL_KetsjiPyNextFrame;
+ pynextframestate.func = &BL_KetsjiPyNextFrame;
printf("Yielding control to Python script '%s'...\n", python_main);
PyRun_SimpleString(python_code);
printf("Exit Python script '%s'\n", python_main);
@@ -590,7 +590,7 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c
const Py_ssize_t numitems= PyList_GET_SIZE(gameLogic_keys_new);
Py_ssize_t listIndex;
for (listIndex=0; listIndex < numitems; listIndex++) {
- PyObject* item = PyList_GET_ITEM(gameLogic_keys_new, listIndex);
+ PyObject *item = PyList_GET_ITEM(gameLogic_keys_new, listIndex);
if (!PySequence_Contains(gameLogic_keys, item)) {
PyDict_DelItem( PyModule_GetDict(gameLogic), item);
}
diff --git a/source/gameengine/BlenderRoutines/KX_BlenderCanvas.cpp b/source/gameengine/BlenderRoutines/KX_BlenderCanvas.cpp
index 6236923d973..4f450bcd668 100644
--- a/source/gameengine/BlenderRoutines/KX_BlenderCanvas.cpp
+++ b/source/gameengine/BlenderRoutines/KX_BlenderCanvas.cpp
@@ -53,7 +53,7 @@ KX_BlenderCanvas::~KX_BlenderCanvas()
void KX_BlenderCanvas::Init()
{
glDepthFunc(GL_LEQUAL);
-}
+}
void KX_BlenderCanvas::SwapBuffers()
@@ -143,7 +143,7 @@ KX_BlenderCanvas::
GetWindowArea(
) {
return m_area_rect;
-}
+}
void
KX_BlenderCanvas::
diff --git a/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp b/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp
index 98a1aa81029..7c4c759e361 100644
--- a/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp
+++ b/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp
@@ -153,7 +153,7 @@ void BL_print_game_line(int fontid, const char* text, int size, int dpi, float*
}
void BL_print_gamedebug_line(const char* text, int xco, int yco, int width, int height)
-{
+{
/* gl prepping */
DisableForText();
glDisable(GL_DEPTH_TEST);
diff --git a/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp b/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp
index c4daecc9958..85b76d7c676 100644
--- a/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp
+++ b/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp
@@ -344,7 +344,7 @@ void KX_BlenderRenderTools::PopMatrix()
int KX_BlenderRenderTools::applyLights(int objectlayer, const MT_Transform& viewmat)
{
- // taken from blender source, incompatibility between Blender Object / GameObject
+ // taken from blender source, incompatibility between Blender Object / GameObject
KX_Scene* kxscene = (KX_Scene*)m_auxilaryClientInfo;
float glviewmat[16];
unsigned int count;
diff --git a/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h b/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h
index a229c9f34e6..54ff4dde947 100644
--- a/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h
+++ b/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h
@@ -62,7 +62,7 @@ class KX_BlenderRenderTools : public RAS_IRenderTools
public:
KX_BlenderRenderTools();
- virtual ~KX_BlenderRenderTools();
+ virtual ~KX_BlenderRenderTools();
void EndFrame(RAS_IRasterizer* rasty);
void BeginFrame(RAS_IRasterizer* rasty);
diff --git a/source/gameengine/Converter/BL_ActionActuator.cpp b/source/gameengine/Converter/BL_ActionActuator.cpp
index 92d04115f10..fcf09588791 100644
--- a/source/gameengine/Converter/BL_ActionActuator.cpp
+++ b/source/gameengine/Converter/BL_ActionActuator.cpp
@@ -96,7 +96,7 @@ BL_ActionActuator::BL_ActionActuator(SCA_IObject* gameobj,
m_userpose(NULL),
m_action(action),
m_propname(propname),
- m_framepropname(framepropname)
+ m_framepropname(framepropname)
{
if (!end_reset)
m_flag |= ACT_FLAG_CONTINUE;
@@ -299,7 +299,7 @@ bool BL_ActionActuator::Update(double curtime, bool frame)
m_flag |= ACT_FLAG_ATTEMPT_PLAY;
}
else if ((m_flag & ACT_FLAG_ACTIVE) && bNegativeEvent)
- {
+ {
m_flag &= ~ACT_FLAG_ATTEMPT_PLAY;
m_localtime = obj->GetActionFrame(m_layer);
bAction *curr_action = obj->GetCurrentAction(m_layer);
@@ -347,7 +347,7 @@ bool BL_ActionActuator::Update(double curtime, bool frame)
/* Python functions */
/* ------------------------------------------------------------------------- */
-PyObject* BL_ActionActuator::PyGetChannel(PyObject* value)
+PyObject *BL_ActionActuator::PyGetChannel(PyObject *value)
{
PyErr_SetString(PyExc_NotImplementedError, "BL_ActionActuator.getChannel() no longer works, please use BL_ArmatureObject.channels instead");
return NULL;
@@ -555,7 +555,7 @@ PyAttributeDef BL_ActionActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* BL_ActionActuator::pyattr_get_action(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ActionActuator::pyattr_get_action(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ActionActuator* self= static_cast<BL_ActionActuator*>(self_v);
return PyUnicode_FromString(self->GetAction() ? self->GetAction()->id.name+2 : "");
@@ -589,7 +589,7 @@ int BL_ActionActuator::pyattr_set_action(void *self_v, const KX_PYATTRIBUTE_DEF
}
-PyObject* BL_ActionActuator::pyattr_get_channel_names(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ActionActuator::pyattr_get_channel_names(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
PyErr_SetString(PyExc_NotImplementedError, "BL_ActionActuator.channelNames no longer works, please use BL_ArmatureObject.channels instead");
return NULL;
@@ -620,7 +620,7 @@ PyObject* BL_ActionActuator::pyattr_get_channel_names(void *self_v, const KX_PYA
#endif
}
-PyObject* BL_ActionActuator::pyattr_get_use_continue(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ActionActuator::pyattr_get_use_continue(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ActionActuator* self= static_cast<BL_ActionActuator*>(self_v);
return PyBool_FromLong(self->m_flag & ACT_FLAG_CONTINUE);
@@ -638,7 +638,7 @@ int BL_ActionActuator::pyattr_set_use_continue(void *self_v, const KX_PYATTRIBUT
return PY_SET_ATTR_SUCCESS;
}
-PyObject* BL_ActionActuator::pyattr_get_frame(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ActionActuator::pyattr_get_frame(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ActionActuator* self= static_cast<BL_ActionActuator*>(self_v);
return PyFloat_FromDouble(((KX_GameObject*)self->m_gameobj)->GetActionFrame(self->m_layer));
diff --git a/source/gameengine/Converter/BL_ArmatureActuator.cpp b/source/gameengine/Converter/BL_ArmatureActuator.cpp
index 3f4a261a972..f0c4b3d32bb 100644
--- a/source/gameengine/Converter/BL_ArmatureActuator.cpp
+++ b/source/gameengine/Converter/BL_ArmatureActuator.cpp
@@ -146,7 +146,7 @@ void BL_ArmatureActuator::FindConstraint()
bool BL_ArmatureActuator::Update(double curtime, bool frame)
{
// the only role of this actuator is to ensure that the armature pose will be evaluated
- bool result = false;
+ bool result = false;
bool bNegativeEvent = IsNegativeEvent();
RemoveAllEvents();
@@ -227,11 +227,11 @@ PyAttributeDef BL_ArmatureActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* BL_ArmatureActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ArmatureActuator* actuator = static_cast<BL_ArmatureActuator*>(self);
KX_GameObject *target = (!strcmp(attrdef->m_name, "target")) ? actuator->m_gametarget : actuator->m_gamesubtarget;
- if (!target)
+ if (!target)
Py_RETURN_NONE;
else
return target->GetProxy();
@@ -247,7 +247,7 @@ int BL_ArmatureActuator::pyattr_set_object(void *self, const struct KX_PYATTRIBU
return PY_SET_ATTR_FAIL; // ConvertPythonToGameObject sets the error
if (target != NULL)
- target->UnregisterActuator(actuator);
+ target->UnregisterActuator(actuator);
target = gameobj;
@@ -257,11 +257,11 @@ int BL_ArmatureActuator::pyattr_set_object(void *self, const struct KX_PYATTRIBU
return PY_SET_ATTR_SUCCESS;
}
-PyObject* BL_ArmatureActuator::pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureActuator::pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ArmatureActuator* actuator = static_cast<BL_ArmatureActuator*>(self);
BL_ArmatureConstraint* constraint = actuator->m_constraint;
- if (!constraint)
+ if (!constraint)
Py_RETURN_NONE;
else
return constraint->GetProxy();
diff --git a/source/gameengine/Converter/BL_ArmatureActuator.h b/source/gameengine/Converter/BL_ArmatureActuator.h
index 638640c27ce..0c88dccb6f3 100644
--- a/source/gameengine/Converter/BL_ArmatureActuator.h
+++ b/source/gameengine/Converter/BL_ArmatureActuator.h
@@ -73,8 +73,8 @@ public:
#ifdef WITH_PYTHON
/* These are used to get and set m_target */
- static PyObject* pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Converter/BL_ArmatureChannel.cpp b/source/gameengine/Converter/BL_ArmatureChannel.cpp
index 7344aa9378e..e588d1d310c 100644
--- a/source/gameengine/Converter/BL_ArmatureChannel.cpp
+++ b/source/gameengine/Converter/BL_ArmatureChannel.cpp
@@ -62,7 +62,7 @@ PyTypeObject BL_ArmatureChannel::Type = {
py_base_new
};
-PyObject* BL_ArmatureChannel::py_repr(void)
+PyObject *BL_ArmatureChannel::py_repr(void)
{
return PyUnicode_FromString(m_posechannel->name);
}
@@ -104,8 +104,8 @@ PyMethodDef BL_ArmatureChannel::Methods[] = {
PyAttributeDef BL_ArmatureChannel::Attributes[] = {
// Keep these attributes in order of BCA_ defines!!! used by py_attr_getattr and py_attr_setattr
- KX_PYATTRIBUTE_RO_FUNCTION("bone",BL_ArmatureChannel,py_attr_getattr),
- KX_PYATTRIBUTE_RO_FUNCTION("parent",BL_ArmatureChannel,py_attr_getattr),
+ KX_PYATTRIBUTE_RO_FUNCTION("bone",BL_ArmatureChannel,py_attr_getattr),
+ KX_PYATTRIBUTE_RO_FUNCTION("parent",BL_ArmatureChannel,py_attr_getattr),
{ NULL } //Sentinel
};
@@ -147,7 +147,7 @@ PyAttributeDef BL_ArmatureChannel::AttributesPtr[] = {
{ NULL } //Sentinel
};
-PyObject* BL_ArmatureChannel::py_attr_getattr(void *self_v, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureChannel::py_attr_getattr(void *self_v, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ArmatureChannel* self= static_cast<BL_ArmatureChannel*>(self_v);
bPoseChannel* channel = self->m_posechannel;
@@ -200,7 +200,7 @@ int BL_ArmatureChannel::py_attr_setattr(void *self_v, const struct KX_PYATTRIBUT
return PY_SET_ATTR_FAIL;
}
-PyObject* BL_ArmatureChannel::py_attr_get_joint_rotation(void *self_v, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureChannel::py_attr_get_joint_rotation(void *self_v, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
bPoseChannel* pchan = static_cast<bPoseChannel*>(self_v);
// decompose the pose matrix in euler rotation
@@ -223,7 +223,7 @@ PyObject* BL_ArmatureChannel::py_attr_get_joint_rotation(void *self_v, const str
}
// remove the rest pose to get the joint movement
transpose_m3(rest_mat);
- mul_m3_m3m3(joint_mat, rest_mat, pose_mat);
+ mul_m3_m3m3(joint_mat, rest_mat, pose_mat);
joints[0] = joints[1] = joints[2] = 0.f;
// returns a 3 element list that gives corresponding joint
int flag = 0;
@@ -458,7 +458,7 @@ PyObject *BL_ArmatureBone::py_bone_get_children(void *self, const struct KX_PYAT
for (child=(Bone*)bone->childbase.first; child; child=(Bone*)child->next)
count++;
- PyObject* childrenlist = PyList_New(count);
+ PyObject *childrenlist = PyList_New(count);
for (count = 0, child=(Bone*)bone->childbase.first; child; child=(Bone*)child->next, ++count)
PyList_SET_ITEM(childrenlist,count,NewProxyPlus_Ext(NULL,&Type,child,false));
diff --git a/source/gameengine/Converter/BL_ArmatureChannel.h b/source/gameengine/Converter/BL_ArmatureChannel.h
index cd38ee2d531..b764d32e8a7 100644
--- a/source/gameengine/Converter/BL_ArmatureChannel.h
+++ b/source/gameengine/Converter/BL_ArmatureChannel.h
@@ -62,11 +62,11 @@ public:
#ifdef WITH_PYTHON
// Python access
- virtual PyObject* py_repr(void);
+ virtual PyObject *py_repr(void);
- static PyObject* py_attr_getattr(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *py_attr_getattr(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int py_attr_setattr(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- static PyObject* py_attr_get_joint_rotation(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *py_attr_get_joint_rotation(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int py_attr_set_joint_rotation(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif // WITH_PYTHON
};
diff --git a/source/gameengine/Converter/BL_ArmatureConstraint.cpp b/source/gameengine/Converter/BL_ArmatureConstraint.cpp
index 7939d6e9235..169205d79e7 100644
--- a/source/gameengine/Converter/BL_ArmatureConstraint.cpp
+++ b/source/gameengine/Converter/BL_ArmatureConstraint.cpp
@@ -61,7 +61,7 @@ PyTypeObject BL_ArmatureConstraint::Type = {
py_base_new
};
-PyObject* BL_ArmatureConstraint::py_repr(void)
+PyObject *BL_ArmatureConstraint::py_repr(void)
{
return PyUnicode_FromString(m_name);
}
@@ -267,8 +267,8 @@ PyMethodDef BL_ArmatureConstraint::Methods[] = {
PyAttributeDef BL_ArmatureConstraint::Attributes[] = {
// Keep these attributes in order of BCA_ defines!!! used by py_attr_getattr and py_attr_setattr
- KX_PYATTRIBUTE_RO_FUNCTION("type",BL_ArmatureConstraint,py_attr_getattr),
- KX_PYATTRIBUTE_RO_FUNCTION("name",BL_ArmatureConstraint,py_attr_getattr),
+ KX_PYATTRIBUTE_RO_FUNCTION("type",BL_ArmatureConstraint,py_attr_getattr),
+ KX_PYATTRIBUTE_RO_FUNCTION("name",BL_ArmatureConstraint,py_attr_getattr),
KX_PYATTRIBUTE_RW_FUNCTION("enforce",BL_ArmatureConstraint,py_attr_getattr,py_attr_setattr),
KX_PYATTRIBUTE_RW_FUNCTION("headtail",BL_ArmatureConstraint,py_attr_getattr,py_attr_setattr),
KX_PYATTRIBUTE_RO_FUNCTION("lin_error",BL_ArmatureConstraint,py_attr_getattr),
@@ -286,7 +286,7 @@ PyAttributeDef BL_ArmatureConstraint::Attributes[] = {
};
-PyObject* BL_ArmatureConstraint::py_attr_getattr(void *self_v, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureConstraint::py_attr_getattr(void *self_v, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ArmatureConstraint* self= static_cast<BL_ArmatureConstraint*>(self_v);
bConstraint* constraint = self->m_constraint;
@@ -312,12 +312,12 @@ PyObject* BL_ArmatureConstraint::py_attr_getattr(void *self_v, const struct KX_P
case BCA_ROTERROR:
return PyFloat_FromDouble(constraint->rot_error);
case BCA_TARGET:
- if (!self->m_target)
+ if (!self->m_target)
Py_RETURN_NONE;
else
return self->m_target->GetProxy();
case BCA_SUBTARGET:
- if (!self->m_subtarget)
+ if (!self->m_subtarget)
Py_RETURN_NONE;
else
return self->m_subtarget->GetProxy();
diff --git a/source/gameengine/Converter/BL_ArmatureConstraint.h b/source/gameengine/Converter/BL_ArmatureConstraint.h
index 0d79bb1cfa7..579153a2e79 100644
--- a/source/gameengine/Converter/BL_ArmatureConstraint.h
+++ b/source/gameengine/Converter/BL_ArmatureConstraint.h
@@ -115,9 +115,9 @@ public:
#ifdef WITH_PYTHON
// Python access
- virtual PyObject* py_repr(void);
+ virtual PyObject *py_repr(void);
- static PyObject* py_attr_getattr(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *py_attr_getattr(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int py_attr_setattr(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif // WITH_PYTHON
};
diff --git a/source/gameengine/Converter/BL_ArmatureObject.cpp b/source/gameengine/Converter/BL_ArmatureObject.cpp
index 7174a563efa..da73d7a762a 100644
--- a/source/gameengine/Converter/BL_ArmatureObject.cpp
+++ b/source/gameengine/Converter/BL_ArmatureObject.cpp
@@ -430,7 +430,7 @@ void BL_ArmatureObject::ProcessReplica()
m_pose = NULL;
m_framePose = NULL;
- game_copy_pose(&m_pose, pose, 1);
+ game_copy_pose(&m_pose, pose, 1);
}
void BL_ArmatureObject::ReParentLogic()
@@ -521,7 +521,7 @@ bool BL_ArmatureObject::SetActiveAction(BL_ActionActuator *act, short priority,
SetPose(m_framePose);
if (m_activeAct && (m_activeAct!=act))
/* Reset the blend timer since this new action cancels the old one */
- m_activeAct->SetBlendTime(0.0);
+ m_activeAct->SetBlendTime(0.0);
}
m_activeAct = act;
m_activePriority = priority;
@@ -648,12 +648,12 @@ PyAttributeDef BL_ArmatureObject::Attributes[] = {
{NULL} //Sentinel
};
-PyObject* BL_ArmatureObject::pyattr_get_constraints(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureObject::pyattr_get_constraints(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return KX_PythonSeq_CreatePyObject((static_cast<BL_ArmatureObject*>(self_v))->m_proxy, KX_PYGENSEQ_OB_TYPE_CONSTRAINTS);
}
-PyObject* BL_ArmatureObject::pyattr_get_channels(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ArmatureObject::pyattr_get_channels(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ArmatureObject* self = static_cast<BL_ArmatureObject*>(self_v);
self->LoadChannels(); // make sure we have the channels
diff --git a/source/gameengine/Converter/BL_ArmatureObject.h b/source/gameengine/Converter/BL_ArmatureObject.h
index 6274e770409..4e7dc3df2f3 100644
--- a/source/gameengine/Converter/BL_ArmatureObject.h
+++ b/source/gameengine/Converter/BL_ArmatureObject.h
@@ -116,8 +116,8 @@ public:
#ifdef WITH_PYTHON
// PYTHON
- static PyObject* pyattr_get_constraints(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_channels(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_constraints(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_channels(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
KX_PYMETHOD_DOC_NOARGS(BL_ArmatureObject, update);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Converter/BL_BlenderDataConversion.cpp b/source/gameengine/Converter/BL_BlenderDataConversion.cpp
index 4a8541cd310..b59f3de7d87 100644
--- a/source/gameengine/Converter/BL_BlenderDataConversion.cpp
+++ b/source/gameengine/Converter/BL_BlenderDataConversion.cpp
@@ -216,7 +216,7 @@ static std::map<int, SCA_IInputDevice::KX_EnumInputs> create_translate_table()
// SYSTEM
-#if 0
+#if 0
/* **** XXX **** */
m[KEYBD ] = SCA_IInputDevice::KX_KEYBD;
m[RAWKEYBD ] = SCA_IInputDevice::KX_RAWKEYBD;
@@ -229,7 +229,7 @@ static std::map<int, SCA_IInputDevice::KX_EnumInputs> create_translate_table()
m[WINQUIT ] = SCA_IInputDevice::KX_WINQUIT;
m[Q_FIRSTTIME ] = SCA_IInputDevice::KX_Q_FIRSTTIME;
/* **** XXX **** */
-#endif
+#endif
// standard keyboard
@@ -447,7 +447,7 @@ static void GetRGB(short type,
else { // backup white
c0 = KX_rgbaint2uint_new(color);
c1 = KX_rgbaint2uint_new(color);
- c2 = KX_rgbaint2uint_new(color);
+ c2 = KX_rgbaint2uint_new(color);
if (mface->v4)
c3 = KX_rgbaint2uint_new( color );
}
@@ -469,7 +469,7 @@ static void GetRGB(short type,
}
c0 = KX_rgbaint2uint_new(color);
c1 = KX_rgbaint2uint_new(color);
- c2 = KX_rgbaint2uint_new(color);
+ c2 = KX_rgbaint2uint_new(color);
if (mface->v4)
c3 = KX_rgbaint2uint_new(color);
} break;
@@ -478,7 +478,7 @@ static void GetRGB(short type,
{
c0 = KX_rgbaint2uint_new(color);
c1 = KX_rgbaint2uint_new(color);
- c2 = KX_rgbaint2uint_new(color);
+ c2 = KX_rgbaint2uint_new(color);
if (mface->v4)
c3 = KX_rgbaint2uint_new(color);
} break;
@@ -1150,7 +1150,7 @@ RAS_MeshObject* BL_ConvertMesh(Mesh* mesh, Object* blenderobj, KX_Scene* scene,
rgb0 = KX_rgbaint2uint_new(color);
rgb1 = KX_rgbaint2uint_new(color);
- rgb2 = KX_rgbaint2uint_new(color);
+ rgb2 = KX_rgbaint2uint_new(color);
if (mface->v4)
rgb3 = KX_rgbaint2uint_new(color);
@@ -1694,7 +1694,7 @@ static void BL_CreatePhysicsObjectNew(KX_GameObject* gameobj,
objprop.m_soft_numclusteriterations= blenderobject->bsoft->numclusteriterations; /* number of iterations to refine collision clusters*/
//objprop.m_soft_welding = blenderobject->bsoft->welding; /* welding */
/* disable welding: it doesn't bring any additional stability and it breaks the relation between soft body collision shape and graphic mesh */
- objprop.m_soft_welding = 0.f;
+ objprop.m_soft_welding = 0.f;
objprop.m_margin = blenderobject->bsoft->margin;
objprop.m_contactProcessingThreshold = 0.f;
} else
@@ -2617,7 +2617,7 @@ void BL_ConvertBlenderObjects(struct Main* maggie,
KX_SlowParentRelation * slow_parent_relation = KX_SlowParentRelation::New(blenderchild->sf);
pcit->m_gamechildnode->SetParentRelation(slow_parent_relation);
break;
- }
+ }
case PARBONE:
{
// parent this to a bone
@@ -2741,7 +2741,7 @@ void BL_ConvertBlenderObjects(struct Main* maggie,
}
- }
+ }
// create physics joints
for (i=0;i<sumolist->GetCount();i++)
@@ -2825,7 +2825,7 @@ void BL_ConvertBlenderObjects(struct Main* maggie,
kxscene->GetPhysicsEnvironment()->setConstraintParam(constraintId,dof,1,-1);
}
dofbit<<=1;
- }
+ }
}
else if (dat->type == PHY_LINEHINGE_CONSTRAINT)
{
diff --git a/source/gameengine/Converter/BL_DeformableGameObject.h b/source/gameengine/Converter/BL_DeformableGameObject.h
index 61477fb1cac..d14160d39a3 100644
--- a/source/gameengine/Converter/BL_DeformableGameObject.h
+++ b/source/gameengine/Converter/BL_DeformableGameObject.h
@@ -89,7 +89,7 @@ public:
public:
-protected:
+protected:
RAS_Deformer *m_pDeformer;
diff --git a/source/gameengine/Converter/BL_MeshDeformer.cpp b/source/gameengine/Converter/BL_MeshDeformer.cpp
index c9371b9df50..b8002d05f18 100644
--- a/source/gameengine/Converter/BL_MeshDeformer.cpp
+++ b/source/gameengine/Converter/BL_MeshDeformer.cpp
@@ -84,7 +84,7 @@ bool BL_MeshDeformer::Apply(RAS_IPolyMaterial*)
}
BL_MeshDeformer::~BL_MeshDeformer()
-{
+{
if (m_transverts)
delete [] m_transverts;
if (m_transnors)
diff --git a/source/gameengine/Converter/BL_ModifierDeformer.cpp b/source/gameengine/Converter/BL_ModifierDeformer.cpp
index c1c94c25108..eafed8497ba 100644
--- a/source/gameengine/Converter/BL_ModifierDeformer.cpp
+++ b/source/gameengine/Converter/BL_ModifierDeformer.cpp
@@ -175,7 +175,7 @@ bool BL_ModifierDeformer::Update(void)
* It may not be the case here because of replace mesh actuator */
Mesh *oldmesh = (Mesh*)blendobj->data;
blendobj->data = m_bmesh;
- /* execute the modifiers */
+ /* execute the modifiers */
DerivedMesh *dm = mesh_create_derived_no_virtual(m_scene, blendobj, m_transverts, CD_MASK_MESH);
/* restore object data */
blendobj->data = oldmesh;
diff --git a/source/gameengine/Converter/BL_ModifierDeformer.h b/source/gameengine/Converter/BL_ModifierDeformer.h
index b4827b1bee4..5d0c3bc1317 100644
--- a/source/gameengine/Converter/BL_ModifierDeformer.h
+++ b/source/gameengine/Converter/BL_ModifierDeformer.h
@@ -54,7 +54,7 @@ public:
Scene *scene,
Object *bmeshobj,
RAS_MeshObject *mesh)
- :
+ :
BL_ShapeDeformer(gameobj,bmeshobj, mesh),
m_lastModifierUpdate(-1),
m_scene(scene),
diff --git a/source/gameengine/Converter/BL_ShapeActionActuator.cpp b/source/gameengine/Converter/BL_ShapeActionActuator.cpp
index c339e10f673..8325e80db78 100644
--- a/source/gameengine/Converter/BL_ShapeActionActuator.cpp
+++ b/source/gameengine/Converter/BL_ShapeActionActuator.cpp
@@ -83,7 +83,7 @@ BL_ShapeActionActuator::BL_ShapeActionActuator(SCA_IObject* gameobj,
m_playtype(playtype),
m_priority(priority),
m_action(action),
- m_framepropname(framepropname),
+ m_framepropname(framepropname),
m_propname(propname)
{
m_idptr = new PointerRNA();
@@ -526,7 +526,7 @@ PyAttributeDef BL_ShapeActionActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* BL_ShapeActionActuator::pyattr_get_action(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *BL_ShapeActionActuator::pyattr_get_action(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
BL_ShapeActionActuator* self= static_cast<BL_ShapeActionActuator*>(self_v);
return PyUnicode_FromString(self->GetAction() ? self->GetAction()->id.name+2 : "");
diff --git a/source/gameengine/Converter/BL_ShapeDeformer.h b/source/gameengine/Converter/BL_ShapeDeformer.h
index efc1b546666..ecf501d9a91 100644
--- a/source/gameengine/Converter/BL_ShapeDeformer.h
+++ b/source/gameengine/Converter/BL_ShapeDeformer.h
@@ -73,7 +73,7 @@ public:
};
protected:
- bool m_useShapeDrivers;
+ bool m_useShapeDrivers;
double m_lastShapeUpdate;
struct Key* m_key;
diff --git a/source/gameengine/Converter/BL_SkinDeformer.cpp b/source/gameengine/Converter/BL_SkinDeformer.cpp
index c508623bdb6..c175c1e3b7b 100644
--- a/source/gameengine/Converter/BL_SkinDeformer.cpp
+++ b/source/gameengine/Converter/BL_SkinDeformer.cpp
@@ -110,7 +110,7 @@ BL_SkinDeformer::BL_SkinDeformer(
class RAS_MeshObject *mesh,
bool release_object,
bool recalc_normal,
- BL_ArmatureObject* arma) :
+ BL_ArmatureObject* arma) :
BL_MeshDeformer(gameobj, bmeshobj_old, mesh),
m_armobj(arma),
m_lastArmaUpdate(-1),
@@ -327,7 +327,7 @@ void BL_SkinDeformer::BGEDeformVerts()
bool BL_SkinDeformer::UpdateInternal(bool shape_applied)
{
/* See if the armature has been updated for this frame */
- if (PoseUpdated()) {
+ if (PoseUpdated()) {
if (!shape_applied) {
/* store verts locally */
diff --git a/source/gameengine/Converter/BlenderWorldInfo.cpp b/source/gameengine/Converter/BlenderWorldInfo.cpp
index fc3b75c49ad..25da8155867 100644
--- a/source/gameengine/Converter/BlenderWorldInfo.cpp
+++ b/source/gameengine/Converter/BlenderWorldInfo.cpp
@@ -199,7 +199,7 @@ void BlenderWorldInfo::setBackColor(float r, float g, float b)
m_backgroundcolor[2] = b;
}
- void
+ void
BlenderWorldInfo::setMistStart(
float d
) {
@@ -215,7 +215,7 @@ BlenderWorldInfo::setMistDistance(
}
- void
+ void
BlenderWorldInfo::setMistColorRed(
float d
) {
@@ -231,7 +231,7 @@ BlenderWorldInfo::setMistColorGreen(
}
- void
+ void
BlenderWorldInfo::setMistColorBlue(
float d
) {
diff --git a/source/gameengine/Converter/BlenderWorldInfo.h b/source/gameengine/Converter/BlenderWorldInfo.h
index e00eb99e73f..2cf706a3089 100644
--- a/source/gameengine/Converter/BlenderWorldInfo.h
+++ b/source/gameengine/Converter/BlenderWorldInfo.h
@@ -73,27 +73,27 @@ public:
float g,
float b
);
- void
+ void
setMistStart(
float d
);
- void
+ void
setMistDistance(
float d
);
- void
+ void
setMistColorRed(
float d
);
- void
+ void
setMistColorGreen(
float d
);
- void
+ void
setMistColorBlue(
float d
);
diff --git a/source/gameengine/Converter/KX_BlenderScalarInterpolator.cpp b/source/gameengine/Converter/KX_BlenderScalarInterpolator.cpp
index f020aab4d50..72212581d4b 100644
--- a/source/gameengine/Converter/KX_BlenderScalarInterpolator.cpp
+++ b/source/gameengine/Converter/KX_BlenderScalarInterpolator.cpp
@@ -78,5 +78,5 @@ KX_IScalarInterpolator *BL_InterpolatorList::GetScalarInterpolator(const char *r
return *i;
}
return NULL;
-}
+}
diff --git a/source/gameengine/Converter/KX_BlenderScalarInterpolator.h b/source/gameengine/Converter/KX_BlenderScalarInterpolator.h
index bc5a6eeef85..980aeef7e60 100644
--- a/source/gameengine/Converter/KX_BlenderScalarInterpolator.h
+++ b/source/gameengine/Converter/KX_BlenderScalarInterpolator.h
@@ -65,7 +65,7 @@ public:
BL_InterpolatorList(struct bAction *action);
~BL_InterpolatorList();
- KX_IScalarInterpolator *GetScalarInterpolator(const char *rna_path, int array_index);
+ KX_IScalarInterpolator *GetScalarInterpolator(const char *rna_path, int array_index);
#ifdef WITH_CXX_GUARDEDALLOC
diff --git a/source/gameengine/Converter/KX_BlenderSceneConverter.cpp b/source/gameengine/Converter/KX_BlenderSceneConverter.cpp
index 1c3352454a2..9020720eaeb 100644
--- a/source/gameengine/Converter/KX_BlenderSceneConverter.cpp
+++ b/source/gameengine/Converter/KX_BlenderSceneConverter.cpp
@@ -160,7 +160,7 @@ KX_BlenderSceneConverter::~KX_BlenderSceneConverter()
while (itmat != m_materials.end()) {
delete (*itmat).second;
itmat++;
- }
+ }
vector<pair<KX_Scene*,RAS_MeshObject*> >::iterator itm = m_meshobjects.begin();
@@ -201,7 +201,7 @@ bool KX_BlenderSceneConverter::TryAndLoadNewFile()
// if not, clear the newfilename
else
{
- m_newfilename = "";
+ m_newfilename = "";
}
*/
return result;
@@ -335,7 +335,7 @@ void KX_BlenderSceneConverter::ConvertScene(class KX_Scene* destinationscene,
ccdPhysEnv->setDebugMode(btIDebugDraw::DBG_DrawWireframe|btIDebugDraw::DBG_DrawAabb|btIDebugDraw::DBG_DrawContactPoints|btIDebugDraw::DBG_DrawText|btIDebugDraw::DBG_DrawConstraintLimits|btIDebugDraw::DBG_DrawConstraints);
//todo: get a button in blender ?
- //disable / enable debug drawing (contact points, aabb's etc)
+ //disable / enable debug drawing (contact points, aabb's etc)
//ccdPhysEnv->setDebugMode(1);
destinationscene->SetPhysicsEnvironment(ccdPhysEnv);
break;
@@ -689,7 +689,7 @@ void KX_BlenderSceneConverter::ResetPhysicsObjectsAnimationIpo(bool clearIpo)
void KX_BlenderSceneConverter::resetNoneDynamicObjectToIpo()
{
- if (addInitFromFrame) {
+ if (addInitFromFrame) {
KX_SceneList* scenes = m_ketsjiEngine->CurrentScenes();
int numScenes = scenes->size();
if (numScenes>=0) {
@@ -704,7 +704,7 @@ void KX_BlenderSceneConverter::resetNoneDynamicObjectToIpo()
if (blenderobject->type==OB_ARMATURE)
continue;
float eu[3];
- mat4_to_eul(eu,blenderobject->obmat);
+ mat4_to_eul(eu,blenderobject->obmat);
MT_Point3 pos = MT_Point3(
blenderobject->obmat[3][0],
blenderobject->obmat[3][1],
@@ -779,8 +779,8 @@ void KX_BlenderSceneConverter::WritePhysicsObjectToAnimationIpo(int frameNumber)
//const MT_Vector3& scale = gameObj->NodeGetWorldScaling();
const MT_Matrix3x3& orn = gameObj->NodeGetWorldOrientation();
- float eulerAngles[3];
- float eulerAnglesOld[3] = {0.0f, 0.0f, 0.0f};
+ float eulerAngles[3];
+ float eulerAnglesOld[3] = {0.0f, 0.0f, 0.0f};
float tmat[3][3];
// XXX animato
@@ -984,7 +984,7 @@ bool KX_BlenderSceneConverter::LinkBlendFile(BlendHandle *bpy_openlib, const cha
}
main_newlib= (Main *)MEM_callocN( sizeof(Main), "BgeMain");
- BKE_reports_init(&reports, RPT_STORE);
+ BKE_reports_init(&reports, RPT_STORE);
load_datablocks(main_newlib, bpy_openlib, path, idcode);
@@ -1000,11 +1000,11 @@ bool KX_BlenderSceneConverter::LinkBlendFile(BlendHandle *bpy_openlib, const cha
BLO_blendhandle_close(bpy_openlib);
BKE_reports_clear(&reports);
- /* done linking */
+ /* done linking */
/* needed for lookups*/
GetMainDynamic().push_back(main_newlib);
- strncpy(main_newlib->name, path, sizeof(main_newlib->name));
+ strncpy(main_newlib->name, path, sizeof(main_newlib->name));
if (idcode==ID_ME) {
@@ -1028,7 +1028,7 @@ bool KX_BlenderSceneConverter::LinkBlendFile(BlendHandle *bpy_openlib, const cha
scene_merge->GetLogicManager()->RegisterActionName(action->name+2, action);
}
}
- else if (idcode==ID_SCE) {
+ else if (idcode==ID_SCE) {
/* Merge all new linked in scene into the existing one */
ID *scene;
for (scene= (ID *)main_newlib->scene.first; scene; scene= (ID *)scene->next ) {
@@ -1117,7 +1117,7 @@ bool KX_BlenderSceneConverter::FreeBlendFile(struct Main *maggie)
{
RAS_MeshObject *meshobj= (RAS_MeshObject *) *mapStringToMeshes.at(i);
if (meshobj && IS_TAGGED(meshobj->GetMesh()))
- {
+ {
STR_HashedString mn = meshobj->GetName();
mapStringToMeshes.remove(mn);
m_map_mesh_to_gamemesh.remove(CHashedPtr(meshobj->GetMesh()));
@@ -1255,7 +1255,7 @@ bool KX_BlenderSceneConverter::FreeBlendFile(struct Main *maggie)
RAS_IPolyMaterial *mat= (*polymit).second;
Material *bmat= NULL;
- /* Why do we need to check for RAS_BLENDERMAT if both are cast to a (PyObject*)? - Campbell */
+ /* Why do we need to check for RAS_BLENDERMAT if both are cast to a (PyObject *)? - Campbell */
if (mat->GetFlag() & RAS_BLENDERMAT) {
KX_BlenderMaterial *bl_mat = static_cast<KX_BlenderMaterial*>(mat);
bmat= bl_mat->GetBlenderMaterial();
@@ -1280,7 +1280,7 @@ bool KX_BlenderSceneConverter::FreeBlendFile(struct Main *maggie)
RAS_IPolyMaterial *mat= (*polymit).second;
Material *bmat= NULL;
- /* Why do we need to check for RAS_BLENDERMAT if both are cast to a (PyObject*)? - Campbell */
+ /* Why do we need to check for RAS_BLENDERMAT if both are cast to a (PyObject *)? - Campbell */
if (mat->GetFlag() & RAS_BLENDERMAT) {
KX_BlenderMaterial *bl_mat = static_cast<KX_BlenderMaterial*>(mat);
bmat= bl_mat->GetBlenderMaterial();
diff --git a/source/gameengine/Converter/KX_ConvertActuators.cpp b/source/gameengine/Converter/KX_ConvertActuators.cpp
index 9caa6bbf579..287be3b8359 100644
--- a/source/gameengine/Converter/KX_ConvertActuators.cpp
+++ b/source/gameengine/Converter/KX_ConvertActuators.cpp
@@ -903,7 +903,7 @@ void BL_ConvertActuators(const char* maggiename,
modeArg = SCA_RandomActuator::KX_RANDOMACT_FLOAT_NEGATIVE_EXPONENTIAL;
break;
default:
- ; /* error */
+ ; /* error */
}
tmprandomact = new SCA_RandomActuator(gameobj,
seedArg,
diff --git a/source/gameengine/Converter/KX_ConvertControllers.cpp b/source/gameengine/Converter/KX_ConvertControllers.cpp
index 81778928c2e..3a6aa228957 100644
--- a/source/gameengine/Converter/KX_ConvertControllers.cpp
+++ b/source/gameengine/Converter/KX_ConvertControllers.cpp
@@ -69,7 +69,7 @@
static void
LinkControllerToActuators(
SCA_IController *game_controller,
- bController* bcontr,
+ bController* bcontr,
SCA_LogicManager* logicmgr,
KX_BlenderSceneConverter* converter
) {
diff --git a/source/gameengine/Converter/KX_ConvertProperties.cpp b/source/gameengine/Converter/KX_ConvertProperties.cpp
index faa7780bac0..fc14c9d2176 100644
--- a/source/gameengine/Converter/KX_ConvertProperties.cpp
+++ b/source/gameengine/Converter/KX_ConvertProperties.cpp
@@ -67,7 +67,7 @@ void BL_ConvertProperties(Object* object,KX_GameObject* gameobj,SCA_TimeEventMan
{
bProperty* prop = (bProperty*)object->prop.first;
- CValue* propval;
+ CValue* propval;
bool show_debug_info;
while(prop)
{
diff --git a/source/gameengine/Converter/KX_ConvertSensors.cpp b/source/gameengine/Converter/KX_ConvertSensors.cpp
index 9f155a6ebc3..3d4f3ae08f2 100644
--- a/source/gameengine/Converter/KX_ConvertSensors.cpp
+++ b/source/gameengine/Converter/KX_ConvertSensors.cpp
@@ -183,7 +183,7 @@ void BL_ConvertSensors(struct Object* blenderobject,
if (gameobj->GetPhysicsController())
- {
+ {
gamesensor = new KX_TouchSensor(eventmgr,
gameobj,
bFindMaterial,
@@ -209,7 +209,7 @@ void BL_ConvertSensors(struct Object* blenderobject,
}
bool bFindMaterial = true;
if (gameobj->GetPhysicsController())
- {
+ {
gamesensor = new KX_TouchSensor(eventmgr,
gameobj,
bFindMaterial,
@@ -224,7 +224,7 @@ void BL_ConvertSensors(struct Object* blenderobject,
KX_NetworkEventManager* eventmgr = (KX_NetworkEventManager*)
logicmgr->FindEventManager(SCA_EventManager::NETWORK_EVENTMGR);
if (eventmgr) {
- bMessageSensor* msgSens = (bMessageSensor*) sens->data;
+ bMessageSensor* msgSens = (bMessageSensor*) sens->data;
/* Get our NetworkScene */
NG_NetworkScene *NetworkScene = kxscene->GetNetworkScene();
@@ -247,7 +247,7 @@ void BL_ConvertSensors(struct Object* blenderobject,
SCA_EventManager* eventmgr = logicmgr->FindEventManager(SCA_EventManager::TOUCH_EVENTMGR);
if (eventmgr)
{
- STR_String nearpropertyname;
+ STR_String nearpropertyname;
bNearSensor* blendernearsensor = (bNearSensor*)sens->data;
if (blendernearsensor->name)
{
@@ -311,7 +311,7 @@ void BL_ConvertSensors(struct Object* blenderobject,
}
case SENS_MOUSE:
{
- int keytype = SCA_MouseSensor::KX_MOUSESENSORMODE_NODEF;
+ int keytype = SCA_MouseSensor::KX_MOUSESENSORMODE_NODEF;
int trackfocus = 0;
bMouseSensor *bmouse = (bMouseSensor *)sens->data;
@@ -639,7 +639,7 @@ void BL_ConvertSensors(struct Object* blenderobject,
gamesensor->SetInvert(invert);
gamesensor->SetLevel(level);
gamesensor->SetTap(tap);
- gamesensor->SetName(sens->name);
+ gamesensor->SetName(sens->name);
gameobj->AddSensor(gamesensor);
diff --git a/source/gameengine/Converter/KX_IpoConvert.cpp b/source/gameengine/Converter/KX_IpoConvert.cpp
index 309959b4324..12f88251805 100644
--- a/source/gameengine/Converter/KX_IpoConvert.cpp
+++ b/source/gameengine/Converter/KX_IpoConvert.cpp
@@ -76,12 +76,12 @@ static BL_InterpolatorList *GetAdtList(struct bAction *for_act, KX_BlenderSceneC
{
BL_InterpolatorList *adtList= converter->FindInterpolatorList(for_act);
- if (!adtList) {
+ if (!adtList) {
adtList = new BL_InterpolatorList(for_act);
converter->RegisterInterpolatorList(adtList, for_act);
}
- return adtList;
+ return adtList;
}
SG_Controller *BL_CreateIPO(struct bAction *action, KX_GameObject* gameobj, KX_BlenderSceneConverter *converter)
@@ -441,7 +441,7 @@ static void ConvertMaterialIpos(
}
interpolator= new KX_ScalarInterpolator(&ipocontr->m_ref, sinterp);
ipocontr->AddInterpolator(interpolator);
- }
+ }
if ((sinterp = adtList->GetScalarInterpolator("emit", 0))) {
if (!ipocontr) {
@@ -452,7 +452,7 @@ static void ConvertMaterialIpos(
interpolator= new KX_ScalarInterpolator(&ipocontr->m_emit, sinterp);
ipocontr->AddInterpolator(interpolator);
}
- }
+ }
}
void BL_ConvertMaterialIpos(
diff --git a/source/gameengine/Expressions/BoolValue.cpp b/source/gameengine/Expressions/BoolValue.cpp
index 40997a25be1..e640923129a 100644
--- a/source/gameengine/Expressions/BoolValue.cpp
+++ b/source/gameengine/Expressions/BoolValue.cpp
@@ -205,7 +205,7 @@ CValue* CBoolValue::GetReplica()
}
#ifdef WITH_PYTHON
-PyObject* CBoolValue::ConvertValueToPython()
+PyObject *CBoolValue::ConvertValueToPython()
{
return PyBool_FromLong(m_bool != 0);
}
diff --git a/source/gameengine/Expressions/BoolValue.h b/source/gameengine/Expressions/BoolValue.h
index 09e931ea661..64ac0266baf 100644
--- a/source/gameengine/Expressions/BoolValue.h
+++ b/source/gameengine/Expressions/BoolValue.h
@@ -29,7 +29,7 @@
class CBoolValue : public CPropValue
{
- //PLUGIN_DECLARE_SERIAL(CBoolValue,CValue)
+ //PLUGIN_DECLARE_SERIAL(CBoolValue,CValue)
public:
static const STR_String sTrueString;
diff --git a/source/gameengine/Expressions/FloatValue.cpp b/source/gameengine/Expressions/FloatValue.cpp
index 403338573e2..c9b59e52ee8 100644
--- a/source/gameengine/Expressions/FloatValue.cpp
+++ b/source/gameengine/Expressions/FloatValue.cpp
@@ -314,7 +314,7 @@ CValue* CFloatValue::GetReplica()
#ifdef WITH_PYTHON
-PyObject* CFloatValue::ConvertValueToPython()
+PyObject *CFloatValue::ConvertValueToPython()
{
return PyFloat_FromDouble(m_float);
}
diff --git a/source/gameengine/Expressions/InputParser.cpp b/source/gameengine/Expressions/InputParser.cpp
index 58837235d30..bdf4ee4605b 100644
--- a/source/gameengine/Expressions/InputParser.cpp
+++ b/source/gameengine/Expressions/InputParser.cpp
@@ -543,7 +543,7 @@ CExpression *CParser::Ex(int i)
}
e1 = Error(errtext);
- break;
+ break;
}
default:
NextSym();
@@ -573,7 +573,7 @@ CExpression* CParser::ProcessText
text = intext;
- chcount = 0;
+ chcount = 0;
if (text.Length() == 0) {
return NULL;
}
diff --git a/source/gameengine/Expressions/IntValue.cpp b/source/gameengine/Expressions/IntValue.cpp
index 2d427440620..12d6e258ddf 100644
--- a/source/gameengine/Expressions/IntValue.cpp
+++ b/source/gameengine/Expressions/IntValue.cpp
@@ -326,7 +326,7 @@ void CIntValue::SetValue(CValue* newval)
#ifdef WITH_PYTHON
-PyObject* CIntValue::ConvertValueToPython()
+PyObject *CIntValue::ConvertValueToPython()
{
if ((m_int > INT_MIN) && (m_int < INT_MAX))
return PyLong_FromSsize_t(m_int);
diff --git a/source/gameengine/Expressions/KX_HashedPtr.h b/source/gameengine/Expressions/KX_HashedPtr.h
index ffc6ff647d5..866689ed203 100644
--- a/source/gameengine/Expressions/KX_HashedPtr.h
+++ b/source/gameengine/Expressions/KX_HashedPtr.h
@@ -50,7 +50,7 @@ public:
inline friend bool operator ==( const CHashedPtr & rhs,const CHashedPtr & lhs)
{
return rhs.m_valptr == lhs.m_valptr;
- }
+ }
#ifdef WITH_CXX_GUARDEDALLOC
diff --git a/source/gameengine/Expressions/ListValue.cpp b/source/gameengine/Expressions/ListValue.cpp
index ef82b9ed8cf..88b0a986a05 100644
--- a/source/gameengine/Expressions/ListValue.cpp
+++ b/source/gameengine/Expressions/ListValue.cpp
@@ -278,7 +278,7 @@ bool CListValue::IsModified()
/* Python interface ---------------------------------------------------- */
/* --------------------------------------------------------------------- */
-static Py_ssize_t listvalue_bufferlen(PyObject* self)
+static Py_ssize_t listvalue_bufferlen(PyObject *self)
{
CListValue *list= static_cast<CListValue *>(BGE_PROXY_REF(self));
if (list==NULL)
@@ -287,7 +287,7 @@ static Py_ssize_t listvalue_bufferlen(PyObject* self)
return (Py_ssize_t)list->GetCount();
}
-static PyObject* listvalue_buffer_item(PyObject* self, Py_ssize_t index)
+static PyObject *listvalue_buffer_item(PyObject *self, Py_ssize_t index)
{
CListValue *list= static_cast<CListValue *>(BGE_PROXY_REF(self));
CValue *cval;
@@ -309,14 +309,14 @@ static PyObject* listvalue_buffer_item(PyObject* self, Py_ssize_t index)
cval= list->GetValue(index);
- PyObject* pyobj = cval->ConvertValueToPython();
+ PyObject *pyobj = cval->ConvertValueToPython();
if (pyobj)
return pyobj;
else
return cval->GetProxy();
}
-static PyObject* listvalue_mapping_subscript(PyObject* self, PyObject* pyindex)
+static PyObject *listvalue_mapping_subscript(PyObject *self, PyObject *pyindex)
{
CListValue *list= static_cast<CListValue *>(BGE_PROXY_REF(self));
if (list==NULL) {
@@ -328,7 +328,7 @@ static PyObject* listvalue_mapping_subscript(PyObject* self, PyObject* pyindex)
{
CValue *item = ((CListValue*) list)->FindValue(_PyUnicode_AsString(pyindex));
if (item) {
- PyObject* pyobj = item->ConvertValueToPython();
+ PyObject *pyobj = item->ConvertValueToPython();
if (pyobj)
return pyobj;
else
@@ -348,7 +348,7 @@ static PyObject* listvalue_mapping_subscript(PyObject* self, PyObject* pyindex)
/* just slice it into a python list... */
-static PyObject* listvalue_buffer_slice(PyObject* self,Py_ssize_t ilow, Py_ssize_t ihigh)
+static PyObject *listvalue_buffer_slice(PyObject *self,Py_ssize_t ilow, Py_ssize_t ihigh)
{
CListValue *list= static_cast<CListValue *>(BGE_PROXY_REF(self));
if (list==NULL) {
@@ -374,17 +374,17 @@ static PyObject* listvalue_buffer_slice(PyObject* self,Py_ssize_t ilow, Py_ssize
for (i = ilow, j = 0; i < ihigh; i++, j++)
{
- PyObject* pyobj = list->GetValue(i)->ConvertValueToPython();
+ PyObject *pyobj = list->GetValue(i)->ConvertValueToPython();
if (!pyobj)
pyobj = list->GetValue(i)->GetProxy();
PyList_SET_ITEM(newlist, i, pyobj);
- }
+ }
return newlist;
}
/* clist + list, return a list that python owns */
-static PyObject *listvalue_buffer_concat(PyObject * self, PyObject * other)
+static PyObject *listvalue_buffer_concat(PyObject *self, PyObject *other)
{
CListValue *listval= static_cast<CListValue *>(BGE_PROXY_REF(self));
Py_ssize_t i, numitems, numitems_orig;
@@ -560,7 +560,7 @@ PyAttributeDef CListValue::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* CListValue::Pyappend(PyObject* value)
+PyObject *CListValue::Pyappend(PyObject *value)
{
CValue* objval = ConvertPythonToValue(value, "CList.append(i): CValueList, ");
@@ -577,15 +577,15 @@ PyObject* CListValue::Pyappend(PyObject* value)
Py_RETURN_NONE;
}
-PyObject* CListValue::Pyreverse()
+PyObject *CListValue::Pyreverse()
{
std::reverse(m_pValueArray.begin(),m_pValueArray.end());
Py_RETURN_NONE;
}
-PyObject* CListValue::Pyindex(PyObject *value)
+PyObject *CListValue::Pyindex(PyObject *value)
{
- PyObject* result = NULL;
+ PyObject *result = NULL;
CValue* checkobj = ConvertPythonToValue(value, "val = cList[i]: CValueList, ");
if (checkobj==NULL)
@@ -612,7 +612,7 @@ PyObject* CListValue::Pyindex(PyObject *value)
-PyObject* CListValue::Pycount(PyObject* value)
+PyObject *CListValue::Pycount(PyObject *value)
{
int numfound = 0;
@@ -638,17 +638,17 @@ PyObject* CListValue::Pycount(PyObject* value)
}
/* Matches python dict.get(key, [default]) */
-PyObject* CListValue::Pyget(PyObject *args)
+PyObject *CListValue::Pyget(PyObject *args)
{
char *key;
- PyObject* def = Py_None;
+ PyObject *def = Py_None;
if (!PyArg_ParseTuple(args, "s|O:get", &key, &def))
return NULL;
CValue *item = FindValue((const char *)key);
if (item) {
- PyObject* pyobj = item->ConvertValueToPython();
+ PyObject *pyobj = item->ConvertValueToPython();
if (pyobj)
return pyobj;
else
@@ -659,7 +659,7 @@ PyObject* CListValue::Pyget(PyObject *args)
}
-PyObject* CListValue::Pyfrom_id(PyObject* value)
+PyObject *CListValue::Pyfrom_id(PyObject *value)
{
uintptr_t id= (uintptr_t)PyLong_AsVoidPtr(value);
diff --git a/source/gameengine/Expressions/ListValue.h b/source/gameengine/Expressions/ListValue.h
index 4d104a4bd3a..20005088310 100644
--- a/source/gameengine/Expressions/ListValue.h
+++ b/source/gameengine/Expressions/ListValue.h
@@ -64,7 +64,7 @@ public:
bool CheckEqual(CValue* first,CValue* second);
#ifdef WITH_PYTHON
- virtual PyObject* py_repr(void) {
+ virtual PyObject *py_repr(void) {
PyObject *py_proxy= this->GetProxy();
PyObject *py_list= PySequence_List(py_proxy);
PyObject *py_string= PyObject_Repr(py_list);
diff --git a/source/gameengine/Expressions/Operator2Expr.cpp b/source/gameengine/Expressions/Operator2Expr.cpp
index 2224b0ff5e8..d0240b5ec75 100644
--- a/source/gameengine/Expressions/Operator2Expr.cpp
+++ b/source/gameengine/Expressions/Operator2Expr.cpp
@@ -102,7 +102,7 @@ and m_rhs
m_cached_calculate = ffleft->Calc(m_op,ffright);
- //if (m_cached_calculate)
+ //if (m_cached_calculate)
// m_cached_calculate->Action(CValue::SETOWNEREXPR,&CVoidValue(this,false,CValue::STACKVALUE));
ffleft->Release();
@@ -163,7 +163,7 @@ bool COperator2Expr::IsInside(float x, float y, float z,bool bBorderInclude)
}
}
- return inside;
+ return inside;
}
@@ -241,7 +241,7 @@ CExpression* COperator2Expr::CheckLink(std::vector<CBrokenLinkInfo*>& brokenlink
if (m_rhs)
return Release(m_rhs->AddRef());
-/
+/
*/
return Release();
diff --git a/source/gameengine/Expressions/PyObjectPlus.cpp b/source/gameengine/Expressions/PyObjectPlus.cpp
index a35cb4f9f69..6bb2f039b5c 100644
--- a/source/gameengine/Expressions/PyObjectPlus.cpp
+++ b/source/gameengine/Expressions/PyObjectPlus.cpp
@@ -145,7 +145,7 @@ PyObject *PyObjectPlus::py_base_repr(PyObject *self) // This should be the ent
}
-PyObject * PyObjectPlus::py_base_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
+PyObject *PyObjectPlus::py_base_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
{
PyTypeObject *base_type;
PyObjectPlus_Proxy *base = NULL;
@@ -270,7 +270,7 @@ PyAttributeDef PyObjectPlus::Attributes[] = {
-PyObject* PyObjectPlus::pyattr_get_invalid(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *PyObjectPlus::pyattr_get_invalid(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return PyBool_FromLong(self_v ? 0:1);
}
@@ -303,7 +303,7 @@ PyObject *PyObjectPlus::py_get_attrdef(PyObject *self_py, const PyAttributeDef *
ptr += attrdef->m_offset;
if (attrdef->m_length > 1)
{
- PyObject* resultlist = PyList_New(attrdef->m_length);
+ PyObject *resultlist = PyList_New(attrdef->m_length);
for (unsigned int i=0; i<attrdef->m_length; i++)
{
switch (attrdef->m_type) {
@@ -420,7 +420,7 @@ PyObject *PyObjectPlus::py_get_attrdef(PyObject *self_py, const PyAttributeDef *
#ifdef USE_MATHUTILS
return Vector_CreatePyObject(val, attrdef->m_imax, Py_NEW, NULL);
#else
- PyObject* resultlist = PyList_New(attrdef->m_imax);
+ PyObject *resultlist = PyList_New(attrdef->m_imax);
for (unsigned int i=0; i<attrdef->m_imax; i++)
{
PyList_SET_ITEM(resultlist,i,PyFloat_FromDouble(val[i]));
@@ -437,10 +437,10 @@ PyObject *PyObjectPlus::py_get_attrdef(PyObject *self_py, const PyAttributeDef *
#ifdef USE_MATHUTILS
return Matrix_CreatePyObject(val, attrdef->m_imin, attrdef->m_imax, Py_WRAP, NULL);
#else
- PyObject* collist = PyList_New(attrdef->m_imin);
+ PyObject *collist = PyList_New(attrdef->m_imin);
for (unsigned int i=0; i<attrdef->m_imin; i++)
{
- PyObject* col = PyList_New(attrdef->m_imax);
+ PyObject *col = PyList_New(attrdef->m_imax);
for (unsigned int j=0; j<attrdef->m_imax; j++)
{
PyList_SET_ITEM(col,j,PyFloat_FromDouble(val[j]));
@@ -460,7 +460,7 @@ PyObject *PyObjectPlus::py_get_attrdef(PyObject *self_py, const PyAttributeDef *
val->getValue(fval);
return Vector_CreatePyObject(fval, 3, Py_NEW, NULL);
#else
- PyObject* resultlist = PyList_New(3);
+ PyObject *resultlist = PyList_New(3);
for (unsigned int i=0; i<3; i++)
{
PyList_SET_ITEM(resultlist,i,PyFloat_FromDouble((*val)[i]));
@@ -1100,7 +1100,7 @@ int PyObjectPlus::py_set_attrdef(PyObject *self_py, PyObject *value, const PyAtt
}
if (undoBuffer)
free(undoBuffer);
- return 0;
+ return 0;
}
@@ -1139,7 +1139,7 @@ PyObject *PyObjectPlus::NewProxyPlus_Ext(PyObjectPlus *self, PyTypeObject *tp, v
if (!self)
{
// in case of proxy without reference to game object
- PyObject* proxy = reinterpret_cast<PyObject *>PyObject_NEW( PyObjectPlus_Proxy, tp);
+ PyObject *proxy = reinterpret_cast<PyObject *>PyObject_NEW( PyObjectPlus_Proxy, tp);
BGE_PROXY_PYREF(proxy) = false;
BGE_PROXY_PYOWNS(proxy) = py_owns;
BGE_PROXY_REF(proxy) = NULL;
diff --git a/source/gameengine/Expressions/PyObjectPlus.h b/source/gameengine/Expressions/PyObjectPlus.h
index f74ed7db8f7..005bf2f6cb2 100644
--- a/source/gameengine/Expressions/PyObjectPlus.h
+++ b/source/gameengine/Expressions/PyObjectPlus.h
@@ -190,9 +190,9 @@ public: \
* macro is one that also requires a documentation string
*/
#define KX_PYMETHOD(class_name, method_name) \
- PyObject* Py##method_name(PyObject* args, PyObject* kwds); \
- static PyObject* \
- sPy##method_name(PyObject* self, PyObject* args, PyObject* kwds) { \
+ PyObject *Py##method_name(PyObject *args, PyObject *kwds); \
+ static PyObject * \
+ sPy##method_name(PyObject *self, PyObject *args, PyObject *kwds) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "() - " \
@@ -203,9 +203,9 @@ public: \
} \
#define KX_PYMETHOD_VARARGS(class_name, method_name) \
- PyObject* Py##method_name(PyObject* args); \
+ PyObject *Py##method_name(PyObject *args); \
static PyObject* \
- sPy##method_name(PyObject* self, PyObject* args) { \
+ sPy##method_name(PyObject *self, PyObject *args) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "() - " \
@@ -215,9 +215,9 @@ public: \
} \
#define KX_PYMETHOD_NOARGS(class_name, method_name) \
- PyObject* Py##method_name(); \
+ PyObject *Py##method_name(); \
static PyObject* \
- sPy##method_name(PyObject* self) { \
+ sPy##method_name(PyObject *self) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "() - " \
@@ -227,9 +227,9 @@ public: \
} \
#define KX_PYMETHOD_O(class_name, method_name) \
- PyObject* Py##method_name(PyObject* value); \
+ PyObject *Py##method_name(PyObject *value); \
static PyObject* \
- sPy##method_name(PyObject* self, PyObject* value) { \
+ sPy##method_name(PyObject *self, PyObject *value) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "(value) - " \
@@ -239,9 +239,9 @@ public: \
} \
#define KX_PYMETHOD_DOC(class_name, method_name) \
- PyObject* Py##method_name(PyObject* args, PyObject* kwds); \
+ PyObject *Py##method_name(PyObject *args, PyObject *kwds); \
static PyObject* \
- sPy##method_name(PyObject* self, PyObject* args, PyObject* kwds) { \
+ sPy##method_name(PyObject *self, PyObject *args, PyObject *kwds) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "(...) - " \
@@ -252,9 +252,9 @@ public: \
static const char method_name##_doc[]; \
#define KX_PYMETHOD_DOC_VARARGS(class_name, method_name) \
- PyObject* Py##method_name(PyObject* args); \
+ PyObject *Py##method_name(PyObject *args); \
static PyObject* \
- sPy##method_name(PyObject* self, PyObject* args) { \
+ sPy##method_name(PyObject *self, PyObject *args) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "(...) - " \
@@ -266,9 +266,9 @@ public: \
static const char method_name##_doc[]; \
#define KX_PYMETHOD_DOC_O(class_name, method_name) \
- PyObject* Py##method_name(PyObject* value); \
- static PyObject* \
- sPy##method_name(PyObject* self, PyObject* value) { \
+ PyObject *Py##method_name(PyObject *value); \
+ static PyObject * \
+ sPy##method_name(PyObject *self, PyObject *value) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "(value) - " \
@@ -280,9 +280,9 @@ public: \
static const char method_name##_doc[]; \
#define KX_PYMETHOD_DOC_NOARGS(class_name, method_name) \
- PyObject* Py##method_name(); \
- static PyObject* \
- sPy##method_name(PyObject* self) { \
+ PyObject *Py##method_name(); \
+ static PyObject * \
+ sPy##method_name(PyObject *self) { \
if(BGE_PROXY_REF(self)==NULL) { \
PyErr_SetString(PyExc_RuntimeError, \
#class_name "." #method_name "() - " \
@@ -315,19 +315,19 @@ public: \
*/
#define KX_PYMETHODDEF_DOC(class_name, method_name, doc_string) \
const char class_name::method_name##_doc[] = doc_string; \
-PyObject* class_name::Py##method_name(PyObject* args, PyObject* kwds)
+PyObject *class_name::Py##method_name(PyObject *args, PyObject *kwds)
#define KX_PYMETHODDEF_DOC_VARARGS(class_name, method_name, doc_string) \
const char class_name::method_name##_doc[] = doc_string; \
-PyObject* class_name::Py##method_name(PyObject* args)
+PyObject *class_name::Py##method_name(PyObject *args)
#define KX_PYMETHODDEF_DOC_O(class_name, method_name, doc_string) \
const char class_name::method_name##_doc[] = doc_string; \
-PyObject* class_name::Py##method_name(PyObject* value)
+PyObject *class_name::Py##method_name(PyObject *value)
#define KX_PYMETHODDEF_DOC_NOARGS(class_name, method_name, doc_string) \
const char class_name::method_name##_doc[] = doc_string; \
-PyObject* class_name::Py##method_name()
+PyObject *class_name::Py##method_name()
/**
* Attribute management
@@ -354,7 +354,7 @@ enum KX_PYATTRIBUTE_ACCESS {
struct KX_PYATTRIBUTE_DEF;
typedef int (*KX_PYATTRIBUTE_CHECK_FUNCTION)(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
typedef int (*KX_PYATTRIBUTE_SET_FUNCTION)(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
-typedef PyObject* (*KX_PYATTRIBUTE_GET_FUNCTION)(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+typedef PyObject *(*KX_PYATTRIBUTE_GET_FUNCTION)(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
typedef struct KX_PYATTRIBUTE_DEF {
const char *m_name; // name of the python attribute
diff --git a/source/gameengine/Expressions/StringValue.h b/source/gameengine/Expressions/StringValue.h
index e37b4638a1e..bc102c6e203 100644
--- a/source/gameengine/Expressions/StringValue.h
+++ b/source/gameengine/Expressions/StringValue.h
@@ -25,7 +25,7 @@ class CStringValue : public CPropValue
{
- //PLUGIN_DECLARE_SERIAL(CStringValue,CValue)
+ //PLUGIN_DECLARE_SERIAL(CStringValue,CValue)
public:
/// Construction / destruction
CStringValue();
diff --git a/source/gameengine/Expressions/Value.cpp b/source/gameengine/Expressions/Value.cpp
index 6507cc32cf1..bcfb7e92d71 100644
--- a/source/gameengine/Expressions/Value.cpp
+++ b/source/gameengine/Expressions/Value.cpp
@@ -340,7 +340,7 @@ vector<STR_String> CValue::GetPropertyNames()
// Clear all properties
//
void CValue::ClearProperties()
-{
+{
// Check if we have any properties
if (m_pNamedPropertyArray == NULL)
return;
@@ -530,13 +530,13 @@ PyAttributeDef CValue::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject * CValue::pyattr_get_name(void * self_v, const KX_PYATTRIBUTE_DEF * attrdef)
+PyObject *CValue::pyattr_get_name(void * self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
CValue * self = static_cast<CValue *> (self_v);
return PyUnicode_From_STR_String(self->GetName());
}
-CValue* CValue::ConvertPythonToValue(PyObject* pyobj, const char *error_prefix)
+CValue* CValue::ConvertPythonToValue(PyObject *pyobj, const char *error_prefix)
{
CValue* vallie = NULL;
@@ -551,7 +551,7 @@ CValue* CValue::ConvertPythonToValue(PyObject* pyobj, const char *error_prefix)
Py_ssize_t numitems = PyList_GET_SIZE(pyobj);
for (i=0;i<numitems;i++)
{
- PyObject* listitem = PyList_GetItem(pyobj,i); /* borrowed ref */
+ PyObject *listitem = PyList_GetItem(pyobj,i); /* borrowed ref */
CValue* listitemval = ConvertPythonToValue(listitem, error_prefix);
if (listitemval)
{
@@ -597,7 +597,7 @@ CValue* CValue::ConvertPythonToValue(PyObject* pyobj, const char *error_prefix)
}
-PyObject* CValue::ConvertKeysToPython(void)
+PyObject *CValue::ConvertKeysToPython(void)
{
if (m_pNamedPropertyArray)
{
@@ -636,5 +636,5 @@ void CValue::SetColorOperator(VALUE_OPERATOR op)
void CValue::SetValue(CValue* newval)
{
// no one should get here
- assertd(newval->GetNumber() == 10121969);
+ assertd(newval->GetNumber() == 10121969);
}
diff --git a/source/gameengine/Expressions/Value.h b/source/gameengine/Expressions/Value.h
index e3b52e80ba6..e0c4daeccd0 100644
--- a/source/gameengine/Expressions/Value.h
+++ b/source/gameengine/Expressions/Value.h
@@ -218,21 +218,21 @@ public:
CValue();
#ifdef WITH_PYTHON
- //static PyObject* PyMake(PyObject*,PyObject*);
+ //static PyObject *PyMake(PyObject *, PyObject *);
virtual PyObject *py_repr(void)
{
return PyUnicode_From_STR_String(GetText());
}
- virtual PyObject* ConvertValueToPython() {
+ virtual PyObject *ConvertValueToPython() {
return NULL;
}
- virtual CValue* ConvertPythonToValue(PyObject* pyobj, const char *error_prefix);
+ virtual CValue *ConvertPythonToValue(PyObject *pyobj, const char *error_prefix);
- static PyObject * pyattr_get_name(void * self, const KX_PYATTRIBUTE_DEF * attrdef);
+ static PyObject *pyattr_get_name(void * self, const KX_PYATTRIBUTE_DEF * attrdef);
- virtual PyObject* ConvertKeysToPython( void );
+ virtual PyObject *ConvertKeysToPython( void );
#endif // WITH_PYTHON
@@ -250,13 +250,13 @@ public:
};
/// Reference Counting
- int GetRefCount()
+ int GetRefCount()
{
return m_refcount;
}
// Add a reference to this value
- CValue* AddRef()
+ CValue *AddRef()
{
// Increase global reference count, used to see at the end of the program
// if all CValue-derived classes have been dereferenced to 0
@@ -269,7 +269,7 @@ public:
}
// Release a reference to this value (when reference count reaches 0, the value is removed from the heap)
- int Release()
+ int Release()
{
// Decrease global reference count, used to see at the end of the program
// if all CValue-derived classes have been dereferenced to 0
@@ -354,16 +354,16 @@ public:
virtual void SetCustomFlag2(bool bCustomFlag) { m_ValFlags.CustomFlag2 = bCustomFlag;}
virtual bool IsCustomFlag2() { return m_ValFlags.CustomFlag2;}
-protected:
+protected:
virtual void DisableRefCount(); // Disable reference counting for this value
- //virtual void AddDataToReplica(CValue* replica);
+ //virtual void AddDataToReplica(CValue* replica);
virtual ~CValue();
private:
- // Member variables
+ // Member variables
std::map<STR_String,CValue*>* m_pNamedPropertyArray; // Properties for user/game etc
ValueFlags m_ValFlags; // Frequently used flags in a bitfield (low memoryusage)
- int m_refcount; // Reference Counter
- static double m_sZeroVec[3];
+ int m_refcount; // Reference Counter
+ static double m_sZeroVec[3];
};
diff --git a/source/gameengine/GameLogic/Joystick/SCA_Joystick.h b/source/gameengine/GameLogic/Joystick/SCA_Joystick.h
index 685cc3fcc48..912484a2fe5 100644
--- a/source/gameengine/GameLogic/Joystick/SCA_Joystick.h
+++ b/source/gameengine/GameLogic/Joystick/SCA_Joystick.h
@@ -65,7 +65,7 @@ class SCA_Joystick
/**
*support for JOYHAT_MAX hats (each is a direction)
*/
- int m_hat_array[JOYHAT_MAX];
+ int m_hat_array[JOYHAT_MAX];
/**
* Precision or range of the axes
diff --git a/source/gameengine/GameLogic/SCA_IController.cpp b/source/gameengine/GameLogic/SCA_IController.cpp
index 3fda542410a..6d76f122163 100644
--- a/source/gameengine/GameLogic/SCA_IController.cpp
+++ b/source/gameengine/GameLogic/SCA_IController.cpp
@@ -238,19 +238,19 @@ PyAttributeDef SCA_IController::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* SCA_IController::pyattr_get_state(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_IController::pyattr_get_state(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_IController* self= static_cast<SCA_IController*>(self_v);
return PyLong_FromSsize_t(self->m_statemask);
}
-PyObject* SCA_IController::pyattr_get_sensors(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_IController::pyattr_get_sensors(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
- return KX_PythonSeq_CreatePyObject((static_cast<SCA_IController*>(self_v))->m_proxy, KX_PYGENSEQ_CONT_TYPE_SENSORS);
+ return KX_PythonSeq_CreatePyObject((static_cast<SCA_IController*>(self_v))->m_proxy, KX_PYGENSEQ_CONT_TYPE_SENSORS);
}
-PyObject* SCA_IController::pyattr_get_actuators(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_IController::pyattr_get_actuators(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
- return KX_PythonSeq_CreatePyObject((static_cast<SCA_IController*>(self_v))->m_proxy, KX_PYGENSEQ_CONT_TYPE_ACTUATORS);
+ return KX_PythonSeq_CreatePyObject((static_cast<SCA_IController*>(self_v))->m_proxy, KX_PYGENSEQ_CONT_TYPE_ACTUATORS);
}
#endif // WITH_PYTHON
diff --git a/source/gameengine/GameLogic/SCA_IInputDevice.cpp b/source/gameengine/GameLogic/SCA_IInputDevice.cpp
index 16626b05526..f4fce034c87 100644
--- a/source/gameengine/GameLogic/SCA_IInputDevice.cpp
+++ b/source/gameengine/GameLogic/SCA_IInputDevice.cpp
@@ -45,7 +45,7 @@ SCA_IInputDevice::SCA_IInputDevice()
SCA_IInputDevice::~SCA_IInputDevice()
{
-}
+}
void SCA_IInputDevice::HookEscape()
{
@@ -134,6 +134,6 @@ void SCA_IInputDevice::NextFrame()
break;
default:
; /* error */
- }
+ }
}
}
diff --git a/source/gameengine/GameLogic/SCA_IInputDevice.h b/source/gameengine/GameLogic/SCA_IInputDevice.h
index 0382a2efd21..66a1209751d 100644
--- a/source/gameengine/GameLogic/SCA_IInputDevice.h
+++ b/source/gameengine/GameLogic/SCA_IInputDevice.h
@@ -69,7 +69,7 @@ class SCA_IInputDevice
public:
SCA_IInputDevice();
- virtual ~SCA_IInputDevice();
+ virtual ~SCA_IInputDevice();
enum KX_EnumInputs {
@@ -120,17 +120,17 @@ public:
KX_RETKEY = 13,
KX_SPACEKEY = 32,
KX_PADASTERKEY = 42,
- KX_COMMAKEY = 44,
- KX_MINUSKEY = 45,
+ KX_COMMAKEY = 44,
+ KX_MINUSKEY = 45,
KX_PERIODKEY = 46,
KX_ZEROKEY = 48,
KX_ONEKEY, // =49
- KX_TWOKEY,
+ KX_TWOKEY,
KX_THREEKEY,
- KX_FOURKEY,
- KX_FIVEKEY,
- KX_SIXKEY,
+ KX_FOURKEY,
+ KX_FIVEKEY,
+ KX_SIXKEY,
KX_SEVENKEY,
KX_EIGHTKEY,
KX_NINEKEY, // = 57
@@ -170,14 +170,14 @@ public:
KX_LEFTALTKEY,
KX_RIGHTALTKEY,
KX_RIGHTCTRLKEY,
- KX_RIGHTSHIFTKEY,
+ KX_RIGHTSHIFTKEY,
KX_LEFTSHIFTKEY,// 129
KX_ESCKEY, // 130
KX_TABKEY, //131
- KX_LINEFEEDKEY, // 132
+ KX_LINEFEEDKEY, // 132
KX_BACKSPACEKEY,
KX_DELKEY,
KX_SEMICOLONKEY, // 135
@@ -188,13 +188,13 @@ public:
KX_SLASHKEY, //138
KX_BACKSLASHKEY,
- KX_EQUALKEY,
- KX_LEFTBRACKETKEY,
+ KX_EQUALKEY,
+ KX_LEFTBRACKETKEY,
KX_RIGHTBRACKETKEY, // 142
KX_LEFTARROWKEY, // 145
KX_DOWNARROWKEY,
- KX_RIGHTARROWKEY,
+ KX_RIGHTARROWKEY,
KX_UPARROWKEY, // 148
KX_PAD2 ,
diff --git a/source/gameengine/GameLogic/SCA_ILogicBrick.cpp b/source/gameengine/GameLogic/SCA_ILogicBrick.cpp
index 018a939f68d..cfbdc1e750f 100644
--- a/source/gameengine/GameLogic/SCA_ILogicBrick.cpp
+++ b/source/gameengine/GameLogic/SCA_ILogicBrick.cpp
@@ -231,7 +231,7 @@ int SCA_ILogicBrick::CheckProperty(void *self, const PyAttributeDef *attrdef)
}
/*Attribute functions */
-PyObject* SCA_ILogicBrick::pyattr_get_owner(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_ILogicBrick::pyattr_get_owner(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_ILogicBrick* self= static_cast<SCA_ILogicBrick*>(self_v);
CValue* parent = self->GetParent();
@@ -254,9 +254,9 @@ bool SCA_ILogicBrick::PyArgToBool(int boolArg)
}
}
-PyObject* SCA_ILogicBrick::BoolToPyArg(bool boolarg)
+PyObject *SCA_ILogicBrick::BoolToPyArg(bool boolarg)
{
- return PyLong_FromSsize_t(boolarg? KX_TRUE: KX_FALSE);
+ return PyLong_FromSsize_t(boolarg? KX_TRUE: KX_FALSE);
}
#endif // WITH_PYTHON
diff --git a/source/gameengine/GameLogic/SCA_ILogicBrick.h b/source/gameengine/GameLogic/SCA_ILogicBrick.h
index b505353c7cd..c5fa9399ab7 100644
--- a/source/gameengine/GameLogic/SCA_ILogicBrick.h
+++ b/source/gameengine/GameLogic/SCA_ILogicBrick.h
@@ -157,7 +157,7 @@ protected:
bool PyArgToBool(int boolArg);
/** Convert a a c++ value to KX_TRUE, KX_FALSE in Python. */
- PyObject* BoolToPyArg(bool);
+ PyObject *BoolToPyArg(bool);
#endif // WITH_PYTHON
diff --git a/source/gameengine/GameLogic/SCA_IObject.cpp b/source/gameengine/GameLogic/SCA_IObject.cpp
index b90952b2092..ab9e2781001 100644
--- a/source/gameengine/GameLogic/SCA_IObject.cpp
+++ b/source/gameengine/GameLogic/SCA_IObject.cpp
@@ -224,7 +224,7 @@ SCA_IController* SCA_IObject::FindController(const STR_String& controllername)
{
foundcontroller = (*itc);
break;
- }
+ }
}
return foundcontroller;
}
diff --git a/source/gameengine/GameLogic/SCA_IObject.h b/source/gameengine/GameLogic/SCA_IObject.h
index 0e657794195..a850d23babf 100644
--- a/source/gameengine/GameLogic/SCA_IObject.h
+++ b/source/gameengine/GameLogic/SCA_IObject.h
@@ -43,7 +43,7 @@ class SCA_IController;
class SCA_IActuator;
#ifdef WITH_PYTHON
-template<class T> T PyVecTo(PyObject*);
+template<class T> T PyVecTo(PyObject *);
#endif
typedef std::vector<SCA_ISensor *> SCA_SensorList;
@@ -213,7 +213,7 @@ public:
*/
unsigned int GetState(void) { return m_state; }
-// const class MT_Point3& ConvertPythonPylist(PyObject* pylist);
+// const class MT_Point3& ConvertPythonPylist(PyObject *pylist);
virtual int GetGameObjectType() {return -1;}
diff --git a/source/gameengine/GameLogic/SCA_ISensor.cpp b/source/gameengine/GameLogic/SCA_ISensor.cpp
index 76b9a8df00f..7cf0b18c3b5 100644
--- a/source/gameengine/GameLogic/SCA_ISensor.cpp
+++ b/source/gameengine/GameLogic/SCA_ISensor.cpp
@@ -248,7 +248,7 @@ void SCA_ISensor::Activate(class SCA_LogicManager* logicmgr)
if (result) {
// the sensor triggered this frame
if (m_state || !m_tap) {
- ActivateControllers(logicmgr);
+ ActivateControllers(logicmgr);
// reset these counters so that pulse are synchronized with transition
m_pos_ticks = 0;
m_neg_ticks = 0;
@@ -380,7 +380,7 @@ PyAttributeDef SCA_ISensor::Attributes[] = {
};
-PyObject* SCA_ISensor::pyattr_get_triggered(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_ISensor::pyattr_get_triggered(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_ISensor* self= static_cast<SCA_ISensor*>(self_v);
int retval = 0;
@@ -389,13 +389,13 @@ PyObject* SCA_ISensor::pyattr_get_triggered(void *self_v, const KX_PYATTRIBUTE_D
return PyLong_FromSsize_t(retval);
}
-PyObject* SCA_ISensor::pyattr_get_positive(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_ISensor::pyattr_get_positive(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_ISensor* self= static_cast<SCA_ISensor*>(self_v);
return PyLong_FromSsize_t(self->GetState());
}
-PyObject* SCA_ISensor::pyattr_get_status(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_ISensor::pyattr_get_status(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_ISensor* self= static_cast<SCA_ISensor*>(self_v);
int status = 0;
@@ -417,13 +417,13 @@ PyObject* SCA_ISensor::pyattr_get_status(void *self_v, const KX_PYATTRIBUTE_DEF
return PyLong_FromSsize_t(status);
}
-PyObject* SCA_ISensor::pyattr_get_posTicks(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_ISensor::pyattr_get_posTicks(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_ISensor* self= static_cast<SCA_ISensor*>(self_v);
return PyLong_FromLong(self->GetPosTicks());
}
-PyObject* SCA_ISensor::pyattr_get_negTicks(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_ISensor::pyattr_get_negTicks(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_ISensor* self= static_cast<SCA_ISensor*>(self_v);
return PyLong_FromLong(self->GetNegTicks());
diff --git a/source/gameengine/GameLogic/SCA_JoystickSensor.cpp b/source/gameengine/GameLogic/SCA_JoystickSensor.cpp
index 2c6beb79fd3..7e9a4bc903c 100644
--- a/source/gameengine/GameLogic/SCA_JoystickSensor.cpp
+++ b/source/gameengine/GameLogic/SCA_JoystickSensor.cpp
@@ -60,7 +60,7 @@ SCA_JoystickSensor::SCA_JoystickSensor(class SCA_JoystickManager* eventmgr,
m_joymode(joymode),
m_joyindex(joyindex),
m_bAllEvents(allevents)
-{
+{
/*
std::cout << " axis " << m_axis << std::endl;
std::cout << " axis flag " << m_axisf << std::endl;
@@ -308,7 +308,7 @@ PyAttributeDef SCA_JoystickSensor::Attributes[] = {
const char SCA_JoystickSensor::GetButtonActiveList_doc[] =
"getButtonActiveList\n"
"\tReturns a list containing the indices of the button currently pressed.\n";
-PyObject* SCA_JoystickSensor::PyGetButtonActiveList( )
+PyObject *SCA_JoystickSensor::PyGetButtonActiveList( )
{
SCA_Joystick *joy = ((SCA_JoystickManager *)m_eventmgr)->GetJoystickDevice(m_joyindex);
PyObject *ls = PyList_New(0);
@@ -331,7 +331,7 @@ PyObject* SCA_JoystickSensor::PyGetButtonActiveList( )
const char SCA_JoystickSensor::GetButtonStatus_doc[] =
"getButtonStatus(buttonIndex)\n"
"\tReturns a bool of the current pressed state of the specified button.\n";
-PyObject* SCA_JoystickSensor::PyGetButtonStatus( PyObject* args )
+PyObject *SCA_JoystickSensor::PyGetButtonStatus( PyObject *args )
{
SCA_Joystick *joy = ((SCA_JoystickManager *)m_eventmgr)->GetJoystickDevice(m_joyindex);
int index;
@@ -345,7 +345,7 @@ PyObject* SCA_JoystickSensor::PyGetButtonStatus( PyObject* args )
return PyBool_FromLong(0);
}
-PyObject* SCA_JoystickSensor::pyattr_get_axis_values(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_axis_values(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
@@ -360,7 +360,7 @@ PyObject* SCA_JoystickSensor::pyattr_get_axis_values(void *self_v, const KX_PYAT
return list;
}
-PyObject* SCA_JoystickSensor::pyattr_get_axis_single(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_axis_single(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
@@ -373,7 +373,7 @@ PyObject* SCA_JoystickSensor::pyattr_get_axis_single(void *self_v, const KX_PYAT
return PyLong_FromSsize_t(joy->GetAxisPosition(self->m_axis-1));
}
-PyObject* SCA_JoystickSensor::pyattr_get_hat_values(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_hat_values(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
@@ -388,7 +388,7 @@ PyObject* SCA_JoystickSensor::pyattr_get_hat_values(void *self_v, const KX_PYATT
return list;
}
-PyObject* SCA_JoystickSensor::pyattr_get_hat_single(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_hat_single(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
@@ -396,28 +396,28 @@ PyObject* SCA_JoystickSensor::pyattr_get_hat_single(void *self_v, const KX_PYATT
return PyLong_FromSsize_t(joy->GetHat(self->m_hat-1));
}
-PyObject* SCA_JoystickSensor::pyattr_get_num_axis(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_num_axis(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
return PyLong_FromSsize_t( joy ? joy->GetNumberOfAxes() : 0 );
}
-PyObject* SCA_JoystickSensor::pyattr_get_num_buttons(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_num_buttons(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
return PyLong_FromSsize_t( joy ? joy->GetNumberOfButtons() : 0 );
}
-PyObject* SCA_JoystickSensor::pyattr_get_num_hats(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_num_hats(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
return PyLong_FromSsize_t( joy ? joy->GetNumberOfHats() : 0 );
}
-PyObject* SCA_JoystickSensor::pyattr_get_connected(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_JoystickSensor::pyattr_get_connected(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_JoystickSensor* self= static_cast<SCA_JoystickSensor*>(self_v);
SCA_Joystick *joy = ((SCA_JoystickManager *)self->m_eventmgr)->GetJoystickDevice(self->m_joyindex);
diff --git a/source/gameengine/GameLogic/SCA_KeyboardManager.h b/source/gameengine/GameLogic/SCA_KeyboardManager.h
index 2d9ad45833f..fd3c0706fa7 100644
--- a/source/gameengine/GameLogic/SCA_KeyboardManager.h
+++ b/source/gameengine/GameLogic/SCA_KeyboardManager.h
@@ -54,7 +54,7 @@ public:
bool IsPressed(SCA_IInputDevice::KX_EnumInputs inputcode);
- virtual void NextFrame();
+ virtual void NextFrame();
SCA_IInputDevice* GetInputDevice();
diff --git a/source/gameengine/GameLogic/SCA_KeyboardSensor.cpp b/source/gameengine/GameLogic/SCA_KeyboardSensor.cpp
index 5208252ceae..9a2dd9bdd57 100644
--- a/source/gameengine/GameLogic/SCA_KeyboardSensor.cpp
+++ b/source/gameengine/GameLogic/SCA_KeyboardSensor.cpp
@@ -351,12 +351,12 @@ void SCA_KeyboardSensor::AddToTargetProp(int keyIndex)
CStringValue * newstringprop = new CStringValue(newprop, m_targetprop);
GetParent()->SetProperty(m_targetprop, newstringprop);
newstringprop->Release();
- }
+ }
} else {
/* append */
char pchar = ToCharacter(keyIndex, IsShifted());
STR_String newprop = tprop->GetText() + pchar;
- CStringValue * newstringprop = new CStringValue(newprop, m_targetprop);
+ CStringValue * newstringprop = new CStringValue(newprop, m_targetprop);
GetParent()->SetProperty(m_targetprop, newstringprop);
newstringprop->Release();
}
@@ -365,7 +365,7 @@ void SCA_KeyboardSensor::AddToTargetProp(int keyIndex)
/* Make a new property. Deletes can be ignored. */
char pchar = ToCharacter(keyIndex, IsShifted());
STR_String newprop = pchar;
- CStringValue * newstringprop = new CStringValue(newprop, m_targetprop);
+ CStringValue * newstringprop = new CStringValue(newprop, m_targetprop);
GetParent()->SetProperty(m_targetprop, newstringprop);
newstringprop->Release();
}
@@ -376,7 +376,7 @@ void SCA_KeyboardSensor::AddToTargetProp(int keyIndex)
/**
* Tests whether shift is pressed
- */
+ */
bool SCA_KeyboardSensor::IsShifted(void)
{
SCA_IInputDevice* inputdev = ((SCA_KeyboardManager *)m_eventmgr)->GetInputDevice();
@@ -391,9 +391,10 @@ bool SCA_KeyboardSensor::IsShifted(void)
== SCA_InputEvent::KX_JUSTACTIVATED)
) {
return true;
- } else {
+ }
+ else {
return false;
- }
+ }
}
void SCA_KeyboardSensor::LogKeystrokes(void)
@@ -494,25 +495,25 @@ PyAttributeDef SCA_KeyboardSensor::Attributes[] = {
};
-PyObject* SCA_KeyboardSensor::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_KeyboardSensor::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_KeyboardSensor* self= static_cast<SCA_KeyboardSensor*>(self_v);
SCA_IInputDevice* inputdev = ((SCA_KeyboardManager *)self->m_eventmgr)->GetInputDevice();
- PyObject* resultlist = PyList_New(0);
+ PyObject *resultlist = PyList_New(0);
for (int i=SCA_IInputDevice::KX_BEGINKEY ; i<= SCA_IInputDevice::KX_ENDKEY;i++)
{
const SCA_InputEvent & inevent = inputdev->GetEventValue((SCA_IInputDevice::KX_EnumInputs) i);
if (inevent.m_status != SCA_InputEvent::KX_NO_INPUTSTATUS)
{
- PyObject* keypair = PyList_New(2);
+ PyObject *keypair = PyList_New(2);
PyList_SET_ITEM(keypair,0,PyLong_FromSsize_t(i));
PyList_SET_ITEM(keypair,1,PyLong_FromSsize_t(inevent.m_status));
PyList_Append(resultlist,keypair);
}
- }
+ }
return resultlist;
}
@@ -655,7 +656,7 @@ bool IsPrintable(int keyIndex)
/**
* Tests whether this is a delete key.
- */
+ */
bool IsDelete(int keyIndex)
{
if ( (keyIndex == SCA_IInputDevice::KX_DELKEY)
diff --git a/source/gameengine/GameLogic/SCA_KeyboardSensor.h b/source/gameengine/GameLogic/SCA_KeyboardSensor.h
index c059aba305b..caa141e48f2 100644
--- a/source/gameengine/GameLogic/SCA_KeyboardSensor.h
+++ b/source/gameengine/GameLogic/SCA_KeyboardSensor.h
@@ -134,7 +134,7 @@ bool IsPrintable(int keyIndex);
/**
* Tests whether this is a delete key.
- */
+ */
bool IsDelete(int keyIndex);
diff --git a/source/gameengine/GameLogic/SCA_MouseManager.h b/source/gameengine/GameLogic/SCA_MouseManager.h
index 60edb2816cb..02c28807566 100644
--- a/source/gameengine/GameLogic/SCA_MouseManager.h
+++ b/source/gameengine/GameLogic/SCA_MouseManager.h
@@ -63,7 +63,7 @@ public:
* mouse related events. Can also flag mouse movement.
*/
bool IsPressed(SCA_IInputDevice::KX_EnumInputs inputcode);
- virtual void NextFrame();
+ virtual void NextFrame();
SCA_IInputDevice* GetInputDevice();
diff --git a/source/gameengine/GameLogic/SCA_MouseSensor.cpp b/source/gameengine/GameLogic/SCA_MouseSensor.cpp
index f4ee54c56a6..51e0bc6550b 100644
--- a/source/gameengine/GameLogic/SCA_MouseSensor.cpp
+++ b/source/gameengine/GameLogic/SCA_MouseSensor.cpp
@@ -156,7 +156,7 @@ bool SCA_MouseSensor::Evaluate()
case KX_MOUSESENSORMODE_WHEELDOWN:
{
const SCA_InputEvent& mevent = mousedev->GetEventValue(m_hotkey);
- switch (mevent.m_status) {
+ switch (mevent.m_status) {
case SCA_InputEvent::KX_JUSTACTIVATED:
m_val = 1;
result = true;
@@ -189,15 +189,15 @@ bool SCA_MouseSensor::Evaluate()
const SCA_InputEvent& eventY = mousedev->GetEventValue(SCA_IInputDevice::KX_MOUSEY);
if (eventX.m_status == SCA_InputEvent::KX_JUSTACTIVATED ||
- eventY.m_status == SCA_InputEvent::KX_JUSTACTIVATED ||
- eventX.m_status == SCA_InputEvent::KX_ACTIVE ||
- eventY.m_status == SCA_InputEvent::KX_ACTIVE)
+ eventY.m_status == SCA_InputEvent::KX_JUSTACTIVATED ||
+ eventX.m_status == SCA_InputEvent::KX_ACTIVE ||
+ eventY.m_status == SCA_InputEvent::KX_ACTIVE)
{
m_val = 1;
result = true;
}
else if (eventX.m_status == SCA_InputEvent::KX_JUSTRELEASED ||
- eventY.m_status == SCA_InputEvent::KX_JUSTRELEASED )
+ eventY.m_status == SCA_InputEvent::KX_JUSTRELEASED )
{
m_val = 0;
result = true;
diff --git a/source/gameengine/GameLogic/SCA_PropertyActuator.cpp b/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
index 31f988fe4b9..0eab6187d07 100644
--- a/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
+++ b/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
@@ -173,7 +173,7 @@ isValid(
SCA_PropertyActuator::KX_ACT_PROP_MODE mode
) {
- bool res = false;
+ bool res = false;
res = ((mode > KX_ACT_PROP_NODEF) && (mode < KX_ACT_PROP_MAX));
return res;
}
diff --git a/source/gameengine/GameLogic/SCA_PythonController.cpp b/source/gameengine/GameLogic/SCA_PythonController.cpp
index ab7f57a5454..7dbbbb2a0d9 100644
--- a/source/gameengine/GameLogic/SCA_PythonController.cpp
+++ b/source/gameengine/GameLogic/SCA_PythonController.cpp
@@ -179,7 +179,7 @@ int SCA_PythonController::IsTriggered(class SCA_ISensor* sensor)
#ifdef WITH_PYTHON
/* warning, self is not the SCA_PythonController, its a PyObjectPlus_Proxy */
-PyObject* SCA_PythonController::sPyGetCurrentController(PyObject *self)
+PyObject *SCA_PythonController::sPyGetCurrentController(PyObject *self)
{
if (m_sCurrentController==NULL)
{
@@ -271,7 +271,7 @@ void SCA_PythonController::ErrorPrint(const char *error_msg)
}
bool SCA_PythonController::Compile()
-{
+{
//printf("py script modified '%s'\n", m_scriptName.Ptr());
m_bModified= false;
@@ -374,7 +374,7 @@ void SCA_PythonController::Trigger(SCA_LogicManager* logicmgr)
m_sCurrentLogicManager = logicmgr;
PyObject *excdict= NULL;
- PyObject* resultobj= NULL;
+ PyObject *resultobj= NULL;
switch(m_mode) {
case SCA_PYEXEC_SCRIPT:
@@ -447,13 +447,13 @@ void SCA_PythonController::Trigger(SCA_LogicManager* logicmgr)
// This doesn't appear to be needed anymore
//PyDict_Clear(excdict);
Py_DECREF(excdict);
- }
+ }
m_triggeredSensors.clear();
m_sCurrentController = NULL;
}
-PyObject* SCA_PythonController::PyActivate(PyObject *value)
+PyObject *SCA_PythonController::PyActivate(PyObject *value)
{
if (m_sCurrentController != this) {
PyErr_SetString(PyExc_SystemError, "Cannot add an actuator from a non-active controller");
@@ -468,7 +468,7 @@ PyObject* SCA_PythonController::PyActivate(PyObject *value)
Py_RETURN_NONE;
}
-PyObject* SCA_PythonController::PyDeActivate(PyObject *value)
+PyObject *SCA_PythonController::PyDeActivate(PyObject *value)
{
if (m_sCurrentController != this) {
PyErr_SetString(PyExc_SystemError, "Cannot add an actuator from a non-active controller");
@@ -483,7 +483,7 @@ PyObject* SCA_PythonController::PyDeActivate(PyObject *value)
Py_RETURN_NONE;
}
-PyObject* SCA_PythonController::pyattr_get_script(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonController::pyattr_get_script(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
//SCA_PythonController* self= static_cast<SCA_PythonController*>(static_cast<SCA_IController*>(static_cast<SCA_ILogicBrick*>(static_cast<CValue*>(static_cast<PyObjectPlus*>(self_v)))));
// static_cast<void *>(dynamic_cast<Derived *>(obj)) - static_cast<void *>(obj)
diff --git a/source/gameengine/GameLogic/SCA_PythonController.h b/source/gameengine/GameLogic/SCA_PythonController.h
index ccdb82aa722..8a72ce6bad9 100644
--- a/source/gameengine/GameLogic/SCA_PythonController.h
+++ b/source/gameengine/GameLogic/SCA_PythonController.h
@@ -74,7 +74,7 @@ class SCA_PythonController : public SCA_IController
//for debugging
//virtual CValue* AddRef();
- //virtual int Release(); // Release a reference to this value (when reference count reaches 0, the value is removed from the heap)
+ //virtual int Release(); // Release a reference to this value (when reference count reaches 0, the value is removed from the heap)
SCA_PythonController(SCA_IObject* gameobj, int mode);
virtual ~SCA_PythonController();
@@ -96,11 +96,11 @@ class SCA_PythonController : public SCA_IController
void ErrorPrint(const char *error_msg);
#ifdef WITH_PYTHON
- static const char* sPyGetCurrentController__doc__;
- static PyObject* sPyGetCurrentController(PyObject* self);
- static const char* sPyAddActiveActuator__doc__;
- static PyObject* sPyAddActiveActuator(PyObject* self,
- PyObject* args);
+ static const char *sPyGetCurrentController__doc__;
+ static PyObject *sPyGetCurrentController(PyObject *self);
+ static const char *sPyAddActiveActuator__doc__;
+ static PyObject *sPyAddActiveActuator(PyObject *self,
+ PyObject *args);
static SCA_IActuator* LinkedActuatorFromPy(PyObject *value);
diff --git a/source/gameengine/GameLogic/SCA_PythonKeyboard.cpp b/source/gameengine/GameLogic/SCA_PythonKeyboard.cpp
index f83b23f510c..42cda9433b8 100644
--- a/source/gameengine/GameLogic/SCA_PythonKeyboard.cpp
+++ b/source/gameengine/GameLogic/SCA_PythonKeyboard.cpp
@@ -58,13 +58,13 @@ SCA_PythonKeyboard::~SCA_PythonKeyboard()
/* ------------------------------------------------------------------------- */
/* clipboard */
-static PyObject* gPyGetClipboard(PyObject* args, PyObject* kwds)
+static PyObject *gPyGetClipboard(PyObject *args, PyObject *kwds)
{
char *buf = (char *)GHOST_getClipboard(0);
return PyUnicode_FromString(buf?buf:"");
}
-static PyObject* gPySetClipboard(PyObject* args, PyObject* value)
+static PyObject *gPySetClipboard(PyObject *args, PyObject *value)
{
char* buf;
if (!PyArg_ParseTuple(value,"s:setClipboard",&buf))
@@ -109,7 +109,7 @@ PyAttributeDef SCA_PythonKeyboard::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* SCA_PythonKeyboard::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonKeyboard::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_PythonKeyboard* self = static_cast<SCA_PythonKeyboard*>(self_v);
@@ -123,7 +123,7 @@ PyObject* SCA_PythonKeyboard::pyattr_get_events(void *self_v, const KX_PYATTRIBU
return self->m_event_dict;
}
-PyObject* SCA_PythonKeyboard::pyattr_get_active_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonKeyboard::pyattr_get_active_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_PythonKeyboard* self = static_cast<SCA_PythonKeyboard*>(self_v);
diff --git a/source/gameengine/GameLogic/SCA_PythonKeyboard.h b/source/gameengine/GameLogic/SCA_PythonKeyboard.h
index df5e46f8c28..aab49bcb83b 100644
--- a/source/gameengine/GameLogic/SCA_PythonKeyboard.h
+++ b/source/gameengine/GameLogic/SCA_PythonKeyboard.h
@@ -35,7 +35,7 @@ class SCA_PythonKeyboard : public PyObjectPlus
private:
class SCA_IInputDevice *m_keyboard;
#ifdef WITH_PYTHON
- PyObject* m_event_dict;
+ PyObject *m_event_dict;
#endif
public:
SCA_PythonKeyboard(class SCA_IInputDevice* keyboard);
diff --git a/source/gameengine/GameLogic/SCA_PythonMouse.cpp b/source/gameengine/GameLogic/SCA_PythonMouse.cpp
index cdbeaba2235..0806bda072b 100644
--- a/source/gameengine/GameLogic/SCA_PythonMouse.cpp
+++ b/source/gameengine/GameLogic/SCA_PythonMouse.cpp
@@ -90,9 +90,9 @@ PyAttributeDef SCA_PythonMouse::Attributes[] = {
KX_PYATTRIBUTE_RW_FUNCTION("position", SCA_PythonMouse, pyattr_get_position, pyattr_set_position),
KX_PYATTRIBUTE_RW_FUNCTION("visible", SCA_PythonMouse, pyattr_get_visible, pyattr_set_visible),
{ NULL } //Sentinel
-};
+};
-PyObject* SCA_PythonMouse::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonMouse::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_PythonMouse* self = static_cast<SCA_PythonMouse*>(self_v);
@@ -106,7 +106,7 @@ PyObject* SCA_PythonMouse::pyattr_get_events(void *self_v, const KX_PYATTRIBUTE_
return self->m_event_dict;
}
-PyObject* SCA_PythonMouse::pyattr_get_active_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonMouse::pyattr_get_active_events(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_PythonMouse* self = static_cast<SCA_PythonMouse*>(self_v);
@@ -123,7 +123,7 @@ PyObject* SCA_PythonMouse::pyattr_get_active_events(void *self_v, const KX_PYATT
return self->m_event_dict;
}
-PyObject* SCA_PythonMouse::pyattr_get_position(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonMouse::pyattr_get_position(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_PythonMouse* self = static_cast<SCA_PythonMouse*>(self_v);
const SCA_InputEvent & xevent = self->m_mouse->GetEventValue(SCA_IInputDevice::KX_MOUSEX);
@@ -134,7 +134,7 @@ PyObject* SCA_PythonMouse::pyattr_get_position(void *self_v, const KX_PYATTRIBUT
x_coord = self->m_canvas->GetMouseNormalizedX(xevent.m_eventval);
y_coord = self->m_canvas->GetMouseNormalizedY(yevent.m_eventval);
- PyObject* ret = PyTuple_New(2);
+ PyObject *ret = PyTuple_New(2);
PyTuple_SET_ITEM(ret, 0, PyFloat_FromDouble(x_coord));
PyTuple_SET_ITEM(ret, 1, PyFloat_FromDouble(y_coord));
@@ -158,7 +158,7 @@ int SCA_PythonMouse::pyattr_set_position(void *self_v, const KX_PYATTRIBUTE_DEF
return PY_SET_ATTR_SUCCESS;
}
-PyObject* SCA_PythonMouse::pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_PythonMouse::pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_PythonMouse* self = static_cast<SCA_PythonMouse*>(self_v);
diff --git a/source/gameengine/GameLogic/SCA_PythonMouse.h b/source/gameengine/GameLogic/SCA_PythonMouse.h
index 1313d55005f..f770a54d6e6 100644
--- a/source/gameengine/GameLogic/SCA_PythonMouse.h
+++ b/source/gameengine/GameLogic/SCA_PythonMouse.h
@@ -36,7 +36,7 @@ private:
class SCA_IInputDevice *m_mouse;
class RAS_ICanvas *m_canvas;
#ifdef WITH_PYTHON
- PyObject* m_event_dict;
+ PyObject *m_event_dict;
#endif
public:
SCA_PythonMouse(class SCA_IInputDevice* mouse, class RAS_ICanvas* canvas);
@@ -47,12 +47,12 @@ public:
#ifdef WITH_PYTHON
KX_PYMETHOD_DOC(SCA_PythonMouse, show);
- static PyObject* pyattr_get_events(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_active_events(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_position(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_position(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject* value);
- static PyObject* pyattr_get_visible(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_visible(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject* value);
+ static PyObject *pyattr_get_events(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_active_events(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_position(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static int pyattr_set_position(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
+ static PyObject *pyattr_get_visible(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static int pyattr_set_visible(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif
};
diff --git a/source/gameengine/GameLogic/SCA_RandomActuator.cpp b/source/gameengine/GameLogic/SCA_RandomActuator.cpp
index c727eebd015..9a54c76ed4e 100644
--- a/source/gameengine/GameLogic/SCA_RandomActuator.cpp
+++ b/source/gameengine/GameLogic/SCA_RandomActuator.cpp
@@ -161,7 +161,7 @@ bool SCA_RandomActuator::Update()
while (b >= a) {
b = b * m_base->DrawFloat();
res++;
- };
+ };
tmpval = new CIntValue(res);
}
break;
@@ -361,9 +361,9 @@ PyAttributeDef SCA_RandomActuator::Attributes[] = {
KX_PYATTRIBUTE_STRING_RW_CHECK("propName",0,MAX_PROP_NAME,false,SCA_RandomActuator,m_propname,CheckProperty),
KX_PYATTRIBUTE_RW_FUNCTION("seed",SCA_RandomActuator,pyattr_get_seed,pyattr_set_seed),
{ NULL } //Sentinel
-};
+};
-PyObject* SCA_RandomActuator::pyattr_get_seed(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_RandomActuator::pyattr_get_seed(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_RandomActuator* act = static_cast<SCA_RandomActuator*>(self);
return PyLong_FromSsize_t(act->m_base->GetSeed());
@@ -420,7 +420,7 @@ KX_PYMETHODDEF_DOC_VARARGS(SCA_RandomActuator, setBoolBernouilli,
}
m_distribution = KX_RANDOMACT_BOOL_BERNOUILLI;
- m_parameter1 = paraArg;
+ m_parameter1 = paraArg;
enforceConstraints();
Py_RETURN_NONE;
}
@@ -473,7 +473,7 @@ KX_PYMETHODDEF_DOC_VARARGS(SCA_RandomActuator, setIntPoisson,
}
m_distribution = KX_RANDOMACT_INT_POISSON;
- m_parameter1 = paraArg;
+ m_parameter1 = paraArg;
enforceConstraints();
Py_RETURN_NONE;
}
@@ -489,7 +489,7 @@ KX_PYMETHODDEF_DOC_VARARGS(SCA_RandomActuator, setFloatConst,
}
m_distribution = KX_RANDOMACT_FLOAT_CONST;
- m_parameter1 = paraArg;
+ m_parameter1 = paraArg;
enforceConstraints();
Py_RETURN_NONE;
}
@@ -544,7 +544,7 @@ KX_PYMETHODDEF_DOC_VARARGS(SCA_RandomActuator, setFloatNegativeExponential,
}
m_distribution = KX_RANDOMACT_FLOAT_NEGATIVE_EXPONENTIAL;
- m_parameter1 = paraArg;
+ m_parameter1 = paraArg;
enforceConstraints();
Py_RETURN_NONE;
}
diff --git a/source/gameengine/GameLogic/SCA_RandomActuator.h b/source/gameengine/GameLogic/SCA_RandomActuator.h
index 522663651e0..f61de24c0cc 100644
--- a/source/gameengine/GameLogic/SCA_RandomActuator.h
+++ b/source/gameengine/GameLogic/SCA_RandomActuator.h
@@ -67,10 +67,10 @@ class SCA_RandomActuator : public SCA_IActuator
KX_RANDOMACT_NODEF,
KX_RANDOMACT_BOOL_CONST,
KX_RANDOMACT_BOOL_UNIFORM,
- KX_RANDOMACT_BOOL_BERNOUILLI,
+ KX_RANDOMACT_BOOL_BERNOUILLI,
KX_RANDOMACT_INT_CONST,
KX_RANDOMACT_INT_UNIFORM,
- KX_RANDOMACT_INT_POISSON,
+ KX_RANDOMACT_INT_POISSON,
KX_RANDOMACT_FLOAT_CONST,
KX_RANDOMACT_FLOAT_UNIFORM,
KX_RANDOMACT_FLOAT_NORMAL,
@@ -98,7 +98,7 @@ class SCA_RandomActuator : public SCA_IActuator
/* Python interface ---------------------------------------------------- */
/* --------------------------------------------------------------------- */
- static PyObject* pyattr_get_seed(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_seed(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_seed(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
KX_PYMETHOD_DOC_VARARGS(SCA_RandomActuator, setBoolConst);
diff --git a/source/gameengine/GameLogic/SCA_RandomSensor.cpp b/source/gameengine/GameLogic/SCA_RandomSensor.cpp
index 3b37507dcf3..17784755421 100644
--- a/source/gameengine/GameLogic/SCA_RandomSensor.cpp
+++ b/source/gameengine/GameLogic/SCA_RandomSensor.cpp
@@ -165,7 +165,7 @@ PyAttributeDef SCA_RandomSensor::Attributes[] = {
{NULL} //Sentinel
};
-PyObject* SCA_RandomSensor::pyattr_get_seed(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *SCA_RandomSensor::pyattr_get_seed(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
SCA_RandomSensor* self= static_cast<SCA_RandomSensor*>(self_v);
return PyLong_FromSsize_t(self->m_basegenerator->GetSeed());
diff --git a/source/gameengine/GameLogic/SCA_TimeEventManager.cpp b/source/gameengine/GameLogic/SCA_TimeEventManager.cpp
index e28f00abba2..e8a6289a98e 100644
--- a/source/gameengine/GameLogic/SCA_TimeEventManager.cpp
+++ b/source/gameengine/GameLogic/SCA_TimeEventManager.cpp
@@ -54,7 +54,7 @@ SCA_TimeEventManager::~SCA_TimeEventManager()
!(it == m_timevalues.end()); ++it)
{
(*it)->Release();
- }
+ }
}
diff --git a/source/gameengine/GamePlayer/common/GPC_Canvas.cpp b/source/gameengine/GamePlayer/common/GPC_Canvas.cpp
index f4224b9e255..7581484a41f 100644
--- a/source/gameengine/GamePlayer/common/GPC_Canvas.cpp
+++ b/source/gameengine/GamePlayer/common/GPC_Canvas.cpp
@@ -99,7 +99,7 @@ void GPC_Canvas::Resize(int width, int height)
void GPC_Canvas::EndFrame()
{
if (m_bannersEnabled)
- DrawAllBanners();
+ DrawAllBanners();
}
diff --git a/source/gameengine/GamePlayer/common/GPC_Canvas.h b/source/gameengine/GamePlayer/common/GPC_Canvas.h
index 25a50fbcac3..453b9505183 100644
--- a/source/gameengine/GamePlayer/common/GPC_Canvas.h
+++ b/source/gameengine/GamePlayer/common/GPC_Canvas.h
@@ -163,7 +163,7 @@ public:
void SetMouseState(RAS_MouseState mousestate)
{
- // not yet
+ // not yet
}
void SetMousePosition(int x, int y)
@@ -250,7 +250,7 @@ protected:
int oldWriteMask;
};
- void
+ void
PushRenderState(
CanvasRenderState & render_state
);
diff --git a/source/gameengine/GamePlayer/common/GPC_MouseDevice.cpp b/source/gameengine/GamePlayer/common/GPC_MouseDevice.cpp
index a38bba7788b..e38a9e3d6cb 100644
--- a/source/gameengine/GamePlayer/common/GPC_MouseDevice.cpp
+++ b/source/gameengine/GamePlayer/common/GPC_MouseDevice.cpp
@@ -67,7 +67,8 @@ void GPC_MouseDevice::NextFrame()
for (int mouseevent= KX_BEGINMOUSE; mouseevent< KX_ENDMOUSEBUTTONS; mouseevent++) {
SCA_InputEvent& oldevent = m_eventStatusTables[previousTable][mouseevent];
if (oldevent.m_status == SCA_InputEvent::KX_JUSTACTIVATED ||
- oldevent.m_status == SCA_InputEvent::KX_ACTIVE) {
+ oldevent.m_status == SCA_InputEvent::KX_ACTIVE)
+ {
m_eventStatusTables[m_currentTable][mouseevent] = oldevent;
m_eventStatusTables[m_currentTable][mouseevent].m_status = SCA_InputEvent::KX_ACTIVE;
}
@@ -76,7 +77,8 @@ void GPC_MouseDevice::NextFrame()
SCA_InputEvent& oldevent = m_eventStatusTables[previousTable][mousemove];
m_eventStatusTables[m_currentTable][mousemove] = oldevent;
if (oldevent.m_status == SCA_InputEvent::KX_JUSTACTIVATED ||
- oldevent.m_status == SCA_InputEvent::KX_ACTIVE) {
+ oldevent.m_status == SCA_InputEvent::KX_ACTIVE)
+ {
m_eventStatusTables[m_currentTable][mousemove].m_status = SCA_InputEvent::KX_JUSTRELEASED;
}
else {
diff --git a/source/gameengine/GamePlayer/common/GPC_RawImage.cpp b/source/gameengine/GamePlayer/common/GPC_RawImage.cpp
index 9f129c1cdfb..c0d66541800 100644
--- a/source/gameengine/GamePlayer/common/GPC_RawImage.cpp
+++ b/source/gameengine/GamePlayer/common/GPC_RawImage.cpp
@@ -89,7 +89,7 @@ bool GPC_RawImage::Load(
// Put original in upper left corner
// Add vertical offset
- dst += offsetY * dstBytesWidth;
+ dst += offsetY * dstBytesWidth;
// Add horizontal offset
dst += offsetX * 4;
for (int row = 0; row < numRows; row++)
diff --git a/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp b/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
index 749e7748e19..9cd6715f3d2 100644
--- a/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
+++ b/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp
@@ -442,7 +442,7 @@ void GPC_RenderTools::PopMatrix()
int GPC_RenderTools::applyLights(int objectlayer, const MT_Transform& viewmat)
{
- // taken from blender source, incompatibility between Blender Object / GameObject
+ // taken from blender source, incompatibility between Blender Object / GameObject
KX_Scene* kxscene = (KX_Scene*)m_auxilaryClientInfo;
float glviewmat[16];
unsigned int count;
diff --git a/source/gameengine/GamePlayer/common/bmfont.cpp b/source/gameengine/GamePlayer/common/bmfont.cpp
index 4c1c6ae5604..6f40d13fe7a 100644
--- a/source/gameengine/GamePlayer/common/bmfont.cpp
+++ b/source/gameengine/GamePlayer/common/bmfont.cpp
@@ -110,7 +110,7 @@ void readBitmapFontVersion0(ImBuf * ibuf, unsigned char * rect, int step)
buffer = (unsigned char*)MEM_mallocN(bytes, "readBitmapFontVersion0:buffer");
- index = 0;
+ index = 0;
for (i = 0; i < bytes; i++) {
buffer[i] = rect[index];
index += step;
diff --git a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
index 21de7011eda..40b52c3212a 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
@@ -479,7 +479,7 @@ bool GPG_Application::processEvent(GHOST_IEvent* event)
// // first check if we want to exit
// m_exitRequested = m_ketsjiengine->GetExitCode();
- //
+ //
// // kick the engine
// bool renderFrame = m_ketsjiengine->NextFrame();
// if (renderFrame)
@@ -546,7 +546,7 @@ bool GPG_Application::initEngine(GHOST_IWindow* window, const int stereoMode)
return false;
// SYS_WriteCommandLineInt(syshandle, "fixedtime", 0);
- // SYS_WriteCommandLineInt(syshandle, "vertexarrays",1);
+ // SYS_WriteCommandLineInt(syshandle, "vertexarrays",1);
GameData *gm= &m_startScene->gm;
bool properties = (SYS_GetCommandLineInt(syshandle, "show_properties", 0) != 0);
bool profile = (SYS_GetCommandLineInt(syshandle, "show_profile", 0) != 0);
@@ -576,7 +576,7 @@ bool GPG_Application::initEngine(GHOST_IWindow* window, const int stereoMode)
m_canvas->Init();
if (gm->flag & GAME_SHOW_MOUSE)
- m_canvas->SetMouseState(RAS_ICanvas::MOUSE_NORMAL);
+ m_canvas->SetMouseState(RAS_ICanvas::MOUSE_NORMAL);
m_rendertools = new GPC_RenderTools();
if (!m_rendertools)
@@ -681,7 +681,7 @@ bool GPG_Application::startEngine(void)
// Temporary hack to disable banner display for NaN approved content.
/*
- m_canvas->SetBannerDisplayEnabled(true);
+ m_canvas->SetBannerDisplayEnabled(true);
Camera* cam;
cam = (Camera*)scene->camera->data;
if (cam) {
@@ -730,7 +730,7 @@ bool GPG_Application::startEngine(void)
// Set the GameLogic.globalDict from marshal'd data, so we can
// load new blend files and keep data in GameLogic.globalDict
loadGamePythonConfig(m_pyGlobalDictString, m_pyGlobalDictString_Length);
-#endif
+#endif
m_sceneconverter->ConvertScene(
startscene,
m_rendertools,
diff --git a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
index d8b07fd50d9..7500a55a059 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
@@ -57,10 +57,10 @@ extern "C"
{
#endif // __cplusplus
#include "MEM_guardedalloc.h"
-#include "BKE_blender.h"
-#include "BKE_global.h"
-#include "BKE_icons.h"
-#include "BKE_node.h"
+#include "BKE_blender.h"
+#include "BKE_global.h"
+#include "BKE_icons.h"
+#include "BKE_node.h"
#include "BKE_report.h"
#include "BKE_library.h"
#include "BLI_threads.h"
@@ -223,7 +223,7 @@ void usage(const char* program, bool isBlenderPlayer)
printf(" --Optional parameters--\n");
printf(" angle = field of view in degrees\n");
printf(" tilt = tilt angle in degrees\n");
- printf(" warpdata = a file to use for warping the image (absolute path)\n");
+ printf(" warpdata = a file to use for warping the image (absolute path)\n");
printf(" mode: fisheye (Fisheye)\n");
printf(" truncatedfront (Front-Truncated)\n");
printf(" truncatedrear (Rear-Truncated)\n");
@@ -1016,12 +1016,12 @@ int main(int argc, char** argv)
gpg_nextframestate.app = &app;
gpg_nextframestate.gs = &gs;
pynextframestate.state = &gpg_nextframestate;
- pynextframestate.func = &GPG_PyNextFrame;
+ pynextframestate.func = &GPG_PyNextFrame;
printf("Yielding control to Python script '%s'...\n", python_main);
PyRun_SimpleString(python_code);
printf("Exit Python script '%s'\n", python_main);
-#endif // WITH_PYTHON
+#endif // WITH_PYTHON
MEM_freeN(python_code);
}
else {
diff --git a/source/gameengine/Ketsji/BL_Shader.cpp b/source/gameengine/Ketsji/BL_Shader.cpp
index c0fca88c426..e0ad1539b4a 100644
--- a/source/gameengine/Ketsji/BL_Shader.cpp
+++ b/source/gameengine/Ketsji/BL_Shader.cpp
@@ -431,7 +431,7 @@ void BL_Shader::SetProg(bool enable)
glUseProgramObjectARB(mShader);
}
else {
- glUseProgramObjectARB(0);
+ glUseProgramObjectARB(0);
}
}
}
@@ -613,7 +613,7 @@ void BL_Shader::SetUniform(int uniform, const MT_Tuple3& vec)
GLEW_ARB_vertex_shader &&
GLEW_ARB_shader_objects
)
- {
+ {
float value[3];
vec.getValue(value);
glUniform3fvARB(uniform, 1, value);
@@ -931,7 +931,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniform1f, "setUniform1f(name, fx)" )
{
#ifdef SORT_UNIFORMS
SetUniformfv(loc, BL_Uniform::UNI_FLOAT, &value, sizeof(float));
-#else
+#else
SetUniform( loc, (float)value );
#endif
}
@@ -1142,7 +1142,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniformfv, "setUniformfv( float (list2 or list
#ifdef SORT_UNIFORMS
SetUniformfv(loc, BL_Uniform::UNI_FLOAT2, array2, sizeof(float)*2);
#else
- SetUniform(loc, array2, 2);
+ SetUniform(loc, array2, 2);
#endif
Py_RETURN_NONE;
} break;
@@ -1152,7 +1152,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniformfv, "setUniformfv( float (list2 or list
#ifdef SORT_UNIFORMS
SetUniformfv(loc, BL_Uniform::UNI_FLOAT3, array3, sizeof(float)*3);
#else
- SetUniform(loc, array3, 3);
+ SetUniform(loc, array3, 3);
#endif
Py_RETURN_NONE;
}break;
@@ -1162,7 +1162,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniformfv, "setUniformfv( float (list2 or list
#ifdef SORT_UNIFORMS
SetUniformfv(loc, BL_Uniform::UNI_FLOAT4, array4, sizeof(float)*4);
#else
- SetUniform(loc, array4, 4);
+ SetUniform(loc, array4, 4);
#endif
Py_RETURN_NONE;
}break;
@@ -1226,7 +1226,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniformiv, "setUniformiv( uniform_name, (list2
#ifdef SORT_UNIFORMS
SetUniformiv(loc, BL_Uniform::UNI_INT2, array2, sizeof(int)*2);
#else
- SetUniform(loc, array2, 2);
+ SetUniform(loc, array2, 2);
#endif
Py_RETURN_NONE;
} break;
@@ -1237,7 +1237,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniformiv, "setUniformiv( uniform_name, (list2
SetUniformiv(loc, BL_Uniform::UNI_INT3, array3, sizeof(int)*3);
#else
- SetUniform(loc, array3, 3);
+ SetUniform(loc, array3, 3);
#endif
Py_RETURN_NONE;
}break;
@@ -1248,7 +1248,7 @@ KX_PYMETHODDEF_DOC( BL_Shader, setUniformiv, "setUniformiv( uniform_name, (list2
SetUniformiv(loc, BL_Uniform::UNI_INT4, array4, sizeof(int)*4);
#else
- SetUniform(loc, array4, 4);
+ SetUniform(loc, array4, 4);
#endif
Py_RETURN_NONE;
}break;
diff --git a/source/gameengine/Ketsji/BL_Shader.h b/source/gameengine/Ketsji/BL_Shader.h
index 2bb094f12ee..b577a1849a0 100644
--- a/source/gameengine/Ketsji/BL_Shader.h
+++ b/source/gameengine/Ketsji/BL_Shader.h
@@ -222,7 +222,7 @@ public:
// Python interface
#ifdef WITH_PYTHON
- virtual PyObject* py_repr(void) { return PyUnicode_FromFormat("BL_Shader\n\tvertex shader:%s\n\n\tfragment shader%s\n\n", vertProg, fragProg); }
+ virtual PyObject *py_repr(void) { return PyUnicode_FromFormat("BL_Shader\n\tvertex shader:%s\n\n\tfragment shader%s\n\n", vertProg, fragProg); }
// -----------------------------------
KX_PYMETHOD_DOC(BL_Shader, setSource);
diff --git a/source/gameengine/Ketsji/BL_Texture.cpp b/source/gameengine/Ketsji/BL_Texture.cpp
index b8cc4ebeff9..7196c1ec664 100644
--- a/source/gameengine/Ketsji/BL_Texture.cpp
+++ b/source/gameengine/Ketsji/BL_Texture.cpp
@@ -47,7 +47,7 @@ static int power_of_2_min_i(int num)
{
while (!is_power_of_2_i(num))
num= num&(num-1);
- return num;
+ return num;
}
// Place holder for a full texture manager
@@ -427,7 +427,7 @@ void BL_Texture::DisableAllTextures()
glMatrixMode(GL_TEXTURE);
glLoadIdentity();
glMatrixMode(GL_MODELVIEW);
- glDisable(GL_TEXTURE_2D);
+ glDisable(GL_TEXTURE_2D);
glDisable(GL_TEXTURE_GEN_S);
glDisable(GL_TEXTURE_GEN_T);
glDisable(GL_TEXTURE_GEN_R);
@@ -447,14 +447,14 @@ void BL_Texture::ActivateTexture()
if (mType == GL_TEXTURE_CUBE_MAP_ARB && GLEW_ARB_texture_cube_map)
{
- glBindTexture( GL_TEXTURE_CUBE_MAP_ARB, mTexture );
+ glBindTexture( GL_TEXTURE_CUBE_MAP_ARB, mTexture );
glEnable(GL_TEXTURE_CUBE_MAP_ARB);
}
else {
if (GLEW_ARB_texture_cube_map )
glDisable(GL_TEXTURE_CUBE_MAP_ARB);
- glBindTexture( GL_TEXTURE_2D, mTexture );
+ glBindTexture( GL_TEXTURE_2D, mTexture );
glEnable(GL_TEXTURE_2D);
}
}
@@ -659,7 +659,7 @@ void my_envmap_split_ima(EnvMap *env, ImBuf *ibuf)
{
int dx, part;
- my_free_envmapdata(env);
+ my_free_envmapdata(env);
dx= ibuf->y;
dx/= 2;
diff --git a/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.cpp b/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.cpp
index a69f02baa57..6260596159d 100644
--- a/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.cpp
+++ b/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.cpp
@@ -38,7 +38,7 @@
#include "NG_NetworkMessage.h"
#include "NG_NetworkScene.h"
#include "NG_NetworkObject.h"
-#include "SCA_IObject.h"
+#include "SCA_IObject.h"
#include "InputParser.h"
#include "ListValue.h"
#include "StringValue.h"
@@ -201,7 +201,7 @@ PyAttributeDef KX_NetworkMessageSensor::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_NetworkMessageSensor::pyattr_get_bodies(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_NetworkMessageSensor::pyattr_get_bodies(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_NetworkMessageSensor *self = static_cast<KX_NetworkMessageSensor*>(self_v);
if (self->m_BodyList) {
@@ -211,7 +211,7 @@ PyObject* KX_NetworkMessageSensor::pyattr_get_bodies(void *self_v, const KX_PYAT
}
}
-PyObject* KX_NetworkMessageSensor::pyattr_get_subjects(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_NetworkMessageSensor::pyattr_get_subjects(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_NetworkMessageSensor *self = static_cast<KX_NetworkMessageSensor*>(self_v);
if (self->m_SubjectList) {
diff --git a/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.h b/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.h
index 66f723d072c..6b9779de6e3 100644
--- a/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.h
+++ b/source/gameengine/Ketsji/KXNetwork/KX_NetworkMessageSensor.h
@@ -80,7 +80,7 @@ public:
/* ------------------------------------------------------------- */
/* attributes */
- static PyObject* pyattr_get_bodies(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject* pyattr_get_bodies(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static PyObject* pyattr_get_subjects(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_ArmatureSensor.cpp b/source/gameengine/Ketsji/KX_ArmatureSensor.cpp
index f72d9c1dee6..523f3ceeaea 100644
--- a/source/gameengine/Ketsji/KX_ArmatureSensor.cpp
+++ b/source/gameengine/Ketsji/KX_ArmatureSensor.cpp
@@ -86,7 +86,7 @@ void KX_ArmatureSensor::FindConstraint()
/* this constraint is not valid, can't use it */
break;
m_constraint = pcon;
- break;
+ break;
}
}
break;
@@ -193,13 +193,13 @@ PyAttributeDef KX_ArmatureSensor::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_ArmatureSensor::pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ArmatureSensor::pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ArmatureSensor* sensor = static_cast<KX_ArmatureSensor*>(self);
if (sensor->m_gameobj->GetGameObjectType() == SCA_IObject::OBJ_ARMATURE) {
BL_ArmatureObject* armobj = (BL_ArmatureObject*)sensor->m_gameobj;
BL_ArmatureConstraint* constraint = armobj->GetConstraint(sensor->m_posechannel, sensor->m_constraintname);
- if (constraint)
+ if (constraint)
return constraint->GetProxy();
}
Py_RETURN_NONE;
diff --git a/source/gameengine/Ketsji/KX_ArmatureSensor.h b/source/gameengine/Ketsji/KX_ArmatureSensor.h
index 9c3faa355a6..74603b3ff01 100644
--- a/source/gameengine/Ketsji/KX_ArmatureSensor.h
+++ b/source/gameengine/Ketsji/KX_ArmatureSensor.h
@@ -72,7 +72,7 @@ public:
/* --------------------------------------------------------------------- */
/* Python interface ---------------------------------------------------- */
/* --------------------------------------------------------------------- */
- static PyObject* pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_constraint(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_BlenderMaterial.cpp b/source/gameengine/Ketsji/KX_BlenderMaterial.cpp
index b602ba447ad..2337e9569f3 100644
--- a/source/gameengine/Ketsji/KX_BlenderMaterial.cpp
+++ b/source/gameengine/Ketsji/KX_BlenderMaterial.cpp
@@ -412,7 +412,7 @@ KX_BlenderMaterial::ActivatShaders(
if ((mMaterial->ras_mode &WIRE) ||
(rasty->GetDrawingMode() <= RAS_IRasterizer::KX_WIREFRAME))
- {
+ {
if (mMaterial->ras_mode &WIRE)
rasty->SetCullFace(false);
rasty->SetLines(true);
@@ -457,7 +457,7 @@ KX_BlenderMaterial::ActivateBlenderShaders(
if ((mMaterial->ras_mode &WIRE) ||
(rasty->GetDrawingMode() <= RAS_IRasterizer::KX_WIREFRAME))
- {
+ {
if (mMaterial->ras_mode &WIRE)
rasty->SetCullFace(false);
rasty->SetLines(true);
@@ -506,7 +506,7 @@ KX_BlenderMaterial::ActivateMat(
if ((mMaterial->ras_mode &WIRE) ||
(rasty->GetDrawingMode() <= RAS_IRasterizer::KX_WIREFRAME))
- {
+ {
if (mMaterial->ras_mode &WIRE)
rasty->SetCullFace(false);
rasty->SetLines(true);
@@ -614,7 +614,7 @@ void KX_BlenderMaterial::ActivatGLMaterials( RAS_IRasterizer* rasty )const
mMaterial->matcolor[2]*mMaterial->ref+mMaterial->emit,
1.0f);
- rasty->SetEmissive(
+ rasty->SetEmissive(
mMaterial->matcolor[0]*mMaterial->emit,
mMaterial->matcolor[1]*mMaterial->emit,
mMaterial->matcolor[2]*mMaterial->emit,
@@ -835,19 +835,19 @@ PyTypeObject KX_BlenderMaterial::Type = {
py_base_new
};
-PyObject* KX_BlenderMaterial::pyattr_get_shader(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_BlenderMaterial::pyattr_get_shader(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_BlenderMaterial* self= static_cast<KX_BlenderMaterial*>(self_v);
return self->PygetShader(NULL, NULL);
}
-PyObject* KX_BlenderMaterial::pyattr_get_materialIndex(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_BlenderMaterial::pyattr_get_materialIndex(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_BlenderMaterial* self= static_cast<KX_BlenderMaterial*>(self_v);
return PyLong_FromSsize_t(self->GetMaterialIndex());
}
-PyObject* KX_BlenderMaterial::pyattr_get_blending(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_BlenderMaterial::pyattr_get_blending(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_BlenderMaterial* self= static_cast<KX_BlenderMaterial*>(self_v);
unsigned int* bfunc = self->getBlendFunc();
@@ -857,7 +857,7 @@ PyObject* KX_BlenderMaterial::pyattr_get_blending(void *self_v, const KX_PYATTRI
int KX_BlenderMaterial::pyattr_set_blending(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value)
{
KX_BlenderMaterial* self= static_cast<KX_BlenderMaterial*>(self_v);
- PyObject* obj = self->PysetBlending(value, NULL);
+ PyObject *obj = self->PysetBlending(value, NULL);
if (obj)
{
Py_DECREF(obj);
diff --git a/source/gameengine/Ketsji/KX_BlenderMaterial.h b/source/gameengine/Ketsji/KX_BlenderMaterial.h
index 8fc86ef9cf2..a69f5c92d19 100644
--- a/source/gameengine/Ketsji/KX_BlenderMaterial.h
+++ b/source/gameengine/Ketsji/KX_BlenderMaterial.h
@@ -106,11 +106,11 @@ public:
#ifdef WITH_PYTHON
// --------------------------------
- virtual PyObject* py_repr(void) { return PyUnicode_From_STR_String(mMaterial->matname); }
+ virtual PyObject *py_repr(void) { return PyUnicode_From_STR_String(mMaterial->matname); }
- static PyObject* pyattr_get_shader(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_materialIndex(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_blending(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_shader(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_materialIndex(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_blending(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_blending(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
KX_PYMETHOD_DOC(KX_BlenderMaterial, getShader);
diff --git a/source/gameengine/Ketsji/KX_BulletPhysicsController.cpp b/source/gameengine/Ketsji/KX_BulletPhysicsController.cpp
index b974886f60a..20c41b95dd3 100644
--- a/source/gameengine/Ketsji/KX_BulletPhysicsController.cpp
+++ b/source/gameengine/Ketsji/KX_BulletPhysicsController.cpp
@@ -269,7 +269,7 @@ void KX_BulletPhysicsController::AddCompoundChild(KX_IPhysicsController* chil
rootScale[2] = 1.0/rootScale[2];
// relative scale = child_scale/parent_scale
btVector3 relativeScale = childShape->getLocalScaling()*rootScale;
- btMatrix3x3 rootRotInverse = rootTrans.getBasis().transpose();
+ btMatrix3x3 rootRotInverse = rootTrans.getBasis().transpose();
// relative pos = parent_rot^-1 * ((parent_pos-child_pos)/parent_scale)
btVector3 relativePos = rootRotInverse*((childTrans.getOrigin()-rootTrans.getOrigin())*rootScale);
// relative rot = parent_rot^-1 * child_rot
diff --git a/source/gameengine/Ketsji/KX_Camera.cpp b/source/gameengine/Ketsji/KX_Camera.cpp
index ac17adaf052..c0071ab22f6 100644
--- a/source/gameengine/Ketsji/KX_Camera.cpp
+++ b/source/gameengine/Ketsji/KX_Camera.cpp
@@ -67,7 +67,7 @@ KX_Camera::~KX_Camera()
delete m_pSGNode;
m_pSGNode = NULL;
}
-}
+}
CValue* KX_Camera::GetReplica()
@@ -119,7 +119,7 @@ const MT_Point3 KX_Camera::GetCameraLocation() const
//MT_Transform trans;
//trans.setBasis(NodeGetWorldOrientation());
- return NodeGetWorldPosition();
+ return NodeGetWorldPosition();
}
@@ -712,7 +712,7 @@ KX_PYMETHODDEF_DOC_NOARGS(KX_Camera, setOnTop,
Py_RETURN_NONE;
}
-PyObject* KX_Camera::pyattr_get_perspective(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_perspective(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyBool_FromLong(self->m_camdata.m_perspective);
@@ -732,7 +732,7 @@ int KX_Camera::pyattr_set_perspective(void *self_v, const KX_PYATTRIBUTE_DEF *at
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_Camera::pyattr_get_lens(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_lens(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyFloat_FromDouble(self->m_camdata.m_lens);
@@ -752,7 +752,7 @@ int KX_Camera::pyattr_set_lens(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef,
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_Camera::pyattr_get_ortho_scale(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_ortho_scale(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyFloat_FromDouble(self->m_camdata.m_scale);
@@ -772,7 +772,7 @@ int KX_Camera::pyattr_set_ortho_scale(void *self_v, const KX_PYATTRIBUTE_DEF *at
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_Camera::pyattr_get_near(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_near(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyFloat_FromDouble(self->m_camdata.m_clipstart);
@@ -792,7 +792,7 @@ int KX_Camera::pyattr_set_near(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef,
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_Camera::pyattr_get_far(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_far(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyFloat_FromDouble(self->m_camdata.m_clipend);
@@ -813,7 +813,7 @@ int KX_Camera::pyattr_set_far(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, P
}
-PyObject* KX_Camera::pyattr_get_use_viewport(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_use_viewport(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyBool_FromLong(self->GetViewport());
@@ -832,7 +832,7 @@ int KX_Camera::pyattr_set_use_viewport(void *self_v, const KX_PYATTRIBUTE_DEF *a
}
-PyObject* KX_Camera::pyattr_get_projection_matrix(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_projection_matrix(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyObjectFrom(self->GetProjectionMatrix());
@@ -849,34 +849,34 @@ int KX_Camera::pyattr_set_projection_matrix(void *self_v, const KX_PYATTRIBUTE_D
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_Camera::pyattr_get_modelview_matrix(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_modelview_matrix(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyObjectFrom(self->GetModelviewMatrix());
}
-PyObject* KX_Camera::pyattr_get_camera_to_world(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_camera_to_world(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyObjectFrom(self->GetCameraToWorld());
}
-PyObject* KX_Camera::pyattr_get_world_to_camera(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_world_to_camera(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Camera* self= static_cast<KX_Camera*>(self_v);
return PyObjectFrom(self->GetWorldToCamera());
}
-PyObject* KX_Camera::pyattr_get_INSIDE(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_INSIDE(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{ return PyLong_FromSsize_t(INSIDE); }
-PyObject* KX_Camera::pyattr_get_OUTSIDE(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_OUTSIDE(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{ return PyLong_FromSsize_t(OUTSIDE); }
-PyObject* KX_Camera::pyattr_get_INTERSECT(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Camera::pyattr_get_INTERSECT(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{ return PyLong_FromSsize_t(INTERSECT); }
-bool ConvertPythonToCamera(PyObject * value, KX_Camera **object, bool py_none_ok, const char *error_prefix)
+bool ConvertPythonToCamera(PyObject *value, KX_Camera **object, bool py_none_ok, const char *error_prefix)
{
if (value==NULL) {
PyErr_Format(PyExc_TypeError, "%s, python pointer NULL, should never happen", error_prefix);
@@ -976,7 +976,7 @@ KX_PYMETHODDEF_DOC_O(KX_Camera, getScreenPosition,
vect[1] = 1.0 - vect[1]; //to follow Blender window coordinate system (Top-Down)
- PyObject* ret = PyTuple_New(2);
+ PyObject *ret = PyTuple_New(2);
if (ret) {
PyTuple_SET_ITEM(ret, 0, PyFloat_FromDouble(vect[0]));
PyTuple_SET_ITEM(ret, 1, PyFloat_FromDouble(vect[1]));
@@ -1040,7 +1040,7 @@ KX_PYMETHODDEF_DOC_VARARGS(KX_Camera, getScreenRay,
if (!PyArg_ParseTuple(args,"ddd|s:getScreenRay",&x,&y,&dist,&propName))
return NULL;
- PyObject* argValue = PyTuple_New(2);
+ PyObject *argValue = PyTuple_New(2);
PyTuple_SET_ITEM(argValue, 0, PyFloat_FromDouble(x));
PyTuple_SET_ITEM(argValue, 1, PyFloat_FromDouble(y));
@@ -1065,7 +1065,7 @@ KX_PYMETHODDEF_DOC_VARARGS(KX_Camera, getScreenRay,
if (propName)
PyTuple_SET_ITEM(argValue, 2, PyUnicode_FromString(propName));
- PyObject* ret= this->PyrayCastTo(argValue,NULL);
+ PyObject *ret= this->PyrayCastTo(argValue,NULL);
Py_DECREF(argValue);
return ret;
}
diff --git a/source/gameengine/Ketsji/KX_Camera.h b/source/gameengine/Ketsji/KX_Camera.h
index 7481b2eb7f0..d95d10e8384 100644
--- a/source/gameengine/Ketsji/KX_Camera.h
+++ b/source/gameengine/Ketsji/KX_Camera.h
@@ -45,7 +45,7 @@
#ifdef WITH_PYTHON
/* utility conversion function */
-bool ConvertPythonToCamera(PyObject * value, KX_Camera **object, bool py_none_ok, const char *error_prefix);
+bool ConvertPythonToCamera(PyObject *value, KX_Camera **object, bool py_none_ok, const char *error_prefix);
#endif
class KX_Camera : public KX_GameObject
@@ -156,7 +156,7 @@ public:
* instance allocated on the heap. Ownership of the new
* object belongs with the caller.
*/
- virtual CValue*
+ virtual CValue*
GetReplica(
);
virtual void ProcessReplica();
@@ -286,8 +286,8 @@ public:
KX_PYMETHOD_DOC_NOARGS(KX_Camera, getCameraToWorld);
KX_PYMETHOD_DOC_NOARGS(KX_Camera, getWorldToCamera);
- KX_PYMETHOD_DOC_VARARGS(KX_Camera, setViewport);
- KX_PYMETHOD_DOC_NOARGS(KX_Camera, setOnTop);
+ KX_PYMETHOD_DOC_VARARGS(KX_Camera, setViewport);
+ KX_PYMETHOD_DOC_NOARGS(KX_Camera, setOnTop);
KX_PYMETHOD_DOC_O(KX_Camera, getScreenPosition);
KX_PYMETHOD_DOC_VARARGS(KX_Camera, getScreenVect);
diff --git a/source/gameengine/Ketsji/KX_CameraActuator.cpp b/source/gameengine/Ketsji/KX_CameraActuator.cpp
index 4c63afa7f3e..9ca1ec59a0b 100644
--- a/source/gameengine/Ketsji/KX_CameraActuator.cpp
+++ b/source/gameengine/Ketsji/KX_CameraActuator.cpp
@@ -394,7 +394,7 @@ PyAttributeDef KX_CameraActuator::Attributes[] = {
{NULL}
};
-PyObject* KX_CameraActuator::pyattr_get_object(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_CameraActuator::pyattr_get_object(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_CameraActuator* self= static_cast<KX_CameraActuator*>(self_v);
if (self->m_ob==NULL)
@@ -412,7 +412,7 @@ int KX_CameraActuator::pyattr_set_object(void *self_v, const KX_PYATTRIBUTE_DEF
return PY_SET_ATTR_FAIL; // ConvertPythonToGameObject sets the error
if (self->m_ob)
- self->m_ob->UnregisterActuator(self);
+ self->m_ob->UnregisterActuator(self);
if ((self->m_ob = (SCA_IObject*)gameobj))
self->m_ob->RegisterActuator(self);
diff --git a/source/gameengine/Ketsji/KX_CameraIpoSGController.h b/source/gameengine/Ketsji/KX_CameraIpoSGController.h
index 06058760332..9b7c1eddf00 100644
--- a/source/gameengine/Ketsji/KX_CameraIpoSGController.h
+++ b/source/gameengine/Ketsji/KX_CameraIpoSGController.h
@@ -77,13 +77,13 @@ public:
m_ipotime = time;
m_modified = true;
}
- void SetModifyLens(bool modify) {
+ void SetModifyLens(bool modify) {
m_modify_lens = modify;
}
- void SetModifyClipEnd(bool modify) {
+ void SetModifyClipEnd(bool modify) {
m_modify_clipend = modify;
}
- void SetModifyClipStart(bool modify) {
+ void SetModifyClipStart(bool modify) {
m_modify_clipstart = modify;
}
void AddInterpolator(KX_IInterpolator* interp);
diff --git a/source/gameengine/Ketsji/KX_ConstraintActuator.cpp b/source/gameengine/Ketsji/KX_ConstraintActuator.cpp
index 322d6e60071..3caa4d35565 100644
--- a/source/gameengine/Ketsji/KX_ConstraintActuator.cpp
+++ b/source/gameengine/Ketsji/KX_ConstraintActuator.cpp
@@ -166,7 +166,7 @@ bool KX_ConstraintActuator::NeedRayCast(KX_ClientObjectInfo* client)
bool KX_ConstraintActuator::Update(double curtime, bool frame)
{
- bool result = false;
+ bool result = false;
bool bNegativeEvent = IsNegativeEvent();
RemoveAllEvents();
@@ -462,7 +462,7 @@ bool KX_ConstraintActuator::Update(double curtime, bool frame)
// we expect a hit object
if (!m_hitObject)
result = false;
- if (result)
+ if (result)
{
MT_Vector3 newnormal = callback.m_hitNormal;
// compute new position & orientation
@@ -619,7 +619,7 @@ int KX_ConstraintActuator::pyattr_check_direction(void *self, const struct KX_PY
return 1;
}
act->m_refDirVector = dir/len;
- return 0;
+ return 0;
}
#endif
diff --git a/source/gameengine/Ketsji/KX_ConstraintActuator.h b/source/gameengine/Ketsji/KX_ConstraintActuator.h
index f491aedba74..786e4ff53d2 100644
--- a/source/gameengine/Ketsji/KX_ConstraintActuator.h
+++ b/source/gameengine/Ketsji/KX_ConstraintActuator.h
@@ -43,7 +43,7 @@ class KX_GameObject;
class KX_ConstraintActuator : public SCA_IActuator
{
Py_Header
-protected:
+protected:
// Damp time (int),
int m_posDampTime;
int m_rotDampTime;
diff --git a/source/gameengine/Ketsji/KX_ConstraintWrapper.cpp b/source/gameengine/Ketsji/KX_ConstraintWrapper.cpp
index df6b08974dd..5727ed29e67 100644
--- a/source/gameengine/Ketsji/KX_ConstraintWrapper.cpp
+++ b/source/gameengine/Ketsji/KX_ConstraintWrapper.cpp
@@ -50,13 +50,13 @@ KX_ConstraintWrapper::~KX_ConstraintWrapper()
#ifdef WITH_PYTHON
-PyObject* KX_ConstraintWrapper::PyGetConstraintId()
+PyObject *KX_ConstraintWrapper::PyGetConstraintId()
{
return PyLong_FromSsize_t(m_constraintId);
}
-PyObject* KX_ConstraintWrapper::PyGetParam(PyObject* args, PyObject* kwds)
+PyObject *KX_ConstraintWrapper::PyGetParam(PyObject *args, PyObject *kwds)
{
int dof;
float value;
@@ -69,7 +69,7 @@ PyObject* KX_ConstraintWrapper::PyGetParam(PyObject* args, PyObject* kwds)
}
-PyObject* KX_ConstraintWrapper::PySetParam(PyObject* args, PyObject* kwds)
+PyObject *KX_ConstraintWrapper::PySetParam(PyObject *args, PyObject *kwds)
{
int dof;
float minLimit,maxLimit;
@@ -117,7 +117,7 @@ PyAttributeDef KX_ConstraintWrapper::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_ConstraintWrapper::pyattr_get_constraintId(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ConstraintWrapper::pyattr_get_constraintId(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ConstraintWrapper* self= static_cast<KX_ConstraintWrapper*>(self_v);
return self->PyGetConstraintId();
diff --git a/source/gameengine/Ketsji/KX_ConstraintWrapper.h b/source/gameengine/Ketsji/KX_ConstraintWrapper.h
index a92ae83e7f0..dbc3571cad6 100644
--- a/source/gameengine/Ketsji/KX_ConstraintWrapper.h
+++ b/source/gameengine/Ketsji/KX_ConstraintWrapper.h
@@ -48,7 +48,7 @@ public:
KX_PYMETHOD(KX_ConstraintWrapper,SetParam);
KX_PYMETHOD(KX_ConstraintWrapper,GetParam);
- static PyObject* pyattr_get_constraintId(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_constraintId(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
#endif
private:
diff --git a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
index f1038c04499..776953206fe 100644
--- a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
+++ b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
@@ -282,7 +282,7 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
relativeRot.getValue(rot);
shapeInfo->m_childTrans.getBasis().setFromOpenGLSubMatrix(rot);
- parentShapeInfo->AddShape(shapeInfo);
+ parentShapeInfo->AddShape(shapeInfo);
compoundShape->addChildShape(shapeInfo->m_childTrans,bm);
//do some recalc?
//recalc inertia for rigidbody
@@ -439,7 +439,7 @@ void KX_ConvertBulletObject( class KX_GameObject* gameobj,
{
env->addCcdPhysicsController( physicscontroller);
}
- physicscontroller->setNewClientInfo(gameobj->getClientInfo());
+ physicscontroller->setNewClientInfo(gameobj->getClientInfo());
{
btRigidBody* rbody = physicscontroller->GetRigidBody();
diff --git a/source/gameengine/Ketsji/KX_Dome.cpp b/source/gameengine/Ketsji/KX_Dome.cpp
index 44c9cb1dab8..fd3a18a9d2a 100644
--- a/source/gameengine/Ketsji/KX_Dome.cpp
+++ b/source/gameengine/Ketsji/KX_Dome.cpp
@@ -592,7 +592,7 @@ void KX_Dome::CreateMeshDome180(void)
cubebottom[0].u[2] = 0.0;
cubebottom[0].v[2] = 0.0;
- nfacesbottom = 1;
+ nfacesbottom = 1;
/* Left face - two triangles */
@@ -682,12 +682,12 @@ void KX_Dome::CreateMeshDome180(void)
cubetop.resize(4*nfacestop);
SplitFace(cubetop,&nfacestop);
cubebottom.resize(4*nfacesbottom);
- SplitFace(cubebottom,&nfacesbottom);
+ SplitFace(cubebottom,&nfacesbottom);
cubeleft.resize(4*nfacesleft);
SplitFace(cubeleft,&nfacesleft);
cuberight.resize(4*nfacesright);
SplitFace(cuberight,&nfacesright);
- }
+ }
// Turn into a hemisphere
for (j=0;j<3;j++) {
@@ -763,13 +763,13 @@ void KX_Dome::CreateMeshDome250(void)
cubefront[0].verts[1][0] = 1.0;
cubefront[0].verts[1][1] = 1.0;
- cubefront[0].verts[1][2] = 1.0;
+ cubefront[0].verts[1][2] = 1.0;
cubefront[0].u[1] = uv_ratio;
cubefront[0].v[1] = uv_ratio;
cubefront[0].verts[2][0] =-1.0;
cubefront[0].verts[2][1] = 1.0;
- cubefront[0].verts[2][2] = 1.0;
+ cubefront[0].verts[2][2] = 1.0;
cubefront[0].u[2] = 0.0;
cubefront[0].v[2] = uv_ratio;
@@ -782,13 +782,13 @@ void KX_Dome::CreateMeshDome250(void)
cubefront[1].verts[1][0] =-1.0;
cubefront[1].verts[1][1] = 1.0;
- cubefront[1].verts[1][2] =-1.0;
+ cubefront[1].verts[1][2] =-1.0;
cubefront[1].u[1] = 0.0;
cubefront[1].v[1] = 0.0;
cubefront[1].verts[2][0] = 1.0;
cubefront[1].verts[2][1] = 1.0;
- cubefront[1].verts[2][2] =-1.0;
+ cubefront[1].verts[2][2] =-1.0;
cubefront[1].u[2] = uv_ratio;
cubefront[1].v[2] = 0.0;
@@ -803,13 +803,13 @@ void KX_Dome::CreateMeshDome250(void)
cubeleft[0].verts[1][0] =-1.0;
cubeleft[0].verts[1][1] =-verts_height;
- cubeleft[0].verts[1][2] = 1.0;
+ cubeleft[0].verts[1][2] = 1.0;
cubeleft[0].u[1] = uv_base;
cubeleft[0].v[1] = uv_ratio;
cubeleft[0].verts[2][0] =-1.0;
cubeleft[0].verts[2][1] =-verts_height;
- cubeleft[0].verts[2][2] =-1.0;
+ cubeleft[0].verts[2][2] =-1.0;
cubeleft[0].u[2] = uv_base;
cubeleft[0].v[2] = 0.0;
@@ -822,13 +822,13 @@ void KX_Dome::CreateMeshDome250(void)
cubeleft[1].verts[1][0] =-1.0;
cubeleft[1].verts[1][1] = 1.0;
- cubeleft[1].verts[1][2] =-1.0;
+ cubeleft[1].verts[1][2] =-1.0;
cubeleft[1].u[1] = uv_ratio;
cubeleft[1].v[1] = 0.0;
cubeleft[1].verts[2][0] =-1.0;
cubeleft[1].verts[2][1] = 1.0;
- cubeleft[1].verts[2][2] = 1.0;
+ cubeleft[1].verts[2][2] = 1.0;
cubeleft[1].u[2] = uv_ratio;
cubeleft[1].v[2] = uv_ratio;
@@ -843,13 +843,13 @@ void KX_Dome::CreateMeshDome250(void)
cuberight[0].verts[1][0] = 1.0;
cuberight[0].verts[1][1] =-verts_height;
- cuberight[0].verts[1][2] =-1.0;
+ cuberight[0].verts[1][2] =-1.0;
cuberight[0].u[1] = uv_height;
cuberight[0].v[1] = 0.0;
cuberight[0].verts[2][0] = 1.0;
cuberight[0].verts[2][1] =-verts_height;
- cuberight[0].verts[2][2] = 1.0;
+ cuberight[0].verts[2][2] = 1.0;
cuberight[0].u[2] = uv_height;
cuberight[0].v[2] = uv_ratio;
@@ -862,13 +862,13 @@ void KX_Dome::CreateMeshDome250(void)
cuberight[1].verts[1][0] = 1.0;
cuberight[1].verts[1][1] = 1.0;
- cuberight[1].verts[1][2] = 1.0;
+ cuberight[1].verts[1][2] = 1.0;
cuberight[1].u[1] = 0.0;
cuberight[1].v[1] = uv_ratio;
cuberight[1].verts[2][0] = 1.0;
cuberight[1].verts[2][1] = 1.0;
- cuberight[1].verts[2][2] =-1.0;
+ cuberight[1].verts[2][2] =-1.0;
cuberight[1].u[2] = 0.0;
cuberight[1].v[2] = 0.0;
@@ -883,13 +883,13 @@ void KX_Dome::CreateMeshDome250(void)
cubetop[0].verts[1][0] = 1.0;
cubetop[0].verts[1][1] =-verts_height;
- cubetop[0].verts[1][2] = 1.0;
+ cubetop[0].verts[1][2] = 1.0;
cubetop[0].u[1] = uv_ratio;
cubetop[0].v[1] = uv_height;
cubetop[0].verts[2][0] =-1.0;
cubetop[0].verts[2][1] =-verts_height;
- cubetop[0].verts[2][2] = 1.0;
+ cubetop[0].verts[2][2] = 1.0;
cubetop[0].u[2] = 0.0;
cubetop[0].v[2] = uv_height;
@@ -902,13 +902,13 @@ void KX_Dome::CreateMeshDome250(void)
cubetop[1].verts[1][0] =-1.0;
cubetop[1].verts[1][1] = 1.0;
- cubetop[1].verts[1][2] = 1.0;
+ cubetop[1].verts[1][2] = 1.0;
cubetop[1].u[1] = 0.0;
cubetop[1].v[1] = 0.0;
cubetop[1].verts[2][0] = 1.0;
cubetop[1].verts[2][1] = 1.0;
- cubetop[1].verts[2][2] = 1.0;
+ cubetop[1].verts[2][2] = 1.0;
cubetop[1].u[2] = uv_ratio;
cubetop[1].v[2] = 0.0;
@@ -923,13 +923,13 @@ void KX_Dome::CreateMeshDome250(void)
cubebottom[0].verts[1][0] = 1.0;
cubebottom[0].verts[1][1] = 1.0;
- cubebottom[0].verts[1][2] =-1.0;
+ cubebottom[0].verts[1][2] =-1.0;
cubebottom[0].u[1] = uv_ratio;
cubebottom[0].v[1] = uv_ratio;
cubebottom[0].verts[2][0] =-1.0;
cubebottom[0].verts[2][1] = 1.0;
- cubebottom[0].verts[2][2] =-1.0;
+ cubebottom[0].verts[2][2] =-1.0;
cubebottom[0].u[2] = 0.0;
cubebottom[0].v[2] = uv_ratio;
@@ -942,13 +942,13 @@ void KX_Dome::CreateMeshDome250(void)
cubebottom[1].verts[1][0] =-1.0;
cubebottom[1].verts[1][1] =-verts_height;
- cubebottom[1].verts[1][2] =-1.0;
+ cubebottom[1].verts[1][2] =-1.0;
cubebottom[1].u[1] = 0.0;
cubebottom[1].v[1] = uv_base;
cubebottom[1].verts[2][0] = 1.0;
cubebottom[1].verts[2][1] =-verts_height;
- cubebottom[1].verts[2][2] =-1.0;
+ cubebottom[1].verts[2][2] =-1.0;
cubebottom[1].u[2] = uv_ratio;
cubebottom[1].v[2] = uv_base;
@@ -963,7 +963,7 @@ void KX_Dome::CreateMeshDome250(void)
cubetop.resize(4*nfacestop);
SplitFace(cubetop,&nfacestop);
cubebottom.resize(4*nfacesbottom);
- SplitFace(cubebottom,&nfacesbottom);
+ SplitFace(cubebottom,&nfacesbottom);
cubeleft.resize(4*nfacesleft);
SplitFace(cubeleft,&nfacesleft);
cuberight.resize(4*nfacesright);
@@ -986,13 +986,13 @@ void KX_Dome::CreateMeshDome250(void)
//flatten onto xz plane
for (i=0;i<nfacesfront;i++)
- FlattenDome(cubefront[i].verts);
+ FlattenDome(cubefront[i].verts);
for (i=0;i<nfacestop;i++)
FlattenDome(cubetop[i].verts);
for (i=0;i<nfacesbottom;i++)
FlattenDome(cubebottom[i].verts);
for (i=0;i<nfacesleft;i++)
- FlattenDome(cubeleft[i].verts);
+ FlattenDome(cubeleft[i].verts);
for (i=0;i<nfacesright;i++)
FlattenDome(cuberight[i].verts);
}
@@ -1417,7 +1417,7 @@ void KX_Dome::SplitFace(vector <DomeFace>& face, int *nfaces)
face[n2+2].u[2] = (face[i].u[2] + face[i].u[0]) /2;
face[n2+2].v[0] = (face[i].v[0] + face[i].v[1]) /2;
face[n2+2].v[1] = (face[i].v[1] + face[i].v[2]) /2;
- face[n2+2].v[2] = (face[i].v[2] + face[i].v[0]) /2;
+ face[n2+2].v[2] = (face[i].v[2] + face[i].v[0]) /2;
//face[i].verts[0] = face[i].verts[0];
face[i].verts[1] = (face[i].verts[0] + face[i].verts[1]) /2;
@@ -1427,7 +1427,7 @@ void KX_Dome::SplitFace(vector <DomeFace>& face, int *nfaces)
face[i].u[2] = (face[i].u[0] + face[i].u[2]) /2;
//face[i].v[0] = face[i].v[0];
face[i].v[1] = (face[i].v[0] + face[i].v[1]) /2;
- face[i].v[2] = (face[i].v[0] + face[i].v[2]) /2;
+ face[i].v[2] = (face[i].v[0] + face[i].v[2]) /2;
n2 += 3; // number of faces
}
@@ -1858,7 +1858,7 @@ void KX_Dome::DrawDomeFisheye(void)
glBindTexture(GL_TEXTURE_2D, domefacesId[0]);
GLDrawTriangles(cubetop, nfacestop);
- // bottom triangle
+ // bottom triangle
glBindTexture(GL_TEXTURE_2D, domefacesId[1]);
GLDrawTriangles(cubebottom, nfacesbottom);
diff --git a/source/gameengine/Ketsji/KX_FontObject.cpp b/source/gameengine/Ketsji/KX_FontObject.cpp
index 78134afdab0..9f6ef894f12 100644
--- a/source/gameengine/Ketsji/KX_FontObject.cpp
+++ b/source/gameengine/Ketsji/KX_FontObject.cpp
@@ -252,7 +252,7 @@ PyAttributeDef KX_FontObject::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_FontObject::pyattr_get_text(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_FontObject::pyattr_get_text(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_FontObject* self= static_cast<KX_FontObject*>(self_v);
STR_String str = STR_String();
diff --git a/source/gameengine/Ketsji/KX_GameObject.cpp b/source/gameengine/Ketsji/KX_GameObject.cpp
index 3818cef7d6e..fe8419d5343 100644
--- a/source/gameengine/Ketsji/KX_GameObject.cpp
+++ b/source/gameengine/Ketsji/KX_GameObject.cpp
@@ -362,7 +362,7 @@ BL_ActionManager* KX_GameObject::GetActionManager()
{
// We only want to create an action manager if we need it
if (!m_actionManager)
- {
+ {
KX_GetActiveScene()->AddAnimatedObject(this);
m_actionManager = new BL_ActionManager(this);
}
@@ -690,7 +690,7 @@ void KX_GameObject::SynchronizeTransformFunc(SG_IObject* node, void* gameobj, vo
void KX_GameObject::SetDebugColor(unsigned int bgra)
{
for (size_t i=0;i<m_meshes.size();i++)
- m_meshes[i]->DebugColor(bgra);
+ m_meshes[i]->DebugColor(bgra);
}
@@ -701,8 +701,8 @@ void KX_GameObject::ResetDebugColor()
}
void KX_GameObject::InitIPO(bool ipo_as_force,
- bool ipo_add,
- bool ipo_local)
+ bool ipo_add,
+ bool ipo_local)
{
SGControllerList::iterator it = GetSGNode()->GetSGControllerList().begin();
@@ -939,7 +939,7 @@ void KX_GameObject::AlignAxisToVect(const MT_Vector3& dir, int axis, float fac)
vect /= len;
orimat = GetSGNode()->GetWorldOrientation();
switch (axis)
- {
+ {
case 0: //x axis
ori.setValue(orimat[0][2], orimat[1][2], orimat[2][2]); //pivot axis
if (MT_abs(vect.dot(ori)) > 1.0-3.0*MT_EPSILON) //is the vector parallel to the pivot?
@@ -1041,7 +1041,7 @@ MT_Vector3 KX_GameObject::GetLinearVelocity(bool local)
return locvel;
}
}
- return velocity;
+ return velocity;
}
MT_Vector3 KX_GameObject::GetAngularVelocity(bool local)
@@ -1060,7 +1060,7 @@ MT_Vector3 KX_GameObject::GetAngularVelocity(bool local)
return locvel;
}
}
- return velocity;
+ return velocity;
}
MT_Vector3 KX_GameObject::GetVelocity(const MT_Point3& point)
@@ -1668,7 +1668,7 @@ PyAttributeDef KX_GameObject::Attributes[] = {
{NULL} //Sentinel
};
-PyObject* KX_GameObject::PyReplaceMesh(PyObject* args)
+PyObject *KX_GameObject::PyReplaceMesh(PyObject *args)
{
KX_Scene *scene = KX_GetActiveScene();
@@ -1686,7 +1686,7 @@ PyObject* KX_GameObject::PyReplaceMesh(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_GameObject::PyEndObject()
+PyObject *KX_GameObject::PyEndObject()
{
SG_Node* node = this->GetSGNode();
KX_Scene* scene = static_cast<KX_Scene*>(node->GetSGClientInfo());
@@ -1697,7 +1697,7 @@ PyObject* KX_GameObject::PyEndObject()
}
-PyObject* KX_GameObject::PyReinstancePhysicsMesh(PyObject* args)
+PyObject *KX_GameObject::PyReinstancePhysicsMesh(PyObject *args)
{
KX_GameObject *gameobj= NULL;
RAS_MeshObject *mesh= NULL;
@@ -1724,7 +1724,7 @@ static PyObject *Map_GetItem(PyObject *self_v, PyObject *item)
KX_GameObject* self= static_cast<KX_GameObject*>BGE_PROXY_REF(self_v);
const char *attr_str= _PyUnicode_AsString(item);
CValue* resultattr;
- PyObject* pyconvert;
+ PyObject *pyconvert;
if (self==NULL) {
PyErr_SetString(PyExc_SystemError, "val = gameOb[key]: KX_GameObject, "BGE_PROXY_ERROR_MSG);
@@ -1733,7 +1733,7 @@ static PyObject *Map_GetItem(PyObject *self_v, PyObject *item)
/* first see if the attributes a string and try get the cvalue attribute */
if (attr_str && (resultattr=self->GetProperty(attr_str))) {
- pyconvert = resultattr->ConvertValueToPython();
+ pyconvert = resultattr->ConvertValueToPython();
return pyconvert ? pyconvert:resultattr->GetProxy();
}
/* no CValue attribute, try get the python only m_attr_dict attribute */
@@ -1907,13 +1907,13 @@ PyTypeObject KX_GameObject::Type = {
py_base_new
};
-PyObject* KX_GameObject::pyattr_get_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
return PyUnicode_From_STR_String(self->GetName());
}
-PyObject* KX_GameObject::pyattr_get_parent(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_parent(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
KX_GameObject* parent = self->GetParent();
@@ -1924,7 +1924,7 @@ PyObject* KX_GameObject::pyattr_get_parent(void *self_v, const KX_PYATTRIBUTE_DE
Py_RETURN_NONE;
}
-PyObject* KX_GameObject::pyattr_get_life(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_life(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
@@ -1937,7 +1937,7 @@ PyObject* KX_GameObject::pyattr_get_life(void *self_v, const KX_PYATTRIBUTE_DEF
Py_RETURN_NONE;
}
-PyObject* KX_GameObject::pyattr_get_mass(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_mass(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
KX_IPhysicsController *spc = self->GetPhysicsController();
@@ -1960,7 +1960,7 @@ int KX_GameObject::pyattr_set_mass(void *self_v, const KX_PYATTRIBUTE_DEF *attrd
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_lin_vel_min(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_lin_vel_min(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
KX_IPhysicsController *spc = self->GetPhysicsController();
@@ -1983,7 +1983,7 @@ int KX_GameObject::pyattr_set_lin_vel_min(void *self_v, const KX_PYATTRIBUTE_DEF
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_lin_vel_max(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_lin_vel_max(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
KX_IPhysicsController *spc = self->GetPhysicsController();
@@ -2007,7 +2007,7 @@ int KX_GameObject::pyattr_set_lin_vel_max(void *self_v, const KX_PYATTRIBUTE_DEF
}
-PyObject* KX_GameObject::pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
return PyBool_FromLong(self->GetVisible());
@@ -2027,7 +2027,7 @@ int KX_GameObject::pyattr_set_visible(void *self_v, const KX_PYATTRIBUTE_DEF *at
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_worldPosition(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_worldPosition(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_POS_GLOBAL);
@@ -2049,11 +2049,11 @@ int KX_GameObject::pyattr_set_worldPosition(void *self_v, const KX_PYATTRIBUTE_D
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localPosition(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localPosition(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
-#ifdef USE_MATHUTILS
+#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_POS_LOCAL);
-#else
+#else
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
return PyObjectFrom(self->NodeGetLocalPosition());
#endif
@@ -2071,7 +2071,7 @@ int KX_GameObject::pyattr_set_localPosition(void *self_v, const KX_PYATTRIBUTE_D
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localInertia(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localInertia(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_INERTIA_LOCAL);
@@ -2083,7 +2083,7 @@ PyObject* KX_GameObject::pyattr_get_localInertia(void *self_v, const KX_PYATTRIB
#endif
}
-PyObject* KX_GameObject::pyattr_get_worldOrientation(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_worldOrientation(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Matrix_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, 3, mathutils_kxgameob_matrix_cb_index, MATHUTILS_MAT_CB_ORI_GLOBAL);
@@ -2108,7 +2108,7 @@ int KX_GameObject::pyattr_set_worldOrientation(void *self_v, const KX_PYATTRIBUT
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localOrientation(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localOrientation(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Matrix_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, 3, mathutils_kxgameob_matrix_cb_index, MATHUTILS_MAT_CB_ORI_LOCAL);
@@ -2132,7 +2132,7 @@ int KX_GameObject::pyattr_set_localOrientation(void *self_v, const KX_PYATTRIBUT
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_worldScaling(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_worldScaling(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_SCALE_GLOBAL);
@@ -2154,7 +2154,7 @@ int KX_GameObject::pyattr_set_worldScaling(void *self_v, const KX_PYATTRIBUTE_DE
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localScaling(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localScaling(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_SCALE_LOCAL);
@@ -2176,7 +2176,7 @@ int KX_GameObject::pyattr_set_localScaling(void *self_v, const KX_PYATTRIBUTE_DE
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localTransform(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localTransform(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self = static_cast<KX_GameObject*>(self_v);
@@ -2222,7 +2222,7 @@ int KX_GameObject::pyattr_set_localTransform(void *self_v, const KX_PYATTRIBUTE_
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_worldTransform(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_worldTransform(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self = static_cast<KX_GameObject*>(self_v);
@@ -2256,7 +2256,7 @@ int KX_GameObject::pyattr_set_worldTransform(void *self_v, const KX_PYATTRIBUTE_
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_worldLinearVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_worldLinearVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_LINVEL_GLOBAL);
@@ -2278,7 +2278,7 @@ int KX_GameObject::pyattr_set_worldLinearVelocity(void *self_v, const KX_PYATTRI
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localLinearVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localLinearVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_LINVEL_LOCAL);
@@ -2300,7 +2300,7 @@ int KX_GameObject::pyattr_set_localLinearVelocity(void *self_v, const KX_PYATTRI
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_worldAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_worldAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_ANGVEL_GLOBAL);
@@ -2322,7 +2322,7 @@ int KX_GameObject::pyattr_set_worldAngularVelocity(void *self_v, const KX_PYATTR
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_localAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_localAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_ANGVEL_LOCAL);
@@ -2345,7 +2345,7 @@ int KX_GameObject::pyattr_set_localAngularVelocity(void *self_v, const KX_PYATTR
}
-PyObject* KX_GameObject::pyattr_get_timeOffset(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_timeOffset(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
SG_Node* sg_parent;
@@ -2372,7 +2372,7 @@ int KX_GameObject::pyattr_set_timeOffset(void *self_v, const KX_PYATTRIBUTE_DEF
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_state(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_state(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
int state = 0;
@@ -2400,7 +2400,7 @@ int KX_GameObject::pyattr_set_state(void *self_v, const KX_PYATTRIBUTE_DEF *attr
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_GameObject::pyattr_get_meshes(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_meshes(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
PyObject *meshes= PyList_New(self->m_meshes.size());
@@ -2415,7 +2415,7 @@ PyObject* KX_GameObject::pyattr_get_meshes(void *self_v, const KX_PYATTRIBUTE_DE
return meshes;
}
-PyObject* KX_GameObject::pyattr_get_obcolor(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_obcolor(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
#ifdef USE_MATHUTILS
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 4, mathutils_kxgameob_vector_cb_index, MATHUTILS_VEC_CB_OBJECT_COLOR);
@@ -2437,35 +2437,35 @@ int KX_GameObject::pyattr_set_obcolor(void *self_v, const KX_PYATTRIBUTE_DEF *at
}
/* These are experimental! */
-PyObject* KX_GameObject::pyattr_get_sensors(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_sensors(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return KX_PythonSeq_CreatePyObject((static_cast<KX_GameObject*>(self_v))->m_proxy, KX_PYGENSEQ_OB_TYPE_SENSORS);
}
-PyObject* KX_GameObject::pyattr_get_controllers(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_controllers(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return KX_PythonSeq_CreatePyObject((static_cast<KX_GameObject*>(self_v))->m_proxy, KX_PYGENSEQ_OB_TYPE_CONTROLLERS);
}
-PyObject* KX_GameObject::pyattr_get_actuators(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_actuators(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return KX_PythonSeq_CreatePyObject((static_cast<KX_GameObject*>(self_v))->m_proxy, KX_PYGENSEQ_OB_TYPE_ACTUATORS);
}
/* End experimental */
-PyObject* KX_GameObject::pyattr_get_children(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_children(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
return self->GetChildren()->NewProxy(true);
}
-PyObject* KX_GameObject::pyattr_get_children_recursive(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_children_recursive(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
return self->GetChildrenRecursive()->NewProxy(true);
}
-PyObject* KX_GameObject::pyattr_get_attrDict(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_GameObject::pyattr_get_attrDict(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_GameObject* self= static_cast<KX_GameObject*>(self_v);
@@ -2476,10 +2476,10 @@ PyObject* KX_GameObject::pyattr_get_attrDict(void *self_v, const KX_PYATTRIBUTE_
return self->m_attr_dict;
}
-PyObject* KX_GameObject::PyApplyForce(PyObject* args)
+PyObject *KX_GameObject::PyApplyForce(PyObject *args)
{
int local = 0;
- PyObject* pyvect;
+ PyObject *pyvect;
if (PyArg_ParseTuple(args, "O|i:applyForce", &pyvect, &local)) {
MT_Vector3 force;
@@ -2491,10 +2491,10 @@ PyObject* KX_GameObject::PyApplyForce(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PyApplyTorque(PyObject* args)
+PyObject *KX_GameObject::PyApplyTorque(PyObject *args)
{
int local = 0;
- PyObject* pyvect;
+ PyObject *pyvect;
if (PyArg_ParseTuple(args, "O|i:applyTorque", &pyvect, &local)) {
MT_Vector3 torque;
@@ -2506,10 +2506,10 @@ PyObject* KX_GameObject::PyApplyTorque(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PyApplyRotation(PyObject* args)
+PyObject *KX_GameObject::PyApplyRotation(PyObject *args)
{
int local = 0;
- PyObject* pyvect;
+ PyObject *pyvect;
if (PyArg_ParseTuple(args, "O|i:applyRotation", &pyvect, &local)) {
MT_Vector3 rotation;
@@ -2521,10 +2521,10 @@ PyObject* KX_GameObject::PyApplyRotation(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PyApplyMovement(PyObject* args)
+PyObject *KX_GameObject::PyApplyMovement(PyObject *args)
{
int local = 0;
- PyObject* pyvect;
+ PyObject *pyvect;
if (PyArg_ParseTuple(args, "O|i:applyMovement", &pyvect, &local)) {
MT_Vector3 movement;
@@ -2536,7 +2536,7 @@ PyObject* KX_GameObject::PyApplyMovement(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PyGetLinearVelocity(PyObject* args)
+PyObject *KX_GameObject::PyGetLinearVelocity(PyObject *args)
{
// only can get the velocity if we have a physics object connected to us...
int local = 0;
@@ -2550,10 +2550,10 @@ PyObject* KX_GameObject::PyGetLinearVelocity(PyObject* args)
}
}
-PyObject* KX_GameObject::PySetLinearVelocity(PyObject* args)
+PyObject *KX_GameObject::PySetLinearVelocity(PyObject *args)
{
int local = 0;
- PyObject* pyvect;
+ PyObject *pyvect;
if (PyArg_ParseTuple(args,"O|i:setLinearVelocity",&pyvect,&local)) {
MT_Vector3 velocity;
@@ -2565,7 +2565,7 @@ PyObject* KX_GameObject::PySetLinearVelocity(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PyGetAngularVelocity(PyObject* args)
+PyObject *KX_GameObject::PyGetAngularVelocity(PyObject *args)
{
// only can get the velocity if we have a physics object connected to us...
int local = 0;
@@ -2579,10 +2579,10 @@ PyObject* KX_GameObject::PyGetAngularVelocity(PyObject* args)
}
}
-PyObject* KX_GameObject::PySetAngularVelocity(PyObject* args)
+PyObject *KX_GameObject::PySetAngularVelocity(PyObject *args)
{
int local = 0;
- PyObject* pyvect;
+ PyObject *pyvect;
if (PyArg_ParseTuple(args,"O|i:setAngularVelocity",&pyvect,&local)) {
MT_Vector3 velocity;
@@ -2594,7 +2594,7 @@ PyObject* KX_GameObject::PySetAngularVelocity(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PySetVisible(PyObject* args)
+PyObject *KX_GameObject::PySetVisible(PyObject *args)
{
int visible, recursive = 0;
if (!PyArg_ParseTuple(args,"i|i:setVisible",&visible, &recursive))
@@ -2606,7 +2606,7 @@ PyObject* KX_GameObject::PySetVisible(PyObject* args)
}
-PyObject* KX_GameObject::PySetOcclusion(PyObject* args)
+PyObject *KX_GameObject::PySetOcclusion(PyObject *args)
{
int occlusion, recursive = 0;
if (!PyArg_ParseTuple(args,"i|i:setOcclusion",&occlusion, &recursive))
@@ -2616,11 +2616,11 @@ PyObject* KX_GameObject::PySetOcclusion(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_GameObject::PyGetVelocity(PyObject* args)
+PyObject *KX_GameObject::PyGetVelocity(PyObject *args)
{
// only can get the velocity if we have a physics object connected to us...
MT_Point3 point(0.0,0.0,0.0);
- PyObject* pypos = NULL;
+ PyObject *pypos = NULL;
if (!PyArg_ParseTuple(args, "|O:getVelocity", &pypos) || (pypos && !PyVecTo(pypos, point)))
return NULL;
@@ -2634,7 +2634,7 @@ PyObject* KX_GameObject::PyGetVelocity(PyObject* args)
}
}
-PyObject* KX_GameObject::PyGetReactionForce()
+PyObject *KX_GameObject::PyGetReactionForce()
{
// only can get the velocity if we have a physics object connected to us...
@@ -2651,7 +2651,7 @@ PyObject* KX_GameObject::PyGetReactionForce()
-PyObject* KX_GameObject::PyEnableRigidBody()
+PyObject *KX_GameObject::PyEnableRigidBody()
{
if (GetPhysicsController())
GetPhysicsController()->setRigidBody(true);
@@ -2661,7 +2661,7 @@ PyObject* KX_GameObject::PyEnableRigidBody()
-PyObject* KX_GameObject::PyDisableRigidBody()
+PyObject *KX_GameObject::PyDisableRigidBody()
{
if (GetPhysicsController())
GetPhysicsController()->setRigidBody(false);
@@ -2670,10 +2670,10 @@ PyObject* KX_GameObject::PyDisableRigidBody()
}
-PyObject* KX_GameObject::PySetParent(PyObject* args)
+PyObject *KX_GameObject::PySetParent(PyObject *args)
{
KX_Scene *scene = KX_GetActiveScene();
- PyObject* pyobj;
+ PyObject *pyobj;
KX_GameObject *obj;
int addToCompound=1, ghost=1;
@@ -2687,7 +2687,7 @@ PyObject* KX_GameObject::PySetParent(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_GameObject::PyRemoveParent()
+PyObject *KX_GameObject::PyRemoveParent()
{
KX_Scene *scene = KX_GetActiveScene();
@@ -2696,7 +2696,7 @@ PyObject* KX_GameObject::PyRemoveParent()
}
-PyObject* KX_GameObject::PySetCollisionMargin(PyObject* value)
+PyObject *KX_GameObject::PySetCollisionMargin(PyObject *value)
{
float collisionMargin = PyFloat_AsDouble(value);
@@ -2716,10 +2716,10 @@ PyObject* KX_GameObject::PySetCollisionMargin(PyObject* value)
-PyObject* KX_GameObject::PyApplyImpulse(PyObject* args)
+PyObject *KX_GameObject::PyApplyImpulse(PyObject *args)
{
- PyObject* pyattach;
- PyObject* pyimpulse;
+ PyObject *pyattach;
+ PyObject *pyimpulse;
if (!m_pPhysicsController1) {
PyErr_SetString(PyExc_RuntimeError, "This object has no physics controller");
@@ -2743,7 +2743,7 @@ PyObject* KX_GameObject::PyApplyImpulse(PyObject* args)
-PyObject* KX_GameObject::PySuspendDynamics()
+PyObject *KX_GameObject::PySuspendDynamics()
{
SuspendDynamics();
Py_RETURN_NONE;
@@ -2751,16 +2751,16 @@ PyObject* KX_GameObject::PySuspendDynamics()
-PyObject* KX_GameObject::PyRestoreDynamics()
+PyObject *KX_GameObject::PyRestoreDynamics()
{
RestoreDynamics();
Py_RETURN_NONE;
}
-PyObject* KX_GameObject::PyAlignAxisToVect(PyObject* args)
+PyObject *KX_GameObject::PyAlignAxisToVect(PyObject *args)
{
- PyObject* pyvect;
+ PyObject *pyvect;
int axis = 2; //z axis is the default
float fac = 1.0f;
@@ -2780,7 +2780,7 @@ PyObject* KX_GameObject::PyAlignAxisToVect(PyObject* args)
return NULL;
}
-PyObject* KX_GameObject::PyGetAxisVect(PyObject* value)
+PyObject *KX_GameObject::PyGetAxisVect(PyObject *value)
{
MT_Vector3 vect;
if (PyVecTo(value, vect))
@@ -2791,7 +2791,7 @@ PyObject* KX_GameObject::PyGetAxisVect(PyObject* value)
}
-PyObject* KX_GameObject::PyGetPhysicsId()
+PyObject *KX_GameObject::PyGetPhysicsId()
{
KX_IPhysicsController* ctrl = GetPhysicsController();
uint_ptr physid=0;
@@ -2802,7 +2802,7 @@ PyObject* KX_GameObject::PyGetPhysicsId()
return PyLong_FromSsize_t((long)physid);
}
-PyObject* KX_GameObject::PyGetPropertyNames()
+PyObject *KX_GameObject::PyGetPropertyNames()
{
PyObject *list= ConvertKeysToPython();
@@ -2932,7 +2932,7 @@ KX_PYMETHODDEF_DOC(KX_GameObject, rayCastTo,
" other = 3-tuple or object reference")
{
MT_Point3 toPoint;
- PyObject* pyarg;
+ PyObject *pyarg;
float dist = 0.0f;
char *propName = NULL;
@@ -3050,8 +3050,8 @@ KX_PYMETHODDEF_DOC(KX_GameObject, rayCast,
{
MT_Point3 toPoint;
MT_Point3 fromPoint;
- PyObject* pyto;
- PyObject* pyfrom = NULL;
+ PyObject *pyto;
+ PyObject *pyfrom = NULL;
float dist = 0.0f;
char *propName = NULL;
KX_GameObject *other;
@@ -3125,7 +3125,7 @@ KX_PYMETHODDEF_DOC(KX_GameObject, rayCast,
if (m_pHitObject)
{
- PyObject* returnValue = (poly==2) ? PyTuple_New(5) : (poly) ? PyTuple_New(4) : PyTuple_New(3);
+ PyObject *returnValue = (poly == 2) ? PyTuple_New(5) : (poly) ? PyTuple_New(4) : PyTuple_New(3);
if (returnValue) { // unlikely this would ever fail, if it does python sets an error
PyTuple_SET_ITEM(returnValue, 0, m_pHitObject->GetProxy());
PyTuple_SET_ITEM(returnValue, 1, PyObjectFrom(callback.m_hitPoint));
@@ -3301,11 +3301,11 @@ KX_PYMETHODDEF_DOC(KX_GameObject, isPlayingAction,
/* Matches python dict.get(key, [default]) */
-PyObject* KX_GameObject::Pyget(PyObject *args)
+PyObject *KX_GameObject::Pyget(PyObject *args)
{
PyObject *key;
- PyObject* def = Py_None;
- PyObject* ret;
+ PyObject *def = Py_None;
+ PyObject *ret;
if (!PyArg_ParseTuple(args, "O|O:get", &key, &def))
return NULL;
@@ -3331,7 +3331,7 @@ PyObject* KX_GameObject::Pyget(PyObject *args)
return def;
}
-bool ConvertPythonToGameObject(PyObject * value, KX_GameObject **object, bool py_none_ok, const char *error_prefix)
+bool ConvertPythonToGameObject(PyObject *value, KX_GameObject **object, bool py_none_ok, const char *error_prefix)
{
if (value==NULL) {
PyErr_Format(PyExc_TypeError, "%s, python pointer NULL, should never happen", error_prefix);
diff --git a/source/gameengine/Ketsji/KX_GameObject.h b/source/gameengine/Ketsji/KX_GameObject.h
index 2b0d13ff2f7..ea75ca4a917 100644
--- a/source/gameengine/Ketsji/KX_GameObject.h
+++ b/source/gameengine/Ketsji/KX_GameObject.h
@@ -68,7 +68,7 @@ struct bAction;
#ifdef WITH_PYTHON
/* utility conversion function */
-bool ConvertPythonToGameObject(PyObject * value, KX_GameObject **object, bool py_none_ok, const char *error_prefix);
+bool ConvertPythonToGameObject(PyObject *value, KX_GameObject **object, bool py_none_ok, const char *error_prefix);
#endif
#ifdef USE_MATHUTILS
@@ -159,7 +159,7 @@ public:
* side effect of storing the result internally. The
* memory for the matrix remains the property of this class.
*/
- double*
+ double *
GetOpenGLMatrix(
);
@@ -170,7 +170,7 @@ public:
* memory for the returned matrix.
*/
- MT_CmMatrix4x4*
+ MT_CmMatrix4x4 *
GetOpenGLMatrixPtr(
) {
return &m_OpenGL_4x4Matrix;
@@ -193,18 +193,18 @@ public:
* object. It is the responsibility of the caller to decrement
* the reference count when you have finished with it.
*/
- KX_GameObject*
+ KX_GameObject*
GetParent(
);
/**
* Sets the parent of this object to a game object
- */
+ */
void SetParent(KX_Scene *scene, KX_GameObject *obj, bool addToCompound=true, bool ghost=true);
/**
* Removes the parent of this object to a game object
- */
+ */
void RemoveParent(KX_Scene *scene);
/*********************************
@@ -292,7 +292,7 @@ public:
/**
* Inherited from CValue -- does nothing!
*/
- CValue*
+ CValue*
Calc(
VALUE_OPERATOR op,
CValue *val
@@ -301,7 +301,7 @@ public:
/**
* Inherited from CValue -- does nothing!
*/
- CValue*
+ CValue*
CalcFinal(
VALUE_DATA_TYPE dtype,
VALUE_OPERATOR op,
@@ -312,7 +312,7 @@ public:
* Inherited from CValue -- does nothing!
*/
const
- STR_String &
+ STR_String &
GetText(
);
@@ -331,14 +331,14 @@ public:
/**
* Inherited from CValue -- returns the name of this object.
*/
- STR_String&
+ STR_String&
GetName(
);
/**
* Inherited from CValue -- set the name of this object.
*/
- void
+ void
SetName(
const char *name
);
@@ -348,7 +348,7 @@ public:
* instance allocated on the heap. Ownership of the new
* object belongs with the caller.
*/
- virtual CValue*
+ virtual CValue*
GetReplica(
);
@@ -356,7 +356,7 @@ public:
* Inherited from CValue -- Makes sure any internal
* data owned by this class is deep copied. Called internally
*/
- virtual void
+ virtual void
ProcessReplica();
/**
@@ -379,7 +379,7 @@ public:
/**
* Return the mass of the object
*/
- MT_Scalar
+ MT_Scalar
GetMass();
/**
@@ -410,7 +410,7 @@ public:
* Quick'n'dirty obcolor ipo stuff
*/
- void
+ void
SetObjectColor(
const MT_Vector4& rgbavec
);
@@ -482,7 +482,7 @@ public:
// adapt local position so that world position is set to desired position
void NodeSetWorldPosition(const MT_Point3& trans);
- void
+ void
NodeUpdateGS(
double time
);
@@ -504,7 +504,7 @@ public:
return m_pSGNode;
}
- const SG_Node* GetSGNode( ) const
+ const SG_Node* GetSGNode( ) const
{
return m_pSGNode;
}
@@ -581,48 +581,48 @@ public:
* place.
*/
- void
+ void
ApplyForce(
const MT_Vector3& force, bool local
);
- void
+ void
ApplyTorque(
const MT_Vector3& torque,
bool local
);
- void
+ void
ApplyRotation(
const MT_Vector3& drot,
bool local
);
- void
+ void
ApplyMovement(
const MT_Vector3& dloc,
bool local
);
- void
+ void
addLinearVelocity(
const MT_Vector3& lin_vel,
bool local
);
- void
+ void
setLinearVelocity(
const MT_Vector3& lin_vel,
bool local
);
- void
+ void
setAngularVelocity(
const MT_Vector3& ang_vel,
bool local
);
- /**
+ /**
* Update the physics object transform based upon the current SG_Node
* position.
*/
@@ -642,7 +642,7 @@ public:
/**
* Function to set IPO option at start of IPO
*/
- void
+ void
InitIPO(
bool ipo_as_force,
bool ipo_add,
@@ -652,7 +652,7 @@ public:
/**
* Odd function to update an ipo. ???
*/
- void
+ void
UpdateIPO(
float curframetime,
bool recurse
@@ -676,20 +676,20 @@ public:
* \section Mesh accessor functions.
*/
- /**
+ /**
* Update buckets to indicate that there is a new
* user of this object's meshes.
*/
- void
+ void
AddMeshUser(
);
- /**
+ /**
* Update buckets with data about the mesh after
* creating or duplicating the object, changing
* visibility, object color, .. .
*/
- void
+ void
UpdateBuckets(
bool recursive
);
@@ -699,7 +699,7 @@ public:
* and remove from the bucketing system.
* Don't think this actually deletes any of the meshes.
*/
- void
+ void
RemoveMeshes(
);
@@ -709,7 +709,7 @@ public:
* Make sure you call RemoveMeshes() before deleting the
* mesh though,
*/
- void
+ void
AddMesh(
RAS_MeshObject* mesh
) {
@@ -719,7 +719,7 @@ public:
/**
* Pick out a mesh associated with the integer 'num'.
*/
- RAS_MeshObject*
+ RAS_MeshObject*
GetMesh(
int num
) const {
@@ -730,17 +730,17 @@ public:
* Return the number of meshes currently associated with this
* game object.
*/
- int
+ int
GetMeshCount(
) const {
return m_meshes.size();
}
- /**
+ /**
* Set the debug color of the meshes associated with this
* class. Does this still work?
*/
- void
+ void
SetDebugColor(
unsigned int bgra
);
@@ -748,7 +748,7 @@ public:
/**
* Reset the debug color of meshes associated with this class.
*/
- void
+ void
ResetDebugColor(
);
@@ -855,7 +855,7 @@ public:
m_bSuspendDynamics = true;
}
- void RestoreDynamics(void) {
+ void RestoreDynamics(void) {
if (!m_bSuspendDynamics)
{
return;
@@ -887,7 +887,7 @@ public:
/**
* \section Python interface functions.
*/
- virtual PyObject* py_repr(void)
+ virtual PyObject *py_repr(void)
{
return PyUnicode_From_STR_String(GetName());
}
@@ -983,7 +983,7 @@ public:
static PyObject* pyattr_get_worldAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_worldAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static PyObject* pyattr_get_localAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_localAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
+ static int pyattr_set_localAngularVelocity(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static PyObject* pyattr_get_timeOffset(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_timeOffset(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static PyObject* pyattr_get_state(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
diff --git a/source/gameengine/Ketsji/KX_IInterpolator.h b/source/gameengine/Ketsji/KX_IInterpolator.h
index 6ca44e1f6e5..6c0bf2d85cc 100644
--- a/source/gameengine/Ketsji/KX_IInterpolator.h
+++ b/source/gameengine/Ketsji/KX_IInterpolator.h
@@ -38,7 +38,7 @@
#include "MEM_guardedalloc.h"
#endif
-class KX_IInterpolator {
+class KX_IInterpolator {
public:
virtual ~KX_IInterpolator() {}
diff --git a/source/gameengine/Ketsji/KX_IScalarInterpolator.h b/source/gameengine/Ketsji/KX_IScalarInterpolator.h
index 2b5aefccfe7..1e822c49c6d 100644
--- a/source/gameengine/Ketsji/KX_IScalarInterpolator.h
+++ b/source/gameengine/Ketsji/KX_IScalarInterpolator.h
@@ -36,7 +36,7 @@
#include "MEM_guardedalloc.h"
#endif
-class KX_IScalarInterpolator {
+class KX_IScalarInterpolator {
public:
virtual ~KX_IScalarInterpolator() {}
diff --git a/source/gameengine/Ketsji/KX_IpoActuator.cpp b/source/gameengine/Ketsji/KX_IpoActuator.cpp
index 5599f3e31c6..5ea7a2e7394 100644
--- a/source/gameengine/Ketsji/KX_IpoActuator.cpp
+++ b/source/gameengine/Ketsji/KX_IpoActuator.cpp
@@ -182,7 +182,7 @@ bool KX_IpoActuator::Update(double curtime, bool frame)
m_bIpoPlaying = true;
bIpoStart = true;
}
- }
+ }
switch ((IpoActType)m_type)
{
@@ -254,7 +254,7 @@ bool KX_IpoActuator::Update(double curtime, bool frame)
result = false;
if (bIpoStart)
- ((KX_GameObject*)GetParent())->InitIPO(m_ipo_as_force, m_ipo_add, m_ipo_local);
+ ((KX_GameObject*)GetParent())->InitIPO(m_ipo_as_force, m_ipo_add, m_ipo_local);
((KX_GameObject*)GetParent())->UpdateIPO(m_localtime,m_recurse);
break;
}
@@ -309,7 +309,7 @@ bool KX_IpoActuator::Update(double curtime, bool frame)
bIpoStart = true;
}
else
- {
+ {
/* Perform clamping */
m_localtime=m_endframe;
result = false;
@@ -453,7 +453,7 @@ PyAttributeDef KX_IpoActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_IpoActuator::pyattr_get_frame_start(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_IpoActuator::pyattr_get_frame_start(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_IpoActuator* self= static_cast<KX_IpoActuator*>(self_v);
return PyFloat_FromDouble(self->m_startframe);
@@ -474,7 +474,7 @@ int KX_IpoActuator::pyattr_set_frame_start(void *self_v, const KX_PYATTRIBUTE_DE
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_IpoActuator::pyattr_get_frame_end(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_IpoActuator::pyattr_get_frame_end(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_IpoActuator* self= static_cast<KX_IpoActuator*>(self_v);
return PyFloat_FromDouble(self->m_endframe);
diff --git a/source/gameengine/Ketsji/KX_KetsjiEngine.cpp b/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
index a560b606f5b..c2857141058 100644
--- a/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
+++ b/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
@@ -253,7 +253,7 @@ void KX_KetsjiEngine::SetRasterizer(RAS_IRasterizer* rasterizer)
* At the moment the bge.logic module is imported into 'pythondictionary' after this function is called.
* if this function ever changes to assign a copy, make sure the game logic module is imported into this dictionary before hand.
*/
-void KX_KetsjiEngine::SetPyNamespace(PyObject* pythondictionary)
+void KX_KetsjiEngine::SetPyNamespace(PyObject *pythondictionary)
{
MT_assert(pythondictionary);
m_pythondictionary = pythondictionary;
@@ -361,7 +361,7 @@ void KX_KetsjiEngine::RenderDome()
// no FlushDebugLines
}
m_dome->BindImages(i);
- }
+ }
m_canvas->EndFrame();//XXX do we really need that?
@@ -391,7 +391,7 @@ void KX_KetsjiEngine::RenderDome()
// Draw Callback for the last scene
#ifdef WITH_PYTHON
scene->RunDrawingCallbacks(scene->GetPostDrawCB());
-#endif
+#endif
EndFrame();
}
@@ -477,7 +477,7 @@ void KX_KetsjiEngine::ClearFrame()
SetBackGround(firstscene->GetWorldInfo());
m_canvas->SetViewPort(clearvp.GetLeft(), clearvp.GetBottom(),
- clearvp.GetRight(), clearvp.GetTop());
+ clearvp.GetRight(), clearvp.GetTop());
m_rasterizer->ClearColorBuffer();
}
}
@@ -498,7 +498,7 @@ bool KX_KetsjiEngine::BeginFrame()
}
return false;
-}
+}
void KX_KetsjiEngine::EndFrame()
@@ -641,7 +641,7 @@ else
scene->GetPhysicsEnvironment()->endFrame();
// Update scenegraph after physics step. This maps physics calculations
- // into node positions.
+ // into node positions.
//m_logger->StartLog(tc_scenegraph, m_kxsystem->GetTimeInSeconds(), true);
//SG_SetActiveStage(SG_STAGE_PHYSICS1_UPDATE);
//scene->UpdateParents(m_frameTime);
@@ -692,7 +692,7 @@ else
if (m_animation_record)
- {
+ {
m_sceneconverter->WritePhysicsObjectToAnimationIpo(++m_currentFrame);
}
@@ -725,7 +725,7 @@ else
bool bUseAsyncLogicBricks= false;//true;
if (bUseAsyncLogicBricks)
- {
+ {
// Logic update sub frame: this will let some logic bricks run at the
// full frame rate.
for (sceneit = m_scenes.begin();sceneit != m_scenes.end(); ++sceneit)
@@ -756,7 +756,7 @@ else
m_logger->StartLog(tc_physics, m_kxsystem->GetTimeInSeconds(), true);
scene->GetPhysicsEnvironment()->proceedDeltaTime(m_clockTime,timestep,timestep);
// Update scenegraph after physics step. This maps physics calculations
- // into node positions.
+ // into node positions.
m_logger->StartLog(tc_scenegraph, m_kxsystem->GetTimeInSeconds(), true);
SG_SetActiveStage(SG_STAGE_PHYSICS2);
scene->UpdateParents(m_clockTime);
@@ -938,7 +938,7 @@ void KX_KetsjiEngine::Render()
//RenderFrame(scene);
RenderFrame(scene, cam);
- list<class KX_Camera*>* cameras = scene->GetCameras();
+ list<class KX_Camera*>* cameras = scene->GetCameras();
// Draw the scene once for each camera with an enabled viewport
list<KX_Camera*>::iterator it = cameras->begin();
@@ -1013,7 +1013,7 @@ void KX_KetsjiEngine::SetBackGround(KX_WorldInfo* wi)
if (wi->hasWorld())
{
if (m_drawingmode == RAS_IRasterizer::KX_TEXTURED)
- {
+ {
m_rasterizer->SetBackColor(
wi->getBackColorRed(),
wi->getBackColorGreen(),
@@ -1038,7 +1038,7 @@ void KX_KetsjiEngine::SetWorldSettings(KX_WorldInfo* wi)
);
if (m_drawingmode >= RAS_IRasterizer::KX_SOLID)
- {
+ {
if (wi->hasMist())
{
m_rasterizer->SetFog(
@@ -1203,11 +1203,11 @@ void KX_KetsjiEngine::RenderFrame(KX_Scene* scene, KX_Camera* cam)
GetSceneViewport(scene, cam, area, viewport);
// store the computed viewport in the scene
- scene->SetSceneViewport(viewport);
+ scene->SetSceneViewport(viewport);
// set the viewport for this frame and scene
m_canvas->SetViewPort(viewport.GetLeft(), viewport.GetBottom(),
- viewport.GetRight(), viewport.GetTop());
+ viewport.GetRight(), viewport.GetTop());
// see KX_BlenderMaterial::Activate
//m_rasterizer->SetAmbient();
@@ -1348,7 +1348,7 @@ void KX_KetsjiEngine::PostRenderScene(KX_Scene* scene)
m_rasterizer->FlushDebugShapes();
scene->Render2DFilters(m_canvas);
#ifdef WITH_PYTHON
- scene->RunDrawingCallbacks(scene->GetPostDrawCB());
+ scene->RunDrawingCallbacks(scene->GetPostDrawCB());
#endif
}
@@ -1368,10 +1368,10 @@ void KX_KetsjiEngine::StopEngine()
{
KX_Scene* scene = *sceneit;
m_sceneconverter->RemoveScene(scene);
- }
+ }
m_scenes.clear();
- // cleanup all the stuff
+ // cleanup all the stuff
m_rasterizer->Exit();
}
}
@@ -1469,7 +1469,7 @@ void KX_KetsjiEngine::RenderDebugProperties()
/* Profile and framerate display */
if (m_show_profile)
- {
+ {
for (int j = tc_first; j < tc_numCategories; j++)
{
debugtxt.Format(m_profileLabels[j]);
@@ -1556,7 +1556,7 @@ void KX_KetsjiEngine::RenderDebugProperties()
KX_SceneList* KX_KetsjiEngine::CurrentScenes()
{
- return &m_scenes;
+ return &m_scenes;
}
@@ -1572,7 +1572,7 @@ KX_Scene* KX_KetsjiEngine::FindScene(const STR_String& scenename)
sceneit++;
}
- return ((sceneit == m_scenes.end()) ? NULL : *sceneit);
+ return ((sceneit == m_scenes.end()) ? NULL : *sceneit);
}
@@ -1635,7 +1635,7 @@ void KX_KetsjiEngine::RemoveScheduledScenes()
m_scenes.erase(sceneit);
break;
}
- }
+ }
}
m_removingScenes.clear();
}
@@ -1737,7 +1737,7 @@ void KX_KetsjiEngine::ReplaceScheduledScenes()
}
}
m_replace_scenes.clear();
- }
+ }
}
@@ -1910,7 +1910,7 @@ void KX_KetsjiEngine::SceneListsChanged(void)
while ((sceneit != m_scenes.end()) && (!m_propertiesPresent))
{
KX_Scene* scene = *sceneit;
- vector<SCA_DebugProp*>& debugproplist = scene->GetDebugProperties();
+ vector<SCA_DebugProp*>& debugproplist = scene->GetDebugProperties();
m_propertiesPresent = !debugproplist.empty();
sceneit++;
}
diff --git a/source/gameengine/Ketsji/KX_KetsjiEngine.h b/source/gameengine/Ketsji/KX_KetsjiEngine.h
index b3bef016b0f..e05ba652bbe 100644
--- a/source/gameengine/Ketsji/KX_KetsjiEngine.h
+++ b/source/gameengine/Ketsji/KX_KetsjiEngine.h
@@ -98,7 +98,7 @@ private:
/* The current list of scenes. */
KX_SceneList m_scenes;
/* State variable recording the presence of object debug info in the current scene list. */
- bool m_propertiesPresent;
+ bool m_propertiesPresent;
bool m_bInitialized;
int m_activecam;
@@ -136,7 +136,7 @@ private:
int m_drawingmode;
float m_cameraZoom;
- bool m_overrideCam;
+ bool m_overrideCam;
STR_String m_overrideSceneName;
bool m_overrideCamUseOrtho;
@@ -220,7 +220,7 @@ public:
void SetRenderTools(RAS_IRenderTools* rendertools);
void SetRasterizer(RAS_IRasterizer* rasterizer);
#ifdef WITH_PYTHON
- void SetPyNamespace(PyObject* pythondictionary);
+ void SetPyNamespace(PyObject *pythondictionary);
PyObject* GetPyNamespace() { return m_pythondictionary; }
#endif
void SetSceneConverter(KX_ISceneConverter* sceneconverter);
@@ -415,7 +415,7 @@ public:
KX_Scene* CreateScene(const STR_String& scenename);
KX_Scene* CreateScene(Scene *scene);
- GlobalSettings* GetGlobalSettings(void);
+ GlobalSettings* GetGlobalSettings(void);
void SetGlobalSettings(GlobalSettings* gs);
protected:
diff --git a/source/gameengine/Ketsji/KX_Light.cpp b/source/gameengine/Ketsji/KX_Light.cpp
index f5aa1bb3c75..8b80daa75d3 100644
--- a/source/gameengine/Ketsji/KX_Light.cpp
+++ b/source/gameengine/Ketsji/KX_Light.cpp
@@ -344,7 +344,7 @@ PyAttributeDef KX_LightObject::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_LightObject::pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_LightObject::pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_LightObject* self = static_cast<KX_LightObject*>(self_v);
return Py_BuildValue("[fff]", self->m_lightobj.m_red, self->m_lightobj.m_green, self->m_lightobj.m_blue);
@@ -365,9 +365,9 @@ int KX_LightObject::pyattr_set_color(void *self_v, const KX_PYATTRIBUTE_DEF *att
return PY_SET_ATTR_FAIL;
}
-PyObject* KX_LightObject::pyattr_get_typeconst(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_LightObject::pyattr_get_typeconst(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
- PyObject* retvalue;
+ PyObject *retvalue;
const char* type = attrdef->m_name;
@@ -387,13 +387,13 @@ PyObject* KX_LightObject::pyattr_get_typeconst(void *self_v, const KX_PYATTRIBUT
return retvalue;
}
-PyObject* KX_LightObject::pyattr_get_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_LightObject::pyattr_get_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_LightObject* self = static_cast<KX_LightObject*>(self_v);
return PyLong_FromSsize_t(self->m_lightobj.m_type);
}
-int KX_LightObject::pyattr_set_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject* value)
+int KX_LightObject::pyattr_set_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value)
{
KX_LightObject* self = static_cast<KX_LightObject*>(self_v);
int val = PyLong_AsSsize_t(value);
diff --git a/source/gameengine/Ketsji/KX_Light.h b/source/gameengine/Ketsji/KX_Light.h
index 9fe13f471ba..7426896a92a 100644
--- a/source/gameengine/Ketsji/KX_Light.h
+++ b/source/gameengine/Ketsji/KX_Light.h
@@ -76,10 +76,10 @@ public:
#ifdef WITH_PYTHON
/* attributes */
static PyObject* pyattr_get_color(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_color(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject* value);
+ static int pyattr_set_color(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static PyObject* pyattr_get_typeconst(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static PyObject* pyattr_get_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject* value);
+ static int pyattr_set_type(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif
};
diff --git a/source/gameengine/Ketsji/KX_LightIpoSGController.h b/source/gameengine/Ketsji/KX_LightIpoSGController.h
index 3a3a9677b04..4a1ceba0963 100644
--- a/source/gameengine/Ketsji/KX_LightIpoSGController.h
+++ b/source/gameengine/Ketsji/KX_LightIpoSGController.h
@@ -74,15 +74,15 @@ public:
m_modified = true;
}
- void SetModifyEnergy(bool modify) {
+ void SetModifyEnergy(bool modify) {
m_modify_energy = modify;
}
- void SetModifyColor(bool modify) {
+ void SetModifyColor(bool modify) {
m_modify_color = modify;
}
- void SetModifyDist(bool modify) {
+ void SetModifyDist(bool modify) {
m_modify_dist = modify;
}
diff --git a/source/gameengine/Ketsji/KX_MeshProxy.cpp b/source/gameengine/Ketsji/KX_MeshProxy.cpp
index f1a9a93c2db..8451dc3497d 100644
--- a/source/gameengine/Ketsji/KX_MeshProxy.cpp
+++ b/source/gameengine/Ketsji/KX_MeshProxy.cpp
@@ -105,7 +105,7 @@ KX_MeshProxy::~KX_MeshProxy()
// stuff for cvalue related things
CValue* KX_MeshProxy::Calc(VALUE_OPERATOR op, CValue *val) { return NULL;}
-CValue* KX_MeshProxy::CalcFinal(VALUE_DATA_TYPE dtype, VALUE_OPERATOR op, CValue *val) { return NULL;}
+CValue* KX_MeshProxy::CalcFinal(VALUE_DATA_TYPE dtype, VALUE_OPERATOR op, CValue *val) { return NULL;}
const STR_String & KX_MeshProxy::GetText() {return m_meshobj->GetName();};
double KX_MeshProxy::GetNumber() { return -1;}
@@ -116,7 +116,7 @@ CValue* KX_MeshProxy::GetReplica() { return NULL;}
// stuff for python integration
-PyObject* KX_MeshProxy::PyGetMaterialName(PyObject* args, PyObject* kwds)
+PyObject *KX_MeshProxy::PyGetMaterialName(PyObject *args, PyObject *kwds)
{
int matid= 1;
STR_String matname;
@@ -134,7 +134,7 @@ PyObject* KX_MeshProxy::PyGetMaterialName(PyObject* args, PyObject* kwds)
}
-PyObject* KX_MeshProxy::PyGetTextureName(PyObject* args, PyObject* kwds)
+PyObject *KX_MeshProxy::PyGetTextureName(PyObject *args, PyObject *kwds)
{
int matid= 1;
STR_String matname;
@@ -151,7 +151,7 @@ PyObject* KX_MeshProxy::PyGetTextureName(PyObject* args, PyObject* kwds)
}
-PyObject* KX_MeshProxy::PyGetVertexArrayLength(PyObject* args, PyObject* kwds)
+PyObject *KX_MeshProxy::PyGetVertexArrayLength(PyObject *args, PyObject *kwds)
{
int matid= 0;
int length = 0;
@@ -174,7 +174,7 @@ PyObject* KX_MeshProxy::PyGetVertexArrayLength(PyObject* args, PyObject* kwds)
}
-PyObject* KX_MeshProxy::PyGetVertex(PyObject* args, PyObject* kwds)
+PyObject *KX_MeshProxy::PyGetVertex(PyObject *args, PyObject *kwds)
{
int vertexindex;
int matindex;
@@ -192,10 +192,10 @@ PyObject* KX_MeshProxy::PyGetVertex(PyObject* args, PyObject* kwds)
return (new KX_VertexProxy(this, vertex))->NewProxy(true);
}
-PyObject* KX_MeshProxy::PyGetPolygon(PyObject* args, PyObject* kwds)
+PyObject *KX_MeshProxy::PyGetPolygon(PyObject *args, PyObject *kwds)
{
int polyindex= 1;
- PyObject* polyob = NULL;
+ PyObject *polyob = NULL;
if (!PyArg_ParseTuple(args,"i:getPolygon",&polyindex))
return NULL;
@@ -218,7 +218,7 @@ PyObject* KX_MeshProxy::PyGetPolygon(PyObject* args, PyObject* kwds)
return polyob;
}
-PyObject* KX_MeshProxy::pyattr_get_materials(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MeshProxy::pyattr_get_materials(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MeshProxy* self= static_cast<KX_MeshProxy*>(self_v);
@@ -233,7 +233,7 @@ PyObject* KX_MeshProxy::pyattr_get_materials(void *self_v, const KX_PYATTRIBUTE_
for (i=0; i<tot; mit++, i++) {
RAS_IPolyMaterial *polymat = mit->m_bucket->GetPolyMaterial();
- /* Why do we need to check for RAS_BLENDERMAT if both are cast to a (PyObject*)? - Campbell */
+ /* Why do we need to check for RAS_BLENDERMAT if both are cast to a (PyObject *)? - Campbell */
if (polymat->GetFlag() & RAS_BLENDERMAT)
{
KX_BlenderMaterial *mat = static_cast<KX_BlenderMaterial*>(polymat);
@@ -243,7 +243,7 @@ PyObject* KX_MeshProxy::pyattr_get_materials(void *self_v, const KX_PYATTRIBUTE_
KX_PolygonMaterial *mat = static_cast<KX_PolygonMaterial*>(polymat);
PyList_SET_ITEM(materials, i, mat->GetProxy());
}
- }
+ }
return materials;
}
@@ -260,7 +260,7 @@ PyObject * KX_MeshProxy::pyattr_get_numPolygons(void * selfv, const KX_PYATTRIBU
}
/* a close copy of ConvertPythonToGameObject but for meshes */
-bool ConvertPythonToMesh(PyObject * value, RAS_MeshObject **object, bool py_none_ok, const char *error_prefix)
+bool ConvertPythonToMesh(PyObject *value, RAS_MeshObject **object, bool py_none_ok, const char *error_prefix)
{
if (value==NULL) {
PyErr_Format(PyExc_TypeError, "%s, python pointer NULL, should never happen", error_prefix);
@@ -297,7 +297,7 @@ bool ConvertPythonToMesh(PyObject * value, RAS_MeshObject **object, bool py_none
if (kx_mesh==NULL) {
PyErr_Format(PyExc_SystemError, "%s, " BGE_PROXY_ERROR_MSG, error_prefix);
return false;
- }
+ }
*object = kx_mesh->GetMesh();
return true;
diff --git a/source/gameengine/Ketsji/KX_MeshProxy.h b/source/gameengine/Ketsji/KX_MeshProxy.h
index 58b5c87e494..a05ef6ab2e7 100644
--- a/source/gameengine/Ketsji/KX_MeshProxy.h
+++ b/source/gameengine/Ketsji/KX_MeshProxy.h
@@ -37,7 +37,7 @@
#include "SCA_IObject.h"
/* utility conversion function */
-bool ConvertPythonToMesh(PyObject * value, class RAS_MeshObject **object, bool py_none_ok, const char *error_prefix);
+bool ConvertPythonToMesh(PyObject *value, class RAS_MeshObject **object, bool py_none_ok, const char *error_prefix);
class KX_MeshProxy : public CValue
{
@@ -73,8 +73,8 @@ public:
KX_PYMETHOD(KX_MeshProxy,GetPolygon);
static PyObject* pyattr_get_materials(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject * pyattr_get_numMaterials(void * self, const KX_PYATTRIBUTE_DEF * attrdef);
- static PyObject * pyattr_get_numPolygons(void * self, const KX_PYATTRIBUTE_DEF * attrdef);
+ static PyObject *pyattr_get_numMaterials(void * self, const KX_PYATTRIBUTE_DEF * attrdef);
+ static PyObject *pyattr_get_numPolygons(void * self, const KX_PYATTRIBUTE_DEF * attrdef);
};
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_MouseFocusSensor.cpp b/source/gameengine/Ketsji/KX_MouseFocusSensor.cpp
index bfee124d443..3251cc4af46 100644
--- a/source/gameengine/Ketsji/KX_MouseFocusSensor.cpp
+++ b/source/gameengine/Ketsji/KX_MouseFocusSensor.cpp
@@ -239,7 +239,7 @@ bool KX_MouseFocusSensor::ParentObjectHasFocusCamera(KX_Camera *cam)
/* build the from and to point in normalized device coordinates
* Normalized device coordinates are [-1,1] in x, y, z
- *
+ *
* The actual z coordinates used don't have to be exact just infront and
* behind of the near and far clip planes.
*/
@@ -392,19 +392,19 @@ PyAttributeDef KX_MouseFocusSensor::Attributes[] = {
};
/* Attributes */
-PyObject* KX_MouseFocusSensor::pyattr_get_ray_source(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_ray_source(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
return PyObjectFrom(self->RaySource());
}
-PyObject* KX_MouseFocusSensor::pyattr_get_ray_target(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_ray_target(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
return PyObjectFrom(self->RayTarget());
}
-PyObject* KX_MouseFocusSensor::pyattr_get_ray_direction(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_ray_direction(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
MT_Vector3 dir = self->RayTarget() - self->RaySource();
@@ -413,7 +413,7 @@ PyObject* KX_MouseFocusSensor::pyattr_get_ray_direction(void *self_v, const KX_P
return PyObjectFrom(dir);
}
-PyObject* KX_MouseFocusSensor::pyattr_get_hit_object(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_hit_object(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
@@ -423,19 +423,19 @@ PyObject* KX_MouseFocusSensor::pyattr_get_hit_object(void *self_v, const KX_PYAT
Py_RETURN_NONE;
}
-PyObject* KX_MouseFocusSensor::pyattr_get_hit_position(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_hit_position(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
return PyObjectFrom(self->HitPosition());
}
-PyObject* KX_MouseFocusSensor::pyattr_get_hit_normal(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_hit_normal(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
return PyObjectFrom(self->HitNormal());
}
-PyObject* KX_MouseFocusSensor::pyattr_get_hit_uv(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_MouseFocusSensor::pyattr_get_hit_uv(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_MouseFocusSensor* self= static_cast<KX_MouseFocusSensor*>(self_v);
return PyObjectFrom(self->HitUV());
diff --git a/source/gameengine/Ketsji/KX_NavMeshObject.cpp b/source/gameengine/Ketsji/KX_NavMeshObject.cpp
index 35058e5fe5d..a05292f268a 100644
--- a/source/gameengine/Ketsji/KX_NavMeshObject.cpp
+++ b/source/gameengine/Ketsji/KX_NavMeshObject.cpp
@@ -210,7 +210,7 @@ bool KX_NavMeshObject::BuildVertIndArrays(float *&vertices, int& nverts,
{
//detailed mesh vertex
memcpy(dvertices+3*(newIdx-nverts), allVerts+3*vi, 3*sizeof(float));
- }
+ }
}
}
@@ -245,7 +245,7 @@ bool KX_NavMeshObject::BuildVertIndArrays(float *&vertices, int& nverts,
{
memset(vert, 0, 3*sizeof(float)); //vertex isn't in any poly, set dummy zero coordinates
}
- vert+=3;
+ vert+=3;
}
//create tris
@@ -294,7 +294,7 @@ bool KX_NavMeshObject::BuildNavMesh()
float *vertices = NULL, *dvertices = NULL;
unsigned short *polys = NULL, *dtris = NULL, *dmeshes = NULL;
- int nverts = 0, npolys = 0, ndvertsuniq = 0, ndtris = 0;
+ int nverts = 0, npolys = 0, ndvertsuniq = 0, ndtris = 0;
int vertsPerPoly = 0;
if (!BuildVertIndArrays(vertices, nverts, polys, npolys,
dmeshes, dvertices, ndvertsuniq, dtris, ndtris, vertsPerPoly )
@@ -446,11 +446,11 @@ bool KX_NavMeshObject::BuildNavMesh()
dtl.nverts = dmeshes[i*4+1];
dtl.tbase = dmeshes[i*4+2];
dtl.ntris = dmeshes[i*4+3];
- }
+ }
}
m_navMesh = new dtStatNavMesh;
- m_navMesh->init(data, dataSize, true);
+ m_navMesh->init(data, dataSize, true);
delete [] vertices;
@@ -487,7 +487,7 @@ void KX_NavMeshObject::DrawNavMesh(NavMeshRenderMode renderMode)
const dtStatPoly* poly = m_navMesh->getPoly(pi);
for (int i = 0, j = (int)poly->nv-1; i < (int)poly->nv; j = i++)
- {
+ {
if (poly->n[j] && renderMode==RM_WALLS)
continue;
const float* vif = m_navMesh->getVertex(poly->v[i]);
@@ -564,7 +564,7 @@ int KX_NavMeshObject::FindPath(const MT_Point3& from, const MT_Point3& to, float
if (!m_navMesh)
return 0;
MT_Point3 localfrom = TransformToLocalCoords(from);
- MT_Point3 localto = TransformToLocalCoords(to);
+ MT_Point3 localto = TransformToLocalCoords(to);
float spos[3], epos[3];
localfrom.getValue(spos); flipAxes(spos);
localto.getValue(epos); flipAxes(epos);
@@ -598,7 +598,7 @@ float KX_NavMeshObject::Raycast(const MT_Point3& from, const MT_Point3& to)
if (!m_navMesh)
return 0.f;
MT_Point3 localfrom = TransformToLocalCoords(from);
- MT_Point3 localto = TransformToLocalCoords(to);
+ MT_Point3 localto = TransformToLocalCoords(to);
float spos[3], epos[3];
localfrom.getValue(spos); flipAxes(spos);
localto.getValue(epos); flipAxes(epos);
diff --git a/source/gameengine/Ketsji/KX_ObjectActuator.cpp b/source/gameengine/Ketsji/KX_ObjectActuator.cpp
index a3f098c3b1f..f35090f9e9b 100644
--- a/source/gameengine/Ketsji/KX_ObjectActuator.cpp
+++ b/source/gameengine/Ketsji/KX_ObjectActuator.cpp
@@ -460,7 +460,7 @@ Mathutils_Callback mathutils_obactu_vector_cb = {
mathutils_obactu_vector_set_index
};
-PyObject* KX_ObjectActuator::pyattr_get_linV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ObjectActuator::pyattr_get_linV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxobactu_vector_cb_index, MATHUTILS_VEC_CB_LINV);
}
@@ -476,7 +476,7 @@ int KX_ObjectActuator::pyattr_set_linV(void *self_v, const KX_PYATTRIBUTE_DEF *a
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_ObjectActuator::pyattr_get_angV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ObjectActuator::pyattr_get_angV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
return Vector_CreatePyObject_cb(BGE_PROXY_FROM_REF(self_v), 3, mathutils_kxobactu_vector_cb_index, MATHUTILS_VEC_CB_ANGV);
}
@@ -501,7 +501,7 @@ void KX_ObjectActuator_Mathutils_Callback_Init(void)
#endif // USE_MATHUTILS
-PyObject* KX_ObjectActuator::pyattr_get_forceLimitX(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ObjectActuator::pyattr_get_forceLimitX(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ObjectActuator* self = reinterpret_cast<KX_ObjectActuator*>(self_v);
PyObject *retVal = PyList_New(3);
@@ -517,7 +517,7 @@ int KX_ObjectActuator::pyattr_set_forceLimitX(void *self_v, const KX_PYATTRIBUTE
{
KX_ObjectActuator* self = reinterpret_cast<KX_ObjectActuator*>(self_v);
- PyObject* seq = PySequence_Fast(value, "");
+ PyObject *seq = PySequence_Fast(value, "");
if (seq && PySequence_Fast_GET_SIZE(seq) == 3)
{
self->m_drot[0] = PyFloat_AsDouble(PySequence_Fast_GET_ITEM(value, 0));
@@ -537,7 +537,7 @@ int KX_ObjectActuator::pyattr_set_forceLimitX(void *self_v, const KX_PYATTRIBUTE
return PY_SET_ATTR_FAIL;
}
-PyObject* KX_ObjectActuator::pyattr_get_forceLimitY(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ObjectActuator::pyattr_get_forceLimitY(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ObjectActuator* self = reinterpret_cast<KX_ObjectActuator*>(self_v);
PyObject *retVal = PyList_New(3);
@@ -553,7 +553,7 @@ int KX_ObjectActuator::pyattr_set_forceLimitY(void *self_v, const KX_PYATTRIBUTE
{
KX_ObjectActuator* self = reinterpret_cast<KX_ObjectActuator*>(self_v);
- PyObject* seq = PySequence_Fast(value, "");
+ PyObject *seq = PySequence_Fast(value, "");
if (seq && PySequence_Fast_GET_SIZE(seq) == 3)
{
self->m_drot[1] = PyFloat_AsDouble(PySequence_Fast_GET_ITEM(value, 0));
@@ -573,7 +573,7 @@ int KX_ObjectActuator::pyattr_set_forceLimitY(void *self_v, const KX_PYATTRIBUTE
return PY_SET_ATTR_FAIL;
}
-PyObject* KX_ObjectActuator::pyattr_get_forceLimitZ(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ObjectActuator::pyattr_get_forceLimitZ(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ObjectActuator* self = reinterpret_cast<KX_ObjectActuator*>(self_v);
PyObject *retVal = PyList_New(3);
@@ -589,7 +589,7 @@ int KX_ObjectActuator::pyattr_set_forceLimitZ(void *self_v, const KX_PYATTRIBUTE
{
KX_ObjectActuator* self = reinterpret_cast<KX_ObjectActuator*>(self_v);
- PyObject* seq = PySequence_Fast(value, "");
+ PyObject *seq = PySequence_Fast(value, "");
if (seq && PySequence_Fast_GET_SIZE(seq) == 3)
{
self->m_drot[2] = PyFloat_AsDouble(PySequence_Fast_GET_ITEM(value, 0));
@@ -609,7 +609,7 @@ int KX_ObjectActuator::pyattr_set_forceLimitZ(void *self_v, const KX_PYATTRIBUTE
return PY_SET_ATTR_FAIL;
}
-PyObject* KX_ObjectActuator::pyattr_get_reference(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ObjectActuator::pyattr_get_reference(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ObjectActuator* actuator = static_cast<KX_ObjectActuator*>(self);
if (!actuator->m_reference)
@@ -632,7 +632,7 @@ int KX_ObjectActuator::pyattr_set_reference(void *self, const struct KX_PYATTRIB
if (refOb==NULL) {
actuator->m_reference= NULL;
}
- else {
+ else {
actuator->m_reference = refOb;
actuator->m_reference->RegisterActuator(actuator);
}
diff --git a/source/gameengine/Ketsji/KX_ObstacleSimulation.cpp b/source/gameengine/Ketsji/KX_ObstacleSimulation.cpp
index a942f87856c..99d9fc7f9ee 100644
--- a/source/gameengine/Ketsji/KX_ObstacleSimulation.cpp
+++ b/source/gameengine/Ketsji/KX_ObstacleSimulation.cpp
@@ -257,7 +257,7 @@ void KX_ObstacleSimulation::AddObstacleForObj(KX_GameObject* gameobj)
}
void KX_ObstacleSimulation::AddObstaclesForNavMesh(KX_NavMeshObject* navmeshobj)
-{
+{
dtStatNavMesh* navmesh = navmeshobj->GetNavMesh();
if (navmesh)
{
@@ -267,7 +267,7 @@ void KX_ObstacleSimulation::AddObstaclesForNavMesh(KX_NavMeshObject* navmeshobj)
const dtStatPoly* poly = navmesh->getPoly(pi);
for (int i = 0, j = (int)poly->nv-1; i < (int)poly->nv; j = i++)
- {
+ {
if (poly->n[j]) continue;
const float* vj = navmesh->getVertex(poly->v[j]);
const float* vi = navmesh->getVertex(poly->v[i]);
@@ -364,9 +364,9 @@ void KX_ObstacleSimulation::DrawObstacles()
else if (m_obstacles[i]->m_shape==KX_OBSTACLE_CIRCLE)
{
KX_RasterizerDrawDebugCircle(m_obstacles[i]->m_pos, m_obstacles[i]->m_rad, bluecolor,
- normal, SECTORS_NUM);
+ normal, SECTORS_NUM);
}
- }
+ }
}
static MT_Point3 nearestPointToObstacle(MT_Point3& pos ,KX_Obstacle* obstacle)
@@ -424,7 +424,7 @@ KX_ObstacleSimulationTOI::KX_ObstacleSimulationTOI(MT_Scalar levelHeight, bool e
void KX_ObstacleSimulationTOI::AdjustObstacleVelocity(KX_Obstacle* activeObst, KX_NavMeshObject* activeNavMeshObj,
- MT_Vector3& velocity, MT_Scalar maxDeltaSpeed, MT_Scalar maxDeltaAngle)
+ MT_Vector3& velocity, MT_Scalar maxDeltaSpeed, MT_Scalar maxDeltaAngle)
{
int nobs = m_obstacles.size();
int obstidx = std::find(m_obstacles.begin(), m_obstacles.end(), activeObst) - m_obstacles.begin();
@@ -446,7 +446,7 @@ void KX_ObstacleSimulationTOI::AdjustObstacleVelocity(KX_Obstacle* activeObst, K
vadd(vel, activeObst->vel, dv);
velocity.x() = vel[0];
- velocity.y() = vel[1];
+ velocity.y() = vel[1];
}
///////////*********TOI_rays**********/////////////////
@@ -642,7 +642,7 @@ static void processSamples(KX_Obstacle* activeObst, KX_NavMeshObject* activeNavM
for (int n = 0; n < nspos; ++n)
{
float vcand[2];
- vcpy(vcand, &spos[n*2]);
+ vcpy(vcand, &spos[n*2]);
// Find min time of impact and exit amongst all obstacles.
float tmin = maxToi;
diff --git a/source/gameengine/Ketsji/KX_ObstacleSimulation.h b/source/gameengine/Ketsji/KX_ObstacleSimulation.h
index 5b359fc031e..50589b5bc69 100644
--- a/source/gameengine/Ketsji/KX_ObstacleSimulation.h
+++ b/source/gameengine/Ketsji/KX_ObstacleSimulation.h
@@ -34,13 +34,13 @@ class KX_GameObject;
class KX_NavMeshObject;
enum KX_OBSTACLE_TYPE
-{
+{
KX_OBSTACLE_OBJ,
KX_OBSTACLE_NAV_MESH,
};
enum KX_OBSTACLE_SHAPE
-{
+{
KX_OBSTACLE_CIRCLE,
KX_OBSTACLE_SEGMENT,
};
@@ -86,9 +86,9 @@ public:
void DestroyObstacleForObj(KX_GameObject* gameobj);
void AddObstaclesForNavMesh(KX_NavMeshObject* navmesh);
KX_Obstacle* GetObstacle(KX_GameObject* gameobj);
- void UpdateObstacles();
+ void UpdateObstacles();
virtual void AdjustObstacleVelocity(KX_Obstacle* activeObst, KX_NavMeshObject* activeNavMeshObj,
- MT_Vector3& velocity, MT_Scalar maxDeltaSpeed,MT_Scalar maxDeltaAngle);
+ MT_Vector3& velocity, MT_Scalar maxDeltaSpeed,MT_Scalar maxDeltaAngle);
};
class KX_ObstacleSimulationTOI: public KX_ObstacleSimulation
diff --git a/source/gameengine/Ketsji/KX_ParentActuator.cpp b/source/gameengine/Ketsji/KX_ParentActuator.cpp
index 5058af18d15..6926fdb1d4c 100644
--- a/source/gameengine/Ketsji/KX_ParentActuator.cpp
+++ b/source/gameengine/Ketsji/KX_ParentActuator.cpp
@@ -172,10 +172,10 @@ PyAttributeDef KX_ParentActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_ParentActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_ParentActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_ParentActuator* actuator = static_cast<KX_ParentActuator*>(self);
- if (!actuator->m_ob)
+ if (!actuator->m_ob)
Py_RETURN_NONE;
else
return actuator->m_ob->GetProxy();
@@ -190,7 +190,7 @@ int KX_ParentActuator::pyattr_set_object(void *self, const struct KX_PYATTRIBUTE
return PY_SET_ATTR_FAIL; // ConvertPythonToGameObject sets the error
if (actuator->m_ob != NULL)
- actuator->m_ob->UnregisterActuator(actuator);
+ actuator->m_ob->UnregisterActuator(actuator);
actuator->m_ob = (SCA_IObject*) gameobj;
diff --git a/source/gameengine/Ketsji/KX_ParentActuator.h b/source/gameengine/Ketsji/KX_ParentActuator.h
index 6191b889da3..f2f5acd3dfb 100644
--- a/source/gameengine/Ketsji/KX_ParentActuator.h
+++ b/source/gameengine/Ketsji/KX_ParentActuator.h
@@ -81,7 +81,7 @@ public:
/* --------------------------------------------------------------------- */
/* These are used to get and set m_ob */
- static PyObject* pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_PhysicsObjectWrapper.cpp b/source/gameengine/Ketsji/KX_PhysicsObjectWrapper.cpp
index 225a1628b3b..f18c35c0c78 100644
--- a/source/gameengine/Ketsji/KX_PhysicsObjectWrapper.cpp
+++ b/source/gameengine/Ketsji/KX_PhysicsObjectWrapper.cpp
@@ -51,7 +51,7 @@ KX_PhysicsObjectWrapper::~KX_PhysicsObjectWrapper()
#ifdef WITH_PYTHON
-PyObject* KX_PhysicsObjectWrapper::PySetPosition(PyObject* args)
+PyObject *KX_PhysicsObjectWrapper::PySetPosition(PyObject *args)
{
float x,y,z;
if (PyArg_ParseTuple(args,"fff:setPosition",&x,&y,&z))
@@ -65,7 +65,7 @@ PyObject* KX_PhysicsObjectWrapper::PySetPosition(PyObject* args)
}
-PyObject* KX_PhysicsObjectWrapper::PySetLinearVelocity(PyObject* args)
+PyObject *KX_PhysicsObjectWrapper::PySetLinearVelocity(PyObject *args)
{
float x,y,z;
int local;
@@ -79,7 +79,7 @@ PyObject* KX_PhysicsObjectWrapper::PySetLinearVelocity(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_PhysicsObjectWrapper::PySetAngularVelocity(PyObject* args)
+PyObject *KX_PhysicsObjectWrapper::PySetAngularVelocity(PyObject *args)
{
float x,y,z;
int local;
@@ -93,7 +93,7 @@ PyObject* KX_PhysicsObjectWrapper::PySetAngularVelocity(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_PhysicsObjectWrapper::PySetActive(PyObject* args)
+PyObject* KX_PhysicsObjectWrapper::PySetActive(PyObject *args)
{
int active;
if (PyArg_ParseTuple(args,"i:setActive",&active))
diff --git a/source/gameengine/Ketsji/KX_PolyProxy.cpp b/source/gameengine/Ketsji/KX_PolyProxy.cpp
index 85c88337d60..13b6bda4ebc 100644
--- a/source/gameengine/Ketsji/KX_PolyProxy.cpp
+++ b/source/gameengine/Ketsji/KX_PolyProxy.cpp
@@ -102,7 +102,7 @@ KX_PolyProxy::~KX_PolyProxy()
// stuff for cvalue related things
CValue* KX_PolyProxy::Calc(VALUE_OPERATOR, CValue *) { return NULL;}
-CValue* KX_PolyProxy::CalcFinal(VALUE_DATA_TYPE, VALUE_OPERATOR, CValue *) { return NULL;}
+CValue* KX_PolyProxy::CalcFinal(VALUE_DATA_TYPE, VALUE_OPERATOR, CValue *) { return NULL;}
STR_String sPolyName="polygone";
const STR_String & KX_PolyProxy::GetText() {return sPolyName;};
double KX_PolyProxy::GetNumber() { return -1;}
@@ -112,52 +112,52 @@ CValue* KX_PolyProxy::GetReplica() { return NULL;}
// stuff for python integration
-PyObject* KX_PolyProxy::pyattr_get_material_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_material_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return self->PygetMaterialName();
}
-PyObject* KX_PolyProxy::pyattr_get_texture_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_texture_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return self->PygetTextureName();
}
-PyObject* KX_PolyProxy::pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return self->PygetMaterial();
}
-PyObject* KX_PolyProxy::pyattr_get_material_id(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_material_id(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return self->PygetMaterialIndex();
}
-PyObject* KX_PolyProxy::pyattr_get_v1(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_v1(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return PyLong_FromSsize_t(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 0));
}
-PyObject* KX_PolyProxy::pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return PyLong_FromSsize_t(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 1));
}
-PyObject* KX_PolyProxy::pyattr_get_v3(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_v3(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return PyLong_FromSsize_t(self->m_polygon->GetVertexOffsetAbs(self->m_mesh, 2));
}
-PyObject* KX_PolyProxy::pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
@@ -168,13 +168,13 @@ PyObject* KX_PolyProxy::pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *at
return PyLong_FromSsize_t(0);
}
-PyObject* KX_PolyProxy::pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return self->PyisVisible();
}
-PyObject* KX_PolyProxy::pyattr_get_collide(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolyProxy::pyattr_get_collide(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolyProxy* self= static_cast<KX_PolyProxy*>(self_v);
return self->PyisCollider();
diff --git a/source/gameengine/Ketsji/KX_PolyProxy.h b/source/gameengine/Ketsji/KX_PolyProxy.h
index 83c3bff0ee2..9e3556a03f8 100644
--- a/source/gameengine/Ketsji/KX_PolyProxy.h
+++ b/source/gameengine/Ketsji/KX_PolyProxy.h
@@ -57,16 +57,16 @@ public:
// stuff for python integration
- static PyObject* pyattr_get_material_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_texture_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_material_id(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_v1(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_v3(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_collide(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_material_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_texture_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_material_id(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_v1(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_v3(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_v4(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_visible(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_collide(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
KX_PYMETHOD_DOC_NOARGS(KX_PolyProxy,getMaterialIndex)
KX_PYMETHOD_DOC_NOARGS(KX_PolyProxy,getNumVertex)
diff --git a/source/gameengine/Ketsji/KX_PolygonMaterial.cpp b/source/gameengine/Ketsji/KX_PolygonMaterial.cpp
index 2e39190f4f9..3b58a8abd83 100644
--- a/source/gameengine/Ketsji/KX_PolygonMaterial.cpp
+++ b/source/gameengine/Ketsji/KX_PolygonMaterial.cpp
@@ -143,7 +143,7 @@ bool KX_PolygonMaterial::Activate(RAS_IRasterizer* rasty, TCachingInfo& cachingI
{
PyObject *pyRasty = PyCapsule_New((void*)rasty, KX_POLYGONMATERIAL_CAPSULE_ID, NULL); /* new reference */
PyObject *pyCachingInfo = PyCapsule_New((void*) &cachingInfo, KX_POLYGONMATERIAL_CAPSULE_ID, NULL); /* new reference */
- PyObject *ret = PyObject_CallMethod(m_pymaterial, (char *)"activate", (char *)"(NNO)", pyRasty, pyCachingInfo, (PyObject*) this->m_proxy);
+ PyObject *ret = PyObject_CallMethod(m_pymaterial, (char *)"activate", (char *)"(NNO)", pyRasty, pyCachingInfo, (PyObject *) this->m_proxy);
if (ret)
{
bool value = PyLong_AsSsize_t(ret);
@@ -252,7 +252,7 @@ PyAttributeDef KX_PolygonMaterial::Attributes[] = {
KX_PYATTRIBUTE_INT_RW("tile", INT_MIN, INT_MAX, true, KX_PolygonMaterial, m_tile),
KX_PYATTRIBUTE_INT_RW("tilexrep", INT_MIN, INT_MAX, true, KX_PolygonMaterial, m_tilexrep),
KX_PYATTRIBUTE_INT_RW("tileyrep", INT_MIN, INT_MAX, true, KX_PolygonMaterial, m_tileyrep),
- KX_PYATTRIBUTE_INT_RW("drawingmode", INT_MIN, INT_MAX, true, KX_PolygonMaterial, m_drawingmode),
+ KX_PYATTRIBUTE_INT_RW("drawingmode", INT_MIN, INT_MAX, true, KX_PolygonMaterial, m_drawingmode),
//KX_PYATTRIBUTE_INT_RW("lightlayer", INT_MIN, INT_MAX, true, KX_PolygonMaterial, m_lightlayer),
KX_PYATTRIBUTE_BOOL_RW("transparent", KX_PolygonMaterial, m_alpha),
@@ -262,7 +262,7 @@ PyAttributeDef KX_PolygonMaterial::Attributes[] = {
KX_PYATTRIBUTE_FLOAT_RW("specularity", 0.0f, 1000.0f, KX_PolygonMaterial, m_specularity),
KX_PYATTRIBUTE_RW_FUNCTION("diffuse", KX_PolygonMaterial, pyattr_get_diffuse, pyattr_set_diffuse),
- KX_PYATTRIBUTE_RW_FUNCTION("specular",KX_PolygonMaterial, pyattr_get_specular, pyattr_set_specular),
+ KX_PYATTRIBUTE_RW_FUNCTION("specular",KX_PolygonMaterial, pyattr_get_specular, pyattr_set_specular),
KX_PYATTRIBUTE_RO_FUNCTION("tface", KX_PolygonMaterial, pyattr_get_tface), /* How the heck is this even useful??? - Campbell */
KX_PYATTRIBUTE_RO_FUNCTION("gl_texture", KX_PolygonMaterial, pyattr_get_gl_texture), /* could be called 'bindcode' */
@@ -355,26 +355,26 @@ KX_PYMETHODDEF_DOC(KX_PolygonMaterial, activate, "activate(rasty, cachingInfo)")
return NULL;
}
-PyObject* KX_PolygonMaterial::pyattr_get_texture(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolygonMaterial::pyattr_get_texture(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolygonMaterial* self= static_cast<KX_PolygonMaterial*>(self_v);
return PyUnicode_From_STR_String(self->m_texturename);
}
-PyObject* KX_PolygonMaterial::pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolygonMaterial::pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolygonMaterial* self= static_cast<KX_PolygonMaterial*>(self_v);
return PyUnicode_From_STR_String(self->m_materialname);
}
/* this does not seem useful */
-PyObject* KX_PolygonMaterial::pyattr_get_tface(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolygonMaterial::pyattr_get_tface(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolygonMaterial* self= static_cast<KX_PolygonMaterial*>(self_v);
return PyCapsule_New(&self->m_tface, KX_POLYGONMATERIAL_CAPSULE_ID, NULL);
}
-PyObject* KX_PolygonMaterial::pyattr_get_gl_texture(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolygonMaterial::pyattr_get_gl_texture(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolygonMaterial* self= static_cast<KX_PolygonMaterial*>(self_v);
int bindcode= 0;
@@ -385,7 +385,7 @@ PyObject* KX_PolygonMaterial::pyattr_get_gl_texture(void *self_v, const KX_PYATT
}
-PyObject* KX_PolygonMaterial::pyattr_get_diffuse(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolygonMaterial::pyattr_get_diffuse(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolygonMaterial* self= static_cast<KX_PolygonMaterial*>(self_v);
return PyObjectFrom(self->m_diffuse);
@@ -403,7 +403,7 @@ int KX_PolygonMaterial::pyattr_set_diffuse(void *self_v, const KX_PYATTRIBUTE_DE
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_PolygonMaterial::pyattr_get_specular(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_PolygonMaterial::pyattr_get_specular(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_PolygonMaterial* self= static_cast<KX_PolygonMaterial*>(self_v);
return PyObjectFrom(self->m_specular);
diff --git a/source/gameengine/Ketsji/KX_PolygonMaterial.h b/source/gameengine/Ketsji/KX_PolygonMaterial.h
index f7ad3973212..6384008fb7d 100644
--- a/source/gameengine/Ketsji/KX_PolygonMaterial.h
+++ b/source/gameengine/Ketsji/KX_PolygonMaterial.h
@@ -137,7 +137,7 @@ public:
KX_PYMETHOD_DOC(KX_PolygonMaterial, setCustomMaterial);
KX_PYMETHOD_DOC(KX_PolygonMaterial, loadProgram);
- virtual PyObject* py_repr(void) { return PyUnicode_FromString(m_material ? ((ID *)m_material)->name+2 : ""); }
+ virtual PyObject *py_repr(void) { return PyUnicode_FromString(m_material ? ((ID *)m_material)->name+2 : ""); }
static PyObject* pyattr_get_texture(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static PyObject* pyattr_get_material(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
@@ -145,9 +145,9 @@ public:
static PyObject* pyattr_get_tface(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static PyObject* pyattr_get_gl_texture(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_diffuse(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject* pyattr_get_diffuse(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_diffuse(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- static PyObject* pyattr_get_specular(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject* pyattr_get_specular(void* self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_specular(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif
diff --git a/source/gameengine/Ketsji/KX_PyConstraintBinding.cpp b/source/gameengine/Ketsji/KX_PyConstraintBinding.cpp
index 6fb315d51cb..5f3a4879150 100644
--- a/source/gameengine/Ketsji/KX_PyConstraintBinding.cpp
+++ b/source/gameengine/Ketsji/KX_PyConstraintBinding.cpp
@@ -89,9 +89,9 @@ static char gPyGetAppliedImpulse__doc__[] = "getAppliedImpulse(int constraintId)
-static PyObject* gPySetGravity(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetGravity(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float x,y,z;
if (PyArg_ParseTuple(args,"fff",&x,&y,&z))
@@ -106,9 +106,9 @@ static PyObject* gPySetGravity(PyObject* self,
Py_RETURN_NONE;
}
-static PyObject* gPySetDebugMode(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetDebugMode(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
int mode;
if (PyArg_ParseTuple(args,"i",&mode))
@@ -129,9 +129,9 @@ static PyObject* gPySetDebugMode(PyObject* self,
-static PyObject* gPySetNumTimeSubSteps(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetNumTimeSubSteps(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
int substep;
if (PyArg_ParseTuple(args,"i",&substep))
@@ -148,9 +148,9 @@ static PyObject* gPySetNumTimeSubSteps(PyObject* self,
}
-static PyObject* gPySetNumIterations(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetNumIterations(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
int iter;
if (PyArg_ParseTuple(args,"i",&iter))
@@ -167,9 +167,9 @@ static PyObject* gPySetNumIterations(PyObject* self,
}
-static PyObject* gPySetDeactivationTime(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetDeactivationTime(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float deactive_time;
if (PyArg_ParseTuple(args,"f",&deactive_time))
@@ -186,9 +186,9 @@ static PyObject* gPySetDeactivationTime(PyObject* self,
}
-static PyObject* gPySetDeactivationLinearTreshold(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetDeactivationLinearTreshold(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float linearDeactivationTreshold;
if (PyArg_ParseTuple(args,"f",&linearDeactivationTreshold))
@@ -205,9 +205,9 @@ static PyObject* gPySetDeactivationLinearTreshold(PyObject* self,
}
-static PyObject* gPySetDeactivationAngularTreshold(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetDeactivationAngularTreshold(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float angularDeactivationTreshold;
if (PyArg_ParseTuple(args,"f",&angularDeactivationTreshold))
@@ -223,9 +223,9 @@ static PyObject* gPySetDeactivationAngularTreshold(PyObject* self,
Py_RETURN_NONE;
}
-static PyObject* gPySetContactBreakingTreshold(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetContactBreakingTreshold(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float contactBreakingTreshold;
if (PyArg_ParseTuple(args,"f",&contactBreakingTreshold))
@@ -242,9 +242,9 @@ static PyObject* gPySetContactBreakingTreshold(PyObject* self,
}
-static PyObject* gPySetCcdMode(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetCcdMode(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float ccdMode;
if (PyArg_ParseTuple(args,"f",&ccdMode))
@@ -260,9 +260,9 @@ static PyObject* gPySetCcdMode(PyObject* self,
Py_RETURN_NONE;
}
-static PyObject* gPySetSorConstant(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetSorConstant(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float sor;
if (PyArg_ParseTuple(args,"f",&sor))
@@ -278,9 +278,9 @@ static PyObject* gPySetSorConstant(PyObject* self,
Py_RETURN_NONE;
}
-static PyObject* gPySetSolverTau(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetSolverTau(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float tau;
if (PyArg_ParseTuple(args,"f",&tau))
@@ -297,9 +297,9 @@ static PyObject* gPySetSolverTau(PyObject* self,
}
-static PyObject* gPySetSolverDamping(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetSolverDamping(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float damping;
if (PyArg_ParseTuple(args,"f",&damping))
@@ -315,9 +315,9 @@ static PyObject* gPySetSolverDamping(PyObject* self,
Py_RETURN_NONE;
}
-static PyObject* gPySetLinearAirDamping(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetLinearAirDamping(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float damping;
if (PyArg_ParseTuple(args,"f",&damping))
@@ -334,9 +334,9 @@ static PyObject* gPySetLinearAirDamping(PyObject* self,
}
-static PyObject* gPySetUseEpa(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetUseEpa(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
int epa;
if (PyArg_ParseTuple(args,"i",&epa))
@@ -351,9 +351,9 @@ static PyObject* gPySetUseEpa(PyObject* self,
}
Py_RETURN_NONE;
}
-static PyObject* gPySetSolverType(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPySetSolverType(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
int solverType;
if (PyArg_ParseTuple(args,"i",&solverType))
@@ -371,9 +371,9 @@ static PyObject* gPySetSolverType(PyObject* self,
-static PyObject* gPyGetVehicleConstraint(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPyGetVehicleConstraint(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
#if defined(_WIN64)
__int64 constraintid;
@@ -403,9 +403,9 @@ static PyObject* gPyGetVehicleConstraint(PyObject* self,
}
-static PyObject* gPyCreateConstraint(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPyCreateConstraint(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
/* FIXME - physicsid is a long being cast to a pointer, should at least use PyCapsule */
#if defined(_WIN64)
@@ -435,7 +435,7 @@ static PyObject* gPyCreateConstraint(PyObject* self,
#else
success = PyArg_ParseTuple(args,"llifff",&physicsid,&physicsid2,&constrainttype,
&pivotX,&pivotY,&pivotZ);
-#endif
+#endif
}
else if (len == 9)
{
@@ -521,9 +521,9 @@ static PyObject* gPyCreateConstraint(PyObject* self,
-static PyObject* gPyGetAppliedImpulse(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPyGetAppliedImpulse(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
float appliedImpulse = 0.f;
@@ -548,9 +548,9 @@ static PyObject* gPyGetAppliedImpulse(PyObject* self,
}
-static PyObject* gPyRemoveConstraint(PyObject* self,
- PyObject* args,
- PyObject* kwds)
+static PyObject *gPyRemoveConstraint(PyObject *self,
+ PyObject *args,
+ PyObject *kwds)
{
#if defined(_WIN64)
__int64 constraintid;
@@ -572,7 +572,7 @@ static PyObject* gPyRemoveConstraint(PyObject* self,
Py_RETURN_NONE;
}
-static PyObject* gPyExportBulletFile(PyObject*, PyObject* args)
+static PyObject *gPyExportBulletFile(PyObject *, PyObject *args)
{
char* filename;
if (!PyArg_ParseTuple(args,"s:exportBulletFile",&filename))
@@ -655,13 +655,13 @@ static struct PyModuleDef PhysicsConstraints_module_def = {
0, /* m_free */
};
-PyObject* initPythonConstraintBinding()
+PyObject *initPythonConstraintBinding()
{
- PyObject* ErrorObject;
- PyObject* m;
- PyObject* d;
- PyObject* item;
+ PyObject *ErrorObject;
+ PyObject *m;
+ PyObject *d;
+ PyObject *item;
/* Use existing module where possible
* be careful not to init any runtime vars after this */
diff --git a/source/gameengine/Ketsji/KX_PyMath.cpp b/source/gameengine/Ketsji/KX_PyMath.cpp
index f459b806d2f..bc324c3b140 100644
--- a/source/gameengine/Ketsji/KX_PyMath.cpp
+++ b/source/gameengine/Ketsji/KX_PyMath.cpp
@@ -47,7 +47,7 @@
#include "KX_Python.h"
#include "KX_PyMath.h"
-bool PyOrientationTo(PyObject* pyval, MT_Matrix3x3 &rot, const char *error_prefix)
+bool PyOrientationTo(PyObject *pyval, MT_Matrix3x3 &rot, const char *error_prefix)
{
int size= PySequence_Size(pyval);
@@ -80,7 +80,7 @@ bool PyOrientationTo(PyObject* pyval, MT_Matrix3x3 &rot, const char *error_prefi
return false;
}
-bool PyQuatTo(PyObject* pyval, MT_Quaternion &qrot)
+bool PyQuatTo(PyObject *pyval, MT_Quaternion &qrot)
{
if (!PyVecTo(pyval, qrot))
return false;
@@ -95,7 +95,7 @@ bool PyQuatTo(PyObject* pyval, MT_Quaternion &qrot)
return true;
}
-PyObject* PyObjectFrom(const MT_Matrix4x4 &mat)
+PyObject *PyObjectFrom(const MT_Matrix4x4 &mat)
{
#ifdef USE_MATHUTILS
float fmat[16];
@@ -119,7 +119,7 @@ PyObject* PyObjectFrom(const MT_Matrix4x4 &mat)
#endif
}
-PyObject* PyObjectFrom(const MT_Matrix3x3 &mat)
+PyObject *PyObjectFrom(const MT_Matrix3x3 &mat)
{
#ifdef USE_MATHUTILS
float fmat[9];
@@ -143,7 +143,7 @@ PyObject* PyObjectFrom(const MT_Matrix3x3 &mat)
}
#ifdef USE_MATHUTILS
-PyObject* PyObjectFrom(const MT_Quaternion &qrot)
+PyObject *PyObjectFrom(const MT_Quaternion &qrot)
{
/* NOTE, were re-ordering here for Mathutils compat */
float fvec[4];
@@ -152,7 +152,7 @@ PyObject* PyObjectFrom(const MT_Quaternion &qrot)
}
#endif
-PyObject* PyObjectFrom(const MT_Tuple4 &vec)
+PyObject *PyObjectFrom(const MT_Tuple4 &vec)
{
#ifdef USE_MATHUTILS
float fvec[4];
@@ -168,7 +168,7 @@ PyObject* PyObjectFrom(const MT_Tuple4 &vec)
#endif
}
-PyObject* PyObjectFrom(const MT_Tuple3 &vec)
+PyObject *PyObjectFrom(const MT_Tuple3 &vec)
{
#ifdef USE_MATHUTILS
float fvec[3];
@@ -180,10 +180,10 @@ PyObject* PyObjectFrom(const MT_Tuple3 &vec)
PyList_SET_ITEM(list, 1, PyFloat_FromDouble(vec[1]));
PyList_SET_ITEM(list, 2, PyFloat_FromDouble(vec[2]));
return list;
-#endif
+#endif
}
-PyObject* PyObjectFrom(const MT_Tuple2 &vec)
+PyObject *PyObjectFrom(const MT_Tuple2 &vec)
{
#ifdef USE_MATHUTILS
float fvec[2];
diff --git a/source/gameengine/Ketsji/KX_PyMath.h b/source/gameengine/Ketsji/KX_PyMath.h
index aec871d7700..d79397ed807 100644
--- a/source/gameengine/Ketsji/KX_PyMath.h
+++ b/source/gameengine/Ketsji/KX_PyMath.h
@@ -61,7 +61,7 @@ inline unsigned int Size(const MT_Tuple4&) { return 4; }
* Converts the given python matrix (column-major) to an MT class (row-major).
*/
template<class T>
-bool PyMatTo(PyObject* pymat, T& mat)
+bool PyMatTo(PyObject *pymat, T& mat)
{
bool noerror = true;
mat.setIdentity();
@@ -133,7 +133,7 @@ bool PyMatTo(PyObject* pymat, T& mat)
* Converts a python sequence to a MT class.
*/
template<class T>
-bool PyVecTo(PyObject* pyval, T& vec)
+bool PyVecTo(PyObject *pyval, T& vec)
{
#ifdef USE_MATHUTILS
/* no need for BaseMath_ReadCallback() here, reading the sequences will do this */
@@ -235,41 +235,41 @@ bool PyVecTo(PyObject* pyval, T& vec)
}
-bool PyQuatTo(PyObject* pyval, MT_Quaternion &qrot);
+bool PyQuatTo(PyObject *pyval, MT_Quaternion &qrot);
-bool PyOrientationTo(PyObject* pyval, MT_Matrix3x3 &mat, const char *error_prefix);
+bool PyOrientationTo(PyObject *pyval, MT_Matrix3x3 &mat, const char *error_prefix);
/**
* Converts an MT_Matrix4x4 to a python object.
*/
-PyObject* PyObjectFrom(const MT_Matrix4x4 &mat);
+PyObject *PyObjectFrom(const MT_Matrix4x4 &mat);
/**
* Converts an MT_Matrix3x3 to a python object.
*/
-PyObject* PyObjectFrom(const MT_Matrix3x3 &mat);
+PyObject *PyObjectFrom(const MT_Matrix3x3 &mat);
/**
* Converts an MT_Tuple2 to a python object.
*/
-PyObject* PyObjectFrom(const MT_Tuple2 &vec);
+PyObject *PyObjectFrom(const MT_Tuple2 &vec);
/**
* Converts an MT_Tuple3 to a python object
*/
-PyObject* PyObjectFrom(const MT_Tuple3 &vec);
+PyObject *PyObjectFrom(const MT_Tuple3 &vec);
#ifdef USE_MATHUTILS
/**
* Converts an MT_Quaternion to a python object.
*/
-PyObject* PyObjectFrom(const MT_Quaternion &qrot);
+PyObject *PyObjectFrom(const MT_Quaternion &qrot);
#endif
/**
* Converts an MT_Tuple4 to a python object.
*/
-PyObject* PyObjectFrom(const MT_Tuple4 &pos);
+PyObject *PyObjectFrom(const MT_Tuple4 &pos);
#endif
diff --git a/source/gameengine/Ketsji/KX_PythonInit.cpp b/source/gameengine/Ketsji/KX_PythonInit.cpp
index 7d29a20d1a2..43fca40f2da 100644
--- a/source/gameengine/Ketsji/KX_PythonInit.cpp
+++ b/source/gameengine/Ketsji/KX_PythonInit.cpp
@@ -210,15 +210,15 @@ static PyObject *gp_OrigPythonSysModules= NULL;
#include "SCA_PythonController.h"
// List of methods defined in the module
-static PyObject* ErrorObject;
+static PyObject *ErrorObject;
static const char *gPyGetRandomFloat_doc="getRandomFloat returns a random floating point value in the range [0..1]";
-static PyObject* gPyGetRandomFloat(PyObject*)
+static PyObject *gPyGetRandomFloat(PyObject *)
{
return PyFloat_FromDouble(MT_random());
}
-static PyObject* gPySetGravity(PyObject*, PyObject* value)
+static PyObject *gPySetGravity(PyObject *, PyObject *value)
{
MT_Vector3 vec;
if (!PyVecTo(value, vec))
@@ -240,7 +240,7 @@ file to make a full path name (doesn't change during the game, even if you load\
other .blend).\n\
The function also converts the directory separator to the local file system format.";
-static PyObject* gPyExpandPath(PyObject*, PyObject* args)
+static PyObject *gPyExpandPath(PyObject *, PyObject *args)
{
char expanded[FILE_MAX];
char* filename;
@@ -257,7 +257,7 @@ static char gPyStartGame_doc[] =
"startGame(blend)\n\
Loads the blend file";
-static PyObject* gPyStartGame(PyObject*, PyObject* args)
+static PyObject *gPyStartGame(PyObject *, PyObject *args)
{
char* blendfile;
@@ -274,7 +274,7 @@ static char gPyEndGame_doc[] =
"endGame()\n\
Ends the current game";
-static PyObject* gPyEndGame(PyObject*)
+static PyObject *gPyEndGame(PyObject *)
{
gp_KetsjiEngine->RequestExit(KX_EXIT_REQUEST_QUIT_GAME);
@@ -287,7 +287,7 @@ static char gPyRestartGame_doc[] =
"restartGame()\n\
Restarts the current game by reloading the .blend file";
-static PyObject* gPyRestartGame(PyObject*)
+static PyObject *gPyRestartGame(PyObject *)
{
gp_KetsjiEngine->RequestExit(KX_EXIT_REQUEST_RESTART_GAME);
gp_KetsjiEngine->SetNameNextGame(gp_GamePythonPath);
@@ -299,7 +299,7 @@ static char gPySaveGlobalDict_doc[] =
"saveGlobalDict()\n"
"Saves bge.logic.globalDict to a file";
-static PyObject* gPySaveGlobalDict(PyObject*)
+static PyObject *gPySaveGlobalDict(PyObject *)
{
char marshal_path[512];
char *marshal_buffer = NULL;
@@ -336,7 +336,7 @@ static char gPyLoadGlobalDict_doc[] =
"LoadGlobalDict()\n"
"Loads bge.logic.globalDict from a file";
-static PyObject* gPyLoadGlobalDict(PyObject*)
+static PyObject *gPyLoadGlobalDict(PyObject *)
{
char marshal_path[512];
char *marshal_buffer = NULL;
@@ -381,7 +381,7 @@ body = Message body\
to = Name of object to send the message to\
from = Name of object to send the string from";
-static PyObject* gPySendMessage(PyObject*, PyObject* args)
+static PyObject *gPySendMessage(PyObject *, PyObject *args)
{
char* subject;
char* body = (char *)"";
@@ -397,9 +397,9 @@ static PyObject* gPySendMessage(PyObject*, PyObject* args)
}
// this gets a pointer to an array filled with floats
-static PyObject* gPyGetSpectrum(PyObject*)
+static PyObject *gPyGetSpectrum(PyObject *)
{
- PyObject* resultlist = PyList_New(512);
+ PyObject *resultlist = PyList_New(512);
for (int index = 0; index < 512; index++)
{
@@ -409,7 +409,7 @@ static PyObject* gPyGetSpectrum(PyObject*)
return resultlist;
}
-static PyObject* gPySetLogicTicRate(PyObject*, PyObject* args)
+static PyObject *gPySetLogicTicRate(PyObject *, PyObject *args)
{
float ticrate;
if (!PyArg_ParseTuple(args, "f:setLogicTicRate", &ticrate))
@@ -419,12 +419,12 @@ static PyObject* gPySetLogicTicRate(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetLogicTicRate(PyObject*)
+static PyObject *gPyGetLogicTicRate(PyObject *)
{
return PyFloat_FromDouble(KX_KetsjiEngine::GetTicRate());
}
-static PyObject* gPySetExitKey(PyObject*, PyObject* args)
+static PyObject *gPySetExitKey(PyObject *, PyObject *args)
{
short exitkey;
if (!PyArg_ParseTuple(args, "h:setExitKey", &exitkey))
@@ -433,12 +433,12 @@ static PyObject* gPySetExitKey(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetExitKey(PyObject*)
+static PyObject *gPyGetExitKey(PyObject *)
{
return PyLong_FromSsize_t(KX_KetsjiEngine::GetExitKey());
}
-static PyObject* gPySetMaxLogicFrame(PyObject*, PyObject* args)
+static PyObject *gPySetMaxLogicFrame(PyObject *, PyObject *args)
{
int frame;
if (!PyArg_ParseTuple(args, "i:setMaxLogicFrame", &frame))
@@ -448,12 +448,12 @@ static PyObject* gPySetMaxLogicFrame(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetMaxLogicFrame(PyObject*)
+static PyObject *gPyGetMaxLogicFrame(PyObject *)
{
return PyLong_FromSsize_t(KX_KetsjiEngine::GetMaxLogicFrame());
}
-static PyObject* gPySetMaxPhysicsFrame(PyObject*, PyObject* args)
+static PyObject *gPySetMaxPhysicsFrame(PyObject *, PyObject *args)
{
int frame;
if (!PyArg_ParseTuple(args, "i:setMaxPhysicsFrame", &frame))
@@ -463,12 +463,12 @@ static PyObject* gPySetMaxPhysicsFrame(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetMaxPhysicsFrame(PyObject*)
+static PyObject *gPyGetMaxPhysicsFrame(PyObject *)
{
return PyLong_FromSsize_t(KX_KetsjiEngine::GetMaxPhysicsFrame());
}
-static PyObject* gPySetPhysicsTicRate(PyObject*, PyObject* args)
+static PyObject *gPySetPhysicsTicRate(PyObject *, PyObject *args)
{
float ticrate;
if (!PyArg_ParseTuple(args, "f:setPhysicsTicRate", &ticrate))
@@ -478,7 +478,7 @@ static PyObject* gPySetPhysicsTicRate(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
#if 0 // unused
-static PyObject* gPySetPhysicsDebug(PyObject*, PyObject* args)
+static PyObject *gPySetPhysicsDebug(PyObject *, PyObject *args)
{
int debugMode;
if (!PyArg_ParseTuple(args, "i:setPhysicsDebug", &debugMode))
@@ -490,21 +490,21 @@ static PyObject* gPySetPhysicsDebug(PyObject*, PyObject* args)
#endif
-static PyObject* gPyGetPhysicsTicRate(PyObject*)
+static PyObject *gPyGetPhysicsTicRate(PyObject *)
{
return PyFloat_FromDouble(PHY_GetActiveEnvironment()->getFixedTimeStep());
}
-static PyObject* gPyGetAverageFrameRate(PyObject*)
+static PyObject *gPyGetAverageFrameRate(PyObject *)
{
return PyFloat_FromDouble(KX_KetsjiEngine::GetAverageFrameRate());
}
-static PyObject* gPyGetBlendFileList(PyObject*, PyObject* args)
+static PyObject *gPyGetBlendFileList(PyObject *, PyObject *args)
{
char cpath[sizeof(gp_GamePythonPath)];
char *searchpath = NULL;
- PyObject* list, *value;
+ PyObject *list, *value;
DIR *dp;
struct dirent *dirp;
@@ -545,7 +545,7 @@ static char gPyAddScene_doc[] =
adds a scene to the game engine\n\
name = Name of the scene\n\
overlay = Overlay or underlay";
-static PyObject* gPyAddScene(PyObject*, PyObject* args)
+static PyObject *gPyAddScene(PyObject *, PyObject *args)
{
char* name;
int overlay = 1;
@@ -561,7 +561,7 @@ static PyObject* gPyAddScene(PyObject*, PyObject* args)
static const char *gPyGetCurrentScene_doc =
"getCurrentScene()\n"
"Gets a reference to the current scene.\n";
-static PyObject* gPyGetCurrentScene(PyObject* self)
+static PyObject *gPyGetCurrentScene(PyObject *self)
{
return gp_KetsjiScene->GetProxy();
}
@@ -569,10 +569,10 @@ static PyObject* gPyGetCurrentScene(PyObject* self)
static const char *gPyGetSceneList_doc =
"getSceneList()\n"
"Return a list of converted scenes.\n";
-static PyObject* gPyGetSceneList(PyObject* self)
+static PyObject *gPyGetSceneList(PyObject *self)
{
KX_KetsjiEngine* m_engine = KX_GetActiveEngine();
- PyObject* list;
+ PyObject *list;
KX_SceneList* scenes = m_engine->CurrentScenes();
int numScenes = scenes->size();
int i;
@@ -665,7 +665,7 @@ static PyObject *pyPrintExt(PyObject *,PyObject *,PyObject *)
Py_RETURN_NONE;
}
-static PyObject *gLibLoad(PyObject*, PyObject* args, PyObject* kwds)
+static PyObject *gLibLoad(PyObject *, PyObject *args, PyObject *kwds)
{
KX_Scene *kx_scene= gp_KetsjiScene;
char *path;
@@ -721,7 +721,7 @@ static PyObject *gLibLoad(PyObject*, PyObject* args, PyObject* kwds)
Py_RETURN_FALSE;
}
-static PyObject *gLibNew(PyObject*, PyObject* args)
+static PyObject *gLibNew(PyObject *, PyObject *args)
{
KX_Scene *kx_scene= gp_KetsjiScene;
char *path;
@@ -779,7 +779,7 @@ static PyObject *gLibNew(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject *gLibFree(PyObject*, PyObject* args)
+static PyObject *gLibFree(PyObject *, PyObject *args)
{
KX_Scene *kx_scene= gp_KetsjiScene;
char *path;
@@ -796,7 +796,7 @@ static PyObject *gLibFree(PyObject*, PyObject* args)
}
}
-static PyObject *gLibList(PyObject*, PyObject* args)
+static PyObject *gLibList(PyObject *, PyObject *args)
{
vector<Main*> &dynMaggie = gp_KetsjiScene->GetSceneConverter()->GetMainDynamic();
int i= 0;
@@ -866,14 +866,14 @@ static struct PyMethodDef game_methods[] = {
{NULL, (PyCFunction) NULL, 0, NULL }
};
-static PyObject* gPyGetWindowHeight(PyObject*, PyObject* args)
+static PyObject *gPyGetWindowHeight(PyObject *, PyObject *args)
{
return PyLong_FromSsize_t((gp_Canvas ? gp_Canvas->GetHeight() : 0));
}
-static PyObject* gPyGetWindowWidth(PyObject*, PyObject* args)
+static PyObject *gPyGetWindowWidth(PyObject *, PyObject *args)
{
return PyLong_FromSsize_t((gp_Canvas ? gp_Canvas->GetWidth() : 0));
}
@@ -883,7 +883,7 @@ static PyObject* gPyGetWindowWidth(PyObject*, PyObject* args)
// temporarility visibility thing, will be moved to rasterizer/renderer later
bool gUseVisibilityTemp = false;
-static PyObject* gPyEnableVisibility(PyObject*, PyObject* args)
+static PyObject *gPyEnableVisibility(PyObject *, PyObject *args)
{
int visible;
if (!PyArg_ParseTuple(args,"i:enableVisibility",&visible))
@@ -895,7 +895,7 @@ static PyObject* gPyEnableVisibility(PyObject*, PyObject* args)
-static PyObject* gPyShowMouse(PyObject*, PyObject* args)
+static PyObject *gPyShowMouse(PyObject *, PyObject *args)
{
int visible;
if (!PyArg_ParseTuple(args,"i:showMouse",&visible))
@@ -916,7 +916,7 @@ static PyObject* gPyShowMouse(PyObject*, PyObject* args)
-static PyObject* gPySetMousePosition(PyObject*, PyObject* args)
+static PyObject *gPySetMousePosition(PyObject *, PyObject *args)
{
int x,y;
if (!PyArg_ParseTuple(args,"ii:setMousePosition",&x,&y))
@@ -928,7 +928,7 @@ static PyObject* gPySetMousePosition(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPySetEyeSeparation(PyObject*, PyObject* args)
+static PyObject *gPySetEyeSeparation(PyObject *, PyObject *args)
{
float sep;
if (!PyArg_ParseTuple(args, "f:setEyeSeparation", &sep))
@@ -944,7 +944,7 @@ static PyObject* gPySetEyeSeparation(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetEyeSeparation(PyObject*)
+static PyObject *gPyGetEyeSeparation(PyObject *)
{
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.getEyeSeparation(), Rasterizer not available");
@@ -954,7 +954,7 @@ static PyObject* gPyGetEyeSeparation(PyObject*)
return PyFloat_FromDouble(gp_Rasterizer->GetEyeSeparation());
}
-static PyObject* gPySetFocalLength(PyObject*, PyObject* args)
+static PyObject *gPySetFocalLength(PyObject *, PyObject *args)
{
float focus;
if (!PyArg_ParseTuple(args, "f:setFocalLength", &focus))
@@ -970,7 +970,7 @@ static PyObject* gPySetFocalLength(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetFocalLength(PyObject*, PyObject*, PyObject*)
+static PyObject *gPyGetFocalLength(PyObject *, PyObject *, PyObject *)
{
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.getFocalLength(), Rasterizer not available");
@@ -982,7 +982,7 @@ static PyObject* gPyGetFocalLength(PyObject*, PyObject*, PyObject*)
Py_RETURN_NONE;
}
-static PyObject* gPySetBackgroundColor(PyObject*, PyObject* value)
+static PyObject *gPySetBackgroundColor(PyObject *, PyObject *value)
{
MT_Vector4 vec;
@@ -1003,7 +1003,7 @@ static PyObject* gPySetBackgroundColor(PyObject*, PyObject* value)
-static PyObject* gPySetMistColor(PyObject*, PyObject* value)
+static PyObject *gPySetMistColor(PyObject *, PyObject *value)
{
MT_Vector3 vec;
@@ -1013,25 +1013,25 @@ static PyObject* gPySetMistColor(PyObject*, PyObject* value)
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.setMistColor(color), Rasterizer not available");
return NULL;
- }
+ }
gp_Rasterizer->SetFogColor((float)vec[0], (float)vec[1], (float)vec[2]);
Py_RETURN_NONE;
}
-static PyObject* gPyDisableMist(PyObject*)
+static PyObject *gPyDisableMist(PyObject *)
{
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.setMistColor(color), Rasterizer not available");
return NULL;
- }
+ }
gp_Rasterizer->DisableFog();
Py_RETURN_NONE;
}
-static PyObject* gPySetMistStart(PyObject*, PyObject* args)
+static PyObject *gPySetMistStart(PyObject *, PyObject *args)
{
float miststart;
@@ -1050,7 +1050,7 @@ static PyObject* gPySetMistStart(PyObject*, PyObject* args)
-static PyObject* gPySetMistEnd(PyObject*, PyObject* args)
+static PyObject *gPySetMistEnd(PyObject *, PyObject *args)
{
float mistend;
@@ -1068,7 +1068,7 @@ static PyObject* gPySetMistEnd(PyObject*, PyObject* args)
}
-static PyObject* gPySetAmbientColor(PyObject*, PyObject* value)
+static PyObject *gPySetAmbientColor(PyObject *, PyObject *value)
{
MT_Vector3 vec;
@@ -1078,7 +1078,7 @@ static PyObject* gPySetAmbientColor(PyObject*, PyObject* value)
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.setAmbientColor(color), Rasterizer not available");
return NULL;
- }
+ }
gp_Rasterizer->SetAmbientColor((float)vec[0], (float)vec[1], (float)vec[2]);
Py_RETURN_NONE;
@@ -1087,7 +1087,7 @@ static PyObject* gPySetAmbientColor(PyObject*, PyObject* value)
-static PyObject* gPyMakeScreenshot(PyObject*, PyObject* args)
+static PyObject *gPyMakeScreenshot(PyObject *, PyObject *args)
{
char* filename;
if (!PyArg_ParseTuple(args,"s:makeScreenshot",&filename))
@@ -1101,7 +1101,7 @@ static PyObject* gPyMakeScreenshot(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyEnableMotionBlur(PyObject*, PyObject* args)
+static PyObject *gPyEnableMotionBlur(PyObject *, PyObject *args)
{
float motionblurvalue;
if (!PyArg_ParseTuple(args,"f:enableMotionBlur",&motionblurvalue))
@@ -1117,7 +1117,7 @@ static PyObject* gPyEnableMotionBlur(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyDisableMotionBlur(PyObject*)
+static PyObject *gPyDisableMotionBlur(PyObject *)
{
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.disableMotionBlur(), Rasterizer not available");
@@ -1147,9 +1147,9 @@ static int getGLSLSettingFlag(const char *setting)
return -1;
}
-static PyObject* gPySetGLSLMaterialSetting(PyObject*,
- PyObject* args,
- PyObject*)
+static PyObject *gPySetGLSLMaterialSetting(PyObject *,
+ PyObject *args,
+ PyObject *)
{
GlobalSettings *gs= gp_KetsjiEngine->GetGlobalSettings();
char *setting;
@@ -1190,9 +1190,9 @@ static PyObject* gPySetGLSLMaterialSetting(PyObject*,
Py_RETURN_NONE;
}
-static PyObject* gPyGetGLSLMaterialSetting(PyObject*,
- PyObject* args,
- PyObject*)
+static PyObject *gPyGetGLSLMaterialSetting(PyObject *,
+ PyObject *args,
+ PyObject *)
{
GlobalSettings *gs= gp_KetsjiEngine->GetGlobalSettings();
char *setting;
@@ -1216,9 +1216,9 @@ static PyObject* gPyGetGLSLMaterialSetting(PyObject*,
#define KX_BLENDER_MULTITEX_MATERIAL 1
#define KX_BLENDER_GLSL_MATERIAL 2
-static PyObject* gPySetMaterialType(PyObject*,
- PyObject* args,
- PyObject*)
+static PyObject *gPySetMaterialType(PyObject *,
+ PyObject *args,
+ PyObject *)
{
GlobalSettings *gs= gp_KetsjiEngine->GetGlobalSettings();
int type;
@@ -1240,7 +1240,7 @@ static PyObject* gPySetMaterialType(PyObject*,
Py_RETURN_NONE;
}
-static PyObject* gPyGetMaterialType(PyObject*)
+static PyObject *gPyGetMaterialType(PyObject *)
{
GlobalSettings *gs= gp_KetsjiEngine->GetGlobalSettings();
int flag;
@@ -1255,7 +1255,7 @@ static PyObject* gPyGetMaterialType(PyObject*)
return PyLong_FromSsize_t(flag);
}
-static PyObject* gPySetAnisotropicFiltering(PyObject*, PyObject* args)
+static PyObject *gPySetAnisotropicFiltering(PyObject *, PyObject *args)
{
short level;
@@ -1272,16 +1272,16 @@ static PyObject* gPySetAnisotropicFiltering(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPyGetAnisotropicFiltering(PyObject*, PyObject* args)
+static PyObject *gPyGetAnisotropicFiltering(PyObject *, PyObject *args)
{
return PyLong_FromLong(gp_Rasterizer->GetAnisotropicFiltering());
}
-static PyObject* gPyDrawLine(PyObject*, PyObject* args)
+static PyObject *gPyDrawLine(PyObject *, PyObject *args)
{
- PyObject* ob_from;
- PyObject* ob_to;
- PyObject* ob_color;
+ PyObject *ob_from;
+ PyObject *ob_to;
+ PyObject *ob_color;
if (!gp_Rasterizer) {
PyErr_SetString(PyExc_RuntimeError, "Rasterizer.drawLine(obFrom, obTo, color): Rasterizer not available");
@@ -1306,7 +1306,7 @@ static PyObject* gPyDrawLine(PyObject*, PyObject* args)
Py_RETURN_NONE;
}
-static PyObject* gPySetWindowSize(PyObject*, PyObject* args)
+static PyObject *gPySetWindowSize(PyObject *, PyObject *args)
{
int width, height;
if (!PyArg_ParseTuple(args, "ii:resize", &width, &height))
@@ -1383,11 +1383,11 @@ static struct PyModuleDef GameLogic_module_def = {
0, /* m_free */
};
-PyObject* initGameLogic(KX_KetsjiEngine *engine, KX_Scene* scene) // quick hack to get gravity hook
+PyObject *initGameLogic(KX_KetsjiEngine *engine, KX_Scene* scene) // quick hack to get gravity hook
{
- PyObject* m;
- PyObject* d;
- PyObject* item; /* temp PyObject* storage */
+ PyObject *m;
+ PyObject *d;
+ PyObject *item; /* temp PyObject *storage */
gp_KetsjiEngine = engine;
gp_KetsjiScene = scene;
@@ -1405,7 +1405,7 @@ PyObject* initGameLogic(KX_KetsjiEngine *engine, KX_Scene* scene) // quick hack
}
else {
PyErr_Clear();
- // Create the module and add the functions
+ // Create the module and add the functions
m = PyModule_Create(&GameLogic_module_def);
PyDict_SetItemString(PySys_GetObject("modules"), GameLogic_module_def.m_name, m);
}
@@ -1832,7 +1832,7 @@ static void restorePySysObjects(void)
PyDict_Clear(sys_mods);
PyDict_Update(sys_mods, gp_OrigPythonSysModules);
Py_DECREF(gp_OrigPythonSysModules);
- gp_OrigPythonSysModules= NULL;
+ gp_OrigPythonSysModules= NULL;
// fprintf(stderr, "\nRestore Path: %d ", PyList_GET_SIZE(sys_path));
@@ -1862,7 +1862,7 @@ static struct _inittab bge_internal_modules[]= {
* Python is not initialized.
* see bpy_interface.c's BPY_python_start() which shares the same functionality in blender.
*/
-PyObject* initGamePlayerPythonScripting(const STR_String& progname, TPythonSecurityLevel level, Main *maggie, int argc, char** argv)
+PyObject *initGamePlayerPythonScripting(const STR_String& progname, TPythonSecurityLevel level, Main *maggie, int argc, char** argv)
{
/* Yet another gotcha in the py api
* Cant run PySys_SetArgv more then once because this adds the
@@ -1935,7 +1935,7 @@ PyObject* initGamePlayerPythonScripting(const STR_String& progname, TPythonSecur
}
void exitGamePlayerPythonScripting()
-{
+{
/* Clean up the Python mouse and keyboard */
delete gp_PythonKeyboard;
gp_PythonKeyboard = NULL;
@@ -1956,7 +1956,7 @@ void exitGamePlayerPythonScripting()
/**
* Python is already initialized.
*/
-PyObject* initGamePythonScripting(const STR_String& progname, TPythonSecurityLevel level, Main *maggie)
+PyObject *initGamePythonScripting(const STR_String& progname, TPythonSecurityLevel level, Main *maggie)
{
#if 0 // XXX TODO Py3
STR_String pname = progname;
@@ -1998,9 +1998,10 @@ void exitGamePythonScripting()
/* similar to the above functions except it sets up the namespace
* and other more general things */
-void setupGamePython(KX_KetsjiEngine* ketsjiengine, KX_Scene* startscene, Main *blenderdata, PyObject * pyGlobalDict, PyObject **gameLogic, PyObject **gameLogic_keys, int argc, char** argv)
+void setupGamePython(KX_KetsjiEngine* ketsjiengine, KX_Scene *startscene, Main *blenderdata,
+ PyObject *pyGlobalDict, PyObject **gameLogic, PyObject **gameLogic_keys, int argc, char** argv)
{
- PyObject* dictionaryobject;
+ PyObject *dictionaryobject;
if (argv) /* player only */
dictionaryobject= initGamePlayerPythonScripting("Ketsji", psl_Lowest, blenderdata, argc, argv);
@@ -2053,15 +2054,15 @@ static struct PyModuleDef Rasterizer_module_def = {
0, /* m_free */
};
-PyObject* initRasterizer(RAS_IRasterizer* rasty,RAS_ICanvas* canvas)
+PyObject *initRasterizer(RAS_IRasterizer* rasty,RAS_ICanvas* canvas)
{
gp_Canvas = canvas;
gp_Rasterizer = rasty;
- PyObject* m;
- PyObject* d;
- PyObject* item;
+ PyObject *m;
+ PyObject *d;
+ PyObject *item;
/* Use existing module where possible
* be careful not to init any runtime vars after this */
@@ -2114,9 +2115,9 @@ static char gPyEventToString_doc[] =
"EventToString(event) - Take a valid event from the GameKeys module or Keyboard Sensor and return a name"
;
-static PyObject* gPyEventToString(PyObject*, PyObject* value)
+static PyObject *gPyEventToString(PyObject *, PyObject *value)
{
- PyObject* mod, *dict, *key, *val, *ret = NULL;
+ PyObject *mod, *dict, *key, *val, *ret = NULL;
Py_ssize_t pos = 0;
mod = PyImport_ImportModule( "GameKeys" );
@@ -2144,7 +2145,7 @@ static char gPyEventToCharacter_doc[] =
"EventToCharacter(event, is_shift) - Take a valid event from the GameKeys module or Keyboard Sensor and return a character"
;
-static PyObject* gPyEventToCharacter(PyObject*, PyObject* args)
+static PyObject *gPyEventToCharacter(PyObject *, PyObject *args)
{
int event, shift;
if (!PyArg_ParseTuple(args,"ii:EventToCharacter", &event, &shift))
@@ -2179,11 +2180,11 @@ static struct PyModuleDef GameKeys_module_def = {
0, /* m_free */
};
-PyObject* initGameKeys()
+PyObject *initGameKeys()
{
- PyObject* m;
- PyObject* d;
- PyObject* item;
+ PyObject *m;
+ PyObject *d;
+ PyObject *item;
/* Use existing module where possible */
m = PyImport_ImportModule( "GameKeys" );
@@ -2231,24 +2232,24 @@ PyObject* initGameKeys()
KX_MACRO_addTypesToDict(d, YKEY, SCA_IInputDevice::KX_YKEY);
KX_MACRO_addTypesToDict(d, ZKEY, SCA_IInputDevice::KX_ZKEY);
- KX_MACRO_addTypesToDict(d, ZEROKEY, SCA_IInputDevice::KX_ZEROKEY);
- KX_MACRO_addTypesToDict(d, ONEKEY, SCA_IInputDevice::KX_ONEKEY);
- KX_MACRO_addTypesToDict(d, TWOKEY, SCA_IInputDevice::KX_TWOKEY);
+ KX_MACRO_addTypesToDict(d, ZEROKEY, SCA_IInputDevice::KX_ZEROKEY);
+ KX_MACRO_addTypesToDict(d, ONEKEY, SCA_IInputDevice::KX_ONEKEY);
+ KX_MACRO_addTypesToDict(d, TWOKEY, SCA_IInputDevice::KX_TWOKEY);
KX_MACRO_addTypesToDict(d, THREEKEY, SCA_IInputDevice::KX_THREEKEY);
- KX_MACRO_addTypesToDict(d, FOURKEY, SCA_IInputDevice::KX_FOURKEY);
- KX_MACRO_addTypesToDict(d, FIVEKEY, SCA_IInputDevice::KX_FIVEKEY);
- KX_MACRO_addTypesToDict(d, SIXKEY, SCA_IInputDevice::KX_SIXKEY);
+ KX_MACRO_addTypesToDict(d, FOURKEY, SCA_IInputDevice::KX_FOURKEY);
+ KX_MACRO_addTypesToDict(d, FIVEKEY, SCA_IInputDevice::KX_FIVEKEY);
+ KX_MACRO_addTypesToDict(d, SIXKEY, SCA_IInputDevice::KX_SIXKEY);
KX_MACRO_addTypesToDict(d, SEVENKEY, SCA_IInputDevice::KX_SEVENKEY);
KX_MACRO_addTypesToDict(d, EIGHTKEY, SCA_IInputDevice::KX_EIGHTKEY);
- KX_MACRO_addTypesToDict(d, NINEKEY, SCA_IInputDevice::KX_NINEKEY);
+ KX_MACRO_addTypesToDict(d, NINEKEY, SCA_IInputDevice::KX_NINEKEY);
KX_MACRO_addTypesToDict(d, CAPSLOCKKEY, SCA_IInputDevice::KX_CAPSLOCKKEY);
- KX_MACRO_addTypesToDict(d, LEFTCTRLKEY, SCA_IInputDevice::KX_LEFTCTRLKEY);
+ KX_MACRO_addTypesToDict(d, LEFTCTRLKEY, SCA_IInputDevice::KX_LEFTCTRLKEY);
KX_MACRO_addTypesToDict(d, LEFTALTKEY, SCA_IInputDevice::KX_LEFTALTKEY);
KX_MACRO_addTypesToDict(d, RIGHTALTKEY, SCA_IInputDevice::KX_RIGHTALTKEY);
KX_MACRO_addTypesToDict(d, RIGHTCTRLKEY, SCA_IInputDevice::KX_RIGHTCTRLKEY);
- KX_MACRO_addTypesToDict(d, RIGHTSHIFTKEY, SCA_IInputDevice::KX_RIGHTSHIFTKEY);
+ KX_MACRO_addTypesToDict(d, RIGHTSHIFTKEY, SCA_IInputDevice::KX_RIGHTSHIFTKEY);
KX_MACRO_addTypesToDict(d, LEFTSHIFTKEY, SCA_IInputDevice::KX_LEFTSHIFTKEY);
KX_MACRO_addTypesToDict(d, ESCKEY, SCA_IInputDevice::KX_ESCKEY);
@@ -2256,25 +2257,25 @@ PyObject* initGameKeys()
KX_MACRO_addTypesToDict(d, RETKEY, SCA_IInputDevice::KX_RETKEY);
KX_MACRO_addTypesToDict(d, ENTERKEY, SCA_IInputDevice::KX_RETKEY);
KX_MACRO_addTypesToDict(d, SPACEKEY, SCA_IInputDevice::KX_SPACEKEY);
- KX_MACRO_addTypesToDict(d, LINEFEEDKEY, SCA_IInputDevice::KX_LINEFEEDKEY);
+ KX_MACRO_addTypesToDict(d, LINEFEEDKEY, SCA_IInputDevice::KX_LINEFEEDKEY);
KX_MACRO_addTypesToDict(d, BACKSPACEKEY, SCA_IInputDevice::KX_BACKSPACEKEY);
KX_MACRO_addTypesToDict(d, DELKEY, SCA_IInputDevice::KX_DELKEY);
KX_MACRO_addTypesToDict(d, SEMICOLONKEY, SCA_IInputDevice::KX_SEMICOLONKEY);
- KX_MACRO_addTypesToDict(d, PERIODKEY, SCA_IInputDevice::KX_PERIODKEY);
- KX_MACRO_addTypesToDict(d, COMMAKEY, SCA_IInputDevice::KX_COMMAKEY);
- KX_MACRO_addTypesToDict(d, QUOTEKEY, SCA_IInputDevice::KX_QUOTEKEY);
- KX_MACRO_addTypesToDict(d, ACCENTGRAVEKEY, SCA_IInputDevice::KX_ACCENTGRAVEKEY);
- KX_MACRO_addTypesToDict(d, MINUSKEY, SCA_IInputDevice::KX_MINUSKEY);
- KX_MACRO_addTypesToDict(d, SLASHKEY, SCA_IInputDevice::KX_SLASHKEY);
+ KX_MACRO_addTypesToDict(d, PERIODKEY, SCA_IInputDevice::KX_PERIODKEY);
+ KX_MACRO_addTypesToDict(d, COMMAKEY, SCA_IInputDevice::KX_COMMAKEY);
+ KX_MACRO_addTypesToDict(d, QUOTEKEY, SCA_IInputDevice::KX_QUOTEKEY);
+ KX_MACRO_addTypesToDict(d, ACCENTGRAVEKEY, SCA_IInputDevice::KX_ACCENTGRAVEKEY);
+ KX_MACRO_addTypesToDict(d, MINUSKEY, SCA_IInputDevice::KX_MINUSKEY);
+ KX_MACRO_addTypesToDict(d, SLASHKEY, SCA_IInputDevice::KX_SLASHKEY);
KX_MACRO_addTypesToDict(d, BACKSLASHKEY, SCA_IInputDevice::KX_BACKSLASHKEY);
- KX_MACRO_addTypesToDict(d, EQUALKEY, SCA_IInputDevice::KX_EQUALKEY);
- KX_MACRO_addTypesToDict(d, LEFTBRACKETKEY, SCA_IInputDevice::KX_LEFTBRACKETKEY);
- KX_MACRO_addTypesToDict(d, RIGHTBRACKETKEY, SCA_IInputDevice::KX_RIGHTBRACKETKEY);
+ KX_MACRO_addTypesToDict(d, EQUALKEY, SCA_IInputDevice::KX_EQUALKEY);
+ KX_MACRO_addTypesToDict(d, LEFTBRACKETKEY, SCA_IInputDevice::KX_LEFTBRACKETKEY);
+ KX_MACRO_addTypesToDict(d, RIGHTBRACKETKEY, SCA_IInputDevice::KX_RIGHTBRACKETKEY);
KX_MACRO_addTypesToDict(d, LEFTARROWKEY, SCA_IInputDevice::KX_LEFTARROWKEY);
KX_MACRO_addTypesToDict(d, DOWNARROWKEY, SCA_IInputDevice::KX_DOWNARROWKEY);
- KX_MACRO_addTypesToDict(d, RIGHTARROWKEY, SCA_IInputDevice::KX_RIGHTARROWKEY);
- KX_MACRO_addTypesToDict(d, UPARROWKEY, SCA_IInputDevice::KX_UPARROWKEY);
+ KX_MACRO_addTypesToDict(d, RIGHTARROWKEY, SCA_IInputDevice::KX_RIGHTARROWKEY);
+ KX_MACRO_addTypesToDict(d, UPARROWKEY, SCA_IInputDevice::KX_UPARROWKEY);
KX_MACRO_addTypesToDict(d, PAD2 , SCA_IInputDevice::KX_PAD2);
KX_MACRO_addTypesToDict(d, PAD4 , SCA_IInputDevice::KX_PAD4);
@@ -2347,14 +2348,14 @@ PyObject* initGameKeys()
int saveGamePythonConfig( char **marshal_buffer)
{
int marshal_length = 0;
- PyObject* gameLogic = PyImport_ImportModule("GameLogic");
+ PyObject *gameLogic = PyImport_ImportModule("GameLogic");
if (gameLogic) {
- PyObject* pyGlobalDict = PyDict_GetItemString(PyModule_GetDict(gameLogic), "globalDict"); // Same as importing the module
+ PyObject *pyGlobalDict = PyDict_GetItemString(PyModule_GetDict(gameLogic), "globalDict"); // Same as importing the module
if (pyGlobalDict) {
-#ifdef Py_MARSHAL_VERSION
- PyObject* pyGlobalDictMarshal = PyMarshal_WriteObjectToString( pyGlobalDict, 2); // Py_MARSHAL_VERSION == 2 as of Py2.5
+#ifdef Py_MARSHAL_VERSION
+ PyObject *pyGlobalDictMarshal = PyMarshal_WriteObjectToString( pyGlobalDict, 2); // Py_MARSHAL_VERSION == 2 as of Py2.5
#else
- PyObject* pyGlobalDictMarshal = PyMarshal_WriteObjectToString( pyGlobalDict );
+ PyObject *pyGlobalDictMarshal = PyMarshal_WriteObjectToString( pyGlobalDict );
#endif
if (pyGlobalDictMarshal) {
// for testing only
@@ -2384,12 +2385,12 @@ int loadGamePythonConfig(char *marshal_buffer, int marshal_length)
{
/* Restore the dict */
if (marshal_buffer) {
- PyObject* gameLogic = PyImport_ImportModule("GameLogic");
+ PyObject *gameLogic = PyImport_ImportModule("GameLogic");
if (gameLogic) {
- PyObject* pyGlobalDict = PyMarshal_ReadObjectFromString(marshal_buffer, marshal_length);
+ PyObject *pyGlobalDict = PyMarshal_ReadObjectFromString(marshal_buffer, marshal_length);
if (pyGlobalDict) {
- PyObject* pyGlobalDict_orig = PyDict_GetItemString(PyModule_GetDict(gameLogic), "globalDict"); // Same as importing the module.
+ PyObject *pyGlobalDict_orig = PyDict_GetItemString(PyModule_GetDict(gameLogic), "globalDict"); // Same as importing the module.
if (pyGlobalDict_orig) {
PyDict_Clear(pyGlobalDict_orig);
PyDict_Update(pyGlobalDict_orig, pyGlobalDict);
@@ -2405,10 +2406,11 @@ int loadGamePythonConfig(char *marshal_buffer, int marshal_length)
PyErr_Clear();
printf("Error could not marshall string\n");
}
- } else {
+ }
+ else {
PyErr_Clear();
printf("Error, bge.logic failed to import bge.logic.globalDict will be lost\n");
- }
+ }
}
return 0;
}
diff --git a/source/gameengine/Ketsji/KX_PythonInit.h b/source/gameengine/Ketsji/KX_PythonInit.h
index 1500dd97ae1..69517b2b1e9 100644
--- a/source/gameengine/Ketsji/KX_PythonInit.h
+++ b/source/gameengine/Ketsji/KX_PythonInit.h
@@ -52,7 +52,8 @@ void exitGamePlayerPythonScripting();
PyObject* initGamePythonScripting(const STR_String& progname, TPythonSecurityLevel level, struct Main *maggie);
void exitGamePythonScripting();
-void setupGamePython(KX_KetsjiEngine* ketsjiengine, KX_Scene* startscene, Main *blenderdata, PyObject *pyGlobalDict, PyObject **gameLogic, PyObject **gameLogic_keys, int argc, char** argv);
+void setupGamePython(KX_KetsjiEngine *ketsjiengine, KX_Scene *startscene, Main *blenderdata,
+ PyObject *pyGlobalDict, PyObject **gameLogic, PyObject **gameLogic_keys, int argc, char** argv);
void setGamePythonPath(const char *path);
void resetGamePythonPath();
@@ -72,11 +73,12 @@ class KX_Scene* KX_GetActiveScene();
class KX_KetsjiEngine* KX_GetActiveEngine();
typedef int (*PyNextFrameFunc)(void *);
+
struct PyNextFrameState {
- //state: can be either a GPG_NextFrameState or a BL_KetsjiNextFrameState
- void *state;
- //func: can be either GPG_PyNextFrame or BL_KetsjiPyNextFrame
- PyNextFrameFunc func;
+ /** can be either a GPG_NextFrameState or a BL_KetsjiNextFrameState */
+ void *state;
+ /** can be either GPG_PyNextFrame or BL_KetsjiPyNextFrame */
+ PyNextFrameFunc func;
};
extern struct PyNextFrameState pynextframestate;
@@ -84,7 +86,7 @@ extern struct PyNextFrameState pynextframestate;
void KX_RasterizerDrawDebugLine(const MT_Vector3& from,const MT_Vector3& to,const MT_Vector3& color);
void KX_RasterizerDrawDebugCircle(const MT_Vector3& center, const MT_Scalar radius, const MT_Vector3& color,
- const MT_Vector3& normal, int nsector);
+ const MT_Vector3& normal, int nsector);
#endif //__KX_PYTHONINIT_H__
diff --git a/source/gameengine/Ketsji/KX_PythonInitTypes.h b/source/gameengine/Ketsji/KX_PythonInitTypes.h
index a06fe46a0ea..d8ee4f75fdd 100644
--- a/source/gameengine/Ketsji/KX_PythonInitTypes.h
+++ b/source/gameengine/Ketsji/KX_PythonInitTypes.h
@@ -29,11 +29,11 @@
* \ingroup ketsji
*/
-#ifndef _adr_py_init_types_h_ // only process once,
-#define _adr_py_init_types_h_ // even if multiply included
+#ifndef __KX_PYTHON_INIT_TYPES__
+#define __KX_PYTHON_INIT_TYPES__
#ifdef WITH_PYTHON
void initPyTypes(void);
#endif
-#endif
+#endif /* __KX_PYTHON_INIT_TYPES__ */
diff --git a/source/gameengine/Ketsji/KX_PythonSeq.cpp b/source/gameengine/Ketsji/KX_PythonSeq.cpp
index 5d082c8394a..5ab3de15fb3 100644
--- a/source/gameengine/Ketsji/KX_PythonSeq.cpp
+++ b/source/gameengine/Ketsji/KX_PythonSeq.cpp
@@ -69,7 +69,7 @@ static void KX_PythonSeq_dealloc(KX_PythonSeq * self)
PyObject_GC_Del(self);
}
-static Py_ssize_t KX_PythonSeq_len( PyObject * self )
+static Py_ssize_t KX_PythonSeq_len( PyObject *self )
{
PyObjectPlus *self_plus= BGE_PROXY_REF(((KX_PythonSeq *)self)->base);
@@ -100,7 +100,7 @@ static Py_ssize_t KX_PythonSeq_len( PyObject * self )
}
}
-static PyObject *KX_PythonSeq_getIndex(PyObject* self, int index)
+static PyObject *KX_PythonSeq_getIndex(PyObject *self, int index)
{
PyObjectPlus *self_plus= BGE_PROXY_REF(((KX_PythonSeq *)self)->base);
@@ -264,7 +264,7 @@ static PyObjectPlus * KX_PythonSeq_subscript__internal(PyObject *self, const cha
}
-static PyObject * KX_PythonSeq_subscript(PyObject * self, PyObject *key)
+static PyObject * KX_PythonSeq_subscript(PyObject *self, PyObject *key)
{
PyObjectPlus *self_plus= BGE_PROXY_REF(((KX_PythonSeq *)self)->base);
@@ -314,10 +314,10 @@ static int KX_PythonSeq_contains(PyObject *self, PyObject *key)
}
/* Matches python dict.get(key, [default]) */
-static PyObject* KX_PythonSeq_get(PyObject * self, PyObject *args)
+static PyObject *KX_PythonSeq_get(PyObject *self, PyObject *args)
{
char *key;
- PyObject* def = Py_None;
+ PyObject *def = Py_None;
PyObjectPlus* ret_plus;
if (!PyArg_ParseTuple(args, "s|O:get", &key, &def))
@@ -396,7 +396,7 @@ static PyObject *KX_PythonSeq_nextIter(KX_PythonSeq *self)
static int KX_PythonSeq_compare( KX_PythonSeq * a, KX_PythonSeq * b )
{
- return ( a->type == b->type && a->base == b->base) ? 0 : -1;
+ return ( a->type == b->type && a->base == b->base) ? 0 : -1;
}
static PyObject *KX_PythonSeq_richcmp(PyObject *a, PyObject *b, int op)
diff --git a/source/gameengine/Ketsji/KX_RadarSensor.cpp b/source/gameengine/Ketsji/KX_RadarSensor.cpp
index 74009f51078..fb949fffa8a 100644
--- a/source/gameengine/Ketsji/KX_RadarSensor.cpp
+++ b/source/gameengine/Ketsji/KX_RadarSensor.cpp
@@ -217,7 +217,7 @@ PyAttributeDef KX_RadarSensor::Attributes[] = {
{NULL} //Sentinel
};
-PyObject* KX_RadarSensor::pyattr_get_angle(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_RadarSensor::pyattr_get_angle(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_RadarSensor* self= static_cast<KX_RadarSensor*>(self_v);
diff --git a/source/gameengine/Ketsji/KX_RaySensor.cpp b/source/gameengine/Ketsji/KX_RaySensor.cpp
index 58ca847b617..14786e8429e 100644
--- a/source/gameengine/Ketsji/KX_RaySensor.cpp
+++ b/source/gameengine/Ketsji/KX_RaySensor.cpp
@@ -361,7 +361,7 @@ PyAttributeDef KX_RaySensor::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_RaySensor::pyattr_get_hitobject(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_RaySensor::pyattr_get_hitobject(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_RaySensor* self = static_cast<KX_RaySensor*>(self_v);
if (self->m_hitObject)
diff --git a/source/gameengine/Ketsji/KX_RaySensor.h b/source/gameengine/Ketsji/KX_RaySensor.h
index f5d1c72d098..27aaa442dcd 100644
--- a/source/gameengine/Ketsji/KX_RaySensor.h
+++ b/source/gameengine/Ketsji/KX_RaySensor.h
@@ -94,7 +94,7 @@ public:
#ifdef WITH_PYTHON
/* Attributes */
- static PyObject* pyattr_get_hitobject(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_hitobject(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp
index 841feda5237..d850168afdf 100644
--- a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp
@@ -203,10 +203,10 @@ PyAttributeDef KX_SCA_AddObjectActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_SCA_AddObjectActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SCA_AddObjectActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SCA_AddObjectActuator* actuator = static_cast<KX_SCA_AddObjectActuator*>(self);
- if (!actuator->m_OriginalObject)
+ if (!actuator->m_OriginalObject)
Py_RETURN_NONE;
else
return actuator->m_OriginalObject->GetProxy();
@@ -221,7 +221,7 @@ int KX_SCA_AddObjectActuator::pyattr_set_object(void *self, const struct KX_PYAT
return PY_SET_ATTR_FAIL; // ConvertPythonToGameObject sets the error
if (actuator->m_OriginalObject != NULL)
- actuator->m_OriginalObject->UnregisterActuator(actuator);
+ actuator->m_OriginalObject->UnregisterActuator(actuator);
actuator->m_OriginalObject = (SCA_IObject*)gameobj;
@@ -231,7 +231,7 @@ int KX_SCA_AddObjectActuator::pyattr_set_object(void *self, const struct KX_PYAT
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_SCA_AddObjectActuator::pyattr_get_objectLastCreated(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SCA_AddObjectActuator::pyattr_get_objectLastCreated(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SCA_AddObjectActuator* actuator = static_cast<KX_SCA_AddObjectActuator*>(self);
if (!actuator->m_lastCreatedObject)
@@ -240,7 +240,7 @@ PyObject* KX_SCA_AddObjectActuator::pyattr_get_objectLastCreated(void *self, con
return actuator->m_lastCreatedObject->GetProxy();
}
-PyObject* KX_SCA_AddObjectActuator::PyInstantAddObject()
+PyObject *KX_SCA_AddObjectActuator::PyInstantAddObject()
{
InstantAddObject();
@@ -253,7 +253,7 @@ void KX_SCA_AddObjectActuator::InstantAddObject()
{
if (m_OriginalObject)
{
- // Add an identical object, with properties inherited from the original object
+ // Add an identical object, with properties inherited from the original object
// Now it needs to be added to the current scene.
SCA_IObject* replica = m_scene->AddReplicaObject(m_OriginalObject,GetParent(),m_timeProp );
KX_GameObject * game_obj = static_cast<KX_GameObject *>(replica);
diff --git a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h
index f49f2473036..9c8cbfa3d09 100644
--- a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h
+++ b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h
@@ -112,7 +112,7 @@ public:
virtual bool
Update();
- SCA_IObject*
+ SCA_IObject *
GetLastCreatedObject(
) const;
@@ -122,9 +122,9 @@ public:
KX_PYMETHOD_DOC_NOARGS(KX_SCA_AddObjectActuator,InstantAddObject);
- static PyObject* pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- static PyObject* pyattr_get_objectLastCreated(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_objectLastCreated(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_SCA_DynamicActuator.cpp b/source/gameengine/Ketsji/KX_SCA_DynamicActuator.cpp
index f408b2cd7c9..5dc67a4cff3 100644
--- a/source/gameengine/Ketsji/KX_SCA_DynamicActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SCA_DynamicActuator.cpp
@@ -119,14 +119,14 @@ bool KX_SCA_DynamicActuator::Update()
switch (m_dyn_operation)
{
- case 0:
- obj->RestoreDynamics();
+ case 0:
+ obj->RestoreDynamics();
break;
case 1:
obj->SuspendDynamics();
break;
case 2:
- controller->setRigidBody(true);
+ controller->setRigidBody(true);
break;
case 3:
controller->setRigidBody(false);
diff --git a/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.cpp b/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.cpp
index ffe5556cfe6..b105256836b 100644
--- a/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.cpp
@@ -87,7 +87,7 @@ PyAttributeDef KX_SCA_ReplaceMeshActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_SCA_ReplaceMeshActuator::pyattr_get_mesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SCA_ReplaceMeshActuator::pyattr_get_mesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SCA_ReplaceMeshActuator* actuator = static_cast<KX_SCA_ReplaceMeshActuator*>(self);
if (!actuator->m_mesh)
diff --git a/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.h b/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.h
index 6db16a0e1b6..52a20142442 100644
--- a/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.h
+++ b/source/gameengine/Ketsji/KX_SCA_ReplaceMeshActuator.h
@@ -84,7 +84,7 @@ class KX_SCA_ReplaceMeshActuator : public SCA_IActuator
m_scene= val;
};
- static PyObject* pyattr_get_mesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_mesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_mesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
KX_PYMETHOD_DOC(KX_SCA_ReplaceMeshActuator,instantReplaceMesh);
diff --git a/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.cpp b/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.cpp
index 13200696ffb..19b9d13087d 100644
--- a/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.cpp
+++ b/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.cpp
@@ -51,14 +51,14 @@ KX_BoneParentRelation::
New(Bone* bone
) {
return new KX_BoneParentRelation(bone);
-}
+}
bool
KX_BoneParentRelation::
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
) {
MT_assert(child != NULL);
@@ -71,7 +71,7 @@ UpdateChildCoordinates(
// we don't know if the armature has been updated or not, assume yes
parentUpdated = true;
- // the childs world locations which we will update.
+ // the childs world locations which we will update.
MT_Vector3 child_w_scale;
MT_Point3 child_w_pos;
diff --git a/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.h b/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.h
index 76fefdebe08..6f4fd482198 100644
--- a/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.h
+++ b/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.h
@@ -57,7 +57,7 @@ public :
static
KX_BoneParentRelation *
New(Bone* bone
- );
+ );
/**
* Updates the childs world coordinates relative to the parent's
diff --git a/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp b/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
index 699b267496d..e80de76861e 100644
--- a/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
+++ b/source/gameengine/Ketsji/KX_SG_NodeRelationships.cpp
@@ -45,14 +45,14 @@ KX_NormalParentRelation::
New(
) {
return new KX_NormalParentRelation();
-}
+}
bool
KX_NormalParentRelation::
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
) {
MT_assert(child != NULL);
@@ -67,7 +67,7 @@ UpdateChildCoordinates(
return true; //false;
}
else {
- // the childs world locations which we will update.
+ // the childs world locations which we will update.
const MT_Vector3 & p_world_scale = parent->GetWorldScaling();
const MT_Point3 & p_world_pos = parent->GetWorldPosition();
const MT_Matrix3x3 & p_world_rotation = parent->GetWorldOrientation();
@@ -121,7 +121,7 @@ KX_VertexParentRelation::
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
) {
MT_assert(child != NULL);
@@ -176,7 +176,7 @@ New(
MT_Scalar relaxation
) {
return new KX_SlowParentRelation(relaxation);
-}
+}
/**
* Method inherited from KX_ParentRelation
@@ -187,7 +187,7 @@ KX_SlowParentRelation::
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
) {
MT_assert(child != NULL);
@@ -198,7 +198,7 @@ UpdateChildCoordinates(
const MT_Point3 & child_pos = child->GetLocalPosition();
const MT_Matrix3x3 & child_rotation = child->GetLocalOrientation();
- // the childs world locations which we will update.
+ // the childs world locations which we will update.
MT_Vector3 child_w_scale;
MT_Point3 child_w_pos;
@@ -230,7 +230,7 @@ UpdateChildCoordinates(
child_w_scale = child->GetWorldScaling();
child_w_pos = child->GetWorldPosition();
- child_w_rotation = child->GetWorldOrientation();
+ child_w_rotation = child->GetWorldOrientation();
// now 'interpolate' the normal coordinates with the last
// world coordinates to get the new world coordinates.
diff --git a/source/gameengine/Ketsji/KX_SG_NodeRelationships.h b/source/gameengine/Ketsji/KX_SG_NodeRelationships.h
index b5ab5302910..5d777f5028f 100644
--- a/source/gameengine/Ketsji/KX_SG_NodeRelationships.h
+++ b/source/gameengine/Ketsji/KX_SG_NodeRelationships.h
@@ -57,7 +57,7 @@ public :
static
KX_NormalParentRelation *
New(
- );
+ );
/**
* Method inherited from KX_ParentRelation
@@ -67,7 +67,7 @@ public :
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
);
/**
@@ -106,7 +106,7 @@ public :
static
KX_VertexParentRelation *
New(
- );
+ );
/**
* Method inherited from KX_ParentRelation
@@ -116,7 +116,7 @@ public :
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
);
/**
@@ -162,7 +162,7 @@ public :
KX_SlowParentRelation *
New(
MT_Scalar relaxation
- );
+ );
/**
* Method inherited from KX_ParentRelation
@@ -172,7 +172,7 @@ public :
UpdateChildCoordinates(
SG_Spatial * child,
const SG_Spatial * parent,
- bool& parentUpdated
+ bool& parentUpdated
);
/**
diff --git a/source/gameengine/Ketsji/KX_Scene.cpp b/source/gameengine/Ketsji/KX_Scene.cpp
index f77cb535eed..652ed2ab2dd 100644
--- a/source/gameengine/Ketsji/KX_Scene.cpp
+++ b/source/gameengine/Ketsji/KX_Scene.cpp
@@ -368,7 +368,7 @@ void KX_Scene::SetFramingType(RAS_FrameSettings & frame_settings)
const RAS_FrameSettings& KX_Scene::GetFramingType() const
{
return m_frame_settings;
-};
+};
@@ -441,7 +441,7 @@ void KX_Scene::EnableZBufferClearing(bool isclearingZbuffer)
void KX_Scene::RemoveNodeDestructObject(class SG_IObject* node,class CValue* gameobj)
{
- KX_GameObject* orgobj = (KX_GameObject*)gameobj;
+ KX_GameObject* orgobj = (KX_GameObject*)gameobj;
if (NewRemoveObject(orgobj) != 0)
{
// object is not yet deleted because a reference is hanging somewhere.
@@ -1072,7 +1072,7 @@ void KX_Scene::ReplaceMesh(class CValue* obj,void* meshobj, bool use_gfx, bool u
}
if (use_gfx && mesh != NULL)
- {
+ {
gameobj->RemoveMeshes();
gameobj->AddMesh(mesh);
@@ -1278,7 +1278,7 @@ void KX_Scene::AddCamera(KX_Camera* cam)
KX_Camera* KX_Scene::GetActiveCamera()
-{
+{
// NULL if not defined
return m_active_camera;
}
@@ -1634,16 +1634,17 @@ void KX_Scene::UpdateObjectActivity(void)
* Manhattan distance. */
MT_Point3 obpos = ob->NodeGetWorldPosition();
- if ( (fabs(camloc[0] - obpos[0]) > m_activity_box_radius)
- || (fabs(camloc[1] - obpos[1]) > m_activity_box_radius)
- || (fabs(camloc[2] - obpos[2]) > m_activity_box_radius) )
- {
+ if ((fabs(camloc[0] - obpos[0]) > m_activity_box_radius) ||
+ (fabs(camloc[1] - obpos[1]) > m_activity_box_radius) ||
+ (fabs(camloc[2] - obpos[2]) > m_activity_box_radius) )
+ {
ob->Suspend();
- } else {
+ }
+ else {
ob->Resume();
}
}
- }
+ }
}
}
@@ -1944,15 +1945,15 @@ void KX_Scene::Render2DFilters(RAS_ICanvas* canvas)
#ifdef WITH_PYTHON
-void KX_Scene::RunDrawingCallbacks(PyObject* cb_list)
+void KX_Scene::RunDrawingCallbacks(PyObject *cb_list)
{
Py_ssize_t len;
if (cb_list && (len=PyList_GET_SIZE(cb_list)))
{
- PyObject* args= PyTuple_New(0); // save python creating each call
- PyObject* func;
- PyObject* ret;
+ PyObject *args = PyTuple_New(0); // save python creating each call
+ PyObject *func;
+ PyObject *ret;
// Iterate the list and run the callbacks
for (Py_ssize_t pos=0; pos < len; pos++)
@@ -2019,7 +2020,7 @@ static PyObject *Map_GetItem(PyObject *self_v, PyObject *item)
{
KX_Scene* self= static_cast<KX_Scene*>BGE_PROXY_REF(self_v);
const char *attr_str= _PyUnicode_AsString(item);
- PyObject* pyconvert;
+ PyObject *pyconvert;
if (self==NULL) {
PyErr_SetString(PyExc_SystemError, "val = scene[key]: KX_Scene, "BGE_PROXY_ERROR_MSG);
@@ -2122,31 +2123,31 @@ PySequenceMethods KX_Scene::Sequence = {
(ssizeargfunc) NULL, /* sq_inplace_repeat */
};
-PyObject* KX_Scene::pyattr_get_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_name(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self= static_cast<KX_Scene*>(self_v);
return PyUnicode_From_STR_String(self->GetName());
}
-PyObject* KX_Scene::pyattr_get_objects(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_objects(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self= static_cast<KX_Scene*>(self_v);
return self->GetObjectList()->GetProxy();
}
-PyObject* KX_Scene::pyattr_get_objects_inactive(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_objects_inactive(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self= static_cast<KX_Scene*>(self_v);
return self->GetInactiveList()->GetProxy();
}
-PyObject* KX_Scene::pyattr_get_lights(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_lights(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self= static_cast<KX_Scene*>(self_v);
return self->GetLightList()->GetProxy();
}
-PyObject* KX_Scene::pyattr_get_cameras(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_cameras(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
/* With refcounts in this case...
* the new CListValue is owned by python, so its possible python holds onto it longer then the BGE
@@ -2167,7 +2168,7 @@ PyObject* KX_Scene::pyattr_get_cameras(void *self_v, const KX_PYATTRIBUTE_DEF *a
return clist->NewProxy(true);
}
-PyObject* KX_Scene::pyattr_get_active_camera(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_active_camera(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self= static_cast<KX_Scene*>(self_v);
KX_Camera* cam= self->GetActiveCamera();
@@ -2190,7 +2191,7 @@ int KX_Scene::pyattr_set_active_camera(void *self_v, const KX_PYATTRIBUTE_DEF *a
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_Scene::pyattr_get_drawing_callback_pre(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_drawing_callback_pre(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self = static_cast<KX_Scene*>(self_v);
@@ -2200,7 +2201,7 @@ PyObject* KX_Scene::pyattr_get_drawing_callback_pre(void *self_v, const KX_PYATT
return self->m_draw_call_pre;
}
-PyObject* KX_Scene::pyattr_get_drawing_callback_post(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_Scene::pyattr_get_drawing_callback_post(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_Scene* self = static_cast<KX_Scene*>(self_v);
@@ -2354,8 +2355,8 @@ KX_PYMETHODDEF_DOC(KX_Scene, drawObstacleSimulation,
KX_PYMETHODDEF_DOC(KX_Scene, get, "")
{
PyObject *key;
- PyObject* def = Py_None;
- PyObject* ret;
+ PyObject *def = Py_None;
+ PyObject *ret;
if (!PyArg_ParseTuple(args, "O|O:get", &key, &def))
return NULL;
diff --git a/source/gameengine/Ketsji/KX_Scene.h b/source/gameengine/Ketsji/KX_Scene.h
index f8480753395..bb329da99de 100644
--- a/source/gameengine/Ketsji/KX_Scene.h
+++ b/source/gameengine/Ketsji/KX_Scene.h
@@ -237,7 +237,7 @@ protected:
/**
* The execution priority of replicated object actuators?
- */
+ */
int m_ueberExecutionPriority;
/**
@@ -295,7 +295,7 @@ protected:
KX_ObstacleSimulation* m_obstacleSimulation;
-public:
+public:
KX_Scene(class SCA_IInputDevice* keyboarddevice,
class SCA_IInputDevice* mousedevice,
class NG_NetworkDeviceInterface* ndi,
@@ -303,7 +303,7 @@ public:
struct Scene* scene,
class RAS_ICanvas* canvas);
- virtual
+ virtual
~KX_Scene();
RAS_BucketManager* GetBucketManager();
@@ -349,11 +349,11 @@ public:
void LogicUpdateFrame(double curtime, bool frame);
void UpdateAnimations(double curtime);
- void
+ void
LogicEndFrame(
);
- CListValue*
+ CListValue*
GetTempObjectList(
);
@@ -361,23 +361,23 @@ public:
GetObjectList(
);
- CListValue*
+ CListValue*
GetInactiveList(
);
- CListValue*
+ CListValue*
GetRootParentList(
);
- CListValue*
+ CListValue*
GetLightList(
);
- SCA_LogicManager*
+ SCA_LogicManager *
GetLogicManager(
);
- SCA_TimeEventManager*
+ SCA_TimeEventManager *
GetTimeEventManager(
);
@@ -426,7 +426,7 @@ public:
);
/** Find the currently active camera. */
- KX_Camera*
+ KX_Camera*
GetActiveCamera(
);
@@ -435,7 +435,7 @@ public:
* camera is not present in the camera list, it will be added
*/
- void
+ void
SetActiveCamera(
class KX_Camera*
);
@@ -453,7 +453,7 @@ public:
* Activates new desired canvas width set at design time.
* \param width The new desired width.
*/
- void
+ void
SetCanvasDesignWidth(
unsigned int width
);
@@ -461,7 +461,7 @@ public:
* Activates new desired canvas height set at design time.
* \param width The new desired height.
*/
- void
+ void
SetCanvasDesignHeight(
unsigned int height
);
@@ -469,7 +469,7 @@ public:
* Returns the current desired canvas width set at design time.
* \return The desired width.
*/
- unsigned int
+ unsigned int
GetCanvasDesignWidth(
void
) const;
@@ -478,7 +478,7 @@ public:
* Returns the current desired canvas height set at design time.
* \return The desired height.
*/
- unsigned int
+ unsigned int
GetCanvasDesignHeight(
void
) const;
@@ -617,7 +617,7 @@ public:
static PyObject* pyattr_get_drawing_callback_post(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_drawing_callback_post(void *selv_v, const KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- virtual PyObject* py_repr(void) { return PyUnicode_From_STR_String(GetName()); }
+ virtual PyObject *py_repr(void) { return PyUnicode_From_STR_String(GetName()); }
/* getitem/setitem */
static PyMappingMethods Mapping;
@@ -626,10 +626,10 @@ public:
/**
* Run the registered python drawing functions.
*/
- void RunDrawingCallbacks(PyObject* cb_list);
+ void RunDrawingCallbacks(PyObject *cb_list);
- PyObject* GetPreDrawCB() { return m_draw_call_pre; }
- PyObject* GetPostDrawCB() { return m_draw_call_post; }
+ PyObject *GetPreDrawCB() { return m_draw_call_pre; }
+ PyObject *GetPostDrawCB() { return m_draw_call_post; }
#endif
/**
diff --git a/source/gameengine/Ketsji/KX_SceneActuator.cpp b/source/gameengine/Ketsji/KX_SceneActuator.cpp
index 781c1fdab87..83b57dee7c1 100644
--- a/source/gameengine/Ketsji/KX_SceneActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SceneActuator.cpp
@@ -256,7 +256,7 @@ PyAttributeDef KX_SceneActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_SceneActuator::pyattr_get_camera(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SceneActuator::pyattr_get_camera(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SceneActuator* actuator = static_cast<KX_SceneActuator*>(self);
if (!actuator->m_camera)
@@ -279,7 +279,7 @@ int KX_SceneActuator::pyattr_set_camera(void *self, const struct KX_PYATTRIBUTE_
if (camOb==NULL) {
actuator->m_camera= NULL;
}
- else {
+ else {
actuator->m_camera = camOb;
actuator->m_camera->RegisterActuator(actuator);
}
diff --git a/source/gameengine/Ketsji/KX_SceneActuator.h b/source/gameengine/Ketsji/KX_SceneActuator.h
index 8e157544e2e..0b633334cce 100644
--- a/source/gameengine/Ketsji/KX_SceneActuator.h
+++ b/source/gameengine/Ketsji/KX_SceneActuator.h
@@ -99,7 +99,7 @@ class KX_SceneActuator : public SCA_IActuator
/* Python interface ---------------------------------------------------- */
/* --------------------------------------------------------------------- */
- static PyObject* pyattr_get_camera(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_camera(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_camera(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_SoundActuator.cpp b/source/gameengine/Ketsji/KX_SoundActuator.cpp
index db91cea9074..c0191db640a 100644
--- a/source/gameengine/Ketsji/KX_SoundActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SoundActuator.cpp
@@ -358,7 +358,7 @@ KX_PYMETHODDEF_DOC_NOARGS(KX_SoundActuator, stopSound,
}
/* Atribute setting and getting -------------------------------------------- */
-PyObject* KX_SoundActuator::pyattr_get_3d_property(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SoundActuator::pyattr_get_3d_property(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SoundActuator * actuator = static_cast<KX_SoundActuator *> (self);
const char* prop = attrdef->m_name;
@@ -392,11 +392,11 @@ PyObject* KX_SoundActuator::pyattr_get_3d_property(void *self, const struct KX_P
Py_RETURN_NONE;
}
- PyObject* result = PyFloat_FromDouble(result_value);
+ PyObject *result = PyFloat_FromDouble(result_value);
return result;
}
-PyObject* KX_SoundActuator::pyattr_get_audposition(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SoundActuator::pyattr_get_audposition(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SoundActuator * actuator = static_cast<KX_SoundActuator *> (self);
float position = 0.0;
@@ -404,32 +404,32 @@ PyObject* KX_SoundActuator::pyattr_get_audposition(void *self, const struct KX_P
if (!actuator->m_handle.isNull())
position = actuator->m_handle->getPosition();
- PyObject* result = PyFloat_FromDouble(position);
+ PyObject *result = PyFloat_FromDouble(position);
return result;
}
-PyObject* KX_SoundActuator::pyattr_get_gain(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SoundActuator::pyattr_get_gain(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SoundActuator * actuator = static_cast<KX_SoundActuator *> (self);
float gain = actuator->m_volume;
- PyObject* result = PyFloat_FromDouble(gain);
+ PyObject *result = PyFloat_FromDouble(gain);
return result;
}
-PyObject* KX_SoundActuator::pyattr_get_pitch(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SoundActuator::pyattr_get_pitch(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SoundActuator * actuator = static_cast<KX_SoundActuator *> (self);
float pitch = actuator->m_pitch;
- PyObject* result = PyFloat_FromDouble(pitch);
+ PyObject *result = PyFloat_FromDouble(pitch);
return result;
}
-PyObject* KX_SoundActuator::pyattr_get_sound(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SoundActuator::pyattr_get_sound(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SoundActuator * actuator = static_cast<KX_SoundActuator *> (self);
if (!actuator->m_sound.isNull())
@@ -542,7 +542,7 @@ int KX_SoundActuator::pyattr_set_pitch(void *self, const struct KX_PYATTRIBUTE_D
int KX_SoundActuator::pyattr_set_sound(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value)
{
- PyObject* sound = NULL;
+ PyObject *sound = NULL;
KX_SoundActuator * actuator = static_cast<KX_SoundActuator *> (self);
if (!PyArg_Parse(value, "O", &sound))
return PY_SET_ATTR_FAIL;
diff --git a/source/gameengine/Ketsji/KX_SoundActuator.h b/source/gameengine/Ketsji/KX_SoundActuator.h
index dbdb17d0da5..fcaf214dd90 100644
--- a/source/gameengine/Ketsji/KX_SoundActuator.h
+++ b/source/gameengine/Ketsji/KX_SoundActuator.h
@@ -115,12 +115,12 @@ public:
static int pyattr_set_type(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static int pyattr_set_sound(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- static PyObject* pyattr_get_3d_property(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_audposition(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_gain(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_pitch(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_type(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_sound(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_3d_property(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_audposition(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_gain(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_pitch(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_type(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_sound(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_SteeringActuator.cpp b/source/gameengine/Ketsji/KX_SteeringActuator.cpp
index 16b9285386a..2fa72c04a20 100644
--- a/source/gameengine/Ketsji/KX_SteeringActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SteeringActuator.cpp
@@ -253,7 +253,7 @@ bool KX_SteeringActuator::Update(double curtime, bool frame)
static const MT_Vector3 PATH_COLOR(1,0,0);
m_navmesh->DrawPath(m_path, m_pathLen, PATH_COLOR);
}
- }
+ }
}
break;
@@ -285,7 +285,7 @@ bool KX_SteeringActuator::Update(double curtime, bool frame)
//temporary solution: set 2D steering velocity directly to obj
//correct way is to apply physical force
MT_Vector3 curvel = obj->GetLinearVelocity();
- newvel.z() = curvel.z();
+ newvel.z() = curvel.z();
obj->setLinearVelocity(newvel, false);
}
else
@@ -356,8 +356,8 @@ static bool getNavmeshNormal(dtStatNavMesh* navmesh, const MT_Vector3& pos, MT_V
{
static const float polyPickExt[3] = {2, 4, 2};
float spos[3];
- pos.getValue(spos);
- flipAxes(spos);
+ pos.getValue(spos);
+ flipAxes(spos);
dtStatPolyRef sPolyRef = navmesh->findNearestPoly(spos, polyPickExt);
if (sPolyRef == 0)
return false;
@@ -382,7 +382,7 @@ static bool getNavmeshNormal(dtStatNavMesh* navmesh, const MT_Vector3& pos, MT_V
{
distMin = dist;
idxMin = i;
- }
+ }
}
if (idxMin>=0)
@@ -416,7 +416,7 @@ void KX_SteeringActuator::HandleActorFace(MT_Vector3& velocity)
KX_GameObject* curobj = (KX_GameObject*) GetParent();
MT_Vector3 dir = m_facingMode==0 ? curobj->NodeGetLocalOrientation().getColumn(1) : velocity;
if (dir.fuzzyZero())
- return;
+ return;
dir.normalize();
MT_Vector3 up(0,0,1);
MT_Vector3 left;
@@ -431,7 +431,7 @@ void KX_SteeringActuator::HandleActorFace(MT_Vector3& velocity)
{
left = (dir.cross(up)).safe_normalized();
- dir = (-left.cross(normal)).safe_normalized();
+ dir = (-left.cross(normal)).safe_normalized();
up = normal;
}
}
@@ -495,7 +495,7 @@ void KX_SteeringActuator::HandleActorFace(MT_Vector3& velocity)
MT_Point3 localpos;
localpos = curobj->GetSGNode()->GetLocalPosition();
MT_Matrix3x3 parentmatinv;
- parentmatinv = parentObject->NodeGetWorldOrientation ().inverse ();
+ parentmatinv = parentObject->NodeGetWorldOrientation ().inverse ();
mat = parentmatinv * mat;
mat = m_parentlocalmat * mat;
curobj->NodeSetLocalOrientation(mat);
@@ -551,16 +551,16 @@ PyAttributeDef KX_SteeringActuator::Attributes[] = {
KX_PYATTRIBUTE_FLOAT_RW("turnspeed", 0.0f, 720.0f, KX_SteeringActuator, m_turnspeed),
KX_PYATTRIBUTE_BOOL_RW("selfterminated", KX_SteeringActuator, m_isSelfTerminated),
KX_PYATTRIBUTE_BOOL_RW("enableVisualization", KX_SteeringActuator, m_enableVisualization),
- KX_PYATTRIBUTE_RO_FUNCTION("steeringVec", KX_SteeringActuator, pyattr_get_steeringVec),
+ KX_PYATTRIBUTE_RO_FUNCTION("steeringVec", KX_SteeringActuator, pyattr_get_steeringVec),
KX_PYATTRIBUTE_SHORT_RW("facingMode", 0, 6, true, KX_SteeringActuator, m_facingMode),
KX_PYATTRIBUTE_INT_RW("pathUpdatePeriod", -1, 100000, true, KX_SteeringActuator, m_pathUpdatePeriod),
{ NULL } //Sentinel
};
-PyObject* KX_SteeringActuator::pyattr_get_target(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SteeringActuator::pyattr_get_target(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SteeringActuator* actuator = static_cast<KX_SteeringActuator*>(self);
- if (!actuator->m_target)
+ if (!actuator->m_target)
Py_RETURN_NONE;
else
return actuator->m_target->GetProxy();
@@ -575,7 +575,7 @@ int KX_SteeringActuator::pyattr_set_target(void *self, const struct KX_PYATTRIBU
return PY_SET_ATTR_FAIL; // ConvertPythonToGameObject sets the error
if (actuator->m_target != NULL)
- actuator->m_target->UnregisterActuator(actuator);
+ actuator->m_target->UnregisterActuator(actuator);
actuator->m_target = (KX_GameObject*) gameobj;
@@ -585,10 +585,10 @@ int KX_SteeringActuator::pyattr_set_target(void *self, const struct KX_PYATTRIBU
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_SteeringActuator::pyattr_get_navmesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SteeringActuator::pyattr_get_navmesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SteeringActuator* actuator = static_cast<KX_SteeringActuator*>(self);
- if (!actuator->m_navmesh)
+ if (!actuator->m_navmesh)
Py_RETURN_NONE;
else
return actuator->m_navmesh->GetProxy();
@@ -609,7 +609,7 @@ int KX_SteeringActuator::pyattr_set_navmesh(void *self, const struct KX_PYATTRIB
}
if (actuator->m_navmesh != NULL)
- actuator->m_navmesh->UnregisterActuator(actuator);
+ actuator->m_navmesh->UnregisterActuator(actuator);
actuator->m_navmesh = static_cast<KX_NavMeshObject*>(gameobj);
@@ -619,7 +619,7 @@ int KX_SteeringActuator::pyattr_set_navmesh(void *self, const struct KX_PYATTRIB
return PY_SET_ATTR_SUCCESS;
}
-PyObject* KX_SteeringActuator::pyattr_get_steeringVec(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_SteeringActuator::pyattr_get_steeringVec(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_SteeringActuator* actuator = static_cast<KX_SteeringActuator*>(self);
const MT_Vector3& steeringVec = actuator->GetSteeringVec();
diff --git a/source/gameengine/Ketsji/KX_SteeringActuator.h b/source/gameengine/Ketsji/KX_SteeringActuator.h
index c22a636cd95..341421d8948 100644
--- a/source/gameengine/Ketsji/KX_SteeringActuator.h
+++ b/source/gameengine/Ketsji/KX_SteeringActuator.h
@@ -82,7 +82,7 @@ public:
KX_GameObject *navmesh,
float distance,
float velocity,
- float acceleration,
+ float acceleration,
float turnspeed,
bool isSelfTerminated,
int pathUpdatePeriod,
@@ -107,11 +107,11 @@ public:
/* --------------------------------------------------------------------- */
/* These are used to get and set m_target */
- static PyObject* pyattr_get_target(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_target(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- static PyObject* pyattr_get_navmesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_navmesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
- static PyObject* pyattr_get_steeringVec(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_target(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static int pyattr_set_target(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
+ static PyObject *pyattr_get_navmesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static int pyattr_set_navmesh(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
+ static PyObject *pyattr_get_steeringVec(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_TouchSensor.cpp b/source/gameengine/Ketsji/KX_TouchSensor.cpp
index d7bcf1306a1..885ac70061e 100644
--- a/source/gameengine/Ketsji/KX_TouchSensor.cpp
+++ b/source/gameengine/Ketsji/KX_TouchSensor.cpp
@@ -331,7 +331,7 @@ PyAttributeDef KX_TouchSensor::Attributes[] = {
/* Python API */
-PyObject* KX_TouchSensor::pyattr_get_object_hit(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_TouchSensor::pyattr_get_object_hit(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_TouchSensor* self= static_cast<KX_TouchSensor*>(self_v);
@@ -341,7 +341,7 @@ PyObject* KX_TouchSensor::pyattr_get_object_hit(void *self_v, const KX_PYATTRIBU
Py_RETURN_NONE;
}
-PyObject* KX_TouchSensor::pyattr_get_object_hit_list(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_TouchSensor::pyattr_get_object_hit_list(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_TouchSensor* self= static_cast<KX_TouchSensor*>(self_v);
return self->m_colliders->GetProxy();
diff --git a/source/gameengine/Ketsji/KX_TouchSensor.h b/source/gameengine/Ketsji/KX_TouchSensor.h
index d739144d70d..c80b8598e43 100644
--- a/source/gameengine/Ketsji/KX_TouchSensor.h
+++ b/source/gameengine/Ketsji/KX_TouchSensor.h
@@ -56,7 +56,7 @@ protected:
/**
* The sensor should only look for objects with this property.
*/
- STR_String m_touchedpropname;
+ STR_String m_touchedpropname;
bool m_bFindMaterial;
bool m_bTouchPulse; /* changes in the colliding objects trigger pulses */
diff --git a/source/gameengine/Ketsji/KX_TrackToActuator.cpp b/source/gameengine/Ketsji/KX_TrackToActuator.cpp
index 17274159545..1597948bafe 100644
--- a/source/gameengine/Ketsji/KX_TrackToActuator.cpp
+++ b/source/gameengine/Ketsji/KX_TrackToActuator.cpp
@@ -166,7 +166,7 @@ static void compatible_eulFast(float *eul, float *oldrot)
static MT_Matrix3x3 matrix3x3_interpol(MT_Matrix3x3 oldmat, MT_Matrix3x3 mat, int m_time)
{
- float eul[3], oldeul[3];
+ float eul[3], oldeul[3];
Mat3ToEulOld(oldmat, oldeul);
Mat3ToEulOld(mat, eul);
@@ -238,7 +238,7 @@ void KX_TrackToActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
bool KX_TrackToActuator::Update(double curtime, bool frame)
{
- bool result = false;
+ bool result = false;
bool bNegativeEvent = IsNegativeEvent();
RemoveAllEvents();
@@ -395,7 +395,7 @@ bool KX_TrackToActuator::Update(double curtime, bool frame)
localpos = curobj->GetSGNode()->GetLocalPosition();
// Get the inverse of the parent matrix
MT_Matrix3x3 parentmatinv;
- parentmatinv = m_parentobj->NodeGetWorldOrientation ().inverse ();
+ parentmatinv = m_parentobj->NodeGetWorldOrientation ().inverse ();
// transform the local coordinate system into the parents system
mat = parentmatinv * mat;
// append the initial parent local rotation matrix
@@ -458,10 +458,10 @@ PyAttributeDef KX_TrackToActuator::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_TrackToActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_TrackToActuator::pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef)
{
KX_TrackToActuator* actuator = static_cast<KX_TrackToActuator*>(self);
- if (!actuator->m_object)
+ if (!actuator->m_object)
Py_RETURN_NONE;
else
return actuator->m_object->GetProxy();
@@ -476,7 +476,7 @@ int KX_TrackToActuator::pyattr_set_object(void *self, const struct KX_PYATTRIBUT
return PY_SET_ATTR_FAIL; // ConvertPythonToGameObject sets the error
if (actuator->m_object != NULL)
- actuator->m_object->UnregisterActuator(actuator);
+ actuator->m_object->UnregisterActuator(actuator);
actuator->m_object = (SCA_IObject*) gameobj;
diff --git a/source/gameengine/Ketsji/KX_TrackToActuator.h b/source/gameengine/Ketsji/KX_TrackToActuator.h
index fb2ced2a415..6329c7b34d9 100644
--- a/source/gameengine/Ketsji/KX_TrackToActuator.h
+++ b/source/gameengine/Ketsji/KX_TrackToActuator.h
@@ -74,8 +74,8 @@ class KX_TrackToActuator : public SCA_IActuator
/* Python part */
/* These are used to get and set m_ob */
- static PyObject* pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
- static int pyattr_set_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
+ static PyObject *pyattr_get_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef);
+ static int pyattr_set_object(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
#endif // WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_VehicleWrapper.cpp b/source/gameengine/Ketsji/KX_VehicleWrapper.cpp
index 1c03df80dc1..b5d6f11a2d5 100644
--- a/source/gameengine/Ketsji/KX_VehicleWrapper.cpp
+++ b/source/gameengine/Ketsji/KX_VehicleWrapper.cpp
@@ -34,11 +34,11 @@ KX_VehicleWrapper::~KX_VehicleWrapper()
#ifdef WITH_PYTHON
-PyObject* KX_VehicleWrapper::PyAddWheel(PyObject* args)
+PyObject *KX_VehicleWrapper::PyAddWheel(PyObject *args)
{
- PyObject* pylistPos,*pylistDir,*pylistAxleDir;
- PyObject* wheelGameObject;
+ PyObject *pylistPos,*pylistDir,*pylistAxleDir;
+ PyObject *wheelGameObject;
float suspensionRestLength,wheelRadius;
int hasSteering;
@@ -83,7 +83,7 @@ PyObject* KX_VehicleWrapper::PyAddWheel(PyObject* args)
-PyObject* KX_VehicleWrapper::PyGetWheelPosition(PyObject* args)
+PyObject *KX_VehicleWrapper::PyGetWheelPosition(PyObject *args)
{
int wheelIndex;
@@ -98,7 +98,7 @@ PyObject* KX_VehicleWrapper::PyGetWheelPosition(PyObject* args)
return NULL;
}
-PyObject* KX_VehicleWrapper::PyGetWheelRotation(PyObject* args)
+PyObject *KX_VehicleWrapper::PyGetWheelRotation(PyObject *args)
{
int wheelIndex;
if (PyArg_ParseTuple(args,"i:getWheelRotation",&wheelIndex))
@@ -108,7 +108,7 @@ PyObject* KX_VehicleWrapper::PyGetWheelRotation(PyObject* args)
return NULL;
}
-PyObject* KX_VehicleWrapper::PyGetWheelOrientationQuaternion(PyObject* args)
+PyObject *KX_VehicleWrapper::PyGetWheelOrientationQuaternion(PyObject *args)
{
int wheelIndex;
if (PyArg_ParseTuple(args,"i:getWheelOrientationQuaternion",&wheelIndex))
@@ -124,20 +124,20 @@ PyObject* KX_VehicleWrapper::PyGetWheelOrientationQuaternion(PyObject* args)
}
-PyObject* KX_VehicleWrapper::PyGetNumWheels(PyObject* args)
+PyObject *KX_VehicleWrapper::PyGetNumWheels(PyObject *args)
{
return PyLong_FromSsize_t(m_vehicle->GetNumWheels());
}
-PyObject* KX_VehicleWrapper::PyGetConstraintId(PyObject* args)
+PyObject *KX_VehicleWrapper::PyGetConstraintId(PyObject *args)
{
return PyLong_FromSsize_t(m_vehicle->GetUserConstraintId());
}
-PyObject* KX_VehicleWrapper::PyApplyEngineForce(PyObject* args)
+PyObject *KX_VehicleWrapper::PyApplyEngineForce(PyObject *args)
{
float force;
int wheelIndex;
@@ -153,7 +153,7 @@ PyObject* KX_VehicleWrapper::PyApplyEngineForce(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_VehicleWrapper::PySetTyreFriction(PyObject* args)
+PyObject *KX_VehicleWrapper::PySetTyreFriction(PyObject *args)
{
float wheelFriction;
int wheelIndex;
@@ -168,7 +168,7 @@ PyObject* KX_VehicleWrapper::PySetTyreFriction(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_VehicleWrapper::PySetSuspensionStiffness(PyObject* args)
+PyObject *KX_VehicleWrapper::PySetSuspensionStiffness(PyObject *args)
{
float suspensionStiffness;
int wheelIndex;
@@ -183,7 +183,7 @@ PyObject* KX_VehicleWrapper::PySetSuspensionStiffness(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_VehicleWrapper::PySetSuspensionDamping(PyObject* args)
+PyObject *KX_VehicleWrapper::PySetSuspensionDamping(PyObject *args)
{
float suspensionDamping;
int wheelIndex;
@@ -197,7 +197,7 @@ PyObject* KX_VehicleWrapper::PySetSuspensionDamping(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_VehicleWrapper::PySetSuspensionCompression(PyObject* args)
+PyObject *KX_VehicleWrapper::PySetSuspensionCompression(PyObject *args)
{
float suspensionCompression;
int wheelIndex;
@@ -211,7 +211,7 @@ PyObject* KX_VehicleWrapper::PySetSuspensionCompression(PyObject* args)
Py_RETURN_NONE;
}
-PyObject* KX_VehicleWrapper::PySetRollInfluence(PyObject* args)
+PyObject *KX_VehicleWrapper::PySetRollInfluence(PyObject *args)
{
float rollInfluence;
int wheelIndex;
@@ -227,7 +227,7 @@ PyObject* KX_VehicleWrapper::PySetRollInfluence(PyObject* args)
}
-PyObject* KX_VehicleWrapper::PyApplyBraking(PyObject* args)
+PyObject *KX_VehicleWrapper::PyApplyBraking(PyObject *args)
{
float braking;
int wheelIndex;
@@ -245,7 +245,7 @@ PyObject* KX_VehicleWrapper::PyApplyBraking(PyObject* args)
-PyObject* KX_VehicleWrapper::PySetSteeringValue(PyObject* args)
+PyObject *KX_VehicleWrapper::PySetSteeringValue(PyObject *args)
{
float steeringValue;
int wheelIndex;
@@ -261,7 +261,7 @@ PyObject* KX_VehicleWrapper::PySetSteeringValue(PyObject* args)
}
-PyObject* KX_VehicleWrapper::PyGetConstraintType(PyObject* args)
+PyObject *KX_VehicleWrapper::PyGetConstraintType(PyObject *args)
{
return PyLong_FromSsize_t(m_vehicle->GetUserConstraintType());
}
diff --git a/source/gameengine/Ketsji/KX_VertexProxy.cpp b/source/gameengine/Ketsji/KX_VertexProxy.cpp
index d489c015273..461563d4512 100644
--- a/source/gameengine/Ketsji/KX_VertexProxy.cpp
+++ b/source/gameengine/Ketsji/KX_VertexProxy.cpp
@@ -101,85 +101,85 @@ PyAttributeDef KX_VertexProxy::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject* KX_VertexProxy::pyattr_get_x(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_x(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getXYZ()[0]);
}
-PyObject* KX_VertexProxy::pyattr_get_y(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_y(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getXYZ()[1]);
}
-PyObject* KX_VertexProxy::pyattr_get_z(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_z(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getXYZ()[2]);
}
-PyObject* KX_VertexProxy::pyattr_get_r(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_r(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getRGBA()[0]/255.0);
}
-PyObject* KX_VertexProxy::pyattr_get_g(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_g(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getRGBA()[1]/255.0);
}
-PyObject* KX_VertexProxy::pyattr_get_b(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_b(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getRGBA()[2]/255.0);
}
-PyObject* KX_VertexProxy::pyattr_get_a(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_a(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getRGBA()[3]/255.0);
}
-PyObject* KX_VertexProxy::pyattr_get_u(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_u(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getUV1()[0]);
}
-PyObject* KX_VertexProxy::pyattr_get_v(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_v(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getUV1()[1]);
}
-PyObject* KX_VertexProxy::pyattr_get_u2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_u2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getUV2()[0]);
}
-PyObject* KX_VertexProxy::pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyFloat_FromDouble(self->m_vertex->getUV2()[1]);
}
-PyObject* KX_VertexProxy::pyattr_get_XYZ(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_XYZ(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyObjectFrom(MT_Vector3(self->m_vertex->getXYZ()));
}
-PyObject* KX_VertexProxy::pyattr_get_UV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_UV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyObjectFrom(MT_Point2(self->m_vertex->getUV1()));
}
-PyObject* KX_VertexProxy::pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
const unsigned char *colp = self->m_vertex->getRGBA();
@@ -188,7 +188,7 @@ PyObject* KX_VertexProxy::pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DE
return PyObjectFrom(color);
}
-PyObject* KX_VertexProxy::pyattr_get_normal(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
+PyObject *KX_VertexProxy::pyattr_get_normal(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef)
{
KX_VertexProxy* self= static_cast<KX_VertexProxy*>(self_v);
return PyObjectFrom(MT_Vector3(self->m_vertex->getNormal()));
@@ -459,12 +459,12 @@ CValue* KX_VertexProxy::GetReplica() { return NULL;}
// stuff for python integration
-PyObject* KX_VertexProxy::PyGetXYZ()
+PyObject *KX_VertexProxy::PyGetXYZ()
{
return PyObjectFrom(MT_Point3(m_vertex->getXYZ()));
}
-PyObject* KX_VertexProxy::PySetXYZ(PyObject* value)
+PyObject *KX_VertexProxy::PySetXYZ(PyObject *value)
{
MT_Point3 vec;
if (!PyVecTo(value, vec))
@@ -475,12 +475,12 @@ PyObject* KX_VertexProxy::PySetXYZ(PyObject* value)
Py_RETURN_NONE;
}
-PyObject* KX_VertexProxy::PyGetNormal()
+PyObject *KX_VertexProxy::PyGetNormal()
{
return PyObjectFrom(MT_Vector3(m_vertex->getNormal()));
}
-PyObject* KX_VertexProxy::PySetNormal(PyObject* value)
+PyObject *KX_VertexProxy::PySetNormal(PyObject *value)
{
MT_Vector3 vec;
if (!PyVecTo(value, vec))
@@ -492,13 +492,13 @@ PyObject* KX_VertexProxy::PySetNormal(PyObject* value)
}
-PyObject* KX_VertexProxy::PyGetRGBA()
+PyObject *KX_VertexProxy::PyGetRGBA()
{
int *rgba = (int *) m_vertex->getRGBA();
return PyLong_FromSsize_t(*rgba);
}
-PyObject* KX_VertexProxy::PySetRGBA(PyObject* value)
+PyObject *KX_VertexProxy::PySetRGBA(PyObject *value)
{
if (PyLong_Check(value)) {
int rgba = PyLong_AsSsize_t(value);
@@ -521,12 +521,12 @@ PyObject* KX_VertexProxy::PySetRGBA(PyObject* value)
}
-PyObject* KX_VertexProxy::PyGetUV()
+PyObject *KX_VertexProxy::PyGetUV()
{
return PyObjectFrom(MT_Vector2(m_vertex->getUV1()));
}
-PyObject* KX_VertexProxy::PySetUV(PyObject* value)
+PyObject *KX_VertexProxy::PySetUV(PyObject *value)
{
MT_Point2 vec;
if (!PyVecTo(value, vec))
@@ -537,17 +537,17 @@ PyObject* KX_VertexProxy::PySetUV(PyObject* value)
Py_RETURN_NONE;
}
-PyObject* KX_VertexProxy::PyGetUV2()
+PyObject *KX_VertexProxy::PyGetUV2()
{
return PyObjectFrom(MT_Vector2(m_vertex->getUV2()));
}
-PyObject* KX_VertexProxy::PySetUV2(PyObject* args)
+PyObject *KX_VertexProxy::PySetUV2(PyObject *args)
{
MT_Point2 vec;
unsigned int unit= RAS_TexVert::SECOND_UV;
- PyObject* list= NULL;
+ PyObject *list = NULL;
if (!PyArg_ParseTuple(args, "O|i:setUV2", &list, &unit))
return NULL;
diff --git a/source/gameengine/Ketsji/KX_VertexProxy.h b/source/gameengine/Ketsji/KX_VertexProxy.h
index 3084e5fac93..f56e2be26a3 100644
--- a/source/gameengine/Ketsji/KX_VertexProxy.h
+++ b/source/gameengine/Ketsji/KX_VertexProxy.h
@@ -59,21 +59,21 @@ public:
// stuff for python integration
- static PyObject* pyattr_get_x(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_y(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_z(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_r(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_g(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_b(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_a(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_u(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_v(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_u2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_XYZ(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_UV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
- static PyObject* pyattr_get_normal(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_x(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_y(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_z(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_r(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_g(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_b(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_a(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_u(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_v(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_u2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_v2(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_XYZ(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_UV(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_color(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
+ static PyObject *pyattr_get_normal(void *self_v, const KX_PYATTRIBUTE_DEF *attrdef);
static int pyattr_set_x(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static int pyattr_set_y(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
static int pyattr_set_z(void *self, const struct KX_PYATTRIBUTE_DEF *attrdef, PyObject *value);
diff --git a/source/gameengine/Ketsji/KX_WorldIpoController.h b/source/gameengine/Ketsji/KX_WorldIpoController.h
index 409b1fec321..575d4e72f14 100644
--- a/source/gameengine/Ketsji/KX_WorldIpoController.h
+++ b/source/gameengine/Ketsji/KX_WorldIpoController.h
@@ -72,15 +72,15 @@ public:
m_modified = true;
}
- void SetModifyMistStart(bool modify) {
+ void SetModifyMistStart(bool modify) {
m_modify_mist_start = modify;
}
- void SetModifyMistColor(bool modify) {
+ void SetModifyMistColor(bool modify) {
m_modify_mist_color = modify;
}
- void SetModifyMistDist(bool modify) {
+ void SetModifyMistDist(bool modify) {
m_modify_mist_dist = modify;
}
diff --git a/source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.h b/source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.h
index 92ba6100359..f9d2146a766 100644
--- a/source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.h
+++ b/source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.h
@@ -36,7 +36,7 @@
#include "NG_NetworkDeviceInterface.h"
class NG_LoopBackNetworkDeviceInterface : public NG_NetworkDeviceInterface
-{
+{
std::deque<NG_NetworkMessage*> m_messages[2];
int m_currentQueue;
diff --git a/source/gameengine/Network/NG_NetworkScene.h b/source/gameengine/Network/NG_NetworkScene.h
index 41ac8ead5e4..381b71da0d7 100644
--- a/source/gameengine/Network/NG_NetworkScene.h
+++ b/source/gameengine/Network/NG_NetworkScene.h
@@ -51,7 +51,7 @@ class NG_NetworkDeviceInterface;
class NG_NetworkScene
{
- class NG_NetworkDeviceInterface *m_networkdevice;
+ class NG_NetworkDeviceInterface *m_networkdevice;
CTR_Map<STR_HashedString, class NG_NetworkObject *> m_networkObjects;
// CTR_Maps used as a 'Bloom' filter
@@ -107,7 +107,7 @@ protected:
* Releases messages for the given message map.
* \param map Message map with messages.
*/
- void ClearMessageMap(TMessageMap& map);
+ void ClearMessageMap(TMessageMap& map);
#ifdef WITH_CXX_GUARDEDALLOC
diff --git a/source/gameengine/Physics/Bullet/CcdGraphicController.h b/source/gameengine/Physics/Bullet/CcdGraphicController.h
index 60ff475832b..15edfeb5759 100644
--- a/source/gameengine/Physics/Bullet/CcdGraphicController.h
+++ b/source/gameengine/Physics/Bullet/CcdGraphicController.h
@@ -33,7 +33,7 @@ class CcdPhysicsEnvironment;
class btCollisionObject;
///CcdGraphicController is a graphic object that supports view frustrum culling and occlusion
-class CcdGraphicController : public PHY_IGraphicController
+class CcdGraphicController : public PHY_IGraphicController
{
public:
CcdGraphicController(CcdPhysicsEnvironment* phyEnv, PHY_IMotionState* motionState);
diff --git a/source/gameengine/Physics/Bullet/CcdPhysicsController.cpp b/source/gameengine/Physics/Bullet/CcdPhysicsController.cpp
index ed2b9cfcb0b..81bf66d9536 100644
--- a/source/gameengine/Physics/Bullet/CcdPhysicsController.cpp
+++ b/source/gameengine/Physics/Bullet/CcdPhysicsController.cpp
@@ -787,7 +787,7 @@ void CcdPhysicsController::PostProcessReplica(class PHY_IMotionState* motionsta
if (oldbody->getActivationState() == DISABLE_DEACTIVATION)
body->setActivationState(DISABLE_DEACTIVATION);
}
- }
+ }
// sensor object are added when needed
if (!m_cci.m_bSensor)
m_cci.m_physicsEnv->addCcdPhysicsController(this);
@@ -806,7 +806,7 @@ void CcdPhysicsController::PostProcessReplica(class PHY_IMotionState* motionsta
m_sumoObj = new SM_Object(
orgsumoobject->getShapeHandle(),
- orgsumoobject->getMaterialProps(),
+ orgsumoobject->getMaterialProps(),
orgsumoobject->getShapeProps(),
dynaparent);
@@ -1142,7 +1142,7 @@ void CcdPhysicsController::ApplyForce(float forceX,float forceY,float forceZ,bo
btTransform xform = m_object->getWorldTransform();
if (local)
- {
+ {
force = xform.getBasis()*force;
}
btRigidBody* body = GetRigidBody();
@@ -1661,7 +1661,7 @@ bool CcdShapeConstructionInfo::SetMesh(RAS_MeshObject* meshobj, DerivedMesh* dm,
}
if (vert_tag_array[mf->v3]==true) { /* *** v3 *** */
vert_tag_array[mf->v3]= false;
- *bt++ = v3->co[0];
+ *bt++ = v3->co[0];
*bt++ = v3->co[1];
*bt++ = v3->co[2];
}
@@ -1693,7 +1693,7 @@ bool CcdShapeConstructionInfo::SetMesh(RAS_MeshObject* meshobj, DerivedMesh* dm,
if (vert_tag_array[mf->v4]==true) { /* *** v4 *** */
vert_tag_array[mf->v4]= false;
*bt++ = v4->co[0];
- *bt++ = v4->co[1];
+ *bt++ = v4->co[1];
*bt++ = v4->co[2];
}
}
@@ -2089,7 +2089,7 @@ bool CcdShapeConstructionInfo::SetProxy(CcdShapeConstructionInfo* shapeInfo)
btCollisionShape* CcdShapeConstructionInfo::CreateBulletShape(btScalar margin, bool useGimpact, bool useBvh)
{
btCollisionShape* collisionShape = 0;
- btCompoundShape* compoundShape = 0;
+ btCompoundShape* compoundShape = 0;
if (m_shapeType == PHY_SHAPE_PROXY && m_shapeProxy != NULL)
return m_shapeProxy->CreateBulletShape(margin, useGimpact, useBvh);
@@ -2138,7 +2138,7 @@ btCollisionShape* CcdShapeConstructionInfo::CreateBulletShape(btScalar margin, b
// One possible optimization is to use directly the btBvhTriangleMeshShape when the scale is 1,1,1
// and btScaledBvhTriangleMeshShape otherwise.
if (useGimpact)
- {
+ {
btTriangleIndexVertexArray* indexVertexArrays = new btTriangleIndexVertexArray(
m_polygonIndexArray.size(),
&m_triFaceArray[0],
diff --git a/source/gameengine/Physics/Bullet/CcdPhysicsController.h b/source/gameengine/Physics/Bullet/CcdPhysicsController.h
index 94dc796df23..2204f224e7d 100644
--- a/source/gameengine/Physics/Bullet/CcdPhysicsController.h
+++ b/source/gameengine/Physics/Bullet/CcdPhysicsController.h
@@ -171,7 +171,7 @@ public:
btVector3 m_halfExtend;
btTransform m_childTrans;
btVector3 m_childScale;
- void* m_userData;
+ void* m_userData;
btAlignedObjectArray<btScalar> m_vertexArray; // Contains both vertex array for polytope shape and
// triangle array for concave mesh shape. Each vertex is 3 consecutive values
// In this case a triangle is made of 3 consecutive points
@@ -397,7 +397,7 @@ class btCollisionObject;
class btSoftBody;
///CcdPhysicsController is a physics object that supports continuous collision detection and time of impact based physics resolution.
-class CcdPhysicsController : public PHY_IPhysicsController
+class CcdPhysicsController : public PHY_IPhysicsController
{
protected:
btCollisionObject* m_object;
diff --git a/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp b/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp
index 5d28bf47401..55bbc0d33b9 100644
--- a/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp
+++ b/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp
@@ -303,13 +303,13 @@ static void DrawAabb(btIDebugDraw* debugDrawer,const btVector3& from,const btVec
{
for (j=0;j<3;j++)
{
- pa = btVector3(edgecoord[0]*halfExtents[0], edgecoord[1]*halfExtents[1],
+ pa = btVector3(edgecoord[0]*halfExtents[0], edgecoord[1]*halfExtents[1],
edgecoord[2]*halfExtents[2]);
pa+=center;
int othercoord = j%3;
edgecoord[othercoord]*=-1.f;
- pb = btVector3(edgecoord[0]*halfExtents[0], edgecoord[1]*halfExtents[1],
+ pb = btVector3(edgecoord[0]*halfExtents[0], edgecoord[1]*halfExtents[1],
edgecoord[2]*halfExtents[2]);
pb+=center;
@@ -484,9 +484,8 @@ void CcdPhysicsEnvironment::updateCcdPhysicsController(CcdPhysicsController* ctr
body->getCollisionShape()->calculateLocalInertia(newMass, inertia);
body->setMassProps(newMass, inertia);
m_dynamicsWorld->addRigidBody(body, newCollisionGroup, newCollisionMask);
- }
- else
- {
+ }
+ else {
m_dynamicsWorld->addCollisionObject(obj, newCollisionGroup, newCollisionMask);
}
}
@@ -605,7 +604,7 @@ bool CcdPhysicsEnvironment::proceedDeltaTime(double curTime,float timeStep,float
float subStep = timeStep / float(m_numTimeSubSteps);
i = m_dynamicsWorld->stepSimulation(interval,25,subStep);//perform always a full simulation step
-//uncomment next line to see where Bullet spend its time (printf in console)
+//uncomment next line to see where Bullet spend its time (printf in console)
//CProfileManager::dumpAll();
processFhSprings(curTime,i*subStep);
@@ -1084,7 +1083,7 @@ static bool GetHitTriangle(btCollisionShape* shape, CcdShapeConstructionInfo* sh
btScalar* graphicsbase = (btScalar*)(vertexbase+graphicsindex*stride);
- triangle[j] = btVector3(graphicsbase[0]*meshScaling.getX(),graphicsbase[1]*meshScaling.getY(),graphicsbase[2]*meshScaling.getZ());
+ triangle[j] = btVector3(graphicsbase[0]*meshScaling.getX(),graphicsbase[1]*meshScaling.getY(),graphicsbase[2]*meshScaling.getZ());
}
meshInterface->unLockReadOnlyVertexBase(0);
return true;
@@ -1248,7 +1247,7 @@ PHY_IPhysicsController* CcdPhysicsEnvironment::rayTest(PHY_IRayCastFilterCallbac
result.m_hitNormal[1] = rayCallback.m_hitNormalWorld.getY();
result.m_hitNormal[2] = rayCallback.m_hitNormalWorld.getZ();
filterCallback.reportHit(&result);
- }
+ }
return result.m_controller;
@@ -1391,7 +1390,7 @@ struct OcclusionBuffer
static bool project(btVector4* p,int n)
{
for (int i=0;i<n;++i)
- {
+ {
p[i][2]=1/p[i][3];
p[i][0]*=p[i][2];
p[i][1]*=p[i][2];
@@ -1611,7 +1610,7 @@ struct OcclusionBuffer
const int a=x[2]*y[0]+x[0]*y[1]-x[2]*y[1]-x[0]*y[2]+x[1]*y[2]-x[1]*y[0];
const btScalar ia=1/(btScalar)a;
const btScalar dzx=ia*(y[2]*(z[1]-z[0])+y[1]*(z[0]-z[2])+y[0]*(z[2]-z[1]));
- const btScalar dzy=ia*(x[2]*(z[0]-z[1])+x[0]*(z[1]-z[2])+x[1]*(z[2]-z[0]))-(dzx*width);
+ const btScalar dzy=ia*(x[2]*(z[0]-z[1])+x[0]*(z[1]-z[2])+x[1]*(z[2]-z[0]))-(dzx*width);
int c[]={ miy*x[1]+mix*y[0]-x[1]*y[0]-mix*y[1]+x[0]*y[1]-miy*x[0],
miy*x[2]+mix*y[1]-x[2]*y[1]-mix*y[2]+x[1]*y[2]-miy*x[1],
miy*x[0]+mix*y[2]-x[0]*y[2]-mix*y[0]+x[2]*y[0]-miy*x[2]};
@@ -1674,7 +1673,7 @@ struct OcclusionBuffer
const float* c,
const float* d,
const float face)
- {
+ {
btVector4 p[4];
transformM(a,p[0]);
transformM(b,p[1]);
@@ -1744,7 +1743,7 @@ struct DbvtCullingCallback : btDbvt::ICollide
Process(node);
}
void Process(const btDbvtNode* leaf)
- {
+ {
btBroadphaseProxy* proxy=(btBroadphaseProxy*)leaf->data;
// the client object is a graphic controller
CcdGraphicController* ctrl = static_cast<CcdGraphicController*>(proxy->m_clientObject);
@@ -1817,11 +1816,11 @@ bool CcdPhysicsEnvironment::cullingTest(PHY_CullingCallback callback, void* user
dispatcher.m_ocb = &gOcb;
// occlusion culling, the direction of the view is taken from the first plan which MUST be the near plane
btDbvt::collideOCL(m_cullingTree->m_sets[1].m_root,planes_n,planes_o,planes_n[0],nplanes,dispatcher);
- btDbvt::collideOCL(m_cullingTree->m_sets[0].m_root,planes_n,planes_o,planes_n[0],nplanes,dispatcher);
+ btDbvt::collideOCL(m_cullingTree->m_sets[0].m_root,planes_n,planes_o,planes_n[0],nplanes,dispatcher);
}
else {
btDbvt::collideKDOP(m_cullingTree->m_sets[1].m_root,planes_n,planes_o,nplanes,dispatcher);
- btDbvt::collideKDOP(m_cullingTree->m_sets[0].m_root,planes_n,planes_o,nplanes,dispatcher);
+ btDbvt::collideKDOP(m_cullingTree->m_sets[0].m_root,planes_n,planes_o,nplanes,dispatcher);
}
return true;
}
diff --git a/source/gameengine/Physics/common/PHY_DynamicTypes.h b/source/gameengine/Physics/common/PHY_DynamicTypes.h
index 69bbc7745e0..6994706ce2d 100644
--- a/source/gameengine/Physics/common/PHY_DynamicTypes.h
+++ b/source/gameengine/Physics/common/PHY_DynamicTypes.h
@@ -32,11 +32,11 @@ struct PHY__Vector2
operator const float* () const
{
return &m_vec[0];
- }
+ }
operator float* ()
{
return &m_vec[0];
- }
+ }
};
struct PHY__Vector3
@@ -46,11 +46,11 @@ struct PHY__Vector3
operator const float* () const
{
return &m_vec[0];
- }
+ }
operator float* ()
{
return &m_vec[0];
- }
+ }
};
struct PHY__Vector4
@@ -75,11 +75,11 @@ struct PHY__Vector4
operator const float* () const
{
return &m_vec[0];
- }
+ }
operator float* ()
{
return &m_vec[0];
- }
+ }
};
//typedef float PHY__Vector3[4];
diff --git a/source/gameengine/Physics/common/PHY_IController.h b/source/gameengine/Physics/common/PHY_IController.h
index 239ac3366e1..729abd8ec04 100644
--- a/source/gameengine/Physics/common/PHY_IController.h
+++ b/source/gameengine/Physics/common/PHY_IController.h
@@ -45,7 +45,7 @@ class PHY_IPhysicsEnvironment;
controlled by the physics engine. This includes the physics objects
and the graphics object for view frustrum and occlusion culling.
*/
-class PHY_IController
+class PHY_IController
{
public:
virtual ~PHY_IController();
diff --git a/source/gameengine/Physics/common/PHY_IMotionState.h b/source/gameengine/Physics/common/PHY_IMotionState.h
index 2eb2a9f39cf..72ff37468ee 100644
--- a/source/gameengine/Physics/common/PHY_IMotionState.h
+++ b/source/gameengine/Physics/common/PHY_IMotionState.h
@@ -43,7 +43,7 @@
class PHY_IMotionState
{
- public:
+ public:
virtual ~PHY_IMotionState();
virtual void getWorldPosition(float& posX,float& posY,float& posZ)=0;
diff --git a/source/gameengine/Physics/common/PHY_IPhysicsEnvironment.h b/source/gameengine/Physics/common/PHY_IPhysicsEnvironment.h
index 30d63e6695d..3f8699d25d2 100644
--- a/source/gameengine/Physics/common/PHY_IPhysicsEnvironment.h
+++ b/source/gameengine/Physics/common/PHY_IPhysicsEnvironment.h
@@ -48,7 +48,7 @@ class PHY_IPhysicsController;
*/
struct PHY_RayCastResult
{
- PHY_IPhysicsController* m_controller;
+ PHY_IPhysicsController* m_controller;
PHY__Vector3 m_hitPoint;
PHY__Vector3 m_hitNormal;
const RAS_MeshObject* m_meshObject; // !=NULL for mesh object (only for Bullet controllers)
diff --git a/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp b/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp
index 06251cd2282..7312b521788 100644
--- a/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp
+++ b/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp
@@ -110,7 +110,7 @@ void RAS_2DFilterManager::PrintShaderErrors(unsigned int shader, const char *tas
unsigned int RAS_2DFilterManager::CreateShaderProgram(const char* shadersource)
{
- GLuint program = 0;
+ GLuint program = 0;
GLuint fShader = glCreateShaderObjectARB(GL_FRAGMENT_SHADER);
GLint success;
@@ -469,7 +469,7 @@ void RAS_2DFilterManager::RenderFilters(RAS_ICanvas* canvas)
glEnable(GL_DEPTH_TEST);
glViewport(viewport[0],viewport[1],viewport[2],viewport[3]);
- EndShaderProgram();
+ EndShaderProgram();
glPopMatrix();
glMatrixMode(GL_MODELVIEW);
glPopMatrix();
diff --git a/source/gameengine/Rasterizer/RAS_BucketManager.cpp b/source/gameengine/Rasterizer/RAS_BucketManager.cpp
index 90587bb9739..457fd0ad90c 100644
--- a/source/gameengine/Rasterizer/RAS_BucketManager.cpp
+++ b/source/gameengine/Rasterizer/RAS_BucketManager.cpp
@@ -232,8 +232,8 @@ void RAS_BucketManager::Renderbuckets(
/* beginning each frame, clear (texture/material) caching information */
rasty->ClearCachingInfo();
- RenderSolidBuckets(cameratrans, rasty, rendertools);
- RenderAlphaBuckets(cameratrans, rasty, rendertools);
+ RenderSolidBuckets(cameratrans, rasty, rendertools);
+ RenderAlphaBuckets(cameratrans, rasty, rendertools);
rendertools->SetClientObject(rasty, NULL);
}
diff --git a/source/gameengine/Rasterizer/RAS_Deformer.h b/source/gameengine/Rasterizer/RAS_Deformer.h
index 51c4da3c49d..d70e56dc285 100644
--- a/source/gameengine/Rasterizer/RAS_Deformer.h
+++ b/source/gameengine/Rasterizer/RAS_Deformer.h
@@ -91,7 +91,7 @@ public:
protected:
class RAS_MeshObject *m_pMesh;
- bool m_bDynamic;
+ bool m_bDynamic;
#ifdef WITH_CXX_GUARDEDALLOC
diff --git a/source/gameengine/Rasterizer/RAS_FramingManager.cpp b/source/gameengine/Rasterizer/RAS_FramingManager.cpp
index 1cd110f8cc6..53d9b64ab0e 100644
--- a/source/gameengine/Rasterizer/RAS_FramingManager.cpp
+++ b/source/gameengine/Rasterizer/RAS_FramingManager.cpp
@@ -43,7 +43,7 @@ ComputeDefaultFrustum(
const short sensor_fit,
const float design_aspect_ratio,
RAS_FrameFrustum & frustum
-) {
+) {
float halfSize;
float sizeX;
float sizeY;
@@ -202,7 +202,7 @@ ComputeViewport(
{
ComputeBestFitViewRect(
availableViewport,
- design_aspect_ratio,
+ design_aspect_ratio,
viewport
);
@@ -260,7 +260,7 @@ ComputeFrustum(
RAS_Rect vt;
ComputeBestFitViewRect(
availableViewport,
- design_aspect_ratio,
+ design_aspect_ratio,
vt
);
@@ -277,13 +277,13 @@ ComputeFrustum(
frustum.y2 *= y_scale;
break;
- }
+ }
case RAS_FrameSettings::e_frame_scale :
case RAS_FrameSettings::e_frame_bars:
default :
break;
}
-}
+}
void
RAS_FramingManager::
@@ -330,7 +330,7 @@ RAS_FramingManager::
RAS_Rect vt;
ComputeBestFitViewRect(
availableViewport,
- design_aspect_ratio,
+ design_aspect_ratio,
vt
);
@@ -347,7 +347,7 @@ RAS_FramingManager::
frustum.y2 *= y_scale;
break;
- }
+ }
case RAS_FrameSettings::e_frame_scale :
case RAS_FrameSettings::e_frame_bars:
default :
diff --git a/source/gameengine/Rasterizer/RAS_FramingManager.h b/source/gameengine/Rasterizer/RAS_FramingManager.h
index dd640bc6839..122f0ca46ec 100644
--- a/source/gameengine/Rasterizer/RAS_FramingManager.h
+++ b/source/gameengine/Rasterizer/RAS_FramingManager.h
@@ -109,7 +109,7 @@ public :
*/
const
- RAS_FrameType &
+ RAS_FrameType &
FrameType(
) const {
return m_frame_type;
@@ -143,13 +143,13 @@ public :
unsigned int
DesignAspectWidth(
) const {
- return m_design_aspect_width;
+ return m_design_aspect_width;
};
unsigned int
DesignAspectHeight(
) const {
- return m_design_aspect_height;
+ return m_design_aspect_height;
};
private :
@@ -262,7 +262,7 @@ public :
const short sensor_fit,
const float design_aspect_ratio,
RAS_FrameFrustum & frustum
- );
+ );
static
void
diff --git a/source/gameengine/Rasterizer/RAS_IRasterizer.h b/source/gameengine/Rasterizer/RAS_IRasterizer.h
index 7749c4af9d6..8efc10f2118 100644
--- a/source/gameengine/Rasterizer/RAS_IRasterizer.h
+++ b/source/gameengine/Rasterizer/RAS_IRasterizer.h
@@ -301,7 +301,7 @@ public:
virtual int GetDrawingMode()=0;
/**
* Sets face culling
- */
+ */
virtual void SetCullFace(bool enable)=0;
/**
* Sets wireframe mode.
diff --git a/source/gameengine/Rasterizer/RAS_IRenderTools.h b/source/gameengine/Rasterizer/RAS_IRenderTools.h
index c02bc5e7a44..ca6f20b71ad 100644
--- a/source/gameengine/Rasterizer/RAS_IRenderTools.h
+++ b/source/gameengine/Rasterizer/RAS_IRenderTools.h
@@ -72,18 +72,18 @@ public:
{
};
- virtual
+ virtual
~RAS_IRenderTools(
) {};
virtual
- void
+ void
BeginFrame(
RAS_IRasterizer* rasty
)=0;
virtual
- void
+ void
EndFrame(
RAS_IRasterizer* rasty
)=0;
@@ -94,7 +94,7 @@ public:
// so must be renamed to 'applyTransform' or something
virtual
- void
+ void
applyTransform(
class RAS_IRasterizer* rasty,
double* oglmatrix,
@@ -112,7 +112,7 @@ public:
* \param aspect A scaling factor to compensate for the size.
*/
virtual
- void
+ void
RenderText3D(int fontid,
const char* text,
int size,
@@ -133,7 +133,7 @@ public:
* \param height Height of the canvas to draw to.
*/
virtual
- void
+ void
RenderText2D(
RAS_TEXT_RENDER_MODE mode,
const char* text,
@@ -145,7 +145,7 @@ public:
// 3d text, mapped on polygon
virtual
- void
+ void
RenderText(
int mode,
RAS_IPolyMaterial* polymat,
@@ -156,8 +156,8 @@ public:
int glattrib
)=0;
- virtual
- void
+ virtual
+ void
ProcessLighting(
RAS_IRasterizer *rasty,
bool uselights,
@@ -165,35 +165,35 @@ public:
)=0;
virtual
- void
+ void
SetClientObject(
RAS_IRasterizer* rasty,
void* obj
);
- void
+ void
SetAuxilaryClientInfo(
void* inf
);
virtual
- void
+ void
PushMatrix(
)=0;
virtual
- void
+ void
PopMatrix(
)=0;
virtual
- void
+ void
AddLight(
struct RAS_LightObject* lightobject
);
virtual
- void
+ void
RemoveLight(
struct RAS_LightObject* lightobject
);
diff --git a/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp b/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
index a18adfd8986..183da9d252e 100644
--- a/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
+++ b/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
@@ -489,7 +489,7 @@ bool RAS_MeshSlot::Split(bool force)
}
-#ifdef USE_SPLIT
+#ifdef USE_SPLIT
bool RAS_MeshSlot::IsCulled()
{
if (m_joinSlot)
@@ -502,7 +502,7 @@ bool RAS_MeshSlot::IsCulled()
return false;
return true;
}
-#endif
+#endif
/* material bucket sorting */
@@ -531,12 +531,12 @@ RAS_IPolyMaterial* RAS_MaterialBucket::GetPolyMaterial() const
}
bool RAS_MaterialBucket::IsAlpha() const
-{
+{
return (m_material->IsAlpha());
}
bool RAS_MaterialBucket::IsZSort() const
-{
+{
return (m_material->IsZSort());
}
diff --git a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp
index b769fc4b703..67423123a7a 100644
--- a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp
+++ b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp
@@ -438,7 +438,7 @@ void RAS_OpenGLRasterizer::EndFrame()
glDisable(GL_MULTISAMPLE_ARB);
m_2DCanvas->EndFrame();
-}
+}
void RAS_OpenGLRasterizer::SetRenderArea()
{
@@ -975,7 +975,7 @@ void RAS_OpenGLRasterizer::SetProjectionMatrix(const MT_Matrix4x4 & mat)
/* Get into argument. Looks a bit dodgy, but it's ok. */
mat.getValue(matrix);
/* Internally, MT_Matrix4x4 uses doubles (MT_Scalar). */
- glLoadMatrixd(matrix);
+ glLoadMatrixd(matrix);
m_camortho= (mat[3][3] != 0.0);
}
diff --git a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h
index e5eba249175..8b54f507ee0 100644
--- a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h
+++ b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h
@@ -278,7 +278,7 @@ public:
line.m_type = OglDebugShape::CIRCLE;
line.m_pos= center;
line.m_param = normal;
- line.m_color = color;
+ line.m_color = color;
line.m_param2.x() = radius;
line.m_param2.y() = (float) nsector;
m_debugShapes.push_back(line);
diff --git a/source/gameengine/SceneGraph/SG_Controller.h b/source/gameengine/SceneGraph/SG_Controller.h
index d82738dbb86..455aaf90d6d 100644
--- a/source/gameengine/SceneGraph/SG_Controller.h
+++ b/source/gameengine/SceneGraph/SG_Controller.h
@@ -53,7 +53,7 @@ public:
) {};
virtual
- bool
+ bool
Update(
double time
)=0;
@@ -69,13 +69,13 @@ public:
);
virtual
- void
+ void
SetSimulatedTime(
double time
)=0;
- virtual
- SG_Controller*
+ virtual
+ SG_Controller*
GetReplica(
class SG_Node* destnode
)=0;
diff --git a/source/gameengine/SceneGraph/SG_IObject.cpp b/source/gameengine/SceneGraph/SG_IObject.cpp
index afd647c2a2a..9ae32a89ff8 100644
--- a/source/gameengine/SceneGraph/SG_IObject.cpp
+++ b/source/gameengine/SceneGraph/SG_IObject.cpp
@@ -70,7 +70,7 @@ AddSGController(
m_SGcontrollers.push_back(cont);
}
- void
+ void
SG_IObject::
RemoveSGController(
SG_Controller* cont
diff --git a/source/gameengine/SceneGraph/SG_IObject.h b/source/gameengine/SceneGraph/SG_IObject.h
index c36c984f3d3..53b51507e97 100644
--- a/source/gameengine/SceneGraph/SG_IObject.h
+++ b/source/gameengine/SceneGraph/SG_IObject.h
@@ -174,7 +174,7 @@ public:
* this object is deleted.
*/
- void
+ void
AddSGController(
SG_Controller* cont
);
@@ -196,7 +196,7 @@ public:
* leaks.
*/
- void
+ void
RemoveAllControllers(
);
@@ -233,7 +233,7 @@ public:
* This may be NULL.
*/
- inline const void* GetSGClientObject() const
+ inline const void* GetSGClientObject() const
{
return m_SGclientObject;
}
@@ -280,7 +280,7 @@ public:
void SetControllerTime(double time);
virtual
- void
+ void
Destruct(
) = 0;
diff --git a/source/gameengine/SceneGraph/SG_Node.cpp b/source/gameengine/SceneGraph/SG_Node.cpp
index 33af9f16d7c..04d9a306fc4 100644
--- a/source/gameengine/SceneGraph/SG_Node.cpp
+++ b/source/gameengine/SceneGraph/SG_Node.cpp
@@ -143,7 +143,7 @@ Destruct()
}
const
- SG_Node*
+ SG_Node *
SG_Node::
GetRootSGParent(
) const {
diff --git a/source/gameengine/SceneGraph/SG_Node.h b/source/gameengine/SceneGraph/SG_Node.h
index 1d0c0e592e6..063eeaab01d 100644
--- a/source/gameengine/SceneGraph/SG_Node.h
+++ b/source/gameengine/SceneGraph/SG_Node.h
@@ -63,7 +63,7 @@ public:
* make a deep copy.
*/
- void
+ void
AddChild(
SG_Node* child
);
@@ -75,7 +75,7 @@ public:
* If the node was not a child of this object no action is performed.
*/
- void
+ void
RemoveChild(
SG_Node* child
);
@@ -149,7 +149,7 @@ public:
* Disconnect this node from it's parent
*/
- void
+ void
DisconnectFromParent(
);
@@ -182,12 +182,12 @@ public:
- /**
+ /**
* Update the spatial data of this node. Iterate through
* the children of this node and update their world data.
*/
- void
+ void
UpdateWorldData(
double time,
bool parentUpdated=false
@@ -198,7 +198,7 @@ public:
* the children nodes and update their simulated time.
*/
- void
+ void
SetSimulatedTime(
double time,
bool recurse
@@ -244,17 +244,17 @@ public:
* Node replication functions.
*/
- SG_Node*
+ SG_Node*
GetSGReplica(
);
- void
+ void
Destruct(
);
private:
- void
+ void
ProcessSGReplica(
SG_Node** replica
);
diff --git a/source/gameengine/SceneGraph/SG_ParentRelation.h b/source/gameengine/SceneGraph/SG_ParentRelation.h
index 4478ed11bc1..6e314996456 100644
--- a/source/gameengine/SceneGraph/SG_ParentRelation.h
+++ b/source/gameengine/SceneGraph/SG_ParentRelation.h
@@ -118,7 +118,7 @@ protected :
*/
SG_ParentRelation(
- ) {
+ ) {
};
/**
diff --git a/source/gameengine/SceneGraph/SG_Spatial.cpp b/source/gameengine/SceneGraph/SG_Spatial.cpp
index f8c4b5165ee..8c0d2b88c63 100644
--- a/source/gameengine/SceneGraph/SG_Spatial.cpp
+++ b/source/gameengine/SceneGraph/SG_Spatial.cpp
@@ -161,8 +161,8 @@ RelativeTranslate(
}
}
SetModified();
-}
-
+}
+
/**
* Scaling methods.
diff --git a/source/gameengine/SceneGraph/SG_Spatial.h b/source/gameengine/SceneGraph/SG_Spatial.h
index e456851d183..7630af51781 100644
--- a/source/gameengine/SceneGraph/SG_Spatial.h
+++ b/source/gameengine/SceneGraph/SG_Spatial.h
@@ -137,7 +137,7 @@ public:
}
- void
+ void
RelativeRotate(
const MT_Matrix3x3& rot,
bool local
@@ -178,12 +178,12 @@ public:
m_worldScaling = scale;
}
- const MT_Point3& GetLocalPosition() const
+ const MT_Point3& GetLocalPosition() const
{
return m_localPosition;
}
- const MT_Matrix3x3& GetLocalOrientation() const
+ const MT_Matrix3x3& GetLocalOrientation() const
{
return m_localRotation;
}
@@ -193,17 +193,17 @@ public:
return m_localScaling;
}
- const MT_Point3& GetWorldPosition() const
+ const MT_Point3& GetWorldPosition() const
{
return m_worldPosition;
}
- const MT_Matrix3x3& GetWorldOrientation() const
+ const MT_Matrix3x3& GetWorldOrientation() const
{
return m_worldRotation;
}
- const MT_Vector3& GetWorldScaling() const
+ const MT_Vector3& GetWorldScaling() const
{
return m_worldScaling;
}
diff --git a/source/gameengine/VideoTexture/BlendType.h b/source/gameengine/VideoTexture/BlendType.h
index 0131cc61c44..e19aadc49d2 100644
--- a/source/gameengine/VideoTexture/BlendType.h
+++ b/source/gameengine/VideoTexture/BlendType.h
@@ -37,7 +37,7 @@ public:
BlendType (const char * name) : m_name(name) {}
/// check blender type and return pointer to contained object or NULL (if type is not valid)
- PyObj * checkType (PyObject * obj)
+ PyObj *checkType(PyObject *obj)
{
// if pointer to type isn't set
if (m_objType == NULL)
@@ -55,17 +55,18 @@ public:
return NULL;
// return pointer to object, this class can only be used for KX object =>
// the Py object is actually a proxy
- return (PyObj*)BGE_PROXY_REF(obj);
+ return (PyObj *)BGE_PROXY_REF(obj);
}
/// parse arguments to get object
- PyObj * parseArg (PyObject * args)
+ PyObj *parseArg(PyObject *args)
{
// parse arguments
- PyObject * obj;
- if (PyArg_ParseTuple(args, "O", &obj))
+ PyObject *obj;
+ if (PyArg_ParseTuple(args, "O", &obj)) {
// if successfully parsed, return pointer to object
return checkType(obj);
+ }
// otherwise return NULL
return NULL;
}
@@ -74,7 +75,7 @@ protected:
/// name of Python type
const char * m_name;
/// pointer to Python type
- PyTypeObject * m_objType;
+ PyTypeObject *m_objType;
};
diff --git a/source/gameengine/VideoTexture/FilterBase.cpp b/source/gameengine/VideoTexture/FilterBase.cpp
index 90ea8436ffe..6ec5e237ac2 100644
--- a/source/gameengine/VideoTexture/FilterBase.cpp
+++ b/source/gameengine/VideoTexture/FilterBase.cpp
@@ -90,10 +90,10 @@ PyTypeList pyFilterTypes;
// object allocation
-PyObject * Filter_allocNew (PyTypeObject * type, PyObject * args, PyObject * kwds)
+PyObject *Filter_allocNew (PyTypeObject *type, PyObject *args, PyObject *kwds)
{
// allocate object
- PyFilter * self = reinterpret_cast<PyFilter*>(type->tp_alloc(type, 0));
+ PyFilter *self = reinterpret_cast<PyFilter*>(type->tp_alloc(type, 0));
// initialize object structure
self->m_filter = NULL;
// return allocated object
@@ -101,7 +101,7 @@ PyObject * Filter_allocNew (PyTypeObject * type, PyObject * args, PyObject * kwd
}
// object deallocation
-void Filter_dealloc (PyFilter * self)
+void Filter_dealloc (PyFilter *self)
{
// release object attributes
if (self->m_filter != NULL)
@@ -114,7 +114,7 @@ void Filter_dealloc (PyFilter * self)
// get previous pixel filter object
-PyObject * Filter_getPrevious (PyFilter * self, void * closure)
+PyObject *Filter_getPrevious (PyFilter *self, void *closure)
{
// if filter object is available
if (self->m_filter != NULL)
@@ -135,7 +135,7 @@ PyObject * Filter_getPrevious (PyFilter * self, void * closure)
// set previous pixel filter object
-int Filter_setPrevious (PyFilter * self, PyObject * value, void * closure)
+int Filter_setPrevious (PyFilter *self, PyObject *value, void *closure)
{
// if filter object is available
if (self->m_filter != NULL)
diff --git a/source/gameengine/VideoTexture/FilterBase.h b/source/gameengine/VideoTexture/FilterBase.h
index 63561c25ffa..422cf86f23e 100644
--- a/source/gameengine/VideoTexture/FilterBase.h
+++ b/source/gameengine/VideoTexture/FilterBase.h
@@ -118,9 +118,9 @@ extern PyTypeList pyFilterTypes;
// functions for python interface
// object initialization
-template <class T> static int Filter_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+template <class T> static int Filter_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
- PyFilter * self = reinterpret_cast<PyFilter*>(pySelf);
+ PyFilter *self = reinterpret_cast<PyFilter*>(pySelf);
// create filter object
if (self->m_filter != NULL) delete self->m_filter;
self->m_filter = new T();
@@ -129,14 +129,14 @@ template <class T> static int Filter_init (PyObject * pySelf, PyObject * args, P
}
// object allocation
-PyObject * Filter_allocNew (PyTypeObject * type, PyObject * args, PyObject * kwds);
+PyObject *Filter_allocNew(PyTypeObject *type, PyObject *args, PyObject *kwds);
// object deallocation
-void Filter_dealloc (PyFilter * self);
+void Filter_dealloc(PyFilter *self);
// get previous pixel filter object
-PyObject * Filter_getPrevious (PyFilter * self, void * closure);
+PyObject *Filter_getPrevious(PyFilter *self, void *closure);
// set previous pixel filter object
-int Filter_setPrevious (PyFilter * self, PyObject * value, void * closure);
+int Filter_setPrevious(PyFilter *self, PyObject *value, void *closure);
#endif
diff --git a/source/gameengine/VideoTexture/FilterBlueScreen.cpp b/source/gameengine/VideoTexture/FilterBlueScreen.cpp
index 02a6a8f0344..8559e8f87f4 100644
--- a/source/gameengine/VideoTexture/FilterBlueScreen.cpp
+++ b/source/gameengine/VideoTexture/FilterBlueScreen.cpp
@@ -66,21 +66,21 @@ void FilterBlueScreen::setLimits (unsigned short minLimit, unsigned short maxLim
// cast Filter pointer to FilterBlueScreen
-inline FilterBlueScreen * getFilter (PyFilter * self)
+inline FilterBlueScreen * getFilter (PyFilter *self)
{ return static_cast<FilterBlueScreen*>(self->m_filter); }
// python methods and get/sets
// get color
-static PyObject * getColor (PyFilter * self, void * closure)
+static PyObject *getColor (PyFilter *self, void *closure)
{
return Py_BuildValue("[BBB]", getFilter(self)->getColor()[0],
getFilter(self)->getColor()[1], getFilter(self)->getColor()[2]);
}
// set color
-static int setColor (PyFilter * self, PyObject * value, void * closure)
+static int setColor (PyFilter *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 3
@@ -100,14 +100,14 @@ static int setColor (PyFilter * self, PyObject * value, void * closure)
}
// get limits
-static PyObject * getLimits (PyFilter * self, void * closure)
+static PyObject *getLimits (PyFilter *self, void *closure)
{
return Py_BuildValue("[II]", getFilter(self)->getLimits()[0],
getFilter(self)->getLimits()[1]);
}
// set limit
-static int setLimits (PyFilter * self, PyObject * value, void * closure)
+static int setLimits (PyFilter *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 2
diff --git a/source/gameengine/VideoTexture/FilterColor.cpp b/source/gameengine/VideoTexture/FilterColor.cpp
index ed75b4f8da8..35a6414f383 100644
--- a/source/gameengine/VideoTexture/FilterColor.cpp
+++ b/source/gameengine/VideoTexture/FilterColor.cpp
@@ -108,14 +108,14 @@ void FilterColor::setMatrix (ColorMatrix & mat)
// cast Filter pointer to FilterColor
-inline FilterColor * getFilterColor (PyFilter * self)
+inline FilterColor * getFilterColor (PyFilter *self)
{ return static_cast<FilterColor*>(self->m_filter); }
// python methods and get/sets
// get color matrix
-static PyObject * getMatrix (PyFilter * self, void * closure)
+static PyObject *getMatrix (PyFilter *self, void *closure)
{
ColorMatrix & mat = getFilterColor(self)->getMatrix();
return Py_BuildValue("((hhhhh)(hhhhh)(hhhhh)(hhhhh))",
@@ -126,7 +126,7 @@ static PyObject * getMatrix (PyFilter * self, void * closure)
}
// set color matrix
-static int setMatrix (PyFilter * self, PyObject * value, void * closure)
+static int setMatrix (PyFilter *self, PyObject *value, void *closure)
{
// matrix to store items
ColorMatrix mat;
@@ -243,14 +243,14 @@ void FilterLevel::setLevels (ColorLevel & lev)
// cast Filter pointer to FilterLevel
-inline FilterLevel * getFilterLevel (PyFilter * self)
+inline FilterLevel * getFilterLevel (PyFilter *self)
{ return static_cast<FilterLevel*>(self->m_filter); }
// python methods and get/sets
// get color levels
-static PyObject * getLevels (PyFilter * self, void * closure)
+static PyObject *getLevels (PyFilter *self, void *closure)
{
ColorLevel & lev = getFilterLevel(self)->getLevels();
return Py_BuildValue("((HH)(HH)(HH)(HH))",
@@ -259,7 +259,7 @@ static PyObject * getLevels (PyFilter * self, void * closure)
}
// set color levels
-static int setLevels (PyFilter * self, PyObject * value, void * closure)
+static int setLevels (PyFilter *self, PyObject *value, void *closure)
{
// matrix to store items
ColorLevel lev;
diff --git a/source/gameengine/VideoTexture/FilterNormal.cpp b/source/gameengine/VideoTexture/FilterNormal.cpp
index dda1a493291..03c500a7e14 100644
--- a/source/gameengine/VideoTexture/FilterNormal.cpp
+++ b/source/gameengine/VideoTexture/FilterNormal.cpp
@@ -59,20 +59,20 @@ void FilterNormal::setDepth (float depth)
// cast Filter pointer to FilterNormal
-inline FilterNormal * getFilter (PyFilter * self)
+inline FilterNormal * getFilter (PyFilter *self)
{ return static_cast<FilterNormal*>(self->m_filter); }
// python methods and get/sets
// get index of color used to calculate normal
-static PyObject * getColor (PyFilter * self, void * closure)
+static PyObject *getColor (PyFilter *self, void *closure)
{
return Py_BuildValue("H", getFilter(self)->getColor());
}
// set index of color used to calculate normal
-static int setColor (PyFilter * self, PyObject * value, void * closure)
+static int setColor (PyFilter *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PyLong_Check(value))
@@ -88,13 +88,13 @@ static int setColor (PyFilter * self, PyObject * value, void * closure)
// get depth
-static PyObject * getDepth (PyFilter * self, void * closure)
+static PyObject *getDepth (PyFilter *self, void *closure)
{
return Py_BuildValue("f", getFilter(self)->getDepth());
}
// set depth
-static int setDepth (PyFilter * self, PyObject * value, void * closure)
+static int setDepth (PyFilter *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value)
diff --git a/source/gameengine/VideoTexture/ImageBase.cpp b/source/gameengine/VideoTexture/ImageBase.cpp
index 9333e0184ec..2de49795681 100644
--- a/source/gameengine/VideoTexture/ImageBase.cpp
+++ b/source/gameengine/VideoTexture/ImageBase.cpp
@@ -128,7 +128,7 @@ PyImage * ImageBase::getSource (const char * id)
// set source object
-bool ImageBase::setSource (const char * id, PyImage * source)
+bool ImageBase::setSource (const char * id, PyImage *source)
{
// find source
ImageSourceList::iterator src = findSource(id);
@@ -315,7 +315,7 @@ bool ImageSource::is (const char * id)
// set source object
-void ImageSource::setSource (PyImage * source)
+void ImageSource::setSource (PyImage *source)
{
// reference new source
if (source != NULL) Py_INCREF(source);
@@ -358,10 +358,10 @@ PyTypeList pyImageTypes;
// functions for python interface
// object allocation
-PyObject * Image_allocNew (PyTypeObject * type, PyObject * args, PyObject * kwds)
+PyObject *Image_allocNew (PyTypeObject *type, PyObject *args, PyObject *kwds)
{
// allocate object
- PyImage * self = reinterpret_cast<PyImage*>(type->tp_alloc(type, 0));
+ PyImage *self = reinterpret_cast<PyImage*>(type->tp_alloc(type, 0));
// initialize object structure
self->m_image = NULL;
// return allocated object
@@ -369,7 +369,7 @@ PyObject * Image_allocNew (PyTypeObject * type, PyObject * args, PyObject * kwds
}
// object deallocation
-void Image_dealloc (PyImage * self)
+void Image_dealloc (PyImage *self)
{
// release object attributes
if (self->m_image != NULL)
@@ -388,7 +388,7 @@ void Image_dealloc (PyImage * self)
}
// get image data
-PyObject * Image_getImage (PyImage * self, char * mode)
+PyObject *Image_getImage (PyImage *self, char * mode)
{
try
{
@@ -463,7 +463,7 @@ PyObject * Image_getImage (PyImage * self, char * mode)
}
}
}
- return (PyObject*)buffer;
+ return (PyObject *)buffer;
}
}
catch (Exception & exp)
@@ -475,28 +475,28 @@ PyObject * Image_getImage (PyImage * self, char * mode)
}
// get image size
-PyObject * Image_getSize (PyImage * self, void * closure)
+PyObject *Image_getSize (PyImage *self, void *closure)
{
return Py_BuildValue("(hh)", self->m_image->getSize()[0],
self->m_image->getSize()[1]);
}
// refresh image
-PyObject * Image_refresh (PyImage * self)
+PyObject *Image_refresh (PyImage *self)
{
self->m_image->refresh();
Py_RETURN_NONE;
}
// get scale
-PyObject * Image_getScale (PyImage * self, void * closure)
+PyObject *Image_getScale (PyImage *self, void *closure)
{
if (self->m_image != NULL && self->m_image->getScale()) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
}
// set scale
-int Image_setScale (PyImage * self, PyObject * value, void * closure)
+int Image_setScale (PyImage *self, PyObject *value, void *closure)
{
// check parameter, report failure
if (value == NULL || !PyBool_Check(value))
@@ -511,14 +511,14 @@ int Image_setScale (PyImage * self, PyObject * value, void * closure)
}
// get flip
-PyObject * Image_getFlip (PyImage * self, void * closure)
+PyObject *Image_getFlip (PyImage *self, void *closure)
{
if (self->m_image != NULL && self->m_image->getFlip()) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
}
// set flip
-int Image_setFlip (PyImage * self, PyObject * value, void * closure)
+int Image_setFlip (PyImage *self, PyObject *value, void *closure)
{
// check parameter, report failure
if (value == NULL || !PyBool_Check(value))
@@ -534,7 +534,7 @@ int Image_setFlip (PyImage * self, PyObject * value, void * closure)
// get filter source object
-PyObject * Image_getSource (PyImage * self, PyObject * args)
+PyObject *Image_getSource (PyImage *self, PyObject *args)
{
// get arguments
char * id;
@@ -543,7 +543,7 @@ PyObject * Image_getSource (PyImage * self, PyObject * args)
if (self->m_image != NULL)
{
// get source object
- PyObject * src = reinterpret_cast<PyObject*>(self->m_image->getSource(id));
+ PyObject *src = reinterpret_cast<PyObject*>(self->m_image->getSource(id));
// if source is available
if (src != NULL)
{
@@ -558,11 +558,11 @@ PyObject * Image_getSource (PyImage * self, PyObject * args)
// set filter source object
-PyObject * Image_setSource (PyImage * self, PyObject * args)
+PyObject *Image_setSource (PyImage *self, PyObject *args)
{
// get arguments
char * id;
- PyObject * obj;
+ PyObject *obj;
if (!PyArg_ParseTuple(args, "sO:setSource", &id, &obj))
return NULL;
if (self->m_image != NULL)
@@ -593,7 +593,7 @@ PyObject * Image_setSource (PyImage * self, PyObject * args)
// get pixel filter object
-PyObject * Image_getFilter (PyImage * self, void * closure)
+PyObject *Image_getFilter (PyImage *self, void *closure)
{
// if image object is available
if (self->m_image != NULL)
@@ -614,7 +614,7 @@ PyObject * Image_getFilter (PyImage * self, void * closure)
// set pixel filter object
-int Image_setFilter (PyImage * self, PyObject * value, void * closure)
+int Image_setFilter (PyImage *self, PyObject *value, void *closure)
{
// if image object is available
if (self->m_image != NULL)
@@ -632,7 +632,7 @@ int Image_setFilter (PyImage * self, PyObject * value, void * closure)
// return success
return 0;
}
-PyObject * Image_valid(PyImage * self, void * closure)
+PyObject *Image_valid(PyImage *self, void *closure)
{
if (self->m_image->isImageAvailable())
{
@@ -674,7 +674,7 @@ static int Image_getbuffer(PyImage *self, Py_buffer *view, int flags)
self->m_image->m_exports++;
return 0;
}
- ret = PyBuffer_FillInfo(view, (PyObject*)self, image, self->m_image->getBuffSize(), 0, flags);
+ ret = PyBuffer_FillInfo(view, (PyObject *)self, image, self->m_image->getBuffSize(), 0, flags);
if (ret >= 0)
self->m_image->m_exports++;
return ret;
@@ -684,7 +684,7 @@ error:
// The bug is fixed in Python SVN 77916, as soon as the python revision used by Blender is
// updated, you can simply return -1 and set the error
static char* buf = (char *)"";
- ret = PyBuffer_FillInfo(view, (PyObject*)self, buf, 0, 0, flags);
+ ret = PyBuffer_FillInfo(view, (PyObject *)self, buf, 0, 0, flags);
if (ret >= 0)
self->m_image->m_exports++;
return ret;
diff --git a/source/gameengine/VideoTexture/ImageBase.h b/source/gameengine/VideoTexture/ImageBase.h
index 6c38b107a4d..bb3f0c19e4b 100644
--- a/source/gameengine/VideoTexture/ImageBase.h
+++ b/source/gameengine/VideoTexture/ImageBase.h
@@ -82,7 +82,7 @@ public:
/// get source object
PyImage * getSource (const char * id);
/// set source object, return true, if source was set
- bool setSource (const char * id, PyImage * source);
+ bool setSource (const char * id, PyImage *source);
/// get pixel filter
PyFilter * getFilter (void) { return m_pyfilter; }
@@ -276,7 +276,7 @@ public:
/// get source object
PyImage * getSource (void) { return m_source; }
/// set source object
- void setSource (PyImage * source);
+ void setSource (PyImage *source);
/// get image from source
unsigned int * getImage (double ts=-1.0);
@@ -312,9 +312,9 @@ extern PyTypeList pyImageTypes;
// functions for python interface
// object initialization
-template <class T> static int Image_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+template <class T> static int Image_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
- PyImage * self = reinterpret_cast<PyImage*>(pySelf);
+ PyImage *self = reinterpret_cast<PyImage*>(pySelf);
// create source object
if (self->m_image != NULL) delete self->m_image;
self->m_image = new T();
@@ -323,37 +323,37 @@ template <class T> static int Image_init (PyObject * pySelf, PyObject * args, Py
}
// object allocation
-PyObject * Image_allocNew (PyTypeObject * type, PyObject * args, PyObject * kwds);
+PyObject *Image_allocNew (PyTypeObject *type, PyObject *args, PyObject *kwds);
// object deallocation
-void Image_dealloc (PyImage * self);
+void Image_dealloc (PyImage *self);
// get image data
-PyObject * Image_getImage (PyImage * self, char * mode);
+PyObject *Image_getImage (PyImage *self, char * mode);
// get image size
-PyObject * Image_getSize (PyImage * self, void * closure);
+PyObject *Image_getSize (PyImage *self, void *closure);
// refresh image - invalidate current content
-PyObject * Image_refresh (PyImage * self);
+PyObject *Image_refresh (PyImage *self);
// get scale
-PyObject * Image_getScale (PyImage * self, void * closure);
+PyObject *Image_getScale (PyImage *self, void *closure);
// set scale
-int Image_setScale (PyImage * self, PyObject * value, void * closure);
+int Image_setScale (PyImage *self, PyObject *value, void *closure);
// get flip
-PyObject * Image_getFlip (PyImage * self, void * closure);
+PyObject *Image_getFlip (PyImage *self, void *closure);
// set flip
-int Image_setFlip (PyImage * self, PyObject * value, void * closure);
+int Image_setFlip (PyImage *self, PyObject *value, void *closure);
// get filter source object
-PyObject * Image_getSource (PyImage * self, PyObject * args);
+PyObject *Image_getSource (PyImage *self, PyObject *args);
// set filter source object
-PyObject * Image_setSource (PyImage * self, PyObject * args);
+PyObject *Image_setSource (PyImage *self, PyObject *args);
// get pixel filter object
-PyObject * Image_getFilter (PyImage * self, void * closure);
+PyObject *Image_getFilter (PyImage *self, void *closure);
// set pixel filter object
-int Image_setFilter (PyImage * self, PyObject * value, void * closure);
+int Image_setFilter (PyImage *self, PyObject *value, void *closure);
// check if a buffer can be extracted
-PyObject * Image_valid(PyImage * self, void * closure);
+PyObject *Image_valid(PyImage *self, void *closure);
// for buffer access to PyImage objects
extern PyBufferProcs imageBufferProcs;
diff --git a/source/gameengine/VideoTexture/ImageBuff.cpp b/source/gameengine/VideoTexture/ImageBuff.cpp
index 17513d20a39..eec0bccbe56 100644
--- a/source/gameengine/VideoTexture/ImageBuff.cpp
+++ b/source/gameengine/VideoTexture/ImageBuff.cpp
@@ -47,7 +47,7 @@ FilterRGB24 defFilter;
// forward declaration;
extern PyTypeObject ImageBuffType;
-static int ImageBuff_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+static int ImageBuff_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
short width = -1;
short height = -1;
@@ -55,7 +55,7 @@ static int ImageBuff_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
PyObject *py_scale = Py_False;
ImageBuff *image;
- PyImage * self = reinterpret_cast<PyImage*>(pySelf);
+ PyImage *self = reinterpret_cast<PyImage*>(pySelf);
// create source object
if (self->m_image != NULL)
delete self->m_image;
@@ -190,7 +190,7 @@ void ImageBuff::plot (ImageBuff* img, short x, short y, short mode)
// cast Image pointer to ImageBuff
-inline ImageBuff * getImageBuff (PyImage * self)
+inline ImageBuff * getImageBuff (PyImage *self)
{ return static_cast<ImageBuff*>(self->m_image); }
@@ -245,7 +245,7 @@ static bool testBGLBuffer(Buffer* buffer, int width, int height, unsigned int pi
// load image
-static PyObject * load (PyImage * self, PyObject * args)
+static PyObject *load(PyImage *self, PyObject *args)
{
// parameters: string image buffer, its size, width, height
Py_buffer buffer;
@@ -306,10 +306,10 @@ static PyObject * load (PyImage * self, PyObject * args)
}
if (PyErr_Occurred())
return NULL;
- Py_RETURN_NONE;
+ Py_RETURN_NONE;
}
-static PyObject * plot (PyImage * self, PyObject * args)
+static PyObject *plot (PyImage *self, PyObject *args)
{
PyImage * other;
Buffer* bglBuffer;
@@ -332,7 +332,7 @@ static PyObject * plot (PyImage * self, PyObject * args)
PyBuffer_Release(&buffer);
if (PyErr_Occurred())
return NULL;
- Py_RETURN_NONE;
+ Py_RETURN_NONE;
}
PyErr_Clear();
// try the other format
@@ -354,7 +354,7 @@ static PyObject * plot (PyImage * self, PyObject * args)
}
if (PyErr_Occurred())
return NULL;
- Py_RETURN_NONE;
+ Py_RETURN_NONE;
}
// methods structure
diff --git a/source/gameengine/VideoTexture/ImageMix.cpp b/source/gameengine/VideoTexture/ImageMix.cpp
index 3907e6c6883..f09454a517b 100644
--- a/source/gameengine/VideoTexture/ImageMix.cpp
+++ b/source/gameengine/VideoTexture/ImageMix.cpp
@@ -101,14 +101,14 @@ void ImageMix::calcImage (unsigned int texId, double ts)
// cast Image pointer to ImageMix
-inline ImageMix * getImageMix (PyImage * self)
+inline ImageMix * getImageMix (PyImage *self)
{ return static_cast<ImageMix*>(self->m_image); }
// python methods
// get source weight
-static PyObject *getWeight (PyImage * self, PyObject * args)
+static PyObject *getWeight (PyImage *self, PyObject *args)
{
// weight
short weight = 0;
diff --git a/source/gameengine/VideoTexture/ImageRender.cpp b/source/gameengine/VideoTexture/ImageRender.cpp
index 6d6cb770afa..2135d0a07eb 100644
--- a/source/gameengine/VideoTexture/ImageRender.cpp
+++ b/source/gameengine/VideoTexture/ImageRender.cpp
@@ -277,7 +277,7 @@ void ImageRender::Render()
// cast Image pointer to ImageRender
-inline ImageRender * getImageRender (PyImage * self)
+inline ImageRender * getImageRender (PyImage *self)
{ return static_cast<ImageRender*>(self->m_image); }
@@ -290,10 +290,10 @@ BlendType<KX_Camera> cameraType ("KX_Camera");
// object initialization
-static int ImageRender_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+static int ImageRender_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
// parameters - scene object
- PyObject * scene;
+ PyObject *scene;
// camera object
PyObject * camera;
// parameter keywords
@@ -317,7 +317,7 @@ static int ImageRender_init (PyObject * pySelf, PyObject * args, PyObject * kwds
if (cameraPtr == NULL) THRWEXCP(CameraInvalid, S_OK);
// get pointer to image structure
- PyImage * self = reinterpret_cast<PyImage*>(pySelf);
+ PyImage *self = reinterpret_cast<PyImage*>(pySelf);
// create source object
if (self->m_image != NULL) delete self->m_image;
self->m_image = new ImageRender(scenePtr, cameraPtr);
@@ -343,7 +343,7 @@ static PyObject *getBackground (PyImage *self, void *closure)
}
// set color
-static int setBackground (PyImage * self, PyObject * value, void * closure)
+static int setBackground (PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 4
@@ -434,14 +434,14 @@ PyTypeObject ImageRenderType =
};
// object initialization
-static int ImageMirror_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+static int ImageMirror_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
// parameters - scene object
- PyObject * scene;
+ PyObject *scene;
// reference object for mirror
- PyObject * observer;
+ PyObject *observer;
// object holding the mirror
- PyObject * mirror;
+ PyObject *mirror;
// material of the mirror
short materialID = 0;
// parameter keywords
@@ -490,7 +490,7 @@ static int ImageMirror_init (PyObject * pySelf, PyObject * args, PyObject * kwds
THRWEXCP(MaterialNotAvail, S_OK);
// get pointer to image structure
- PyImage * self = reinterpret_cast<PyImage*>(pySelf);
+ PyImage *self = reinterpret_cast<PyImage*>(pySelf);
// create source object
if (self->m_image != NULL)
@@ -516,7 +516,7 @@ static PyObject *getClip (PyImage *self, void *closure)
}
// set clip
-static int setClip (PyImage * self, PyObject * value, void * closure)
+static int setClip (PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
double clip;
diff --git a/source/gameengine/VideoTexture/ImageViewport.cpp b/source/gameengine/VideoTexture/ImageViewport.cpp
index a780fdcc38c..9b503efcf39 100644
--- a/source/gameengine/VideoTexture/ImageViewport.cpp
+++ b/source/gameengine/VideoTexture/ImageViewport.cpp
@@ -165,7 +165,7 @@ void ImageViewport::calcImage (unsigned int texId, double ts)
// cast Image pointer to ImageViewport
-inline ImageViewport * getImageViewport (PyImage * self)
+inline ImageViewport * getImageViewport (PyImage *self)
{ return static_cast<ImageViewport*>(self->m_image); }
@@ -173,14 +173,14 @@ inline ImageViewport * getImageViewport (PyImage * self)
// get whole
-PyObject * ImageViewport_getWhole (PyImage * self, void * closure)
+PyObject *ImageViewport_getWhole (PyImage *self, void *closure)
{
if (self->m_image != NULL && getImageViewport(self)->getWhole()) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
}
// set whole
-int ImageViewport_setWhole (PyImage * self, PyObject * value, void * closure)
+int ImageViewport_setWhole (PyImage *self, PyObject *value, void *closure)
{
// check parameter, report failure
if (value == NULL || !PyBool_Check(value))
@@ -203,14 +203,14 @@ int ImageViewport_setWhole (PyImage * self, PyObject * value, void * closure)
}
// get alpha
-PyObject * ImageViewport_getAlpha (PyImage * self, void * closure)
+PyObject *ImageViewport_getAlpha (PyImage *self, void *closure)
{
if (self->m_image != NULL && getImageViewport(self)->getAlpha()) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
}
// set whole
-int ImageViewport_setAlpha (PyImage * self, PyObject * value, void * closure)
+int ImageViewport_setAlpha (PyImage *self, PyObject *value, void *closure)
{
// check parameter, report failure
if (value == NULL || !PyBool_Check(value))
@@ -226,14 +226,14 @@ int ImageViewport_setAlpha (PyImage * self, PyObject * value, void * closure)
// get position
-static PyObject * ImageViewport_getPosition (PyImage * self, void * closure)
+static PyObject *ImageViewport_getPosition (PyImage *self, void *closure)
{
return Py_BuildValue("(ii)", getImageViewport(self)->getPosition()[0],
getImageViewport(self)->getPosition()[1]);
}
// set position
-static int ImageViewport_setPosition (PyImage * self, PyObject * value, void * closure)
+static int ImageViewport_setPosition (PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 2
@@ -254,14 +254,14 @@ static int ImageViewport_setPosition (PyImage * self, PyObject * value, void * c
}
// get capture size
-PyObject * ImageViewport_getCaptureSize (PyImage * self, void * closure)
+PyObject *ImageViewport_getCaptureSize (PyImage *self, void *closure)
{
return Py_BuildValue("(ii)", getImageViewport(self)->getCaptureSize()[0],
getImageViewport(self)->getCaptureSize()[1]);
}
// set capture size
-int ImageViewport_setCaptureSize (PyImage * self, PyObject * value, void * closure)
+int ImageViewport_setCaptureSize (PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 2
diff --git a/source/gameengine/VideoTexture/ImageViewport.h b/source/gameengine/VideoTexture/ImageViewport.h
index ccc58a41605..198655c6ebf 100644
--- a/source/gameengine/VideoTexture/ImageViewport.h
+++ b/source/gameengine/VideoTexture/ImageViewport.h
@@ -91,12 +91,12 @@ protected:
GLint * getViewportSize (void) { return m_viewport + 2; }
};
-PyObject * ImageViewport_getCaptureSize (PyImage * self, void * closure);
-int ImageViewport_setCaptureSize (PyImage * self, PyObject * value, void * closure);
-PyObject * ImageViewport_getWhole (PyImage * self, void * closure);
-int ImageViewport_setWhole (PyImage * self, PyObject * value, void * closure);
-PyObject * ImageViewport_getAlpha (PyImage * self, void * closure);
-int ImageViewport_setAlpha (PyImage * self, PyObject * value, void * closure);
+PyObject *ImageViewport_getCaptureSize (PyImage *self, void *closure);
+int ImageViewport_setCaptureSize (PyImage *self, PyObject *value, void *closure);
+PyObject *ImageViewport_getWhole (PyImage *self, void *closure);
+int ImageViewport_setWhole (PyImage *self, PyObject *value, void *closure);
+PyObject *ImageViewport_getAlpha (PyImage *self, void *closure);
+int ImageViewport_setAlpha (PyImage *self, PyObject *value, void *closure);
#endif
diff --git a/source/gameengine/VideoTexture/PyTypeList.cpp b/source/gameengine/VideoTexture/PyTypeList.cpp
index ed53e8bd1f1..9fe98544961 100644
--- a/source/gameengine/VideoTexture/PyTypeList.cpp
+++ b/source/gameengine/VideoTexture/PyTypeList.cpp
@@ -41,7 +41,7 @@ PyTypeList::~PyTypeList()
}
/// check, if type is in list
-bool PyTypeList::in (PyTypeObject * type)
+bool PyTypeList::in (PyTypeObject *type)
{
// if list exists
if (m_list.get() != NULL)
@@ -54,7 +54,7 @@ bool PyTypeList::in (PyTypeObject * type)
}
/// add type to list
-void PyTypeList::add (PyTypeObject * type, const char * name)
+void PyTypeList::add (PyTypeObject *type, const char * name)
{
// if list doesn't exist, create it
if (m_list.get() == NULL)
@@ -78,7 +78,7 @@ bool PyTypeList::ready (void)
}
/// register types to module
-void PyTypeList::reg (PyObject * module)
+void PyTypeList::reg(PyObject *module)
{
// if list exists
if (m_list.get() != NULL)
@@ -88,6 +88,6 @@ void PyTypeList::reg (PyObject * module)
// increase ref count
Py_INCREF((*it)->getType());
// add type to module
- PyModule_AddObject(module, (char*)(*it)->getName(), (PyObject*)(*it)->getType());
+ PyModule_AddObject(module, (char*)(*it)->getName(), (PyObject *)(*it)->getType());
}
}
diff --git a/source/gameengine/VideoTexture/PyTypeList.h b/source/gameengine/VideoTexture/PyTypeList.h
index aa1df0ce54b..4872b3c3d5c 100644
--- a/source/gameengine/VideoTexture/PyTypeList.h
+++ b/source/gameengine/VideoTexture/PyTypeList.h
@@ -49,16 +49,16 @@ public:
~PyTypeList();
/// check, if type is in list
- bool in (PyTypeObject * type);
+ bool in (PyTypeObject *type);
/// add type to list
- void add (PyTypeObject * type, const char * name);
+ void add (PyTypeObject *type, const char * name);
/// prepare types
bool ready (void);
/// register types to module
- void reg (PyObject * module);
+ void reg(PyObject *module);
protected:
/// pointer to list of types
@@ -71,21 +71,21 @@ class PyTypeListItem
{
public:
/// constructor adds type into list
- PyTypeListItem (PyTypeObject * type, const char * name)
+ PyTypeListItem (PyTypeObject *type, const char * name)
: m_type(type), m_name(name)
{ }
/// does type match
- PyTypeObject * getType (void) { return m_type; }
+ PyTypeObject *getType (void) { return m_type; }
/// get name of type
const char * getName (void) { return m_name; }
protected:
/// pointer to type object
- PyTypeObject * m_type;
+ PyTypeObject *m_type;
/// name of type
- const char * m_name;
+ const char *m_name;
};
diff --git a/source/gameengine/VideoTexture/Texture.cpp b/source/gameengine/VideoTexture/Texture.cpp
index a189f5f9aaf..f58d17f949c 100644
--- a/source/gameengine/VideoTexture/Texture.cpp
+++ b/source/gameengine/VideoTexture/Texture.cpp
@@ -119,7 +119,7 @@ static KX_LightObject *getLamp(PyObject *obj)
// get material ID
-short getMaterialID(PyObject * obj, const char *name)
+short getMaterialID(PyObject *obj, const char *name)
{
// search for material
for (short matID = 0;; ++matID)
@@ -167,8 +167,8 @@ static PyObject *Texture_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
// forward declaration
-PyObject * Texture_close(Texture * self);
-int Texture_setSource (Texture * self, PyObject * value, void * closure);
+PyObject *Texture_close(Texture * self);
+int Texture_setSource (Texture * self, PyObject *value, void *closure);
// Texture object deallocation
@@ -177,12 +177,12 @@ static void Texture_dealloc(Texture *self)
// release renderer
Py_XDECREF(self->m_source);
// close texture
- PyObject* ret = Texture_close(self);
+ PyObject *ret = Texture_close(self);
Py_DECREF(ret);
// release scaled image buffer
delete [] self->m_scaledImg;
// release object
- Py_TYPE((PyObject *)self)->tp_free((PyObject*)self);
+ Py_TYPE((PyObject *)self)->tp_free((PyObject *)self);
}
@@ -193,7 +193,7 @@ ExpDesc MaterialNotAvailDesc (MaterialNotAvail, "Texture material is not availab
static int Texture_init(Texture *self, PyObject *args, PyObject *kwds)
{
// parameters - game object with video texture
- PyObject * obj = NULL;
+ PyObject *obj = NULL;
// material ID
short matID = 0;
// texture ID
@@ -275,7 +275,7 @@ static int Texture_init(Texture *self, PyObject *args, PyObject *kwds)
// close added texture
-PyObject * Texture_close(Texture * self)
+PyObject *Texture_close(Texture * self)
{
// restore texture
if (self->m_orgSaved)
@@ -301,7 +301,7 @@ PyObject * Texture_close(Texture * self)
static PyObject *Texture_refresh(Texture *self, PyObject *args)
{
// get parameter - refresh source
- PyObject * param;
+ PyObject *param;
double ts = -1.0;
if (!PyArg_ParseTuple(args, "O|d:refresh", &param, &ts) || !PyBool_Check(param))
@@ -435,7 +435,7 @@ static PyObject *Texture_getSource(Texture *self, PyObject *value, void *closure
// set source object
-int Texture_setSource (Texture * self, PyObject * value, void * closure)
+int Texture_setSource (Texture * self, PyObject *value, void *closure)
{
// check new value
if (value == NULL || !pyImageTypes.in(Py_TYPE(value)))
diff --git a/source/gameengine/VideoTexture/Texture.h b/source/gameengine/VideoTexture/Texture.h
index ad5b7b9fb44..cc265725b29 100644
--- a/source/gameengine/VideoTexture/Texture.h
+++ b/source/gameengine/VideoTexture/Texture.h
@@ -78,14 +78,14 @@ struct Texture
extern PyTypeObject TextureType;
// load texture
-void loadTexture (unsigned int texId, unsigned int * texture, short * size,
- bool mipmap = false);
+void loadTexture(unsigned int texId, unsigned int *texture, short *size,
+ bool mipmap = false);
// get material
-RAS_IPolyMaterial * getMaterial (PyObject *obj, short matID);
+RAS_IPolyMaterial *getMaterial(PyObject *obj, short matID);
// get material ID
-short getMaterialID (PyObject * obj, const char *name);
+short getMaterialID(PyObject *obj, const char *name);
// Exceptions
extern ExceptionID MaterialNotAvail;
diff --git a/source/gameengine/VideoTexture/VideoBase.cpp b/source/gameengine/VideoTexture/VideoBase.cpp
index 6662df8d7d1..1eb2e830d37 100644
--- a/source/gameengine/VideoTexture/VideoBase.cpp
+++ b/source/gameengine/VideoTexture/VideoBase.cpp
@@ -116,24 +116,24 @@ void Video_open (VideoBase * self, char * file, short captureID)
// play video
-PyObject * Video_play (PyImage * self)
+PyObject *Video_play(PyImage *self)
{ if (getVideo(self)->play()) Py_RETURN_TRUE; else Py_RETURN_FALSE; }
// pause video
-PyObject * Video_pause (PyImage * self)
+PyObject *Video_pause(PyImage *self)
{ if (getVideo(self)->pause()) Py_RETURN_TRUE; else Py_RETURN_FALSE; }
-PyObject * Video_stop (PyImage * self)
+PyObject *Video_stop(PyImage *self)
{ if (getVideo(self)->stop()) Py_RETURN_TRUE; else Py_RETURN_FALSE; }
// get status
-PyObject * Video_getStatus (PyImage * self, void * closure)
+PyObject *Video_getStatus(PyImage *self, void *closure)
{
return Py_BuildValue("h", getVideo(self)->getStatus());
}
// refresh video
-PyObject * Video_refresh (PyImage * self)
+PyObject *Video_refresh(PyImage *self)
{
getVideo(self)->refresh();
return Video_getStatus(self, NULL);
@@ -141,19 +141,20 @@ PyObject * Video_refresh (PyImage * self)
// get range
-PyObject * Video_getRange (PyImage * self, void * closure)
+PyObject *Video_getRange(PyImage *self, void *closure)
{
return Py_BuildValue("[ff]", getVideo(self)->getRange()[0],
getVideo(self)->getRange()[1]);
}
// set range
-int Video_setRange (PyImage * self, PyObject * value, void * closure)
+int Video_setRange(PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
- if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 2
- || !PyFloat_Check(PySequence_Fast_GET_ITEM(value, 0))
- || !PyFloat_Check(PySequence_Fast_GET_ITEM(value, 1)))
+ if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 2 ||
+ /* XXX - this is incorrect if the sequence is not a list/tuple! */
+ !PyFloat_Check(PySequence_Fast_GET_ITEM(value, 0)) ||
+ !PyFloat_Check(PySequence_Fast_GET_ITEM(value, 1)))
{
PyErr_SetString(PyExc_TypeError, "The value must be a sequence of 2 float");
return -1;
@@ -166,11 +167,11 @@ int Video_setRange (PyImage * self, PyObject * value, void * closure)
}
// get repeat
-PyObject * Video_getRepeat (PyImage * self, void * closure)
+PyObject *Video_getRepeat (PyImage *self, void *closure)
{ return Py_BuildValue("h", getVideo(self)->getRepeat()); }
// set repeat
-int Video_setRepeat (PyImage * self, PyObject * value, void * closure)
+int Video_setRepeat(PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PyLong_Check(value))
@@ -185,11 +186,11 @@ int Video_setRepeat (PyImage * self, PyObject * value, void * closure)
}
// get frame rate
-PyObject * Video_getFrameRate (PyImage * self, void * closure)
+PyObject *Video_getFrameRate (PyImage *self, void *closure)
{ return Py_BuildValue("f", double(getVideo(self)->getFrameRate())); }
// set frame rate
-int Video_setFrameRate (PyImage * self, PyObject * value, void * closure)
+int Video_setFrameRate(PyImage *self, PyObject *value, void *closure)
{
// check validity of parameter
if (value == NULL || !PyFloat_Check(value))
diff --git a/source/gameengine/VideoTexture/VideoBase.h b/source/gameengine/VideoTexture/VideoBase.h
index e221d876358..4cf913d755d 100644
--- a/source/gameengine/VideoTexture/VideoBase.h
+++ b/source/gameengine/VideoTexture/VideoBase.h
@@ -164,14 +164,14 @@ protected:
// cast Image pointer to Video
-inline VideoBase * getVideo (PyImage * self)
+inline VideoBase *getVideo(PyImage *self)
{ return static_cast<VideoBase*>(self->m_image); }
extern ExceptionID SourceVideoCreation;
// object initialization
-template <class T> void Video_init (PyImage * self)
+template <class T> void Video_init(PyImage *self)
{
// create source video object
if (self->m_image != NULL) delete self->m_image;
@@ -182,18 +182,18 @@ template <class T> void Video_init (PyImage * self)
// video functions
-void Video_open (VideoBase * self, char * file, short captureID);
-PyObject * Video_play (PyImage * self);
-PyObject * Video_pause (PyImage * self);
-PyObject * Video_stop (PyImage * self);
-PyObject * Video_refresh (PyImage * self);
-PyObject * Video_getStatus (PyImage * self, void * closure);
-PyObject * Video_getRange (PyImage * self, void * closure);
-int Video_setRange (PyImage * self, PyObject * value, void * closure);
-PyObject * Video_getRepeat (PyImage * self, void * closure);
-int Video_setRepeat (PyImage * self, PyObject * value, void * closure);
-PyObject * Video_getFrameRate (PyImage * self, void * closure);
-int Video_setFrameRate (PyImage * self, PyObject * value, void * closure);
+void Video_open(VideoBase * self, char * file, short captureID);
+PyObject *Video_play(PyImage *self);
+PyObject *Video_pause(PyImage *self);
+PyObject *Video_stop(PyImage *self);
+PyObject *Video_refresh(PyImage *self);
+PyObject *Video_getStatus(PyImage *self, void *closure);
+PyObject *Video_getRange(PyImage *self, void *closure);
+int Video_setRange(PyImage *self, PyObject *value, void *closure);
+PyObject *Video_getRepeat(PyImage *self, void *closure);
+int Video_setRepeat(PyImage *self, PyObject *value, void *closure);
+PyObject *Video_getFrameRate(PyImage *self, void *closure);
+int Video_setFrameRate(PyImage *self, PyObject *value, void *closure);
#endif
diff --git a/source/gameengine/VideoTexture/VideoFFmpeg.cpp b/source/gameengine/VideoTexture/VideoFFmpeg.cpp
index f1c92f2feb3..cf65362c31d 100644
--- a/source/gameengine/VideoTexture/VideoFFmpeg.cpp
+++ b/source/gameengine/VideoTexture/VideoFFmpeg.cpp
@@ -524,7 +524,7 @@ void VideoFFmpeg::openFile (char * filename)
if (m_codecCtx->gop_size)
m_preseek = (m_codecCtx->gop_size < 25) ? m_codecCtx->gop_size+1 : 25;
- else if (m_codecCtx->has_b_frames)
+ else if (m_codecCtx->has_b_frames)
m_preseek = 25; // should determine gopsize
else
m_preseek = 0;
@@ -1076,14 +1076,14 @@ AVFrame *VideoFFmpeg::grabFrame(long position)
// cast Image pointer to VideoFFmpeg
-inline VideoFFmpeg * getVideoFFmpeg (PyImage * self)
+inline VideoFFmpeg * getVideoFFmpeg (PyImage *self)
{ return static_cast<VideoFFmpeg*>(self->m_image); }
// object initialization
-static int VideoFFmpeg_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+static int VideoFFmpeg_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
- PyImage * self = reinterpret_cast<PyImage*>(pySelf);
+ PyImage *self = reinterpret_cast<PyImage*>(pySelf);
// parameters - video source
// file name or format type for capture (only for Linux: video4linux or dv1394)
char * file = NULL;
@@ -1239,9 +1239,9 @@ PyTypeObject VideoFFmpegType =
};
// object initialization
-static int ImageFFmpeg_init (PyObject * pySelf, PyObject * args, PyObject * kwds)
+static int ImageFFmpeg_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
{
- PyImage * self = reinterpret_cast<PyImage*>(pySelf);
+ PyImage *self = reinterpret_cast<PyImage*>(pySelf);
// parameters - video source
// file name or format type for capture (only for Linux: video4linux or dv1394)
char * file = NULL;
diff --git a/source/gameengine/VideoTexture/VideoFFmpeg.h b/source/gameengine/VideoTexture/VideoFFmpeg.h
index e63032e0c66..cd0edfc09ef 100644
--- a/source/gameengine/VideoTexture/VideoFFmpeg.h
+++ b/source/gameengine/VideoTexture/VideoFFmpeg.h
@@ -204,7 +204,7 @@ private:
static void *cacheThread(void *);
};
-inline VideoFFmpeg * getFFmpeg (PyImage * self)
+inline VideoFFmpeg *getFFmpeg(PyImage *self)
{
return static_cast<VideoFFmpeg*>(self->m_image);
}
diff --git a/source/gameengine/VideoTexture/blendVideoTex.cpp b/source/gameengine/VideoTexture/blendVideoTex.cpp
index 7d595832ffd..dd9d83c043f 100644
--- a/source/gameengine/VideoTexture/blendVideoTex.cpp
+++ b/source/gameengine/VideoTexture/blendVideoTex.cpp
@@ -48,10 +48,10 @@ http://www.gnu.org/copyleft/lesser.txt.
// get material id
-static PyObject * getMaterialID (PyObject *self, PyObject *args)
+static PyObject *getMaterialID (PyObject *self, PyObject *args)
{
// parameters - game object with video texture
- PyObject * obj = NULL;
+ PyObject *obj = NULL;
// material name
char * matName;
@@ -72,13 +72,13 @@ static PyObject * getMaterialID (PyObject *self, PyObject *args)
// get last error description
-static PyObject * getLastError (PyObject *self, PyObject *args)
+static PyObject *getLastError (PyObject *self, PyObject *args)
{
return PyUnicode_FromString(Exception::m_lastError.c_str());
}
// set log file
-static PyObject * setLogFile (PyObject *self, PyObject *args)
+static PyObject *setLogFile (PyObject *self, PyObject *args)
{
// get parameters
if (!PyArg_ParseTuple(args, "s:setLogFile", &Exception::m_logFile))
@@ -89,10 +89,10 @@ static PyObject * setLogFile (PyObject *self, PyObject *args)
// image to numpy array
-static PyObject * imageToArray (PyObject * self, PyObject *args)
+static PyObject *imageToArray(PyObject *self, PyObject *args)
{
// parameter is Image object
- PyObject * pyImg;
+ PyObject *pyImg;
char *mode = NULL;
if (!PyArg_ParseTuple(args, "O|s:imageToArray", &pyImg, &mode) || !pyImageTypes.in(Py_TYPE(pyImg)))
{
@@ -172,7 +172,7 @@ static struct PyModuleDef VideoTexture_module_def = {
PyObject *initVideoTexture(void)
{
- PyObject * m;
+ PyObject *m;
// initialize GL extensions
//bgl::InitExtensions(0);
@@ -210,7 +210,7 @@ PyObject *initVideoTexture(void)
pyFilterTypes.reg(m);
Py_INCREF(&TextureType);
- PyModule_AddObject(m, (char*)"Texture", (PyObject*)&TextureType);
+ PyModule_AddObject(m, (char*)"Texture", (PyObject *)&TextureType);
PyModule_AddIntConstant(m, (char*)"SOURCE_ERROR", SourceError);
PyModule_AddIntConstant(m, (char*)"SOURCE_EMPTY", SourceEmpty);
PyModule_AddIntConstant(m, (char*)"SOURCE_READY", SourceReady);