[vtkusers] Filter to delete a cell/point doesn't show any change in render window

Darshan Pai darshanpai at gmail.com
Sat Apr 3 16:02:55 EDT 2010


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 .

Regards
Darshan

On Sat, Apr 3, 2010 at 5:09 AM, Rakesh Patil <rakeshthp at in.com> wrote:

>
> Hi Darshan,
>
> 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...
>
> I'm struggling with how to solve this problem..
>
> Any suggestions or comments..??
>
> Thanks
>
> Rakesh Patil
>
>
> ---------- Original message ----------
> From:Darshan Pai< darshanpai at gmail.com >
> Date: 02 Apr 10 22:12:10
> Subject: Re: [vtkusers] Filter to delete a cell/point doest show any change
> in render window
> To: Rakesh Patil
>
> Rakesh,
>
> 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.
>
> Regards
> Darshan
>
> On Fri, Apr 2, 2010 at 5:21 AM, Rakesh Patil <rakeshthp at in.com> wrote:
>
>> Hello users,
>>
>> 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..
>>
>> 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..
>>
>> Can anyone find out the mistake?? should ids be in sequence while
>> rendering..?? The logic is based on the example below
>>
>> http://www.vtk.org/Wiki/VTK/Examples/DeletePoint
>>
>> Help, guidance from any of the seniors wil be appreciated
>>
>> Thanks
>>
>> Regards
>> Rakesh Patil
>>
>>
>> Dear *vtkusers !* Get Yourself a cool, short *@in.com* Email ID now!<http://mail.in.com/mails/new_reg.php?utm_source=invite&utm_medium=outgoing>
>>
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the VTK FAQ at:
>> http://www.vtk.org/Wiki/VTK_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.vtk.org/mailman/listinfo/vtkusers
>>
>>
>
>
> Get Yourself a cool, short *@in.com* Email ID now!<http://mail.in.com/mails/new_reg.php?utm_source=invite&utm_medium=outgoing>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100403/19751f26/attachment.htm>


More information about the vtkusers mailing list