I didn't see anything like this in vtkMath, does it exist somewhere else? Or can this be added somewhere?<br><br><br>void Project(const double* A, const double* B, double* Projection)<br>{<br> //find the projection of A on B<br>
double scale = vtkMath::Dot(A,B)/pow(vtkMath::Norm(B), 2);<br> for(unsigned int i = 0; i < 3; i++)<br> Projection[i] = scale * B[i];<br> <br>}<br><br clear="all">Thanks,<br><br>David<br>