# Example of vtkProgrammableGlyphFilter in Python

**URL:** https://discourse.vtk.org/t/example-of-vtkprogrammableglyphfilter-in-python/6926
**Category:** Support
**Created:** [October 20, 2021, 10:03pm UTC](https://discourse.vtk.org/t/example-of-vtkprogrammableglyphfilter-in-python/6926 "2021-10-20T22:03:29Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![woodscn](https://discourse.vtk.org/user_avatar/discourse.vtk.org/woodscn/32/1738_2.png) [@woodscn](https://discourse.vtk.org/u/woodscn)
#### Post date: [October 20, 2021, 10:03pm UTC](https://discourse.vtk.org/t/example-of-vtkprogrammableglyphfilter-in-python/6926/1 "2021-10-20T22:03:29Z")

</div>

Is it possible to provide an example of vtkProgrammableGlyphFilter in Python? I’m not sure how to handle the void function pointer.

---

<div class="post-metadata">

### Author: ![amaclean](https://discourse.vtk.org/user_avatar/discourse.vtk.org/amaclean/32/224_2.png) [@amaclean](https://discourse.vtk.org/u/amaclean)
#### Post date: [October 22, 2021, 4:58am UTC](https://discourse.vtk.org/t/example-of-vtkprogrammableglyphfilter-in-python/6926/2 "2021-10-22T04:58:14Z")

</div>

I have just created an example based on the C++ version. Please see [ProgrammableGlyphFilter](https://kitware.github.io/vtk-examples/site/Python/Visualization/ProgrammableGlyphFilter/).

Essentially you just create an observer and define a ` __call__ ` method. Also the class is initialised with the `vtkProgrammableGlyphFilter` via the ` __init__ ()` method so there is no need to check for existence etc.

Also [ProgrammableGlyphs](https://kitware.github.io/vtk-examples/site/Python/Visualization/ProgrammableGlyphs/) may be of use.
