[vtkusers] VTK class to do interpolation of scalar values

Bill Lorensen bill.lorensen at gmail.com
Mon Dec 7 13:34:50 EST 2009


The data for the example should be some points scattered in space. I
assume that is what Jin has, not just three points on a line. I'll dig
up some meaningful data, uless Jin can share a small sample of his
data.

Bill

Bill

On Mon, Dec 7, 2009 at 1:11 PM, David Doria <daviddoria+vtk at gmail.com> wrote:
> On Mon, Dec 7, 2009 at 12:20 PM, David Gobbi <david.gobbi at gmail.com> wrote:
>> On Mon, Dec 7, 2009 at 9:51 AM, David Doria <daviddoria+vtk at gmail.com> wrote:
>>> On Mon, Dec 7, 2009 at 11:43 AM, Jin Ryong Kim <jinryongkim at gmail.com> wrote:
>>>> I have a question about interpolation method in VTK.
>>>> Currently, I'm trying to interpolate scalar values between data points to
>>>> create a contour map.
>>>> I have some data points set (x, y, z) and scalar values related with each
>>>> data point.
>>>> So far, I found out vtkProbeFilter but when I tried, nothing came up.
>>>> My questions are as follow.
>>>> 1. Is vtkProbeFilter the right choice in this case?
>>>> 2. If not, what are the right vtk classes to accomplish such a goal?
>>>> If anyone has the solution for this, please let me know.
>>>> Thanks in advance!
>>>
>>> Jin,
>>>
>>> If I'm not mistaken you sent this same question yesterday. I am
>>> interesting in making an example of this so I have started poking
>>> around. I understand that you may be in a hurry, but asking twice is
>>> just going to annoy people on the list, making your answer come
>>> slower, not faster.
>>>
>>> Can anyone confirm or deny that ProbeFilter is the right way to go?
>>
>> The probe needs cells to interpolate the data.  If all you have is
>> points, then you have to apply delaunay first to make the cells, and
>> then use probe to interpolate the data onto a grid (i.e. make an
>> image), and then contour the grid.  It might also be possible to
>> contour directly from the output of delaunay, but I'm not sure whether
>> VTK can do that.  I'm no expert in this area, but hopefully I've
>> answered your question.
>>
>>   David
>>
>
> From Bill's suggestion I have tried to make an example:
> http://www.vtk.org/Wiki/VTK_Examples_Interpolation
>
> the problem is that the Shepard filter outputs an ImageData and the
> ContourFilter seems to expect a DataObject.
>
> Jin, this is a simple version of what you are trying to do, correct?
> If so, let try to get this little demo working.
>
> Thanks,
>
> David
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>



More information about the vtkusers mailing list