Sorry, just re-read your post - I see that you attached the header file for the file you included.  Try this:<div><br></div><div><div>#ifndef IVTK_SAMPLE_FILTER</div><div>#define IVTK_SAMPLE_FILTER</div><div><br></div><div>
//BTX</div><div>#include &quot;vtkObjectFactory.h&quot;</div><div>//ETX</div><div>#include &quot;vtkSimpleImageToImageFilter.h&quot;</div><div>//BTX</div><div>#include &quot;xtkBox.h&quot;</div><div>//ETX</div><div><br></div>
<div>class VTK_IMAGING_EXPORT ivtkSampleImageFilter : public vtkSimpleImageToImageFilter {</div><div>  public:</div><div>  static ivtkSampleImageFilter* New();</div><div><br></div><div>  vtkTypeMacro( ivtkSampleImageFilter, vtkSimpleImageToImageFilter);</div>
<div>  protected:</div><div>  ivtkSampleImageFilter();</div><div>  ivtkSampleImageFilter(const ivtkSampleImageFilter&amp;) {};</div><div>  void operator=(const ivtkSampleImageFilter&amp;) {};</div><div><br></div><div>  //override from vtkImageToImageFilter</div>
<div>  virtual void SimpleExecute(vtkImageData* inp, vtkImageData* out);</div><div><br></div><div>    vtkImageData*    vtkResultImage;</div><div>//BTX</div><div>  vtkITKFilter_H_Macro;</div><div>  /// custom Filter function ///</div>
<div>  template &lt;typename ImageType&gt;</div><div>  void ApplyFilter(vtkImageData* vtkInput);</div><div>//ETX</div><div>};</div><div>#endif</div></div><div><br></div><div>That might work but I haven&#39;t really looked to see what your macro is expanding out to.   </div>
<div><br></div><div>Regards,</div><div>Paul</div><div><br></div><div><br></div><div><div class="gmail_quote">On 24 February 2010 09:29, Paul Edwards <span dir="ltr">&lt;<a href="mailto:paul.m.edwards@gmail.com">paul.m.edwards@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">I don&#39;t really understand what you are doing but one obvious thing from the header is that the BTX/ETX is around the wrong way:<div>
<br></div><div><div>//ETX</div><div>#include &quot;itkImage.h&quot;</div><div>//BTX</div>
<div><br></div><div>should be:</div><div><div><br></div><div>//BTX</div><div>#include &quot;itkImage.h&quot;</div><div>//ETX</div></div><div><br></div><div>I didn&#39;t even realise that the the parser work for templates though...</div>

<div><br></div><div>Regards,</div><div>Paul</div><br><div class="gmail_quote"><div><div></div><div class="h5">On 24 February 2010 08:55, Christian Werner <span dir="ltr">&lt;<a href="mailto:christian.werner@rwth-aachen.de" target="_blank">christian.werner@rwth-aachen.de</a>&gt;</span> wrote:<br>

</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div></div><div class="h5">Hello!<br>
<br>
I am writng a plugin for my paraview. I already succeeded doing this with another filter but this one drives me crazy. I keep getting these<br>
<br>
&quot;*** SYNTAX ERROR found in parsing the header file /home/christian/programming/pv-plugins/Transformation/ivtkSampleFilter.h before line 8 ***<br>
<br>
messages, no matter where I put these //BTX //ETX. This is my header:<br>
<br>
<br>
#ifndef IVTK_SAMPLE_FILTER<br>
#define IVTK_SAMPLE_FILTER<br>
<br>
#include &quot;vtkObjectFactory.h&quot;<br>
#include &quot;vtkSimpleImageToImageFilter.h&quot;<br>
#include &quot;xtkBox.h&quot;<br>
<br>
class VTK_IMAGING_EXPORT ivtkSampleImageFilter : public vtkSimpleImageToImageFilter {<br>
   public:<br>
   static ivtkSampleImageFilter* New();<br>
<br>
   vtkTypeMacro( ivtkSampleImageFilter, vtkSimpleImageToImageFilter);<br>
   protected:<br>
   ivtkSampleImageFilter();<br>
   ivtkSampleImageFilter(const ivtkSampleImageFilter&amp;) {};<br>
   void operator=(const ivtkSampleImageFilter&amp;) {};<br>
<br>
   //override from vtkImageToImageFilter<br>
   virtual void SimpleExecute(vtkImageData* inp, vtkImageData* out);<br>
<br>
   //BTX<br>
   vtkImageData*    vtkResultImage;<br>
   //ETX<br>
   vtkITKFilter_H_Macro;<br>
   /// custom Filter function ///<br>
   template &lt;typename ImageType&gt;<br>
   void ApplyFilter(vtkImageData* vtkInput);<br>
};<br>
#endif<br>
<br>
It also complains if I comment out my #include &quot;xtkBox.h&quot;, or put some //BTX//ETX all around other places. It keeps coming with the error message as if I did not even edit the right file. (I do, I checked that... :)<br>


<br>
I call a macro later in the header which is defined in the xtkBox.h but the compiler does not even care if it is defined or not. Anyway, for completeness I attached this xtkBox.h.<br>
<br>
Does anyone see what I am missing?<br>
<br>
<br>
Best regards,<br>
Chrsitian<br>
<br></div></div>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>