<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2668" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hello,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV>
<DIV><FONT face=Arial size=2>I am using VTK 4.2 on Windows XP with VC++ 6.0 and 
am&nbsp;relatively new to VTK. I&nbsp;am doing a project where I have to 
register two 2.5 D scans (two surfaces) which are in wavefront obj format. I 
have had no problems so far in terms of rendering or implementation of the 
Iterative Closest Point Transform.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Now i need to implement a landmark detection 
algorithm that needs the values of Gaussian and Mean curvatures at each point of 
the surface. I have written the code using the VTK class vtkCurvatures and it 
compiles and runs error free. I am able to get values for Gaussian curvature, 
but for mean curvature i get the value zero at all points of the scan. Snippet 
of my code is provided below, if anyone has faced this problem before or knows 
what I am doing wrong, please please let me know.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Thanks in advance.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Regards,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Prathap Nair<BR>Dept of Electronic 
Engineering,<BR>Queen Mary, University of London,<BR>Mile End Road, London E1 
4NS (UK).</FONT></DIV></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>/************************Code 
Snippet***************/</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>//face 3 is a polydata object containing the 
surface</FONT></DIV>
<DIV><FONT face=Arial 
size=2>this-&gt;face3-&gt;DeepCopy(face2-&gt;GetOutput());<BR></DIV>
<DIV></FONT><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>//Get the Mean curvature and store in 
vtkDoubleArray "mvals"</FONT></DIV>
<DIV><FONT face=Arial 
size=2>this-&gt;curvm-&gt;SetInput(this-&gt;face3);&nbsp;&nbsp;&nbsp; 
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  
//curvm is an object of 
vtkCurvatures<BR>this-&gt;curvm-&gt;SetCurvatureTypeToMean();<BR>this-&gt;curvm-&gt;Update();<BR>this-&gt;mvals-&gt;DeepCopy(curvm-&gt;GetOutput()-&gt;GetPointData()-&gt;GetScalars());<BR></FONT></DIV>
<DIV><FONT face=Arial size=2>//Get the&nbsp;Gaussian curvature and store in 
vtkDoubleArray "gvals"</DIV></FONT>
<DIV><FONT face=Arial 
size=2>this-&gt;curvg-&gt;SetInput(this-&gt;face3);&nbsp;&nbsp;&nbsp; 
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 
//curvg is an object of 
vtkCurvatures<BR>this-&gt;curvg-&gt;SetCurvatureTypeToGaussian();<BR>this-&gt;curvg-&gt;Update();</FONT></DIV>
<DIV><FONT face=Arial 
size=2>this-&gt;gvals-&gt;DeepCopy(curvg-&gt;GetOutput()-&gt;GetPointData()-&gt;GetScalars());</DIV></FONT></BODY></HTML>