# Draw Cylinder & Curved Shapes in VTKUnStructuredGrid

**URL:** https://discourse.vtk.org/t/draw-cylinder-curved-shapes-in-vtkunstructuredgrid/11954
**Category:** Support
**Tags:** python, code, proposal, file-formats
**Created:** [July 17, 2023, 6:25am UTC](https://discourse.vtk.org/t/draw-cylinder-curved-shapes-in-vtkunstructuredgrid/11954 "2023-07-17T06:25:54Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![anshakeel](https://discourse.vtk.org/user_avatar/discourse.vtk.org/anshakeel/32/7459_2.png) [@anshakeel](https://discourse.vtk.org/u/anshakeel)
#### Post date: [July 17, 2023, 6:25am UTC](https://discourse.vtk.org/t/draw-cylinder-curved-shapes-in-vtkunstructuredgrid/11954/1 "2023-07-17T06:25:55Z")

</div>

Hello Everyone,

**Q1:** I’m trying to generate VTK data. I have some Data that have cylindrical shapes like pipes and bends. I would like to convert them to VTK format. To achieve this, I am using VtkUnstructuredGrid.I searched thoroughly online for information on using CylinderSource in VtkUnstructuredGrid, but I could not find any helpful resources. I utilized VTK\_POLYHEDRON to transform the problem into a cylindrical shape, but the results were not up to par with my expectations. The shape requires further enhancement to attain a more accurate cylindrical appearance.

Please check the attached Image below:  
 ![image](https://discourse.vtk.org/uploads/default/original/2X/8/8c4d4e9c4a91400976c8e9da5a932d5972d49532.png)

Note: For this, I only had 2 Points as Starting and Ending. I generated 12 Points in a Circular manner with a specified radius for both starting and ending points and Joined them, forming a 14-faced PolyHedron shape.

**Q2:** How to Draw Bend in VtkUnstructuredGrid if we have 3 Points as Starting, Mid and ending points?

If you have any suggestions or information regarding this, please guide me.

Regards,  
Ans
