[vtk-developers] vtkMath::Dot2D

Dean Inglis dean.inglis at camris.ca
Wed Dec 9 19:05:50 EST 2009

sorry, possible objection here.  Use case scenario: I might be
using vtkContourWidget with 2D contours defined in an
x-y plane.  The widget stores all its node coords as
3 tuples accessable via a vtkPolyData's vtkPoints.
I might want to compute the dot product on sequential
point pairs in a tangent vector calculation and it
would be nice to not have to convert every point to a
2 tuple.


----- Original Message ----- 
From: "David Doria" <daviddoria+vtk at gmail.com>
Cc: "VTK Developers" <vtk-developers at vtk.org>
Sent: Wednesday, December 09, 2009 6:35 PM
Subject: Re: [vtk-developers] vtkMath::Dot2D

On Wed, Dec 9, 2009 at 6:11 PM, Moreland, Kenneth <kmorel at sandia.gov> wrote:
> My guess would be that that is a copy-paste error. Change it to 2-vectors
> is probably the right thing to do.
> AFAIK, the array declaration in a function/method argument is treated just
> like a pointer. C++ does not do any range checking. I think it just serves
> to help document what size array you expect.
> -Ken

This actually seems to be the case with almost all of the 2D vtkMath
functions. I'm going to change them all as Ken suggested. Any


Powered by www.kitware.com

Visit other Kitware open-source projects at 

Follow this link to subscribe/unsubscribe:

More information about the vtk-developers mailing list