Commit 24892674 authored by Dave Moxey's avatar Dave Moxey

Merge branch 'fix/surface-mesher' into 'master'

fix/surface-mesher

Fix bug in compilation, tests and surface mesher.

See merge request !728
parents b0dc56a3 725703e4
......@@ -113,8 +113,8 @@ if(OCC_FOUND)
TKHLR
TKFeat
)
if(OCC_VERSION_STRING VERSION_LESS 6.8)
if(OCC_VERSION_STRING VERSION_LESS 6.7)
MESSAGE(SEND_ERROR "OCC version too low")
endif(OCC_VERSION_STRING VERSION_LESS 6.8)
endif(OCC_VERSION_STRING VERSION_LESS 6.7)
message(STATUS "-- Found OCE/OpenCASCADE with OCC version: ${OCC_VERSION_STRING}")
endif(OCC_FOUND)
......@@ -185,9 +185,21 @@ NekDouble Octree::Query(Array<OneD, NekDouble> loc)
found = true;
}
}
return min(n->GetDelta(),tmp);
}
NekDouble Octree::GetMinDelta()
{
NekDouble tmp = numeric_limits<double>::max();
for(int i = 0; i < m_lsources.size(); i++)
{
tmp = min(m_lsources[i].delta,tmp);
}
return min(m_minDelta,tmp);
}
void Octree::WriteOctree(string nm)
{
MeshSharedPtr oct = boost::shared_ptr<Mesh>(new Mesh());
......
......@@ -132,10 +132,7 @@ public:
*
* @return miminum delta in octree
*/
NekDouble GetMinDelta()
{
return m_minDelta;
}
NekDouble GetMinDelta();
/**
* @brief sets the parameters used for curvature sampling
......
......@@ -918,17 +918,17 @@ bool FaceMesh::Validate()
int numValid = 0;
if (r[0] < triDelta[0] && r[2] < triDelta[0])
if (r[0] < (triDelta[0] + triDelta[1]) / 2.0 *1.41)
{
numValid++;
}
if (r[1] < triDelta[1] && r[0] < triDelta[1])
if (r[1] < (triDelta[1] + triDelta[2]) / 2.0 *1.41)
{
numValid++;
}
if (r[2] < triDelta[2] && r[1] < triDelta[2])
if (r[2] < (triDelta[2] + triDelta[0]) / 2.0 *1.41)
{
numValid++;
}
......
......@@ -7,9 +7,9 @@
</INFORMATION>
<PARAMETERS>
<P PARAM="MinDelta" VALUE="0.005" />
<P PARAM="MinDelta" VALUE="0.003" />
<P PARAM="MaxDelta" VALUE="0.2" />
<P PARAM="EPS" VALUE="0.09" />
<P PARAM="EPS" VALUE="0.05" />
<P PARAM="Order" VALUE="4" />
</PARAMETERS>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment