mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-24 03:10:33 +05:00
#18963 Minimize compiler warnings (finish)
This commit is contained in:
parent
2f4749af53
commit
fba6d9eef3
@ -352,10 +352,10 @@ namespace MED
|
||||
TGaussInfo::TLess
|
||||
::operator()(const TGaussInfo& theLeft, const TGaussInfo& theRight) const
|
||||
{
|
||||
if(!&theLeft) // todo: address of reference can be assumed always non-null by compiler
|
||||
if(!&theLeft) // address of reference can be assumed always non-null by compiler - OK
|
||||
return true;
|
||||
|
||||
if(!&theRight) // todo: address of reference can be assumed always non-null by compiler
|
||||
if(!&theRight) //address of reference can be assumed always non-null by compiler - OK
|
||||
return false;
|
||||
|
||||
if(theLeft.myGeom != theRight.myGeom)
|
||||
|
@ -3857,9 +3857,9 @@ void SMESH_MeshEditor::Smooth (TIDSortedElemSet & theElems,
|
||||
}
|
||||
else {
|
||||
if ( isUPeriodic )
|
||||
newUV.SetX( ElCLib::InPeriod( newUV.X(), u1, u2 )); // todo: u may be used unitialized
|
||||
newUV.SetX( ElCLib::InPeriod( newUV.X(), u1, u2 ));
|
||||
if ( isVPeriodic )
|
||||
newUV.SetY( ElCLib::InPeriod( newUV.Y(), v1, v2 )); // todo: v may be used unitialized
|
||||
newUV.SetY( ElCLib::InPeriod( newUV.Y(), v1, v2 ));
|
||||
// check new UV
|
||||
// if ( posType != SMDS_TOP_3DSPACE )
|
||||
// dist2 = pNode.SquareDistance( surface->Value( newUV.X(), newUV.Y() ));
|
||||
|
@ -4132,30 +4132,30 @@ namespace { // Structures used by FixQuadraticElements()
|
||||
*/
|
||||
//================================================================================
|
||||
|
||||
bool QFace::IsSpoiled(const QLink* bentLink ) const // todo: unused
|
||||
{
|
||||
// code is valid for convex faces only
|
||||
gp_XYZ gc(0,0,0);
|
||||
for ( TIDSortedNodeSet::const_iterator n = begin(); n != end(); ++n )
|
||||
gc += XYZ( *n ) / double( size() );
|
||||
for ( size_t i = 0; i < _sides.size(); ++i )
|
||||
{
|
||||
if ( _sides[i] == bentLink ) continue;
|
||||
gp_Vec linkNorm = _normal ^ gp_Vec( XYZ(_sides[i]->node1()), XYZ(_sides[i]->node2()));
|
||||
gp_Vec vecOut( gc, _sides[i]->MiddlePnt() );
|
||||
if ( linkNorm * vecOut < 0 )
|
||||
linkNorm.Reverse();
|
||||
double mag2 = linkNorm.SquareMagnitude();
|
||||
if ( mag2 > numeric_limits<double>::min() )
|
||||
linkNorm /= sqrt( mag2 );
|
||||
gp_Vec vecBent ( _sides[i]->MiddlePnt(), bentLink->MediumPnt());
|
||||
gp_Vec vecStraight( _sides[i]->MiddlePnt(), bentLink->MiddlePnt());
|
||||
if ( vecBent * linkNorm > -0.1*vecStraight.Magnitude() )
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
// bool QFace::IsSpoiled(const QLink* bentLink ) const
|
||||
// {
|
||||
// // code is valid for convex faces only
|
||||
// gp_XYZ gc(0,0,0);
|
||||
// for ( TIDSortedNodeSet::const_iterator n = begin(); n != end(); ++n )
|
||||
// gc += XYZ( *n ) / double( size() );
|
||||
// for ( size_t i = 0; i < _sides.size(); ++i )
|
||||
// {
|
||||
// if ( _sides[i] == bentLink ) continue;
|
||||
// gp_Vec linkNorm = _normal ^ gp_Vec( XYZ(_sides[i]->node1()), XYZ(_sides[i]->node2()));
|
||||
// gp_Vec vecOut( gc, _sides[i]->MiddlePnt() );
|
||||
// if ( linkNorm * vecOut < 0 )
|
||||
// linkNorm.Reverse();
|
||||
// double mag2 = linkNorm.SquareMagnitude();
|
||||
// if ( mag2 > numeric_limits<double>::min() )
|
||||
// linkNorm /= sqrt( mag2 );
|
||||
// gp_Vec vecBent ( _sides[i]->MiddlePnt(), bentLink->MediumPnt());
|
||||
// gp_Vec vecStraight( _sides[i]->MiddlePnt(), bentLink->MiddlePnt());
|
||||
// if ( vecBent * linkNorm > -0.1*vecStraight.Magnitude() )
|
||||
// return true;
|
||||
// }
|
||||
// return false;
|
||||
|
||||
}
|
||||
// }
|
||||
|
||||
//================================================================================
|
||||
/*!
|
||||
|
@ -211,7 +211,7 @@ QWidget* SMESHGUI_FilterLibraryDlg::createMainFrame (QWidget* theParent)
|
||||
myTable->SetLibsEnabled(false);
|
||||
|
||||
myListBox->setMinimumHeight((int)(myTable->sizeHint().height() * 0.5));
|
||||
//myListBox->setRowMode(QListWidget::FitToWidth); //VSR : TODO ???
|
||||
//myListBox->setRowMode(QListWidget::FitToWidth);
|
||||
myListBox->setSelectionMode(QListWidget::SingleSelection);
|
||||
|
||||
myOpenBtn->setAutoDefault(false);
|
||||
|
Loading…
Reference in New Issue
Block a user