Skip to content
Snippets Groups Projects
Commit a1240b1d authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

smooth: added support for weighting methods avg, dist, gauss

parent 8cbde6ad
No related branches found
No related tags found
1 merge request!287M214003/develop
......@@ -3,6 +3,10 @@
* Using CDI library version 2.5.0
* Version 2.5.0 release
2024-11-25 Uwe Schulzweida
* smooth: added support for weighting methods avg, dist, gauss
2024-11-14 Uwe Schulzweida
* intgridknn: added method avg, gauss
......
......@@ -190,6 +190,16 @@ grid_search_point_smooth(GridPointsearch &gps, const PointLonLat &pointLL, KnnDa
}
knnData.check_distance();
if (knnData.m_weighted == WeightingMethod::gaussWeighted)
{
numNeighbors = knnData.m_numNeighbors;
if (numNeighbors > knnData.m_srcCoords.size()) knnData.m_srcCoords.resize(numNeighbors);
for (size_t i = 0; i < numNeighbors; ++i)
{
gcLLtoXYZ(gps.plons[knnData.m_indices[i]], gps.plats[knnData.m_indices[i]], knnData.m_srcCoords[i]);
}
}
}
void
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment