Added newlines and did other clean-ups to eliminate errors and

minimize warnings compiling with g++ 3.2.
This commit is contained in:
david
2002-09-14 16:03:39 +00:00
parent adeb0d48fc
commit d068915b42
30 changed files with 40 additions and 35 deletions

View File

@@ -16,4 +16,4 @@ template <class object>
class SkyAABBTree : public SkyBVTree<object, SkyMinMaxBox, SkyAABBTreeSplitter<object> >
{};
#endif //__SKYAABBTREE_HPP__
#endif //__SKYAABBTREE_HPP__

View File

@@ -240,4 +240,4 @@ private:
SKYRESULT _Load(FILE* pSrcFile);
};
#endif //__SKYARCHIVE_HPP__
#endif //__SKYARCHIVE_HPP__

View File

@@ -294,4 +294,4 @@ private:
std::vector<NodeObject> _objList;
};
#endif //__SKYBVTREE_HPP__
#endif //__SKYBVTREE_HPP__

View File

@@ -239,4 +239,4 @@ private:
SkyBoundingBoxSplitter<Object> _splitter;
};*/
#endif //__SKYBVTREESPLITTER_HPP__
#endif //__SKYBVTREESPLITTER_HPP__

View File

@@ -148,4 +148,4 @@ protected:
float _rRadius;
};
#endif //__SKYBOUNDINGVOLUME_HPP__
#endif //__SKYBOUNDINGVOLUME_HPP__

View File

@@ -172,4 +172,4 @@ protected: // data
static float s_rSortSquareDistanceTolerance; // how far the view must move to cause a resort.
};
#endif //__SKYCLOUD_HPP__
#endif //__SKYCLOUD_HPP__

View File

@@ -172,4 +172,4 @@ inline const Vec4f& SkyCloudParticle::GetLitColor(unsigned int index) const
return Vec4f::ZERO;
}
#endif //__SKYCLOUDPARTICLE_HPP__
#endif //__SKYCLOUDPARTICLE_HPP__

View File

@@ -138,4 +138,4 @@ protected: // data
};
#endif //__SKYCONTEXT_HPP__
#endif //__SKYCONTEXT_HPP__

View File

@@ -77,4 +77,4 @@ protected: // data
unsigned int _iNumTextureBytesCheckedIn;
};
#endif //__SKYDYNAMICTEXTUREMANAGER_HPP__
#endif //__SKYDYNAMICTEXTUREMANAGER_HPP__

View File

@@ -218,4 +218,4 @@ SKYRESULT SkyLight::Activate(int iLightID)
glPopMatrix();
return SKYRESULT_OK;
}
}

View File

@@ -94,4 +94,4 @@ protected: // data
static SkyMaterial *s_pMaterial; // used for rendering the lights during debugging
};
#endif //__SKYLIGHT_HPP__
#endif //__SKYLIGHT_HPP__

View File

@@ -265,4 +265,4 @@ protected:
GLenum _eTextureEnvMode;
};
#endif //__SKYMATERIAL_HPP__
#endif //__SKYMATERIAL_HPP__

View File

@@ -319,4 +319,4 @@ void SkyMinMaxBox::_CalcVerts(Vec3f pVerts[8]) const
pVerts[1].Set(_min.x, _max.y, _max.z); pVerts[5].Set(_min.x, _max.y, _min.z);
pVerts[2].Set(_min.x, _min.y, _max.z); pVerts[6].Set(_min);
pVerts[3].Set(_max.x, _min.y, _max.z); pVerts[7].Set(_max.x, _min.y, _min.z);
}
}

View File

@@ -82,4 +82,4 @@ private:
Vec3f _max;
};
#endif //__SKYMINMAXBOX_HPP__
#endif //__SKYMINMAXBOX_HPP__

View File

@@ -113,4 +113,4 @@ protected:
std::string _name; // the name of this renderable.
};
#endif //__SKYRENDERABLE_HPP__
#endif //__SKYRENDERABLE_HPP__

View File

@@ -199,4 +199,4 @@ inline void SkyRenderableInstance::GetWorldToModelTransform(Mat44f &mat) const
mat[15] = 1;
}
#endif //__SKYRENDERABLEINSTANCE_HPP__
#endif //__SKYRENDERABLEINSTANCE_HPP__

View File

@@ -68,7 +68,7 @@ SkyRenderableInstanceCloud::SkyRenderableInstanceCloud(SkyCloud *pCloud,
_iCulledCount(0)
{
_Initialize();
cout << "Cloud Instance created" << endl;
// cout << "Cloud Instance created" << endl;
}
//------------------------------------------------------------------------------

View File

@@ -270,4 +270,4 @@ inline void SkyRenderableInstanceCloud::_UpdateWorldSpaceBounds()
_vecPosition = _pCloud->CopyBoundingVolume()->GetCenter();
}
#endif //__SKYRENDERABLEINSTANCECLOUD_HPP__
#endif //__SKYRENDERABLEINSTANCECLOUD_HPP__

View File

@@ -73,4 +73,4 @@ protected:
SkyMinMaxBox *_pBV; // Pointer to bounding volume
};
#endif //__SKYRENDERABLEINSTANCEGENERIC_HPP__
#endif //__SKYRENDERABLEINSTANCEGENERIC_HPP__

View File

