<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>It looks like the GPUCommon library is not being included. &nbsp;</div><div>You should have something like this line in your CMakeLists.txt:</div><div><br></div><div><div>target_link_libraries(YourExecutable ${ITK_LIBRARIES})</div></div><div><br></div><div>Can you provide your CMakeLists.txt ?</div><div>-Kris</div><br><blockquote type="cite">Date: Tue, 5 Jun 2012 18:55:55 +0200<br>From: Yass Jd &lt;<a href="mailto:yasso50@hotmail.com">yasso50@hotmail.com</a>&gt;<br>Subject: [Insight-users] ITK 4.2 - GPUMeanImageFilter -<br><span class="Apple-tab-span" style="white-space: pre; ">        </span>itkGPUKernelManager<br>To:&nbsp;<a href="mailto:insight-users@itk.org">insight-users@itk.org</a><br>Message-ID: &lt;<a href="mailto:BLU0-SMTP296F767A77A5AD6D75BD509BD0C0@phx.gbl">BLU0-SMTP296F767A77A5AD6D75BD509BD0C0@phx.gbl</a>&gt;<br>Content-Type: text/plain; charset="iso-8859-1"; Format="flowed"<br><br>Dear all,<br><br>I am trying to run the following sample code with ITK 4.2 in order to&nbsp;<br>perform a GPU-based mean filter:<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;typedef itk::GPUMeanImageFilter&lt;ImageType,ImageType&gt; filterType;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filterType::Pointer blurFilter = filterType::New();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;blurFilter-&gt;SetInput(handler.getOutput());<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;blurFilter-&gt;SetRadius(2);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;blurFilter-&gt;Update();<br><br><br>And i get the following errors from the linker (compilation is fine):<br><br>&nbsp;&nbsp;&nbsp;CMakeFiles/ReadDCMWriteNii.dir/main.cxx.o: In function<br>&nbsp;&nbsp;&nbsp;`itk::GPUKernelManager::New()':<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUKernelManager.h:60: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::GPUKernelManager::GPUKernelManager()'<br>&nbsp;&nbsp;&nbsp;CMakeFiles/ReadDCMWriteNii.dir/main.cxx.o: In function<br>&nbsp;&nbsp;&nbsp;`itk::GPUMeanImageFilter&lt;itk::Image&lt;short, 4u&gt;, itk::Image&lt;short,<br>&nbsp;&nbsp;&nbsp;4u&gt; &gt;::GPUGenerateData()':<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUMeanImageFilter.hxx:92: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::OpenCLGetLocalBlockSize(unsigned int)'<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUMeanImageFilter.hxx:105: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::GPUKernelManager::SetKernelArgWithImage(int,<br>&nbsp;&nbsp;&nbsp;unsigned int, itk::SmartPointer&lt;itk::GPUDataManager&gt;)'<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUMeanImageFilter.hxx:106: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::GPUKernelManager::SetKernelArgWithImage(int,<br>&nbsp;&nbsp;&nbsp;unsigned int, itk::SmartPointer&lt;itk::GPUDataManager&gt;)'<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUMeanImageFilter.hxx:110: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::GPUKernelManager::SetKernelArg(int, unsigned int,<br>&nbsp;&nbsp;&nbsp;unsigned long, void const*)'<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUMeanImageFilter.hxx:115: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::GPUKernelManager::SetKernelArg(int, unsigned int,<br>&nbsp;&nbsp;&nbsp;unsigned long, void const*)'<br>&nbsp;&nbsp;&nbsp;/usr/local/include/ITK-4.2/itkGPUMeanImageFilter.hxx:119: undefined<br>&nbsp;&nbsp;&nbsp;reference to `itk::GPUKernelManager::LaunchKernel(int, int, unsigned<br>&nbsp;&nbsp;&nbsp;long*, unsigned long*)<br><br>I don't see the error ? Seems like a bad declaration in the header&nbsp;<br>itkGPUKernelManager.h but I didn't find it... Everythinh is well&nbsp;<br>included in my code though. Anybody got an idea ?<br><br>Thank you !<br><br>Best regards,<br>Yass Jd.<br><br>-------------- next part --------------<br>An HTML attachment was scrubbed...<br>URL: &lt;<a href="http://www.itk.org/pipermail/insight-users/attachments/20120605/7257158d/attachment-0001.htm">http://www.itk.org/pipermail/insight-users/attachments/20120605/7257158d/attachment-0001.htm</a>&gt;<br><br>------------------------------</blockquote></body></html>