From: Pawel Date: Fri, 13 Apr 2012 11:38:52 +0000 (+0200) Subject: 0023021: MeshVS_DataSource::GetNormalsByElement returns Standard_False and gives... X-Git-Tag: V6_5_4_beta1~177 X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=commitdiff_plain;h=c1338f4f6490604b555797aa74245894200d1038;hp=a7aa1465388b7670b71e0f3dcd9bd317bfebd020 0023021: MeshVS_DataSource::GetNormalsByElement returns Standard_False and gives no result even when all normals are OK If all normals are correctly computed using GetNodeNormal the variable 'res' is never set to Standard_True and the normals are not passed to the variable 'Normals' that is supposed to hold the result of the computation. --- diff --git a/src/MeshVS/MeshVS_DataSource.cxx b/src/MeshVS/MeshVS_DataSource.cxx index 020cb794e9..6f6b583606 100755 --- a/src/MeshVS/MeshVS_DataSource.cxx +++ b/src/MeshVS/MeshVS_DataSource.cxx @@ -206,10 +206,10 @@ Standard_Boolean MeshVS_DataSource::GetNormalsByElement(const Standard_Integer I } // switch ( Type ) } // if ( !allNormals ) - if ( res ) + if ( res || allNormals ) Normals = aNormals; - return res; + return ( res || allNormals ); } //================================================================