From 3ea58bf8dbbe067c1aec9ef394518960d59c16b9 Mon Sep 17 00:00:00 2001 From: torsten Date: Thu, 20 Aug 2009 11:53:58 +0000 Subject: [PATCH] warning fixes --- simgear/scene/sky/CloudShaderGeometry.cxx | 2 +- simgear/scene/sky/newcloud.cxx | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/simgear/scene/sky/CloudShaderGeometry.cxx b/simgear/scene/sky/CloudShaderGeometry.cxx index 9acc3f30..53e1b3d4 100755 --- a/simgear/scene/sky/CloudShaderGeometry.cxx +++ b/simgear/scene/sky/CloudShaderGeometry.cxx @@ -58,7 +58,7 @@ void CloudShaderGeometry::drawImplementation(RenderInfo& renderInfo) const if (!sortData.spriteIdx) sortData.spriteIdx = new SortData::SortItemList; if (sortData.spriteIdx->size() < _cloudsprites.size()) { - for (int i = sortData.spriteIdx->size(); i < _cloudsprites.size(); ++i) + for (unsigned i = sortData.spriteIdx->size(); i < (unsigned)_cloudsprites.size(); ++i) sortData.spriteIdx->push_back(SortData::SortItem(i, 0.0f)); sortData.frameSorted = frameNumber - (sortData.skip_limit + 1); } diff --git a/simgear/scene/sky/newcloud.cxx b/simgear/scene/sky/newcloud.cxx index efdf0c55..1c1b0d24 100644 --- a/simgear/scene/sky/newcloud.cxx +++ b/simgear/scene/sky/newcloud.cxx @@ -278,10 +278,12 @@ osg::Geometry* SGNewCloud::createOrthQuad(float w, float h, int varieties_x, int return geom; } +#if 0 // return a random number between -n/2 and n/2, tending to 0 static float Rnd(float n) { return n * (-0.5f + (sg_random() + sg_random()) / 2.0f); } +#endif osg::ref_ptr SGNewCloud::genCloud() { -- 2.39.5