Commit e25aabc9 authored by Michael Turner's avatar Michael Turner
Browse files

80% speed up in makeorder

parent ef5da778
......@@ -92,7 +92,7 @@ Array<OneD, NekDouble> CADSurfOCE::locuv(Array<OneD, NekDouble> p)
m_occSurface.FirstUParameter(), m_occSurface.LastUParameter(),
m_occSurface.FirstVParameter(), m_occSurface.LastVParameter());
gp_Pnt2d p2 = sas.ValueOfUV(loc, 1e-7);
gp_Pnt2d p2 = sas.ValueOfUV(loc, 1e-3);
uvr[0] = p2.X();
uvr[1] = p2.Y();
......@@ -217,7 +217,7 @@ void CADSurfOCE::ProjectTo(Array<OneD, NekDouble> &tp, Array<OneD, NekDouble> &u
m_occSurface.FirstVParameter(),
m_occSurface.LastVParameter());
gp_Pnt2d p2 = sas.ValueOfUV(loc, 1e-7);
gp_Pnt2d p2 = sas.ValueOfUV(loc, 1e-3);
gp_Pnt p3 = sas.Value(p2);
......
......@@ -164,7 +164,8 @@ void Edge::MakeOrder(int order,
std::vector<CADSurfSharedPtr> s = c->GetAdjSurf();
for(int j = 0; j < s.size(); j++)
{
Array<OneD, NekDouble> uv = s[j]->locuv(loc);
Array<OneD, NekDouble> uv(2);
s[j]->ProjectTo(loc,uv);
m_edgeNodes[i]->SetCADSurf(s[j]->GetId(),s[j],uv);
}
}
......@@ -178,7 +179,8 @@ void Edge::MakeOrder(int order,
loc[0] = m_edgeNodes[i]->m_x;
loc[1] = m_edgeNodes[i]->m_y;
loc[2] = m_edgeNodes[i]->m_z;
Array<OneD, NekDouble> uv = s->locuv(loc);
Array<OneD, NekDouble> uv(2);
s->ProjectTo(loc,uv);
loc = s->P(uv);
m_edgeNodes[i]->m_x = loc[0];
m_edgeNodes[i]->m_y = loc[1];
......
......@@ -263,7 +263,8 @@ void Face::MakeOrder(int order,
loc[0] = m_faceNodes[i]->m_x;
loc[1] = m_faceNodes[i]->m_y;
loc[2] = m_faceNodes[i]->m_z;
Array<OneD, NekDouble> uv = s->locuv(loc);
Array<OneD, NekDouble> uv(2);
s->ProjectTo(loc,uv);
loc = s->P(uv);
m_faceNodes[i]->m_x = loc[0];
m_faceNodes[i]->m_y = loc[1];
......
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