Fixed shadows warnings
This commit is contained in:
@@ -66,18 +66,18 @@ void addDrawableAndReverseWindingOrder( osg::Geode* geode )
|
||||
// Replace double sided polygons by duplicating the drawables and inverting the normals.
|
||||
std::vector<osg::Geometry*> new_drawables;
|
||||
|
||||
for (size_t i=0; i<geode->getNumDrawables(); ++i)
|
||||
for (size_t di=0; di<geode->getNumDrawables(); ++di)
|
||||
{
|
||||
const osg::Geometry* geometry = dynamic_cast<const osg::Geometry*>(geode->getDrawable(i));
|
||||
const osg::Geometry* geometry = dynamic_cast<const osg::Geometry*>(geode->getDrawable(di));
|
||||
if(geometry)
|
||||
{
|
||||
osg::Geometry* geom = new osg::Geometry(*geometry
|
||||
, osg::CopyOp::DEEP_COPY_ARRAYS | osg::CopyOp::DEEP_COPY_PRIMITIVES);
|
||||
new_drawables.push_back(geom);
|
||||
|
||||
for( size_t i = 0; i < geom->getNumPrimitiveSets( ); ++i )
|
||||
for( size_t pi = 0; pi < geom->getNumPrimitiveSets( ); ++pi )
|
||||
{
|
||||
osg::DrawArrays* drawarray = dynamic_cast<osg::DrawArrays*>( geom->getPrimitiveSet( i ) );
|
||||
osg::DrawArrays* drawarray = dynamic_cast<osg::DrawArrays*>( geom->getPrimitiveSet( pi ) );
|
||||
if( drawarray )
|
||||
{
|
||||
GLint first = drawarray->getFirst();
|
||||
|
||||
@@ -688,13 +688,13 @@ FltExportVisitor::writeLightPoint( const osgSim::LightPointNode* lpn )
|
||||
float32 horizLobe( 360.f );
|
||||
float32 vertLobe( 360.f );
|
||||
float32 lobeRoll( 0.f );
|
||||
const osgSim::DirectionalSector* ds = dynamic_cast< osgSim::DirectionalSector* >( lp0._sector.get() );
|
||||
if (ds)
|
||||
const osgSim::DirectionalSector* dirSector = dynamic_cast< osgSim::DirectionalSector* >( lp0._sector.get() );
|
||||
if (dirSector)
|
||||
{
|
||||
directionality = UNIDIRECTIONAL;
|
||||
horizLobe = osg::RadiansToDegrees( ds->getHorizLobeAngle() );
|
||||
vertLobe = osg::RadiansToDegrees( ds->getVertLobeAngle() );
|
||||
lobeRoll = osg::RadiansToDegrees( ds->getLobeRollAngle() );
|
||||
horizLobe = osg::RadiansToDegrees( dirSector->getHorizLobeAngle() );
|
||||
vertLobe = osg::RadiansToDegrees( dirSector->getVertLobeAngle() );
|
||||
lobeRoll = osg::RadiansToDegrees( dirSector->getLobeRollAngle() );
|
||||
}
|
||||
|
||||
{
|
||||
|
||||
@@ -3709,8 +3709,8 @@ int unzReadCurrentFile (unzFile file, voidp buf, unsigned len, bool *reached_eo
|
||||
pfile_in_zip_read_info->stream.avail_in = (uInt)uReadThis;
|
||||
//
|
||||
if (pfile_in_zip_read_info->encrypted)
|
||||
{ char *buf = (char*)pfile_in_zip_read_info->stream.next_in;
|
||||
for (unsigned int i=0; i<uReadThis; i++) buf[i]=zdecode(pfile_in_zip_read_info->keys,buf[i]);
|
||||
{ char *dbuf = (char*)pfile_in_zip_read_info->stream.next_in;
|
||||
for (unsigned int i=0; i<uReadThis; i++) dbuf[i]=zdecode(pfile_in_zip_read_info->keys,dbuf[i]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user