correct indentation and some whitespace edits (no functional changes)

This commit is contained in:
2011-11-11 13:09:14 +00:00
parent 094c9799f9
commit e84c0980a3
142 changed files with 722 additions and 688 deletions

View File

@@ -177,8 +177,9 @@ void BL_ShapeActionActuator::BlendShape(Key* key, float srcweight)
dstweight = 1.0F - srcweight;
for (it=m_blendshape.begin(), kb = (KeyBlock*)key->block.first;
kb && it != m_blendshape.end();
kb = (KeyBlock*)kb->next, it++) {
kb && it != m_blendshape.end();
kb = (KeyBlock*)kb->next, it++)
{
kb->curval = kb->curval * dstweight + (*it) * srcweight;
}
}

View File

@@ -36,8 +36,8 @@ public:
CIntValue();
CIntValue(cInt innie);
CIntValue(cInt innie,
const char *name,
AllocationTYPE alloctype=CValue::HEAPVALUE);
const char *name,
AllocationTYPE alloctype=CValue::HEAPVALUE);
virtual CValue* Calc(VALUE_OPERATOR op,
CValue *val);

View File

@@ -88,9 +88,9 @@ class SCA_MouseSensor : public SCA_ISensor
bool isValid(KX_MOUSESENSORMODE);
SCA_MouseSensor(class SCA_MouseManager* keybdmgr,
int startx,int starty,
short int mousemode,
SCA_IObject* gameobj);
int startx,int starty,
short int mousemode,
SCA_IObject* gameobj);
virtual ~SCA_MouseSensor();
virtual CValue* GetReplica();

View File

@@ -451,14 +451,14 @@ MakeScreenShot(
// png image settings
png_set_IHDR(png_ptr,
info_ptr,
GetWidth(),
GetHeight(),
8,
color_type,
PNG_INTERLACE_NONE,
PNG_COMPRESSION_TYPE_DEFAULT,
PNG_FILTER_TYPE_DEFAULT);
info_ptr,
GetWidth(),
GetHeight(),
8,
color_type,
PNG_INTERLACE_NONE,
PNG_COMPRESSION_TYPE_DEFAULT,
PNG_FILTER_TYPE_DEFAULT);
// write the file header information
png_write_info(png_ptr, info_ptr);

View File

@@ -309,8 +309,9 @@ void BL_Action::BlendShape(Key* key, float srcweight, std::vector<float>& blends
dstweight = 1.0F - srcweight;
//printf("Dst: %f\tSrc: %f\n", srcweight, dstweight);
for (it=blendshape.begin(), kb = (KeyBlock*)key->block.first;
kb && it != blendshape.end();
kb = (KeyBlock*)kb->next, it++) {
kb && it != blendshape.end();
kb = (KeyBlock*)kb->next, it++)
{
//printf("OirgKeys: %f\t%f\n", kb->curval, (*it));
kb->curval = kb->curval * dstweight + (*it) * srcweight;
//printf("NewKey: %f\n", kb->curval);

View File

@@ -451,7 +451,7 @@ void BL_Shader::Update( const RAS_MeshSlot & ms, RAS_IRasterizer* rasty )
const MT_Matrix4x4& view = rasty->GetViewMatrix();
if(mAttr==SHD_TANGENT)
ms.m_mesh->SetMeshModified(true);
ms.m_mesh->SetMeshModified(true);
BL_UniformVecDef::iterator it;
for(it = mPreDef.begin(); it!= mPreDef.end(); it++)

View File

@@ -425,21 +425,21 @@ void KX_Dome::GLDrawWarpQuads(void)
if (warp.nodes[i][j].i < 0 || warp.nodes[i2][j].i < 0 || warp.nodes[i2][j+1].i < 0 || warp.nodes[i][j+1].i < 0)
continue;
glColor3f(warp.nodes[i][j].i,warp.nodes[i][j].i,warp.nodes[i][j].i);
glTexCoord2f((warp.nodes[i][j].u * uv_width), (warp.nodes[i][j].v * uv_height));
glVertex3f(warp.nodes[i][j].x,warp.nodes[i][j].y,0.0);
glColor3f(warp.nodes[i][j].i,warp.nodes[i][j].i,warp.nodes[i][j].i);
glTexCoord2f((warp.nodes[i][j].u * uv_width), (warp.nodes[i][j].v * uv_height));
glVertex3f(warp.nodes[i][j].x,warp.nodes[i][j].y,0.0);
glColor3f(warp.nodes[i2][j].i,warp.nodes[i2][j].i,warp.nodes[i2][j].i);
glTexCoord2f((warp.nodes[i2][j].u * uv_width), (warp.nodes[i2][j].v * uv_height));
glVertex3f(warp.nodes[i2][j].x,warp.nodes[i2][j].y,0.0);
glColor3f(warp.nodes[i2][j].i,warp.nodes[i2][j].i,warp.nodes[i2][j].i);
glTexCoord2f((warp.nodes[i2][j].u * uv_width), (warp.nodes[i2][j].v * uv_height));
glVertex3f(warp.nodes[i2][j].x,warp.nodes[i2][j].y,0.0);
glColor3f(warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i);
glTexCoord2f((warp.nodes[i2][j+1].u * uv_width), (warp.nodes[i2][j+1].v * uv_height));
glVertex3f(warp.nodes[i2][j+1].x,warp.nodes[i2][j+1].y,0.0);
glColor3f(warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i);
glTexCoord2f((warp.nodes[i2][j+1].u * uv_width), (warp.nodes[i2][j+1].v * uv_height));
glVertex3f(warp.nodes[i2][j+1].x,warp.nodes[i2][j+1].y,0.0);
glColor3f(warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i);
glTexCoord2f((warp.nodes[i2][j+1].u * uv_width), (warp.nodes[i2][j+1].v * uv_height));
glVertex3f(warp.nodes[i2][j+1].x,warp.nodes[i2][j+1].y,0.0);
glColor3f(warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i,warp.nodes[i2][j+1].i);
glTexCoord2f((warp.nodes[i2][j+1].u * uv_width), (warp.nodes[i2][j+1].v * uv_height));
glVertex3f(warp.nodes[i2][j+1].x,warp.nodes[i2][j+1].y,0.0);
}
}

View File

@@ -123,15 +123,15 @@ public:
int m_type;
KX_IpoActuator(SCA_IObject* gameobj,
const STR_String& propname,
const STR_String& framePropname,
float starttime,
float endtime,
bool recurse,
int acttype,
bool ipo_as_force,
bool ipo_add,
bool ipo_local);
const STR_String& propname,
const STR_String& framePropname,
float starttime,
float endtime,
bool recurse,
int acttype,
bool ipo_as_force,
bool ipo_add,
bool ipo_local);
virtual ~KX_IpoActuator() {};
virtual CValue* GetReplica() {

View File

@@ -121,7 +121,7 @@ class KX_MouseFocusSensor : public SCA_MouseSensor
/**
* The focus mode. 1 for handling focus, 0 for not handling, 2 for focus on any object
*/
int m_focusmode;
int m_focusmode;
/**
* Flags whether the previous test showed a mouse-over.

View File

@@ -49,12 +49,12 @@ protected:
KX_ClientObjectInfo* m_client_info;
public:
KX_NearSensor(class SCA_EventManager* eventmgr,
class KX_GameObject* gameobj,
float margin,
float resetmargin,
bool bFindMaterial,
const STR_String& touchedpropname,
PHY_IPhysicsController* ctrl);
class KX_GameObject* gameobj,
float margin,
float resetmargin,
bool bFindMaterial,
const STR_String& touchedpropname,
PHY_IPhysicsController* ctrl);
/*
public:
KX_NearSensor(class SCA_EventManager* eventmgr,

View File

@@ -1247,9 +1247,10 @@ KX_Camera* KX_Scene::FindCamera(KX_Camera* cam)
{
list<KX_Camera*>::iterator it = m_cameras.begin();
while ( (it != m_cameras.end())
&& ((*it) != cam) ) {
it++;
while ( (it != m_cameras.end())
&& ((*it) != cam) )
{
it++;
}
return ((it == m_cameras.end()) ? NULL : (*it));
@@ -1260,9 +1261,10 @@ KX_Camera* KX_Scene::FindCamera(STR_String& name)
{
list<KX_Camera*>::iterator it = m_cameras.begin();
while ( (it != m_cameras.end())
&& ((*it)->GetName() != name) ) {
it++;
while ( (it != m_cameras.end())
&& ((*it)->GetName() != name) )
{
it++;
}
return ((it == m_cameras.end()) ? NULL : (*it));

View File

@@ -2130,8 +2130,8 @@ btCollisionShape* CcdShapeConstructionInfo::CreateBulletShape(btScalar margin, b
{
compoundShape = new btCompoundShape();
for (std::vector<CcdShapeConstructionInfo*>::iterator sit = m_shapeArray.begin();
sit != m_shapeArray.end();
sit++)
sit != m_shapeArray.end();
sit++)
{
collisionShape = (*sit)->CreateBulletShape(margin, useGimpact, useBvh);
if (collisionShape)
@@ -2156,8 +2156,8 @@ void CcdShapeConstructionInfo::AddShape(CcdShapeConstructionInfo* shapeInfo)
CcdShapeConstructionInfo::~CcdShapeConstructionInfo()
{
for (std::vector<CcdShapeConstructionInfo*>::iterator sit = m_shapeArray.begin();
sit != m_shapeArray.end();
sit++)
sit != m_shapeArray.end();
sit++)
{
(*sit)->Release();
}

View File

@@ -79,7 +79,7 @@ extern PyTypeObject TextureType;
// load texture
void loadTexture (unsigned int texId, unsigned int * texture, short * size,
bool mipmap = false);
bool mipmap = false);
// get material
RAS_IPolyMaterial * getMaterial (PyObject *obj, short matID);