Closed juanraul8 closed 5 years ago
Why didnt you change computing normals in PointCloud? Can we fix it?
Why didnt you change computing normals in PointCloud? Can we fix it?
I do not think the problem is the normal computation. They are similar.
@BarisYazici normals visualization using PCL looks good.
First image is computing normals directly from depth maps (I follow a tutorial). Our normals where computed after backprojection, maybe that is the problem.
Ok, now I see what was the problem.
The problem was basically that m_normals does not have the grid structure. I also realize that normal computation does not seem to be same as paper formula.
Exercise 3 formula:
Kinect Fusion formula:
Another comment, in exercise 3, the following prune is applied:
const float du = 0.5f * (depthMap[idx + 1] - depthMap[idx - 1]);
const float dv = 0.5f * (depthMap[idx + width] - depthMap[idx - width]);
if (!std::isfinite(du) || !std::isfinite(dv) || abs(du) > maxDistanceHalved || abs(dv) > maxDistanceHalved) {
normalsTmp[idx] = Vector3f(MINF, MINF, MINF);
continue;
}
Maybe we are missing something like that.
Paper mentioned a validity mask, which can be used to know if the vertex map or normal map pixel is valid.
Features:
Normal maps computed directly by depth maps:
Normals computed using point cloud normals:
Problem above was solved, see comments.
Future tasks: