<div>Hi,</div>It is better to return smartpointers over regular pointers?<div><br></div><div>Regards<br><br><div class="gmail_quote">On Thu, Jun 7, 2012 at 2:39 PM, David Doria <span dir="ltr"><<a href="mailto:daviddoria@gmail.com" target="_blank">daviddoria@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">> MeshType::Pointer mesh = MeshType::New();<br>
><br>
><br>
> So, how should I declate the mesh type in the header?<br>
><br>
> Thanks<br>
><br>
> Jothy<br>
<br>
<br>
</div>MeshType* vtkMeshToITKMesh(vtkPolyData* vtkMesh);<br>
<br>
or<br>
<br>
MeshType::Pointer vtkMeshToITKMesh(vtkPolyData* vtkMesh);<br>
<br>
depending on how you allocate it in the function.<br>
<br>
David<br>
<div class="im">_____________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at<br>
<a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
</div>Kitware offers ITK Training Courses, for more information visit:<br>
<a href="http://www.kitware.com/products/protraining.php" target="_blank">http://www.kitware.com/products/protraining.php</a><br>
<br>
Please keep messages on-topic and check the ITK FAQ at:<br>
<a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
<div class="im"><br>
Follow this link to subscribe/unsubscribe:<br>
</div><a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Sergio Vera<br><br> Alma IT Systems<br> C/ Vilana, 4B, 4º 1ª<br> 08022 Barcelona<br> T. (+34) 932 380 592<br> <a href="http://www.alma3d.com">www.alma3d.com</a><br>
</div>