Commit 31e34829 authored by Sean McBride's avatar Sean McBride

Fixed many readability-misleading-indentation warnings

I was surprised how many there were.  But no bugs at least, as best as I could tell.

Removed a few useless semi-colons that were nearby.
parent 144384d0
......@@ -803,8 +803,8 @@ vtkIdType vtkStringArray::LookupValue(const vtkStdString& value)
{
// Check whether we still have a value equivalent to what we're
// looking for.
if (value == *found)
{
if (value == *found)
{
// Check that the value in the original array hasn't changed.
vtkIdType index = this->Lookup->IndexArray->GetId(offset);
vtkStdString currentValue = this->GetValue(index);
......@@ -812,7 +812,7 @@ vtkIdType vtkStringArray::LookupValue(const vtkStdString& value)
{
return index;
}
}
}
else
{
break;
......
......@@ -96,8 +96,7 @@ int TestTriangle(int,char *[])
cerr << "Squared error tolerance: 0.00000001" << endl;
return EXIT_FAILURE;
}
else
if ( !inside && i > 16 )
else if ( !inside && i > 16 )
{
cerr << "ERROR: point #" << i << ", an inside-point, considered to be outside the triangle!!!" << endl;
cerr << "Squared error tolerance: 0.00000001" << endl;
......
......@@ -323,8 +323,7 @@ void vtkIncrementalOctreePointLocator::GenerateRepresentation
{
nodesList.push_back( pTempNode );
}
else
if ( !pTempNode->IsLeaf() )
else if ( !pTempNode->IsLeaf() )
{
for ( int i = 0; i < 8; i ++ )
{
......@@ -648,8 +647,7 @@ vtkIdType vtkIncrementalOctreePointLocator::FindClosestPoint
{
initialPt[0] = minBounds[0] + this->FudgeFactor;
}
else
if ( initialPt[0] >= maxBounds[0] )
else if ( initialPt[0] >= maxBounds[0] )
{
initialPt[0] = maxBounds[0] - this->FudgeFactor;
}
......@@ -658,8 +656,7 @@ vtkIdType vtkIncrementalOctreePointLocator::FindClosestPoint
{
initialPt[1] = minBounds[1] + this->FudgeFactor;
}
else
if ( initialPt[1] >= maxBounds[1] )
else if ( initialPt[1] >= maxBounds[1] )
{
initialPt[1] = maxBounds[1] - this->FudgeFactor;
}
......@@ -668,8 +665,7 @@ vtkIdType vtkIncrementalOctreePointLocator::FindClosestPoint
{
initialPt[2] = minBounds[2] + this->FudgeFactor;
}
else
if ( initialPt[2] >= maxBounds[2] )
else if ( initialPt[2] >= maxBounds[2] )
{
initialPt[2] = maxBounds[2] - this->FudgeFactor;
}
......@@ -741,14 +737,12 @@ void vtkIncrementalOctreePointLocator::FindPointsWithinSquaredRadius
outMinDst2 += tempValue0 * tempValue0;
maximDist2 += tempValue1 * tempValue1;
}
else
if ( tempValue1 < 0.0 )
else if ( tempValue1 < 0.0 )
{
outMinDst2 += tempValue1 * tempValue1;
maximDist2 += tempValue0 * tempValue0;
}
else
if ( tempValue1 > tempValue0 )
else if ( tempValue1 > tempValue0 )
{
maximDist2 += tempValue1 * tempValue1;
}
......@@ -997,9 +991,8 @@ void vtkIncrementalOctreePointLocator::FindClosestNPoints
}
}
}
else
if ( pThisNode->GetDistance2ToBoundary( x, this->OctreeRootNode, 1 )
< maxiDist2 )
else if ( pThisNode->GetDistance2ToBoundary( x, this->OctreeRootNode, 1 )
< maxiDist2 )
{
// This is a leaf node AND its data bounding box is close enough for us
// to process the points inside the node. Note that the success of the
......
......@@ -160,10 +160,10 @@ void vtkXMLDataElement::SetName(const char* _arg)
this->Name = cp1;
do { *cp1++ = *cp2++; } while ( --n );
}
else
{
else
{
this->Name = nullptr;
}
}
this->Modified();
}
......
......@@ -1149,13 +1149,13 @@ vtkStreamingDemandDrivenPipeline
{
input = this->GetInputData(0, 0);
}
if (input &&
input->GetInformation()->Has(vtkDataObject::DATA_TIME_STEP()))
{
if (input &&
input->GetInformation()->Has(vtkDataObject::DATA_TIME_STEP()))
{
dataInfo->CopyEntry(input->GetInformation(),
vtkDataObject::DATA_TIME_STEP(),
1);
}
}
// Does the update request have it? If yes, copy it. This
// should not normally happen.
else if (outInfo->Has(UPDATE_TIME_STEP()))
......
......@@ -303,15 +303,13 @@ int vtkSocket::SelectSocket(int socketdescriptor, unsigned long msec)
// time out
return 0;
}
else
if (res == vtkSocketErrorReturnMacro)
else if (res == vtkSocketErrorReturnMacro)
{
// error in the call
vtkSocketErrorMacro(vtkErrnoMacro, "Socket error in call to select.");
return -1;
}
else
if (!FD_ISSET(socketdescriptor, &rset))
else if (!FD_ISSET(socketdescriptor, &rset))
{
vtkErrorMacro("Socket error in select. Descriptor not selected.");
return -1;
......@@ -375,8 +373,7 @@ int vtkSocket::SelectSockets(const int* sockets_to_select, int size,
// time out
return 0;
}
else
if (res == vtkSocketErrorReturnMacro)
else if (res == vtkSocketErrorReturnMacro)
{
// error in the call
vtkSocketGenericErrorMacro("Socket error in call to select.");
......@@ -465,8 +462,7 @@ int vtkSocket::Connect(int socketdescriptor, const char* hostName, int port)
vtkErrnoMacro, "Socket error in call to getsockopt.");
return -1;
}
else
if (pendingErr)
else if (pendingErr)
{
vtkSocketErrorMacro(
pendingErr, "Socket error pending from call to connect.");
......@@ -474,8 +470,7 @@ int vtkSocket::Connect(int socketdescriptor, const char* hostName, int port)
}
}
}
else
if (iErr == vtkSocketErrorReturnMacro)
else if (iErr == vtkSocketErrorReturnMacro)
{
vtkSocketErrorMacro(
vtkErrnoMacro, "Socket error in call to connect.");
......
......@@ -308,10 +308,10 @@ int vtkTimerLog::GetNumberOfEvents()
{
return vtkTimerLog::MaxEntries;
}
else
{
else
{
return vtkTimerLog::NextEntry;
}
}
}
//----------------------------------------------------------------------------
......
......@@ -1126,10 +1126,10 @@ void vtkFieldDataToAttributeDataFilter::SetArrayName(vtkObject *self, char* &nam
name = new char[strlen(newName)+1];
strcpy(name,newName);
}
else
{
else
{
name = nullptr;
}
}
self->Modified();
}
......
......@@ -268,11 +268,11 @@ template<typename T> void vtkSPDF_MovePoints(vtkSPDF_InternalParams<T>& params)
maxDist = dist;
}
}//if can move point
else
{
newPtsCoords += 3;
}
++vertsPtr;
else
{
newPtsCoords += 3;
}
++vertsPtr;
}//for all points
}//for not converged or within iteration count
......
......@@ -150,11 +150,11 @@ int vtkExtractUnstructuredGrid::RequestData(
{
for(cellId=0; cellId < numCells; cellId++)
{
if ( this->CellClipping && (cellId < this->CellMinimum ||
cellId > this->CellMaximum) )
{
if ( this->CellClipping && (cellId < this->CellMinimum ||
cellId > this->CellMaximum) )
{
cellVis[cellId] = 0;
}
}
else
{
cell = input->GetCell(cellId);
......
......@@ -262,8 +262,7 @@ double vtkStreamTracer::ConvertToLength(
{
retVal = interval;
}
else
if ( unit == CELL_LENGTH_UNIT )
else if ( unit == CELL_LENGTH_UNIT )
{
retVal = interval * cellLength;
}
......
......@@ -3611,11 +3611,11 @@ void vtkBoxClipDataSet::ClipHexahedronInOut(vtkPoints *newPoints,
break; // some vertex could be on plane, so you need to test all vertex
}
}
if (outside == 0)
{
if (outside == 0)
{
// else it is possible intersection if other plane
newCellId = newcellArray->InsertNextCell(4,v_id);
}
}
else
{
newCellId = tets[1]->InsertNextCell(4,v_id);
......
......@@ -573,8 +573,7 @@ int vtkHyperStreamline::RequestData(
sNext->CellId = sPtr->CellId;
sNext->SubId = sPtr->SubId;
}
else
if ( evalResult == 0 )
else if ( evalResult == 0 )
{ //integration has passed out of cell
sNext->CellId = input->FindCell(xNext, cell, sPtr->CellId, tol2,
sNext->SubId, sNext->P, w);
......
......@@ -1443,8 +1443,7 @@ void vtkTableBasedClipperVolumeFromVolume::
{
id = centroidStart - 1 - ce.ptIds[k];
}
else
if ( ce.ptIds[k] >= numPrevPts )
else if ( ce.ptIds[k] >= numPrevPts )
{
id = numUsed + ( ce.ptIds[k] - numPrevPts );
}
......@@ -1842,8 +1841,7 @@ int vtkTableBasedClipDataSet::RequestData( vtkInformation * vtkNotUsed( request
this->InsideOut = !(this->InsideOut);
}
}
else
if ( gridType == VTK_POLY_DATA )
else if ( gridType == VTK_POLY_DATA )
{
this->ClipPolyData( cpyInput, clipAray, isoValue, outputUG );
if (clippedOutputUG)
......@@ -1854,8 +1852,7 @@ int vtkTableBasedClipDataSet::RequestData( vtkInformation * vtkNotUsed( request
this->InsideOut = !(this->InsideOut);
}
}
else
if ( gridType == VTK_RECTILINEAR_GRID )
else if ( gridType == VTK_RECTILINEAR_GRID )
{
this->ClipRectilinearGridData( cpyInput, clipAray,
isoValue, outputUG );
......@@ -1867,8 +1864,7 @@ int vtkTableBasedClipDataSet::RequestData( vtkInformation * vtkNotUsed( request
this->InsideOut = !(this->InsideOut);
}
}
else
if ( gridType == VTK_STRUCTURED_GRID )
else if ( gridType == VTK_STRUCTURED_GRID )
{
this->ClipStructuredGridData( cpyInput, clipAray,
isoValue, outputUG );
......@@ -1880,8 +1876,7 @@ int vtkTableBasedClipDataSet::RequestData( vtkInformation * vtkNotUsed( request
this->InsideOut = !(this->InsideOut);
}
}
else
if ( gridType == VTK_UNSTRUCTURED_GRID )
else if ( gridType == VTK_UNSTRUCTURED_GRID )
{
this->ClipUnstructuredGridData( cpyInput, clipAray,
isoValue, outputUG );
......@@ -2535,8 +2530,7 @@ void vtkTableBasedClipDataSet::ClipRectilinearGridData( vtkDataSet * inputGrd,
( theCellK + shiftLUT[2][ pntIndex ] ) * pzStride
);
}
else
if ( pntIndex >= EA && pntIndex <= EL )
else if ( pntIndex >= EA && pntIndex <= EL )
{
int pt1Index = vtkTableBasedClipperTriangulationTables::
HexVerticesFromEdges[ pntIndex - EA ][0];
......@@ -2592,8 +2586,7 @@ void vtkTableBasedClipDataSet::ClipRectilinearGridData( vtkDataSet * inputGrd,
// point-locator based detection of duplicate points.
shapeIds[p] = visItVFV->AddPoint( pntIndx1, pntIndx2, p1Weight );
}
else
if ( pntIndex >= N0 && pntIndex <= N3 )
else if ( pntIndex >= N0 && pntIndex <= N3 )
{
shapeIds[p] = intrpIds[ pntIndex - N0 ];
}
......@@ -2884,8 +2877,7 @@ void vtkTableBasedClipDataSet::ClipStructuredGridData( vtkDataSet * inputGrd,
( theCellK + shiftLUT[2][ pntIndex ] ) * pzStride
);
}
else
if ( pntIndex >= EA && pntIndex <= EL )
else if ( pntIndex >= EA && pntIndex <= EL )
{
int pt1Index = vtkTableBasedClipperTriangulationTables::
HexVerticesFromEdges[ pntIndex - EA ][0];
......@@ -2916,8 +2908,7 @@ void vtkTableBasedClipDataSet::ClipStructuredGridData( vtkDataSet * inputGrd,
shapeIds[p] = visItVFV->AddPoint( pntIndx1, pntIndx2, p1Weight );
}
else
if ( pntIndex >= N0 && pntIndex <= N3 )
else if ( pntIndex >= N0 && pntIndex <= N3 )
{
shapeIds[p] = intrpIds[ pntIndex - N0 ];
}
......
......@@ -222,11 +222,11 @@ int vtkGeometryFilter::RequestData(
{
for(cellId=0; cellId < numCells; cellId++)
{
if ( this->CellClipping && (cellId < this->CellMinimum ||
cellId > this->CellMaximum) )
{
cellVis[cellId] = 0;
}
if ( this->CellClipping && (cellId < this->CellMinimum ||
cellId > this->CellMaximum) )
{
cellVis[cellId] = 0;
}
else
{
input->GetCell(cellId,cell);
......@@ -553,11 +553,11 @@ void vtkGeometryFilter::PolyDataExecute(vtkDataSet *dataSetInput,
visible = 1;
if ( !allVisible )
{
if ( this->CellClipping && (cellId < this->CellMinimum ||
cellId > this->CellMaximum) )
{
if ( this->CellClipping && (cellId < this->CellMinimum ||
cellId > this->CellMaximum) )
{
visible = 0;
}
}
else
{
for (i=0; i < npts; i++)
......
......@@ -286,7 +286,7 @@ void vtkCellSizeFilter::ExecuteBlock(vtkDataSet* input, vtkDataSet* output, doub
}
break;
case 1:
if ( this->ComputeLength )
if ( this->ComputeLength )
{
cell->Triangulate(1, cellPtIds, cellPoints);
value = this->IntegrateGeneral1DCell(input, cellPtIds);
......@@ -298,7 +298,7 @@ void vtkCellSizeFilter::ExecuteBlock(vtkDataSet* input, vtkDataSet* output, doub
}
break;
case 2:
if ( this->ComputeArea )
if ( this->ComputeArea )
{
cell->Triangulate(1, cellPtIds, cellPoints);
value = this->IntegrateGeneral2DCell(inputPS, cellPtIds);
......
......@@ -239,14 +239,14 @@ void vtkAMREnzoReader::SetFileName( const char* fileName )
this->Internal->HierarchyFileName = tempName;
this->Internal->BoundaryFileName = this->Internal->MajorFileName+bExtName;
}
else if( tempName.length() > bExtName.length() &&
tempName.substr( tempName.length() - bExtName.length() )==bExtName )
{
this->Internal->MajorFileName =
tempName.substr( 0, tempName.length() - bExtName.length() );
this->Internal->BoundaryFileName = tempName;
this->Internal->HierarchyFileName = this->Internal->MajorFileName+hExtName;
}
else if( tempName.length() > bExtName.length() &&
tempName.substr( tempName.length() - bExtName.length() )==bExtName )
{
this->Internal->MajorFileName =
tempName.substr( 0, tempName.length() - bExtName.length() );
this->Internal->BoundaryFileName = tempName;
this->Internal->HierarchyFileName = this->Internal->MajorFileName+hExtName;
}
else
{
vtkErrorMacro( "Enzo file has invalid extension!");
......
......@@ -542,8 +542,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_DOUBLE ) )
else if ( H5Tequal( dataType, H5T_NATIVE_DOUBLE ) )
{
this->DataArray = vtkDoubleArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -552,8 +551,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_INT ) )
else if ( H5Tequal( dataType, H5T_NATIVE_INT ) )
{
this->DataArray = vtkIntArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -562,8 +560,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_UINT ) )
else if ( H5Tequal( dataType, H5T_NATIVE_UINT ) )
{
this->DataArray = vtkUnsignedIntArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -572,8 +569,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_SHORT ) )
else if ( H5Tequal( dataType, H5T_NATIVE_SHORT ) )
{
this->DataArray = vtkShortArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -582,8 +578,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_USHORT ) )
else if ( H5Tequal( dataType, H5T_NATIVE_USHORT ) )
{
this->DataArray = vtkUnsignedShortArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -592,8 +587,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_UCHAR ) )
else if ( H5Tequal( dataType, H5T_NATIVE_UCHAR ) )
{
this->DataArray = vtkUnsignedCharArray::New();
......@@ -603,8 +597,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_LONG ) )
else if ( H5Tequal( dataType, H5T_NATIVE_LONG ) )
{
this->DataArray = vtkLongArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -613,8 +606,7 @@ int vtkEnzoReaderInternal::LoadAttribute( const char *attribute, int blockIdx )
H5Dread( attrIndx, dataType, H5S_ALL, H5S_ALL, H5P_DEFAULT, arrayPtr );
arrayPtr = nullptr;
}
else
if ( H5Tequal( dataType, H5T_NATIVE_LLONG ) )
else if ( H5Tequal( dataType, H5T_NATIVE_LLONG ) )
{
this->DataArray = vtkLongLongArray::New();
this->DataArray->SetNumberOfTuples( numTupls );
......@@ -841,8 +833,7 @@ void vtkEnzoReaderInternal::ReadBlockStructures()
this->Blocks[parent].ChildrenIds.push_back( tmpBlk.Index );
this->NumberOfBlocks = static_cast < int > ( this->Blocks.size() ) - 1;
}
else
if ( theStr == "Pointer:" )
else if ( theStr == "Pointer:" )
{
theStr = "";
int tmpInt;
......@@ -872,8 +863,7 @@ void vtkEnzoReaderInternal::ReadBlockStructures()
stream >> tmpInt;
}
}
else
if ( theStr == "Time" )
else if ( theStr == "Time" )
{
stream >> theStr; // '='
stream >> this->DataTime;
......@@ -914,14 +904,12 @@ void vtkEnzoReaderInternal::ReadGeneralParameters()
stream >> tmpStr; // '='
stream >> this->CycleIndex;
}
else
if ( tmpStr == "InitialTime" )
else if ( tmpStr == "InitialTime" )
{
stream >> tmpStr; // '='
stream >> this->DataTime;
}
else
if ( tmpStr == "TopGridRank" )
else if ( tmpStr == "TopGridRank" )
{
stream >> tmpStr; // '='
stream >> this->NumberOfDimensions;
......@@ -1061,10 +1049,9 @@ void vtkEnzoReaderInternal::GetAttributeNames()
this->ParticleAttributeNames.push_back( tempName );
}
}
else
if ( ( strlen( tempName ) > 16 ) &&
( strncmp( tempName, "tracer_particles", 16 ) == 0 )
)
else if ( ( strlen( tempName ) > 16 ) &&
( strncmp( tempName, "tracer_particles", 16 ) == 0 )
)
{
// it's a tracer_particle variable and skip over coordinate arrays
if ( strncmp( tempName, "tracer_particle_position_", 25 ) != 0 )
......
......@@ -508,23 +508,19 @@ void vtkFlashReaderInternal::ReadIntegerScalars( hid_t fileIndx )
{
this->SimulationParameters.NumberOfXDivisions = is[i].Value;
}
else
if ( strncmp( is[i].Name, "nyb", 3 ) == 0 )
else if ( strncmp( is[i].Name, "nyb", 3 ) == 0 )
{
this->SimulationParameters.NumberOfYDivisions = is[i].Value;
}
else
if ( strncmp( is[i].Name, "nzb", 3 ) == 0 )
else if ( strncmp( is[i].Name, "nzb", 3 ) == 0 )
{
this->SimulationParameters.NumberOfZDivisions = is[i].Value;
}
else
if ( strncmp( is[i].Name, "globalnumblocks", 15 ) == 0 )
else if ( strncmp( is[i].Name, "globalnumblocks", 15 ) == 0 )
{
this->SimulationParameters.NumberOfBlocks = is[i].Value;
}
else
if ( strncmp( is[i].Name, "nstep", 5 ) == 0 )
else if ( strncmp( is[i].Name, "nstep", 5 ) == 0 )
{
this->SimulationParameters.NumberOfTimeSteps = is[i].Value;
}
......@@ -940,8 +936,7 @@ void vtkFlashReaderInternal::ReadBlockBounds()
delete[] bbox_array;
bbox_array = nullptr;
}
else
if ( this->FileFormatVersion == FLASH_READER_FLASH3_FFV9 )
else if ( this->FileFormatVersion == FLASH_READER_FLASH3_FFV9 )
{
if ( static_cast<int> ( bbox_ndims ) != 3 ||
static_cast<int> ( bbox_dims[0] ) != this->NumberOfBlocks ||
......@@ -1058,15 +1053,13 @@ void vtkFlashReaderInternal::ReadBlockCenters()
this->Blocks[b].Center[1] = 0.0;
this->Blocks[b].Center[2] = 0.0;
}
else
if ( this->NumberOfDimensions == 2 )
else if ( this->NumberOfDimensions == 2 )
{
this->Blocks[b].Center[0] = coords[0];
this->Blocks[b].Center[1] = coords[1];
this->Blocks[b].Center[2] = 0.0;
}
else
if ( this->NumberOfDimensions == 3 )
else if ( this->NumberOfDimensions == 3 )
{
this->Blocks[b].Center[0] = coords[0];
this->Blocks[b].Center[1] = coords[1];
......@@ -1079,8 +1072,7 @@ void vtkFlashReaderInternal::ReadBlockCenters()
delete [] coordinates_array;
coordinates_array = nullptr;
}
else
if ( this->FileFormatVersion == FLASH_READER_FLASH3_FFV9 )
else if ( this->FileFormatVersion == FLASH_READER_FLASH3_FFV9 )
{
if ( static_cast<int> ( coordinates_ndims ) != 2 ||
static_cast<int> ( coordinates_dims[0] ) != this->NumberOfBlocks ||
......@@ -1412,8 +1404,7 @@ void vtkFlashReaderInternal::ReadParticleAttributes()
this->ParticleAttributeNames.push_back( member_name );
this->ParticleAttributeNamesToIds[ nice_name ] = index;
}
else
if ( H5Tequal( member_type, H5T_NATIVE_INT ) > 0 )
else if ( H5Tequal( member_type, H5T_NATIVE_INT ) > 0 )
{
this->ParticleAttributeTypes.push_back( H5T_NATIVE_INT );
this->ParticleAttributeNames.push_back( member_name );
......
......@@ -1227,8 +1227,7 @@ int vtkEnSightReader::ReadCaseFileTime(char* line)
{
this->MinimumTimeValue = timeStep;
}
else
if ( timeStep > this->MaximumTimeValue )
else if ( timeStep > this->MaximumTimeValue )
{
this->MaximumTimeValue = timeStep;
}
......
......@@ -1298,8 +1298,8 @@ void vtkRIBExporter::WriteTexture (vtkTexture *aTexture)
// renderman and bmrt seem to require r,g,b and alpha in all their
// texture maps. So if our tmap doesn't have the right components
// we add them
if (bpp == 1) // needs intensity intensity and alpha
{
if (bpp == 1) // needs intensity intensity and alpha
{
iac1 = vtkImageAppendComponents::New();
iac2 = vtkImageAppendComponents::New();
icp = vtkImageConstantPad::New();
......@@ -1313,7 +1313,7 @@ void vtkRIBExporter::WriteTexture (vtkTexture *aTexture)
icp->SetOutputNumberOfScalarComponents(4);
aWriter->SetInputConnection(icp->GetOutputPort());
}
}
else if (bpp == 2) // needs intensity intensity
{
iec = vtkImageExtractComponents::New();
......@@ -1344,12 +1344,12 @@ void vtkRIBExporter::WriteTexture (vtkTexture *aTexture)
aWriter->SetFileName (this->GetTIFFName (aTexture));
aWriter->Write ();
if (bpp == 1)
{
if (bpp == 1)
{
iac1->Delete ();
iac2->Delete ();
icp->Delete ();
}
}
else if (bpp == 2)
{
iec->Delete ();
......@@ -1394,12 +1394,12 @@ void vtkRIBExporter::ModifyArrayName(char *newname, const char* name)
int cc = 0;
for ( cc =0; name[cc]; cc++ )
{
if ( (name[cc] >= 'A' && name[cc] <= 'Z') ||
(name[cc] >= '0' && name[cc] <= '9') ||
(name[cc] >= 'a' && name[cc] <= 'z') )