[Paraview] Connecting points with line

Andy Bauer andy.bauer at kitware.com
Tue Mar 18 14:45:57 EDT 2014


Hi Patrik,

Please keep the discussion on the mailing list so that everyone can
participate.

As for connecting points via a line cell, I don't think there's any filter
to do that since it would have to make an assumption about which points
should be connected by a line cell. To use my recommendation, after the
Table To Points filter, select the Programmable Filter, enter that text
into the Script entry widget and hit apply. What it does is connect the
first point to the second point, the second point to the third point, ...,
and finally the second to last point to the last point. If you have some
different way you want to connect the points you can change the script
yourself. Note though that this filter may not work as desired in parallel.

Andy


On Tue, Mar 18, 2014 at 2:22 PM, Patrik Blahuta <patrik.blahuta at gmail.com>wrote:

> Is there any posibility to do it through filters because im little noob in
> this program :(
>
>
> *S pozdravom / Kind regards,*
>
>
>
> *Patrik Blahuta*
>
>
> 2014-03-18 19:21 GMT+01:00 Andy Bauer <andy.bauer at kitware.com>:
>
> If you use the Programmable Filter you can connect the points with the
>> following script:
>> pdi = self.GetPolyDataInput()
>> pdo =  self.GetPolyDataOutput()
>> numPoints = pdi.GetNumberOfPoints()
>> pdo.Allocate()
>> for i in range(0, numPoints-1):
>>     points = [i, i+1]
>>     # VTK_LINE is 3
>>     pdo.InsertNextCell(3, 2, points)
>>
>>
>>
>> On Tue, Mar 18, 2014 at 2:10 PM, Patrik Blahuta <patrik.blahuta at gmail.com
>> > wrote:
>>
>>> Hello,
>>>
>>> I am new using the paraview software. I would like to ask if you can help me with connecting points with line. I opened my .csv file and made table to points. That just shown me points in 3D view. Can you give me please tutor how to connect them?
>>>
>>>
>>> Thanks
>>>
>>>
>>> *Kind regards,*
>>>
>>>
>>>
>>> *Patrik*
>>>
>>> _______________________________________________
>>> 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 ParaView Wiki at:
>>> http://paraview.org/Wiki/ParaView
>>>
>>> Follow this link to subscribe/unsubscribe:
>>> http://www.paraview.org/mailman/listinfo/paraview
>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20140318/f8a3903e/attachment.html>


More information about the ParaView mailing list