Merge pull request #2639 from escherstair/fix-codacy-issues
Fix codacy issues - part #3pull/2644/head
commit
3801b84ef9
|
@ -647,7 +647,7 @@ void X3DImporter::XML_ReadNode_GetAttrVal_AsArrCol4f(const int pAttrIdx, std::ve
|
|||
|
||||
XML_ReadNode_GetAttrVal_AsListCol4f(pAttrIdx, tlist);// read as list
|
||||
// and copy to array
|
||||
if(tlist.size() > 0)
|
||||
if(!tlist.empty())
|
||||
{
|
||||
pValue.reserve(tlist.size());
|
||||
for ( std::list<aiColor4D>::iterator it = tlist.begin(); it != tlist.end(); ++it )
|
||||
|
|
|
@ -554,7 +554,7 @@ void X3DImporter::Postprocess_BuildMesh(const CX3DImporter_NodeElement& pNodeEle
|
|||
}
|
||||
|
||||
// copy additional information from children
|
||||
for(std::list<CX3DImporter_NodeElement*>::iterator ch_it = tnemesh.Child.begin(); ch_it != tnemesh.Child.end(); ch_it++)
|
||||
for(std::list<CX3DImporter_NodeElement*>::iterator ch_it = tnemesh.Child.begin(); ch_it != tnemesh.Child.end(); ++ch_it)
|
||||
{
|
||||
ai_assert(*pMesh);
|
||||
if((*ch_it)->Type == CX3DImporter_NodeElement::ENET_Color)
|
||||
|
|
|
@ -295,7 +295,7 @@ void X3DImporter::ParseNode_Rendering_IndexedTriangleFanSet()
|
|||
ne_alias.CoordIndex.clear();
|
||||
int counter = 0;
|
||||
int32_t idx[3];
|
||||
for(std::vector<int32_t>::const_iterator idx_it = index.begin(); idx_it != index.end(); idx_it++)
|
||||
for(std::vector<int32_t>::const_iterator idx_it = index.begin(); idx_it != index.end(); ++idx_it)
|
||||
{
|
||||
idx[2] = *idx_it;
|
||||
if (idx[2] < 0)
|
||||
|
@ -617,7 +617,7 @@ void X3DImporter::ParseNode_Rendering_LineSet()
|
|||
size_t coord_num = 0;
|
||||
|
||||
ne_alias.CoordIndex.clear();
|
||||
for(std::vector<int32_t>::const_iterator vc_it = ne_alias.VertexCount.begin(); vc_it != ne_alias.VertexCount.end(); vc_it++)
|
||||
for(std::vector<int32_t>::const_iterator vc_it = ne_alias.VertexCount.begin(); vc_it != ne_alias.VertexCount.end(); ++vc_it)
|
||||
{
|
||||
if(*vc_it < 2) throw DeadlyImportError("LineSet. vertexCount shall be greater than or equal to two.");
|
||||
|
||||
|
|
Loading…
Reference in New Issue