[vtk-developers] [VTK 0011550]: vtkImageData::FindCell ignores tolerance
Mantis Bug Tracker
mantis at public.kitware.com
Wed Dec 1 13:11:34 EST 2010
The following issue has been SUBMITTED.
======================================================================
http://public.kitware.com/Bug/view.php?id=11550
======================================================================
Reported By: David Doria
Assigned To:
======================================================================
Project: VTK
Issue ID: 11550
Category: (No Category)
Reproducibility: always
Severity: minor
Priority: normal
Status: new
======================================================================
Date Submitted: 2010-12-01 13:11 EST
Last Modified: 2010-12-01 13:11 EST
======================================================================
Summary: vtkImageData::FindCell ignores tolerance
Description:
vtkImageData::FindCell ignores the tolerance parameter. Because of this, there
is no way to ensure that FindCell will return a cell when given a point that
lies on the boundary of the data set.
Steps to Reproduce:
The following code returns -1 when it should return cell 0.
#include <vtkSmartPointer.h>
#include <vtkImageData.h>
int main(int, char *[])
{
int dims[3] = {1,2,3};
double spacing[3] = {1.0, 1.0, 1.0};
vtkSmartPointer<vtkImageData> image =
vtkSmartPointer<vtkImageData>::New();
image->SetDimensions(dims);
image->SetSpacing(spacing);
double p[3] = {1.0,1.0,1.0};
int subId;
double pcoords[3] = {0,0,0};
double weights[8];
int index = image->FindCell(p, NULL, 0, 10.0, subId, pcoords, weights);
std::cout << "index: " << index << std::endl;
return EXIT_SUCCESS;
}
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2010-12-01 13:11 David Doria New Issue
======================================================================
More information about the vtk-developers
mailing list