From: david Date: Sat, 14 Sep 2002 16:03:39 +0000 (+0000) Subject: Added newlines and did other clean-ups to eliminate errors and X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=d068915b42db8618cf6e1617a3500699c077ed73;p=simgear.git Added newlines and did other clean-ups to eliminate errors and minimize warnings compiling with g++ 3.2. --- diff --git a/simgear/scene/sky/clouds3d/SkyAABBTree.hpp b/simgear/scene/sky/clouds3d/SkyAABBTree.hpp index 81fecddc..56b723ee 100644 --- a/simgear/scene/sky/clouds3d/SkyAABBTree.hpp +++ b/simgear/scene/sky/clouds3d/SkyAABBTree.hpp @@ -16,4 +16,4 @@ template class SkyAABBTree : public SkyBVTree > {}; -#endif //__SKYAABBTREE_HPP__ \ No newline at end of file +#endif //__SKYAABBTREE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyArchive.hpp b/simgear/scene/sky/clouds3d/SkyArchive.hpp index a6aae02b..0385f951 100644 --- a/simgear/scene/sky/clouds3d/SkyArchive.hpp +++ b/simgear/scene/sky/clouds3d/SkyArchive.hpp @@ -240,4 +240,4 @@ private: SKYRESULT _Load(FILE* pSrcFile); }; -#endif //__SKYARCHIVE_HPP__ \ No newline at end of file +#endif //__SKYARCHIVE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyBVTree.hpp b/simgear/scene/sky/clouds3d/SkyBVTree.hpp index d7aaa012..aa03dcac 100644 --- a/simgear/scene/sky/clouds3d/SkyBVTree.hpp +++ b/simgear/scene/sky/clouds3d/SkyBVTree.hpp @@ -294,4 +294,4 @@ private: std::vector _objList; }; -#endif //__SKYBVTREE_HPP__ \ No newline at end of file +#endif //__SKYBVTREE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyBVTreeSplitter.hpp b/simgear/scene/sky/clouds3d/SkyBVTreeSplitter.hpp index 83f25134..2bf1f543 100644 --- a/simgear/scene/sky/clouds3d/SkyBVTreeSplitter.hpp +++ b/simgear/scene/sky/clouds3d/SkyBVTreeSplitter.hpp @@ -239,4 +239,4 @@ private: SkyBoundingBoxSplitter _splitter; };*/ -#endif //__SKYBVTREESPLITTER_HPP__ \ No newline at end of file +#endif //__SKYBVTREESPLITTER_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyBoundingVolume.hpp b/simgear/scene/sky/clouds3d/SkyBoundingVolume.hpp index 9f2242cd..1e5ee026 100644 --- a/simgear/scene/sky/clouds3d/SkyBoundingVolume.hpp +++ b/simgear/scene/sky/clouds3d/SkyBoundingVolume.hpp @@ -148,4 +148,4 @@ protected: float _rRadius; }; -#endif //__SKYBOUNDINGVOLUME_HPP__ \ No newline at end of file +#endif //__SKYBOUNDINGVOLUME_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyCloud.hpp b/simgear/scene/sky/clouds3d/SkyCloud.hpp index 6eeb5bbc..24b2d3a6 100644 --- a/simgear/scene/sky/clouds3d/SkyCloud.hpp +++ b/simgear/scene/sky/clouds3d/SkyCloud.hpp @@ -172,4 +172,4 @@ protected: // data static float s_rSortSquareDistanceTolerance; // how far the view must move to cause a resort. }; -#endif //__SKYCLOUD_HPP__ \ No newline at end of file +#endif //__SKYCLOUD_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyCloudParticle.hpp b/simgear/scene/sky/clouds3d/SkyCloudParticle.hpp index 0b9c15b7..90e6a334 100644 --- a/simgear/scene/sky/clouds3d/SkyCloudParticle.hpp +++ b/simgear/scene/sky/clouds3d/SkyCloudParticle.hpp @@ -172,4 +172,4 @@ inline const Vec4f& SkyCloudParticle::GetLitColor(unsigned int index) const return Vec4f::ZERO; } -#endif //__SKYCLOUDPARTICLE_HPP__ \ No newline at end of file +#endif //__SKYCLOUDPARTICLE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyContext.hpp b/simgear/scene/sky/clouds3d/SkyContext.hpp index e6d08040..fcf0d18f 100644 --- a/simgear/scene/sky/clouds3d/SkyContext.hpp +++ b/simgear/scene/sky/clouds3d/SkyContext.hpp @@ -138,4 +138,4 @@ protected: // data }; -#endif //__SKYCONTEXT_HPP__ \ No newline at end of file +#endif //__SKYCONTEXT_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyDynamicTextureManager.hpp b/simgear/scene/sky/clouds3d/SkyDynamicTextureManager.hpp index 57f09bbd..f16060a9 100644 --- a/simgear/scene/sky/clouds3d/SkyDynamicTextureManager.hpp +++ b/simgear/scene/sky/clouds3d/SkyDynamicTextureManager.hpp @@ -77,4 +77,4 @@ protected: // data unsigned int _iNumTextureBytesCheckedIn; }; -#endif //__SKYDYNAMICTEXTUREMANAGER_HPP__ \ No newline at end of file +#endif //__SKYDYNAMICTEXTUREMANAGER_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyLight.cpp b/simgear/scene/sky/clouds3d/SkyLight.cpp index b3d4cb3c..c71f1657 100644 --- a/simgear/scene/sky/clouds3d/SkyLight.cpp +++ b/simgear/scene/sky/clouds3d/SkyLight.cpp @@ -218,4 +218,4 @@ SKYRESULT SkyLight::Activate(int iLightID) glPopMatrix(); return SKYRESULT_OK; -} \ No newline at end of file +} diff --git a/simgear/scene/sky/clouds3d/SkyLight.hpp b/simgear/scene/sky/clouds3d/SkyLight.hpp index b78fb11e..e7d62494 100644 --- a/simgear/scene/sky/clouds3d/SkyLight.hpp +++ b/simgear/scene/sky/clouds3d/SkyLight.hpp @@ -94,4 +94,4 @@ protected: // data static SkyMaterial *s_pMaterial; // used for rendering the lights during debugging }; -#endif //__SKYLIGHT_HPP__ \ No newline at end of file +#endif //__SKYLIGHT_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyMaterial.hpp b/simgear/scene/sky/clouds3d/SkyMaterial.hpp index cf3a1d50..255f8f92 100644 --- a/simgear/scene/sky/clouds3d/SkyMaterial.hpp +++ b/simgear/scene/sky/clouds3d/SkyMaterial.hpp @@ -265,4 +265,4 @@ protected: GLenum _eTextureEnvMode; }; -#endif //__SKYMATERIAL_HPP__ \ No newline at end of file +#endif //__SKYMATERIAL_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyMinMaxBox.cpp b/simgear/scene/sky/clouds3d/SkyMinMaxBox.cpp index 968470fe..6c28790a 100644 --- a/simgear/scene/sky/clouds3d/SkyMinMaxBox.cpp +++ b/simgear/scene/sky/clouds3d/SkyMinMaxBox.cpp @@ -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); -} \ No newline at end of file +} diff --git a/simgear/scene/sky/clouds3d/SkyMinMaxBox.hpp b/simgear/scene/sky/clouds3d/SkyMinMaxBox.hpp index 6a385198..aebfa5dc 100644 --- a/simgear/scene/sky/clouds3d/SkyMinMaxBox.hpp +++ b/simgear/scene/sky/clouds3d/SkyMinMaxBox.hpp @@ -82,4 +82,4 @@ private: Vec3f _max; }; -#endif //__SKYMINMAXBOX_HPP__ \ No newline at end of file +#endif //__SKYMINMAXBOX_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyRenderable.hpp b/simgear/scene/sky/clouds3d/SkyRenderable.hpp index 83640953..8f224ae9 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderable.hpp +++ b/simgear/scene/sky/clouds3d/SkyRenderable.hpp @@ -113,4 +113,4 @@ protected: std::string _name; // the name of this renderable. }; -#endif //__SKYRENDERABLE_HPP__ \ No newline at end of file +#endif //__SKYRENDERABLE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyRenderableInstance.hpp b/simgear/scene/sky/clouds3d/SkyRenderableInstance.hpp index c483999a..9c09a509 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderableInstance.hpp +++ b/simgear/scene/sky/clouds3d/SkyRenderableInstance.hpp @@ -199,4 +199,4 @@ inline void SkyRenderableInstance::GetWorldToModelTransform(Mat44f &mat) const mat[15] = 1; } -#endif //__SKYRENDERABLEINSTANCE_HPP__ \ No newline at end of file +#endif //__SKYRENDERABLEINSTANCE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.cpp b/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.cpp index 2f404034..b83f0f12 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.cpp +++ b/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.cpp @@ -68,7 +68,7 @@ SkyRenderableInstanceCloud::SkyRenderableInstanceCloud(SkyCloud *pCloud, _iCulledCount(0) { _Initialize(); - cout << "Cloud Instance created" << endl; +// cout << "Cloud Instance created" << endl; } //------------------------------------------------------------------------------ diff --git a/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.hpp b/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.hpp index e7bac3de..5cbd4f6f 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.hpp +++ b/simgear/scene/sky/clouds3d/SkyRenderableInstanceCloud.hpp @@ -270,4 +270,4 @@ inline void SkyRenderableInstanceCloud::_UpdateWorldSpaceBounds() _vecPosition = _pCloud->CopyBoundingVolume()->GetCenter(); } -#endif //__SKYRENDERABLEINSTANCECLOUD_HPP__ \ No newline at end of file +#endif //__SKYRENDERABLEINSTANCECLOUD_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyRenderableInstanceGeneric.hpp b/simgear/scene/sky/clouds3d/SkyRenderableInstanceGeneric.hpp index b69d26a2..461f3b0a 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderableInstanceGeneric.hpp +++ b/simgear/scene/sky/clouds3d/SkyRenderableInstanceGeneric.hpp @@ -73,4 +73,4 @@ protected: SkyMinMaxBox *_pBV; // Pointer to bounding volume }; -#endif //__SKYRENDERABLEINSTANCEGENERIC_HPP__ \ No newline at end of file +#endif //__SKYRENDERABLEINSTANCEGENERIC_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.cpp b/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.cpp index dbd8871d..2fa497a8 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.cpp +++ b/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.cpp @@ -175,4 +175,4 @@ void SkyRenderableInstanceGroup::AddSubInstance(SkyRenderableInstance *pInstance _pObjectSpaceBV->AddPoint(xform * min); _pObjectSpaceBV->AddPoint(xform * max); } -} \ No newline at end of file +} diff --git a/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.hpp b/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.hpp index 1557003b..6ec8d6a9 100644 --- a/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.hpp +++ b/simgear/scene/sky/clouds3d/SkyRenderableInstanceGroup.hpp @@ -60,4 +60,4 @@ protected: }; -#endif //__SKYRENDERABLEINSTANCEGROUP_HPP__ \ No newline at end of file +#endif //__SKYRENDERABLEINSTANCEGROUP_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkySceneManager.cpp b/simgear/scene/sky/clouds3d/SkySceneManager.cpp index 726eed3f..6b1b2a76 100644 --- a/simgear/scene/sky/clouds3d/SkySceneManager.cpp +++ b/simgear/scene/sky/clouds3d/SkySceneManager.cpp @@ -293,7 +293,8 @@ SkyMaterial* SkySceneManager::GetMaterial(int iMaterialID) * @todo */ SKYRESULT SkySceneManager::ActivateMaterial(int iMaterialID) -{ cout << "Activating material\n"; char mm; cin >> mm; +{ +// cout << "Activating material\n"; char mm; cin >> mm; MaterialIterator mi = _materials.find(iMaterialID); if (_materials.end() == mi) { @@ -478,7 +479,8 @@ SKYRESULT SkySceneManager::RebuildCloudBVTree() * @todo */ SKYRESULT SkySceneManager::ShadeClouds() -{ cout << "SkySceneManager::ShadeClouds()\n"; +{ +// cout << "SkySceneManager::ShadeClouds()\n"; int i=0; for (CloudInstanceIterator cii = _cloudInstances.begin(); cii != _cloudInstances.end(); ++cii) @@ -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 ); +// printf("Shading Cloud %d of %d with light %d \n", i++, _cloudInstances.size(), *li ); } } } @@ -750,7 +752,8 @@ SKYRESULT SkySceneManager::_ResolveVisibility(const Camera &cam) // opaque instances for (ii = _instances.begin(); ii != _instances.end(); ++ii) - { cout << "Opague instance\n"; char zz; cin >> zz; + { +// cout << "Opague instance\n"; char zz; cin >> zz; (*ii)->ViewFrustumCull(cam); // First VFC then check if culled, some instances may // manually set the culled flag, instead of using VFC if (!(*ii)->IsCulled()) @@ -765,7 +768,8 @@ SKYRESULT SkySceneManager::_ResolveVisibility(const Camera &cam) // transparent instances for (ii = _transparentInstances.begin(); ii != _transparentInstances.end(); ++ii) - { cout << "Transparent instance\n"; char tt; cin >> tt; + { +// cout << "Transparent instance\n"; char tt; cin >> tt; (*ii)->ViewFrustumCull(cam); // First VFC then check if culled, some instances may // manually set the culled flag, instead of using VFC if (!(*ii)->IsCulled()) diff --git a/simgear/scene/sky/clouds3d/SkySceneManager.hpp b/simgear/scene/sky/clouds3d/SkySceneManager.hpp index 054c5176..8926d396 100644 --- a/simgear/scene/sky/clouds3d/SkySceneManager.hpp +++ b/simgear/scene/sky/clouds3d/SkySceneManager.hpp @@ -185,4 +185,4 @@ private: // data bool _bReshadeClouds; }; -#endif //__SKYSCENEMANAGER_HPP__ \ No newline at end of file +#endif //__SKYSCENEMANAGER_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkySingleton.hpp b/simgear/scene/sky/clouds3d/SkySingleton.hpp index e8aeaf6f..ad408430 100644 --- a/simgear/scene/sky/clouds3d/SkySingleton.hpp +++ b/simgear/scene/sky/clouds3d/SkySingleton.hpp @@ -289,4 +289,4 @@ private: // declare the static instance pointer template SkySingleton* SkySingleton::s_pInstance = NULL; -#endif //__SKYSINGLETON_HPP__ \ No newline at end of file +#endif //__SKYSINGLETON_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyTexture.hpp b/simgear/scene/sky/clouds3d/SkyTexture.hpp index 50790118..5bb515c2 100644 --- a/simgear/scene/sky/clouds3d/SkyTexture.hpp +++ b/simgear/scene/sky/clouds3d/SkyTexture.hpp @@ -93,4 +93,4 @@ inline SKYRESULT SkyTexture::Destroy() return SKYRESULT_OK; } -#endif //__SKYTEXTURE_HPP__ \ No newline at end of file +#endif //__SKYTEXTURE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyTextureManager.cpp b/simgear/scene/sky/clouds3d/SkyTextureManager.cpp index 715971b7..346d7e78 100644 --- a/simgear/scene/sky/clouds3d/SkyTextureManager.cpp +++ b/simgear/scene/sky/clouds3d/SkyTextureManager.cpp @@ -285,7 +285,7 @@ SKYRESULT SkyTextureManager::Clone2DTexture(const string &filename, if (!pImageData) { char buffer[256]; - sprintf(buffer, "SkyTextureManager::Clone2DTexture(): Could not load image. %s.\n", filename); + sprintf(buffer, "SkyTextureManager::Clone2DTexture(): Could not load image. %s.\n", filename.c_str()); FAIL_RETURN_MSG(SKYRESULT_OK, buffer); } @@ -880,4 +880,4 @@ void SkyTextureManager::DestroyTextureObject(SkyTexture &texture) glDeleteTextures(texture.iDepth, texture.pSliceIDs); delete [] texture.pSliceIDs; }*/ -} \ No newline at end of file +} diff --git a/simgear/scene/sky/clouds3d/SkyTextureState.cpp b/simgear/scene/sky/clouds3d/SkyTextureState.cpp index 5495ce1c..e8ee29b2 100644 --- a/simgear/scene/sky/clouds3d/SkyTextureState.cpp +++ b/simgear/scene/sky/clouds3d/SkyTextureState.cpp @@ -268,4 +268,5 @@ SKYRESULT SkyTextureState::SetTextureParameter(unsigned int iTextureUnit, } return SKYRESULT_OK; -} \ No newline at end of file +} + diff --git a/simgear/scene/sky/clouds3d/SkyTextureState.hpp b/simgear/scene/sky/clouds3d/SkyTextureState.hpp index 1df2d39d..24312919 100644 --- a/simgear/scene/sky/clouds3d/SkyTextureState.hpp +++ b/simgear/scene/sky/clouds3d/SkyTextureState.hpp @@ -202,4 +202,4 @@ inline GLenum SkyTextureState::GetTextureParameter(unsigned int iTextureUnit, GL return GL_NONE; } -#endif //__SKYTEXTURESTATE_HPP__ \ No newline at end of file +#endif //__SKYTEXTURESTATE_HPP__ diff --git a/simgear/scene/sky/clouds3d/SkyUtil.hpp b/simgear/scene/sky/clouds3d/SkyUtil.hpp index 9e020f69..5467f6de 100644 --- a/simgear/scene/sky/clouds3d/SkyUtil.hpp +++ b/simgear/scene/sky/clouds3d/SkyUtil.hpp @@ -189,4 +189,4 @@ enum SKYRESULT_CODES #define FAIL_RETURN_MSGBOX(p,str) p #endif -#endif //__SKYUTIL_HPP__ \ No newline at end of file +#endif //__SKYUTIL_HPP__ diff --git a/simgear/scene/sky/clouds3d/camera.cpp b/simgear/scene/sky/clouds3d/camera.cpp index c5b89fa4..86078376 100644 --- a/simgear/scene/sky/clouds3d/camera.cpp +++ b/simgear/scene/sky/clouds3d/camera.cpp @@ -21,7 +21,7 @@ // $Id$ //============================================================================ #include "camera.hpp" -#include +#include //---------------------------------------------------------------------------- // CONSTRUCTOR: defines a default camera system defined as (45 DEG FOV)