Hi Robert,<div><br></div><div>See the following presentation and code example,</div><div><br></div><div><a href="http://www.vtk.org/Wiki/images/2/24/Insight-MultiThreading.ppt">http://www.vtk.org/Wiki/images/2/24/Insight-MultiThreading.ppt</a></div>
<div><br></div><div><a href="http://www.vtk.org/Wiki/ITK/Examples/Developer/OilPaintingImageFilter">http://www.vtk.org/Wiki/ITK/Examples/Developer/OilPaintingImageFilter</a></div><div><br></div><div>HTH,</div><div>Dawood</div>
<div><br></div><div><br></div><div>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<</div>
<div><br></div><div>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<</div><div>
<br></div><div><br></div><div><span class="Apple-style-span" style="font-family: 'Times New Roman'; font-size: medium; "><pre>Hi there,
I am developing an application for reconstructing MRI images and
performing real time image processing ( i,e image processing ) as I
would like to explore the effect of mutlitthreading on execution speed
I am not exactly sure how multi-threading works in ITK so I would
appreciate some guidance on this. Please correct me if any of the
following is incorrect:.
I originally assumed the user would have to write the code themselves
if they want to implement multithreading, but as I understand it you
are only required to do this if you are writing your own custom
filter? In which case multithreading is already implicitly implemented
in a lot of the ITK filters and is automatically used if your code
runs on a multi-core processor?
For example, if I apply the FFT filter to some kspace data, will it
automatically execute on the 4 processors of my machine or do I need
to explicitly tell it to do do?
I presume if no multithreading libraries are specified when building
iTK in cmake then the code will automatically execute on one
processor?
I did build ITK and checked the CMAKE USE WIN32 THREADS so I think my
code should automatically run on the four processors but I am not sure
how to check this? I checked the windows task manager when I executed
my code and the four processors appear to fire up but I would like to
verify this somehow in ITK?
Also how can I set the number of processors I want my code to run on?
Any guidance would be much appreciated,
Rob</pre></span></div>