[vtkusers] FindCell in multithreaded application

John Haiducek jhaiduce at gmail.com
Sun Oct 31 09:37:00 EDT 2010


On Sat, 2010-10-30 at 14:39 -0400, Jim Peterson wrote:
> John,
> 
> Just curious, where did you get the original premise that protecting the 
> first call to FindCell would make all calls threadsafe? Was that in a 
> VTK usage recomendation or document somewhere?
> 
> Thanks,
> Jim

In the documentation for vtkDataSet it says: THIS METHOD IS THREAD SAFE
IF FIRST CALLED FROM A SINGLE THREAD AND THE DATASET IS NOT MODIFIED.
That's for the second version of FindCell, which takes a vtkGenericCell
as a parameter. I may be misunderstanding it, but I thought the text in
all caps meant that it's thread-safe as long as the first call is
protected.

John




More information about the vtkusers mailing list