[vtkusers] Python interface of vtkCellLocator does not match C++ interface

Rodrigo Valiña Gutiérrez rodrigo.valina at usc.es
Fri Apr 9 07:45:59 EDT 2010


Hi,

I am using Python interface of VTK 5.4.2 and was using a
vtk.vtkPointLocator, which works well.

But now I want to use vtk.vtkCellLocator, and there is a problem:
there are methods (specially FindClosestPoint) that I want to use and
they appear in documentation and in source of vtkCellLocator, but not
in Python interface. Also FindCell does not seem to work.

vtkCellLocator:
http://www.vtk.org/doc/release/5.4/html/a00250.html

The methods defined in Python are:

a = vtk.vtkPointLocator()
dir(a)
['AddObserver', 'AutomaticOff', 'AutomaticOn', 'BreakOnError',
'BuildLocator', 'DebugOff', 'DebugOn', 'FastDelete',
'FindClosestInsertedPoint', 'FindClosestNPoints', 'FindClosestPoint',
'FindDistributedPoints', 'FindPointsWithinRadius',
'FreeSearchStructure', 'GenerateRepresentation', 'GetAddressAsString',
'GetAutomatic', 'GetBuildTime', 'GetClassName', 'GetDataSet',
'GetDebug', 'GetDivisions', 'GetGlobalWarningDisplay', 'GetLevel',
'GetMTime', 'GetMaxLevel', 'GetMaxLevelMaxValue',
'GetMaxLevelMinValue', 'GetNumberOfPointsPerBucket',
'GetNumberOfPointsPerBucketMaxValue',
'GetNumberOfPointsPerBucketMinValue', 'GetPoints',
'GetPointsInBucket', 'GetReferenceCount', 'GetTolerance',
'GetToleranceMaxValue', 'GetToleranceMinValue',
'GlobalWarningDisplayOff', 'GlobalWarningDisplayOn', 'HasObserver',
'InitPointInsertion', 'Initialize', 'InsertNextPoint', 'InsertPoint',
'InvokeEvent', 'IsA', 'IsInsertedPoint', 'IsTypeOf', 'Modified',
'NewInstance', 'PrintRevisions', 'Register', 'RemoveAllObservers',
'RemoveObserver', 'RemoveObservers', 'SafeDownCast', 'SetAutomatic',
'SetDataSet', 'SetDebug', 'SetDivisions', 'SetGlobalWarningDisplay',
'SetMaxLevel', 'SetNumberOfPointsPerBucket', 'SetReferenceCount',
'SetTolerance', 'UnRegister', 'Update']

b = vtk.vtkCellLocator()
dir(b)
['AddObserver', 'AutomaticOff', 'AutomaticOn', 'BreakOnError',
'BuildLocator', 'CacheCellBoundsOff', 'CacheCellBoundsOn', 'DebugOff',
'DebugOn', 'FastDelete', 'FindCell', 'FindCellsAlongLine',
'FreeSearchStructure', 'GenerateRepresentation', 'GetAddressAsString',
'GetAutomatic', 'GetBuildTime', 'GetCacheCellBounds', 'GetCells',
'GetClassName', 'GetDataSet', 'GetDebug', 'GetGlobalWarningDisplay',
'GetLazyEvaluation', 'GetLevel', 'GetMTime', 'GetMaxLevel',
'GetMaxLevelMaxValue', 'GetMaxLevelMinValue', 'GetNumberOfBuckets',
'GetNumberOfCellsPerBucket', 'GetNumberOfCellsPerNode',
'GetNumberOfCellsPerNodeMaxValue', 'GetNumberOfCellsPerNodeMinValue',
'GetReferenceCount', 'GetRetainCellLists', 'GetTolerance',
'GetToleranceMaxValue', 'GetToleranceMinValue',
'GetUseExistingSearchStructure', 'GlobalWarningDisplayOff',
'GlobalWarningDisplayOn', 'HasObserver', 'Initialize',
'InsideCellBounds', 'IntersectWithLine', 'InvokeEvent', 'IsA',
'IsTypeOf', 'LazyEvaluationOff', 'LazyEvaluationOn', 'Modified',
'NewInstance', 'PrintRevisions', 'Register', 'RemoveAllObservers',
'RemoveObserver', 'RemoveObservers', 'RetainCellListsOff',
'RetainCellListsOn', 'SafeDownCast', 'SetAutomatic',
'SetCacheCellBounds', 'SetDataSet', 'SetDebug',
'SetGlobalWarningDisplay', 'SetLazyEvaluation', 'SetMaxLevel',
'SetNumberOfCellsPerBucket', 'SetNumberOfCellsPerNode',
'SetReferenceCount', 'SetRetainCellLists', 'SetTolerance',
'SetUseExistingSearchStructure', 'UnRegister', 'Update',
'UseExistingSearchStructureOff', 'UseExistingSearchStructureOn']

is it a bug ?

am I missing something ?



More information about the vtkusers mailing list