@@ -175,4 +175,4 @@ void SkyRenderableInstanceGroup::AddSubInstance(SkyRenderableInstance *pInstance
_pObjectSpaceBV->AddPoint(xform * min);
_pObjectSpaceBV->AddPoint(xform * max);
}
}

View File

@@ -60,4 +60,4 @@ protected:
};
#endif //__SKYRENDERABLEINSTANCEGROUP_HPP__
#endif //__SKYRENDERABLEINSTANCEGROUP_HPP__

View File

@@ -293,7 +293,8 @@ SkyMaterial* SkySceneManager::GetMaterial(int iMaterialID)
*
* @todo <WRITE EXTENDED SkySceneManager::ActivateMaterial FUNCTION DOCUMENTATION>
*/
SKYRESULT SkySceneManager::ActivateMaterial(int iMaterialID)
SKYRESULT SkySceneManager::ActivateMaterial(int iMaterialID)
{
// cout << "Activating material\n"; char mm; cin >> mm;
MaterialIterator mi = _materials.find(iMaterialID);
if (_materials.end() == mi)
@@ -478,7 +479,8 @@ SKYRESULT SkySceneManager::RebuildCloudBVTree()
* @brief @todo <WRITE BRIEF SkySceneManager::ShadeClouds DOCUMENTATION>
*
* @todo <WRITE EXTENDED SkySceneManager::ShadeClouds FUNCTION DOCUMENTATION>
* @todo <WRITE EXTENDED SkySceneManager::ShadeClouds FUNCTION DOCUMENTATION>
*/
SKYRESULT SkySceneManager::ShadeClouds()
{
// cout << "SkySceneManager::ShadeClouds()\n";
int i=0;
@@ -489,7 +491,7 @@ SKYRESULT SkySceneManager::ShadeClouds()
{
if (SkyLight::SKY_LIGHT_DIRECTIONAL == li->second->GetType())
{
(*cii)->GetCloud()->Illuminate(li->second, *cii, li == _lights.begin());
// printf("Shading Cloud %d of %d with light %d \n", i++, _cloudInstances.size(), *li );
}
@@ -750,7 +752,8 @@ SKYRESULT SkySceneManager::_ResolveVisibility(const Camera &cam)
// rendered with the cloud in which it is contained for correct visibility. If the instance is
// not inside any cloud, then it is a "free" instance, and will be rendered after all contained
// instances. Transparent instances of each type are rendered after opaque instances of each
// not inside any cloud, then it is a "free" instance, and will be rendered after all contained
// type.
// opaque instances
for (ii = _instances.begin(); ii != _instances.end(); ++ii)
{
@@ -765,7 +768,8 @@ SKYRESULT SkySceneManager::_ResolveVisibility(const Camera &cam)
if (!_TestInsertInstanceIntoClouds(cam, _cloudBVTree.GetRoot(), *ii, false))
_visibleInstances.push_back(*ii);
}
if (!_TestInsertInstanceIntoClouds(cam, _cloudBVTree.GetRoot(), *ii, false))
}
// transparent instances
for (ii = _transparentInstances.begin(); ii != _transparentInstances.end(); ++ii)
{

View File

@@ -185,4 +185,4 @@ private: // data
bool _bReshadeClouds;
};
#endif //__SKYSCENEMANAGER_HPP__
#endif //__SKYSCENEMANAGER_HPP__

View File

@@ -289,4 +289,4 @@ private:
// declare the static instance pointer
template<class T> SkySingleton<T>* SkySingleton<T>::s_pInstance = NULL;
#endif //__SKYSINGLETON_HPP__
#endif //__SKYSINGLETON_HPP__

View File

@@ -93,4 +93,4 @@ inline SKYRESULT SkyTexture::Destroy()
return SKYRESULT_OK;
}
#endif //__SKYTEXTURE_HPP__
#endif //__SKYTEXTURE_HPP__

View File

@@ -285,7 +285,7 @@ SKYRESULT SkyTextureManager::Clone2DTexture(const string &filename,
//}
}
}
if (!pImageData)
{
char buffer[256];
@@ -880,4 +880,4 @@ void SkyTextureManager::DestroyTextureObject(SkyTexture &texture)
/*if (texture.GetID)
glDeleteTextures(1, &(texture.iTextureID));
if (texture.bSliced3D && texture.pSliceIDs)
{
{

View File

@@ -268,4 +268,5 @@ SKYRESULT SkyTextureState::SetTextureParameter(unsigned int iTextureUnit,
}
return SKYRESULT_OK;
}
}

View File

@@ -202,4 +202,4 @@ inline GLenum SkyTextureState::GetTextureParameter(unsigned int iTextureUnit, GL
return GL_NONE;
}
#endif //__SKYTEXTURESTATE_HPP__
#endif //__SKYTEXTURESTATE_HPP__

View File

@@ -189,4 +189,4 @@ enum SKYRESULT_CODES
#define FAIL_RETURN_MSGBOX(p,str) p
#endif
#endif //__SKYUTIL_HPP__
#endif //__SKYUTIL_HPP__

View File

@@ -21,7 +21,7 @@
// $Id$
//============================================================================
#include "camera.hpp"
#include <iostream.h>
#include <iostream>
//----------------------------------------------------------------------------
// CONSTRUCTOR: defines a default camera system defined as (45 DEG FOV)