mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-31 16:30:32 +05:00
0021208: Performance issue when loading SMESH with an hdf file containing a big mesh
+ bool IsUpToDate() const;
This commit is contained in:
parent
709188eac6
commit
abb0ef62f4
@ -135,6 +135,17 @@ int SMESHDS_GroupOnFilter::GetTic() const
|
|||||||
return GetMesh()->GetMTime() * myPredicateTic;
|
return GetMesh()->GetMTime() * myPredicateTic;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//================================================================================
|
||||||
|
/*!
|
||||||
|
* \brief Return false if update() is needed
|
||||||
|
*/
|
||||||
|
//================================================================================
|
||||||
|
|
||||||
|
bool SMESHDS_GroupOnFilter::IsUpToDate() const
|
||||||
|
{
|
||||||
|
return !( myMeshModifTime < GetMesh()->GetMTime() );
|
||||||
|
}
|
||||||
|
|
||||||
//================================================================================
|
//================================================================================
|
||||||
/*!
|
/*!
|
||||||
* \brief Updates myElements if necessary
|
* \brief Updates myElements if necessary
|
||||||
@ -143,7 +154,7 @@ int SMESHDS_GroupOnFilter::GetTic() const
|
|||||||
|
|
||||||
void SMESHDS_GroupOnFilter::update() const
|
void SMESHDS_GroupOnFilter::update() const
|
||||||
{
|
{
|
||||||
if ( myMeshModifTime < GetMesh()->GetMTime() )
|
if ( !IsUpToDate() )
|
||||||
{
|
{
|
||||||
SMESHDS_GroupOnFilter* me = const_cast<SMESHDS_GroupOnFilter*>( this );
|
SMESHDS_GroupOnFilter* me = const_cast<SMESHDS_GroupOnFilter*>( this );
|
||||||
me->myElements.clear();
|
me->myElements.clear();
|
||||||
|
@ -58,6 +58,8 @@ class SMESHDS_EXPORT SMESHDS_GroupOnFilter: public SMESHDS_GroupBase
|
|||||||
|
|
||||||
virtual int GetTic() const;
|
virtual int GetTic() const;
|
||||||
|
|
||||||
|
bool IsUpToDate() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
void update() const;
|
void update() const;
|
||||||
|
Loading…
Reference in New Issue
Block a user