<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><DIV>Hi Dan</DIV>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman, new york, times, serif">
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman, new york, times, serif">
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman, new york, times, serif">
<DIV>&nbsp;</DIV>
<DIV>Thanks so much for your help. I used your piece of code with an analyze file and it solved the problem, thanks.&nbsp;Now the problem is:</DIV>
<DIV>&nbsp;</DIV>
<DIV>1- I need to draw the path on the input image.&nbsp;Right&nbsp;now the created image only includes the path not the image itself. how&nbsp;can I fix that?&nbsp;</DIV>
<DIV>2- I need to use orientImageFilter to make sure the read images are in common orientation. I can't find any<FONT color=#008000 size=2><FONT color=#000000 size=3>&nbsp; 
<P>SetDesiredCoordinateOrientation method to set the orientation to RPI, PIR, and RIP so I get the error&nbsp;Analyze 7.5 File Format Only Allows RPI, PIR, and RIP Orientation</P>
<P>&nbsp;</P>
<P>Thanks verymuch for all your help</P>
<P>&nbsp;</P>
<P>Shaady</P>
<P>&nbsp;</P></FONT></FONT></DIV>
<DIV>Here's my code:</DIV>
<DIV>&nbsp;</DIV>
<DIV><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.Collections.Generic;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.ComponentModel;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.Data;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.Drawing;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.Linq;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.Text;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> System.Windows.Forms;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> vtk;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>using</FONT></FONT><FONT size=2> itk;</P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>
<P>namespace</FONT></FONT><FONT size=2> InteractiveHierarchicalSegmentationDotNet</P>
<P>{</P>
<P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>public</FONT></FONT><FONT size=2> </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>partial</FONT></FONT><FONT size=2> </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>class</FONT></FONT><FONT size=2> </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>TestForm</FONT></FONT><FONT size=2> : </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>Form</P></FONT></FONT><FONT size=2>
<P>{</P>
<P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>public</FONT></FONT><FONT size=2> TestForm()</P>
<P>{</P>
<P>InitializeComponent();</P>
<P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>try</P></FONT></FONT><FONT size=2>
<P>{</P>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// Read image</P></FONT></FONT><FONT size=2>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkImage_UC3</FONT></FONT><FONT size=2> input = </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkImage_UC3</FONT></FONT><FONT size=2>.New();</P>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkImage_UC3</FONT></FONT><FONT size=2> output = </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkImage_UC3</FONT></FONT><FONT size=2>.New();</P></FONT><FONT size=2>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkImage_UC3</FONT></FONT><FONT size=2> outputO = </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkImage_UC3</FONT></FONT><FONT size=2>.New();</P>
<P></P>
<P>input.Read(</FONT><FONT color=#a31515 size=2><FONT color=#a31515 size=2>"D:/PHD/images/BI02_PSMR.hdr"</FONT></FONT><FONT size=2>);</P>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2></FONT></FONT>&nbsp;</P>
<P><FONT color=#008000 size=2><FONT color=#008000 size=2>// Create path</P></FONT></FONT><FONT size=2>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkPolyLineParametricPath_3</FONT></FONT><FONT size=2> path =</P>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkPolyLineParametricPath_3</FONT></FONT><FONT size=2>.New();</P>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkPoint</FONT></FONT><FONT size=2> point = </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>new</FONT></FONT><FONT size=2> </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkPoint</FONT></FONT><FONT size=2>(3U);</P>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkContinuousIndex</FONT></FONT><FONT size=2> vertex = </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>new</FONT></FONT><FONT size=2> </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkContinuousIndex</FONT></FONT><FONT size=2>(3U);</P>
<P>point[0] = 0.0;</P>
<P>point[1] = 0.0;</P>
<P>point[2] = 0.0;</P>
<P>input.TransformPhysicalPointToContinuousIndex(point, </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>out</FONT></FONT><FONT size=2> vertex);</P>
<P>path.AddVertex(vertex);</P>
<P>point[0] = 180.0;</P>
<P>point[1] = 180.0;</P>
<P>point[2] = 0.0;</P>
<P>input.TransformPhysicalPointToContinuousIndex(point, </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>out</FONT></FONT><FONT size=2> vertex);</P>
<P>path.AddVertex(vertex);</P>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2></FONT></FONT>&nbsp;</P>
<P><FONT color=#008000 size=2><FONT color=#008000 size=2>// Convert path to image</P></FONT></FONT><FONT size=2>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkPathToImageFilter_PLPP3IUC3</FONT></FONT><FONT size=2> pathToImage =</P>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkPathToImageFilter_PLPP3IUC3</FONT></FONT><FONT size=2>.New();</P>
<P>pathToImage.Size = input.Size;</P>
<P>pathToImage.Spacing = input.Spacing;</P>
<P>pathToImage.Origin = input.Origin;</P>
<P>pathToImage.SetInput(path);</P>
<P>pathToImage.PathValue = 255;</P>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//pathToImage.BackgroundValue = 0;</P></FONT></FONT><FONT size=2>
<P>pathToImage.UpdateLargestPossibleRegion();</P>
<P>pathToImage.GetOutput(output);</P></FONT><FONT size=2>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2></FONT></FONT>&nbsp;</P>
<P><FONT color=#008000 size=2><FONT color=#008000 size=2>//set orientation of the image</P></FONT></FONT><FONT size=2>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkOrientImageFilter_IUC3IUC3</FONT></FONT><FONT size=2> orientFilter = </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>itkOrientImageFilter_IUC3IUC3</FONT></FONT><FONT size=2>.New();</P>
<P>orientFilter.UseImageDirection = </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>true</FONT></FONT><FONT size=2>;</P>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// orientFilter.SetDesiredCoordinateOrientationToAxial();</P></FONT></FONT><FONT size=2>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//orientFilter.SetDesiredCoordinateOrientationToCoronal();</P></FONT></FONT><FONT size=2>
<P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//orientFilter.SetDesiredCoordinateOrientationToSagittal();</P></FONT></FONT><FONT size=2>
<P></P>
<P>orientFilter.SetInput(output);</P>
<P>orientFilter.GetOutput(outputO);</P>
<P>output.Write(</FONT><FONT color=#a31515 size=2><FONT color=#a31515 size=2>"D:/PHD/images/BI02_PSMR_copy.hdr"</FONT></FONT><FONT size=2>); </FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>//I actually need to write outputO to output not output</P></FONT></FONT><FONT size=2>
<P>}</P>
<P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>catch</FONT></FONT><FONT size=2> (</FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>Exception</FONT></FONT><FONT size=2> ex)</P>
<P>{</P>
<P></FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>Console</FONT></FONT><FONT size=2>.WriteLine(ex);</P>
<P>}</P>
<P>}</P>
<P>}</P>
<P>}</P></FONT><BR></DIV>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman, new york, times, serif"><BR>
<DIV style="FONT-SIZE: 13px; FONT-FAMILY: arial, helvetica, sans-serif">----- Forwarded Message ----<BR>From: Dan Mueller &lt;dan.muel@gmail.com&gt;<BR>To: Shady Shidfar &lt;shady_shidfar@yahoo.com&gt;<BR>Cc: Insight Users &lt;insight-users@itk.org&gt;<BR>Sent: Wednesday, 23 July, 2008 8:28:43 AM<BR>Subject: Re: [Insight-users] using spatialObjects in ManagedITK<BR><BR>Hi Shady,<BR><BR>Please find attached the following code which I have tested and<BR>verifies works correctly.<BR><BR>The differences are the following:<BR>&nbsp; 1. When you create a new itkPoint or itkContinuousIndex be careful<BR>to use itkPoint.New(3U) in the constructor. This creates a<BR>three-dimensional empty object, rather than itkPoint.New(3) which<BR>(may) create a 1 dimensional object with value "3".<BR>&nbsp; 2. The input image must be three-dimensional (I don't think<BR>"brain.tif" is 3-D).<BR>&nbsp; 3. Ensure all vertices added to the path are inside the largest<BR>possible
 region of the image. If not, you can receive the error<BR>message you reported. (Without further investigation, I'm not sure if<BR>this is a problem with the wrappings or with ITK itself...)<BR><BR>Hope this helps.<BR><BR>Regards, Dan<BR><BR>using System;<BR>using itk;<BR><BR>namespace ItkPathTest<BR>{<BR>&nbsp; &nbsp; class Program<BR>&nbsp; &nbsp; {<BR>&nbsp; &nbsp; &nbsp; &nbsp; static void Main(string[] args)<BR>&nbsp; &nbsp; &nbsp; &nbsp; {<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Read image<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkImage_UC3 input = itkImage_UC3.New();<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkImage_UC3 output = itkImage_UC3.New();<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; input.Read("D:/Temp/engine.mhd");<BR><BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Create path<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkPolyLineParametricPath_3 path =<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
 itkPolyLineParametricPath_3.New();<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkPoint point = new itkPoint(3U);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkContinuousIndex vertex = new itkContinuousIndex(3U);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; point[0] = 50.0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; point[1] = 50.0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; point[2] = 50.0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; input.TransformPhysicalPointToContinuousIndex(point, out vertex);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; path.AddVertex(vertex);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; point[0] = 200.0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; point[1] = 200.0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; point[2] = 100.0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; input.TransformPhysicalPointToContinuousIndex(point, out vertex);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; path.AddVertex(vertex);<BR><BR>&nbsp;
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Convert path to image<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkPathToImageFilter_PLPP3IUC3 pathToImage =<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; itkPathToImageFilter_PLPP3IUC3.New();<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.Size = input.Size;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.Spacing = input.Spacing;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.Origin = input.Origin;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.SetInput(path);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.PathValue = 255;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.BackgroundValue = 0;<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.UpdateLargestPossibleRegion();<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; pathToImage.GetOutput(output);<BR>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; output.Write("D:/Temp/Path01.mhd");<BR>&nbsp;
 &nbsp; &nbsp; &nbsp; }<BR>&nbsp; &nbsp; }<BR>}<BR><BR><BR>2008/7/22 Shady Shidfar &lt;<A href="mailto:shady_shidfar@yahoo.com" target=_blank rel=nofollow ymailto="mailto:shady_shidfar@yahoo.com">shady_shidfar@yahoo.com</A>&gt;:<BR>&gt; Hi Dan,<BR>&gt;<BR>&gt; Thanks for the file, I guess I'll wait for you to solve the problem :-). Now<BR>&gt; instead of using SpatialObjects I'm trying to<BR>&gt; use itkPolyLineParametricPath&nbsp; to draw contours on my image, then use<BR>&gt; itkPathToImageFilter to display them on the image. The problem is that I get<BR>&gt; a weird message. Could you please have a look at the following code and see<BR>&gt; what the problem is.<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; the error is: Attempted to read or write protected memory. This is often an<BR>&gt; indication that other memory is corrupt.<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt;
 System.Collections.Generic;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Linq;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Windows.Forms;<BR>&gt;<BR>&gt; namespace<BR>&gt;<BR>&gt; InteractiveHierarchicalSegmentationDotNet<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; static class Program<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; /// &lt;summary&gt;<BR>&gt;<BR>&gt; /// The main entry point for the application.<BR>&gt;<BR>&gt; /// &lt;/summary&gt;<BR>&gt;<BR>&gt; [<BR>&gt;<BR>&gt; STAThread]<BR>&gt;<BR>&gt; static void Main()<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; //Application.EnableVisualStyles();<BR>&gt;<BR>&gt; //Application.SetCompatibleTextRenderingDefault(false);<BR>&gt;<BR>&gt; //Application.Run(new Form1());<BR>&gt;<BR>&gt; Application.Run(new TestForm());<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt;
 System.Collections.Generic;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.ComponentModel;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Data;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Drawing;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Linq;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Text;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; System.Windows.Forms;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; vtk;<BR>&gt;<BR>&gt; using<BR>&gt;<BR>&gt; itk;<BR>&gt;<BR>&gt; namespace<BR>&gt;<BR>&gt; InteractiveHierarchicalSegmentationDotNet<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; public partial class TestForm : Form<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; public TestForm()<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; InitializeComponent();<BR>&gt;<BR>&gt; try<BR>&gt;<BR>&gt; {<BR>&gt;<BR>&gt; // Read ITK image<BR>&gt;<BR>&gt; itkImage_UC3 inputImage = itkImage_UC3.New();<BR>&gt;<BR>&gt; inputImage.Read(<BR>&gt;<BR>&gt; "C:/brain.tif");<BR>&gt;<BR>&gt;
 inputImage.DisconnectPipeline();<BR>&gt;<BR>&gt; // Import ITK image to VTK<BR>&gt;<BR>&gt; itkImageToVTKImageFilter itk2vtk =<BR>&gt;<BR>&gt; itkImageToVTKImageFilter.New(inputImage);<BR>&gt;<BR>&gt; itk2vtk.SetInput(inputImage);<BR>&gt;<BR>&gt; itk2vtk.Update();<BR>&gt;<BR>&gt; vtkImageData data = itk2vtk.GetOutput();<BR>&gt;<BR>&gt; vtkImageActor actor = new vtkImageActor();<BR>&gt;<BR>&gt; actor.SetInput(data);<BR>&gt;<BR>&gt; Console.WriteLine(actor.ToString());<BR>&gt;<BR>&gt; vtkRenderer vtkRenderer1 = new vtkRenderer();<BR>&gt;<BR>&gt; this.vtkFormsWindowControl1.GetRenderWindow().AddRenderer(vtkRenderer1);<BR>&gt;<BR>&gt; vtkRenderer1.AddActor(actor);<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; // define and display a path<BR>&gt;<BR>&gt; itkPoint origin = inputImage.Origin;<BR>&gt;<BR>&gt; itkSpacing spacing = inputImage.Spacing;<BR>&gt;<BR>&gt; itkSize size = inputImage.Size;<BR>&gt;<BR>&gt; itkPoint point = new itkPoint(3);<BR>&gt;<BR>&gt;
 itkPolyLineParametricPath_3 path = itkPolyLineParametricPath_3.New();<BR>&gt;<BR>&gt; point[0] = origin[0] + spacing[0] * size[0];<BR>&gt;<BR>&gt; point[1] = origin[1] + spacing[1] * size[1];<BR>&gt;<BR>&gt; //point[3] = origin[2] + spacing[2] * size[2];<BR>&gt;<BR>&gt; itkContinuousIndex cindex = new itkContinuousIndex(3);<BR>&gt;<BR>&gt; inputImage.TransformPhysicalPointToContinuousIndex(origin,<BR>&gt;<BR>&gt; out cindex);<BR>&gt;<BR>&gt; path.AddVertex(cindex);<BR>&gt;<BR>&gt; inputImage.TransformPhysicalPointToContinuousIndex(point,<BR>&gt;<BR>&gt; out cindex);<BR>&gt;<BR>&gt; path.AddVertex(cindex);<BR>&gt;<BR>&gt; itkPathToImageFilter_PLPP3IUC3 path2ImageFilter =<BR>&gt; itkPathToImageFilter_PLPP3IUC3.New();<BR>&gt;<BR>&gt; path2ImageFilter.SetInput(path);<BR>&gt;<BR>&gt; path2ImageFilter.PathValue = 200;<BR>&gt;<BR>&gt; path2ImageFilter.GetOutput(inputImage);<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt; catch (Exception ex)<BR>&gt;<BR>&gt;
 {<BR>&gt;<BR>&gt; Console.WriteLine(ex);<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt; }<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; I can send you the whole project if it helps.<BR>&gt;<BR>&gt;<BR>&gt;<BR>&gt; Cheers, Shaady<BR></DIV></DIV></DIV></DIV></DIV></div><br>



      <hr size=1> 
Not happy with your email address?
<br> <a href="http://uk.docs.yahoo.com/ymail/new.html"> Get the one you 

really want</a> - millions of new email addresses available now at <a 

href="http://uk.docs.yahoo.com/ymail/new.html"> Yahoo!</a></body></html>