Fixed warnings

This commit is contained in:
Robert Osfield
2009-01-07 11:24:47 +00:00
parent 98bd058317
commit 418dc34776
43 changed files with 67 additions and 65 deletions

View File

@@ -238,6 +238,11 @@ struct IdHelper
flt::FltExportVisitor& v_;
const std::string id_;
DataOutputStream* dos_;
protected:
IdHelper& operator = (const IdHelper&) { return *this; }
};
@@ -262,6 +267,10 @@ struct SubfaceHelper
flt::FltExportVisitor& v_;
bool _polygonOffsetOn;
protected:
SubfaceHelper& operator = (const SubfaceHelper&) { return *this; }
};
}

View File

@@ -66,6 +66,10 @@ class LightSourcePaletteManager
ExportOptions& _fltOpt;
protected:
LightSourcePaletteManager& operator = (const LightSourcePaletteManager&) { return *this; }
};

View File

@@ -64,6 +64,10 @@ class MaterialPaletteManager
MaterialPalette _materialPalette;
ExportOptions& _fltOpt;
protected:
MaterialPaletteManager& operator = (const MaterialPaletteManager&) { return *this; }
};

View File

@@ -46,6 +46,8 @@ public:
protected:
TexturePaletteManager& operator = (const TexturePaletteManager&) { return *this; }
int _currIndex;
typedef std::map< const osg::Texture2D*, int > TextureIndexMap;
@@ -54,6 +56,7 @@ protected:
const FltExportVisitor& _nv;
const ExportOptions& _fltOpt;
};

View File

@@ -1187,9 +1187,12 @@ class ReaderGEO
return;
}
Group *makeTextGeode(const georecord *gr)
{ // in geo text is defined with a matrix included in the geo.geode (gr is this geo.geode)
{
// in geo text is defined with a matrix included in the geo.geode (gr is this geo.geode)
// - we need to create this tree to render text
#if 1
return NULL; // temporary disable april 2003
#else
Group *nug=new Group;
const geoField *gfd=gr->getField(GEO_DB_RENDERGROUP_MAT);
// may be used in future const unsigned int imat=gfd ? gfd->getInt():0;
@@ -1202,7 +1205,9 @@ class ReaderGEO
nug=NULL;
}
return nug;
#endif
}
Group *makeLightPointGeodes(const georecord *gr) {
const geoField *gfd=gr->getField(GEO_DB_RENDERGROUP_MAT);
Group *nug=new Group;

View File

@@ -260,8 +260,8 @@ public:
success = HDRWriter::writeHeader(source.get(),fout);
if(!success)
{
return WriteResult::ERROR_IN_WRITING_FILE; // early out
source = 0; // delete the temporary image
return WriteResult::ERROR_IN_WRITING_FILE; // early out
}
success = HDRWriter::writeRLE(source.get(), fout);

View File

@@ -51,6 +51,9 @@ namespace iff
inline std::ostream &os() { return os_; }
private:
GenericParser& operator = (const GenericParser&) { return *this; }
Chunk_list chunks_;
std::ostream &os_;
};

View File

@@ -34,6 +34,8 @@ namespace lwo2
protected:
virtual iff::Chunk *parse_chunk_data(const std::string &tag, const std::string &context, Iter it, Iter end);
iff::Chunk *parse_subchunk(Iter &it, const std::string &context);
Parser& operator = (const Parser&) { return *this; }
};

View File

@@ -42,7 +42,8 @@ MDLReader::~MDLReader()
std::string MDLReader::getToken(std::string str, const char * delim,
size_t & index)
{
size_t start, end;
size_t start;
size_t end = std::string::npos;
std::string token;
// Look for the first non-occurrence of the delimiters

View File

@@ -136,6 +136,8 @@ class OBJWriterNodeVisitor: public osg::NodeVisitor {
private:
OBJWriterNodeVisitor& operator = (const OBJWriterNodeVisitor&) { return *this; }
void processGeometry(osg::Geometry* geo, osg::Matrix& m);
void processArray(const std::string& key, osg::Array* array, const osg::Matrix& m = osg::Matrix::identity(), bool isNormal = false);

View File

@@ -955,26 +955,6 @@ void* layerRead::Parse(trpgToken /*tok*/,trpgReadBuffer &buf)
_parse->setCurrentNode(osgGroup.get());
_parse->getCurrTop()->addChild(osgGroup.get());
return (void*)1;
#if 0
osg::Group* osgGroup = new osg::Group;
_parse->setCurrentNode(osgGroup);
_parse->getCurrTop()->addChild(osgGroup);
_parse->addLayer(osgGroup);
return (void*)1;
#else
if (_parse->underLayerSubgraph()) return (void*)1;
osg::ref_ptr<GeodeGroup> layer = new GeodeGroup;
_parse->setLayerGeode(layer->getGeode());
_parse->setUnderLayerSubgraph(true);
_parse->setCurrentNode(layer.get());
_parse->getCurrTop()->addChild(layer.get());
return (void *)1;
#endif
}
//----------------------------------------------------------------------------

View File

@@ -308,9 +308,6 @@ bool TileMapper::canParentBeTraversed(const TileIdentifier& tid) const
return (!parentHasSouthNeighour && !parentHasWestNeighour);
}
}
// we shouldn't get here...
return true;
}
void TileMapper::checkValidityOfAllVisibleTiles()