mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-06 22:15:37 +00:00
Remove unused code
This commit is contained in:
parent
b66c2abfe3
commit
5044816770
4 changed files with 2 additions and 15 deletions
|
@ -186,8 +186,6 @@ osg::ref_ptr<osg::Node> ChunkManager::createChunk(float chunkSize, const osg::Ve
|
||||||
|
|
||||||
geometry->addPrimitiveSet(mBufferCache.getIndexBuffer(numVerts, lodFlags));
|
geometry->addPrimitiveSet(mBufferCache.getIndexBuffer(numVerts, lodFlags));
|
||||||
|
|
||||||
geometry->getBound();
|
|
||||||
|
|
||||||
bool useCompositeMap = chunkSize >= 1.f;
|
bool useCompositeMap = chunkSize >= 1.f;
|
||||||
unsigned int numUvSets = useCompositeMap ? 1 : 2;
|
unsigned int numUvSets = useCompositeMap ? 1 : 2;
|
||||||
|
|
||||||
|
|
|
@ -59,7 +59,7 @@ namespace Terrain
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<osg::ref_ptr<osg::StateSet> > createPasses(bool useShaders, bool forcePerPixelLighting, bool clampLighting, Shader::ShaderManager* shaderManager, const std::vector<TextureLayer> &layers,
|
std::vector<osg::ref_ptr<osg::StateSet> > createPasses(bool useShaders, bool forcePerPixelLighting, bool clampLighting, Shader::ShaderManager* shaderManager, const std::vector<TextureLayer> &layers,
|
||||||
const std::vector<osg::ref_ptr<osg::Texture2D> > &blendmaps, int blendmapScale, float layerTileSize, bool renderCompositeMap)
|
const std::vector<osg::ref_ptr<osg::Texture2D> > &blendmaps, int blendmapScale, float layerTileSize)
|
||||||
{
|
{
|
||||||
std::vector<osg::ref_ptr<osg::StateSet> > passes;
|
std::vector<osg::ref_ptr<osg::StateSet> > passes;
|
||||||
|
|
||||||
|
@ -104,8 +104,6 @@ namespace Terrain
|
||||||
stateset->addUniform(new osg::Uniform("normalMap", texunit));
|
stateset->addUniform(new osg::Uniform("normalMap", texunit));
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: fix shader for renderCompositeMap=True
|
|
||||||
|
|
||||||
Shader::ShaderManager::DefineMap defineMap;
|
Shader::ShaderManager::DefineMap defineMap;
|
||||||
defineMap["forcePPL"] = forcePerPixelLighting ? "1" : "0";
|
defineMap["forcePPL"] = forcePerPixelLighting ? "1" : "0";
|
||||||
defineMap["clamp"] = clampLighting ? "1" : "0";
|
defineMap["clamp"] = clampLighting ? "1" : "0";
|
||||||
|
|
|
@ -28,7 +28,7 @@ namespace Terrain
|
||||||
|
|
||||||
std::vector<osg::ref_ptr<osg::StateSet> > createPasses(bool useShaders, bool forcePerPixelLighting, bool clampLighting, Shader::ShaderManager* shaderManager,
|
std::vector<osg::ref_ptr<osg::StateSet> > createPasses(bool useShaders, bool forcePerPixelLighting, bool clampLighting, Shader::ShaderManager* shaderManager,
|
||||||
const std::vector<TextureLayer>& layers,
|
const std::vector<TextureLayer>& layers,
|
||||||
const std::vector<osg::ref_ptr<osg::Texture2D> >& blendmaps, int blendmapScale, float layerTileSize, bool renderCompositeMap=false);
|
const std::vector<osg::ref_ptr<osg::Texture2D> >& blendmaps, int blendmapScale, float layerTileSize);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -99,15 +99,6 @@ void QuadTreeNode::traverse(osg::NodeVisitor &nv)
|
||||||
if (!hasValidBounds())
|
if (!hasValidBounds())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (nv.getVisitorType() == osg::NodeVisitor::CULL_VISITOR)
|
|
||||||
{
|
|
||||||
osgUtil::CullVisitor* cv = static_cast<osgUtil::CullVisitor*>(&nv);
|
|
||||||
|
|
||||||
// do another culling test against bounding box as its much more accurate than the bounding sphere.
|
|
||||||
if (cv->isCulled(mBoundingBox))
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((mLodCallback && mLodCallback->isSufficientDetail(this, nv.getEyePoint())) || !getNumChildren())
|
if ((mLodCallback && mLodCallback->isSufficientDetail(this, nv.getEyePoint())) || !getNumChildren())
|
||||||
getView(nv)->add(this, true);
|
getView(nv)->add(this, true);
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue