# How to retrieve the renderer from a server-side Python's plugin

**URL:** https://discourse.paraview.org/t/how-to-retrieve-the-renderer-from-a-server-side-pythons-plugin/17030
**Category:** ParaView Support
**Tags:** python, vtk
**Created:** [July 31, 2025, 6:49am UTC](https://discourse.paraview.org/t/how-to-retrieve-the-renderer-from-a-server-side-pythons-plugin/17030 "2025-07-31T06:49:40Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![florezg](https://discourse.paraview.org/user_avatar/discourse.paraview.org/florezg/32/15983_2.png) [@florezg](https://discourse.paraview.org/u/florezg)
#### Post date: [July 31, 2025, 6:49am UTC](https://discourse.paraview.org/t/how-to-retrieve-the-renderer-from-a-server-side-pythons-plugin/17030/1 "2025-07-31T06:49:40Z")

</div>

To render VTK objects in top of default ones, like vtkPolyData, vtkUnstructuredGrid, etc., you need to get both the active view and then the respective renderer to attach a VTK actor to that display or viewport. To do so we often rely on the “simple” module, for instance:

# Sample helper class.

class ParaviewHelper:

```
@staticmethod
def GetActiveOrRenderView():
    from paraview.simple import GetActiveView, GetRenderView
    # Empty once loaded from session file?
    active_view = GetActiveView() 
    if active_view != None:
         return active_view
    # Empty once loaded from session file?
    return GetRenderView()

@staticmethod
def GetActiveRenderer():
    active_view = GPParaviewHelper.GetActiveOrRenderView()
    return active_view.GetRenderer() if active_view != None else None

```

We need to create a VTK actor to render “names” (strings) in 3-D as texture mappings via well-know mapper approach. However, it is illegal to call the “paraview.simple” module on a server, i.e., distributed plugin, because Paraview crashes. It seems that such API is not available on the server side. That said, I wonder how can I get the renderer from the plugin slot “RequestData” or executive object. Any hints about how this feature can be accomplished?

Thanks in advance,  
Horacio Florez.

---

<div class="post-metadata">

### Author: ![nenad-vujicic](https://discourse.paraview.org/user_avatar/discourse.paraview.org/nenad-vujicic/32/1969_2.png) [@nenad-vujicic](https://discourse.paraview.org/u/nenad-vujicic)
#### Post date: [July 31, 2025, 12:31pm UTC](https://discourse.paraview.org/t/how-to-retrieve-the-renderer-from-a-server-side-pythons-plugin/17030/2 "2025-07-31T12:31:23Z")

</div>

I think there is no legal way for this (let others correct me) because you don’t have guarantee that calculations (your server-side python’s plugin) and renderings will execute on same machine, right?

But, perhaps you could generate inside of your server-side plugin some meta-data which you can use to generate “names” (strings) on client side?

---

<div class="post-metadata">

### Author: ![florezg](https://discourse.paraview.org/user_avatar/discourse.paraview.org/florezg/32/15983_2.png) [@florezg](https://discourse.paraview.org/u/florezg)
#### Post date: [July 31, 2025, 1:11pm UTC](https://discourse.paraview.org/t/how-to-retrieve-the-renderer-from-a-server-side-pythons-plugin/17030/3 "2025-07-31T13:11:54Z")

</div>

It is a good point, thanks! However, I have observed that it is also illegal to combine server and client side plugins. I agree; there should be a way for Paraview to do the texture mapping and render captions at 3-D points through a multi-block dataset or annotation of some sort. Perhaps, that is the work-around. Best.
