# Can I avoid adding duplicate cells to a vtkPolyData?

**URL:** https://discourse.vtk.org/t/can-i-avoid-adding-duplicate-cells-to-a-vtkpolydata/12483
**Category:** Support
**Created:** [October 13, 2023, 1:05pm UTC](https://discourse.vtk.org/t/can-i-avoid-adding-duplicate-cells-to-a-vtkpolydata/12483 "2023-10-13T13:05:47Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![spyridon97](https://discourse.vtk.org/user_avatar/discourse.vtk.org/spyridon97/32/7069_2.png) [@spyridon97](https://discourse.vtk.org/u/spyridon97)
#### Post date: [October 13, 2023, 8:20pm UTC](https://discourse.vtk.org/t/can-i-avoid-adding-duplicate-cells-to-a-vtkpolydata/12483/2 "2023-10-13T20:20:20Z")

</div>

As of now, this is not possible unless you parse all the existing faces already present.

I have implemented a new data structure in VTK named vtkStaticFaceHashLinksTemplate, which vtkGeometryFilter uses to get the external faces. I am envisioning that it could also be used for extracting the internal faces of a mesh, along with internal and external together, which is what you need. I don’t know when I will have some time to work on it, but I hope it will be soon.

---

_[View the full topic](https://discourse.vtk.org/t/can-i-avoid-adding-duplicate-cells-to-a-vtkpolydata/12483)._
