What i meant is you have defined _newPoints as a smartPointer in the constructor . Once the Constructor returns , the _newPoints is deallocated since it has gone out of scope. Hence you have a memory leak right there . If you had not defined _newPoints as a smartPointer it will work fine .<br>
<br>Regards<br>Darshan<br><br><div class="gmail_quote">On Sat, Apr 3, 2010 at 5:09 AM, Rakesh Patil <span dir="ltr"><<a href="mailto:rakeshthp@in.com">rakeshthp@in.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>Hi Darshan,<br><br>Thanks for your reply.. But what difference will it make if i initialize it in the constructor or in Update() function..?? I think it got to do something with the point ids... When i copy the cells from input grid to output grid, the point Ids might not be available i feel... <br>
<br>I'm struggling with how to solve this problem..<br><br>Any suggestions or comments..??<br><br>Thanks<br><br>Rakesh Patil<br><blockquote><br>---------- Original message ----------<br>From:Darshan Pai< <a href="mailto:darshanpai@gmail.com" target="_blank">darshanpai@gmail.com</a> ><br>
Date: 02 Apr 10 22:12:10<br>Subject: Re: [vtkusers] Filter to delete a cell/point doest show any change in render window<br>To: Rakesh Patil <br><br>Rakesh,<br><br>I did not run the program but I think your problem is the initialization of the _newPoints . I think you should initialize your _newPoints in the Update() function rather than in the constructor. Or do not define it as a smartpointer.<br>
<br>Regards<br>Darshan<br><br><div class="gmail_quote">On Fri, Apr 2, 2010 at 5:21 AM, Rakesh Patil <span dir="ltr"><<a href="mailto:rakeshthp@in.com" target="_blank">rakeshthp@in.com</a>></span> wrote:<br><font color="#000000"></font><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<font color="#000000">Hello users,<br><br>Here are the two files which i have written. The filters to remove points and cells from an unstructured grid. It accepts an unstructured grid as an input and returns new unstructured grid as an output..<br>
<br>When i check the number of points and number of cells of the output grid, it shows correctly.. But when i render the output grid, it gives error..<br><br>Can anyone find out the mistake?? should ids be in sequence while rendering..?? The logic is based on the example below<br>
<br><a href="http://www.vtk.org/Wiki/VTK/Examples/DeletePoint" target="_blank">http://www.vtk.org/Wiki/VTK/Examples/DeletePoint</a><br><br>Help, guidance from any of the seniors wil be appreciated<br><br>Thanks<br><br>Regards<br>
Rakesh Patil<br><br><br></font><div style="border-top: 1px dashed rgb(204, 204, 204); border-bottom: 1px dashed rgb(204, 204, 204); padding: 5px;"><font color="#000000"><a href="http://mail.in.com/mails/new_reg.php?utm_source=invite&utm_medium=outgoing" style="font: 13px arial; color: rgb(30, 86, 161);" target="_blank">Dear <b>vtkusers !</b> Get Yourself a cool, short <b>@in.com</b> Email ID now!</a></font></div>
<font color="#000000"><br>_______________________________________________<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 VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
<br></font></blockquote></div><br>
</blockquote> <br><br><div style="border-top: 1px dashed rgb(204, 204, 204); border-bottom: 1px dashed rgb(204, 204, 204); padding: 5px;"><a href="http://mail.in.com/mails/new_reg.php?utm_source=invite&utm_medium=outgoing" style="font: 13px arial; color: rgb(30, 86, 161); text-decoration: none;" target="_blank">Get Yourself a cool, short <b>@in.com</b> Email ID now!</a></div>
</blockquote></div><br>