# Multiple graphics card rendering

**URL:** https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927
**Category:** Support
**Created:** [July 11, 2023, 7:41am UTC](https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927 "2023-07-11T07:41:06Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![kingui1106](https://discourse.vtk.org/user_avatar/discourse.vtk.org/kingui1106/32/3780_2.png) [@kingui1106](https://discourse.vtk.org/u/kingui1106)
#### Post date: [July 11, 2023, 7:41am UTC](https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927/1 "2023-07-11T07:41:06Z")

</div>

I have dynamic scene what I would like to render in a VTK window (QT, VC++ 2015 application). Objects in the scene are pointcoulds with hundreds of thousands points. Scene consists of:

- House (~800,000 points),
- Car (~700,000 points),
- Tree (~1,500,000 points).

Pointclouds are constantly generated at 30 fps in 3 separate threads. In the end all 3 pointclouds are merged in a 3 million pointcloud and rendered with a typical VTK code: vtkPoints → vtkPolyData -\>vtkPolyDataMapper → etc.

Problem is that performance is very poor and it hardly reaches 4 fps on my PC.

How can I parallelize rendering of separate data streams in a single VTK window? Multiple mappers? Multiple actors? vtkParallelRenderManager?  
Or use graphics cards from multiple machines and eventually render to a single window？  
Thanks！

---

<div class="post-metadata">

### Author: ![Paulo\_Carvalho](https://discourse.vtk.org/user_avatar/discourse.vtk.org/paulo_carvalho/32/370_2.png) [@Paulo\_Carvalho](https://discourse.vtk.org/u/Paulo_Carvalho)
#### Post date: [July 11, 2023, 10:55pm UTC](https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927/2 "2023-07-11T22:55:12Z")

</div>

Hello,

A naïve pipeline will never get high f.p.s. for millions of points, even for high-end graphics hardware. You have to use some large data management technique to achive that. You can test whether the `vtkMaskPoints` ([https://vtk.org/doc/nightly/html/classvtkMaskPoints.html](https://vtk.org/doc/nightly/html/classvtkMaskPoints.html)) filter can improve rendering performance. You can also reduce point count during interaction and render all the points only when the camera stands still. Another approach is to use multi-resolution actors (`vtkLODActor`).

take care,

PC

---

<div class="post-metadata">

### Author: ![kingui1106](https://discourse.vtk.org/user_avatar/discourse.vtk.org/kingui1106/32/3780_2.png) [@kingui1106](https://discourse.vtk.org/u/kingui1106)
#### Post date: [July 14, 2023, 2:02am UTC](https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927/4 "2023-07-14T02:02:28Z")

</div>

Is there a way to provide multiple machine rendering. Every machine has a graphics card. I want to give it a try.

Thank you very much!

---

<div class="post-metadata">

### Author: ![Paulo\_Carvalho](https://discourse.vtk.org/user_avatar/discourse.vtk.org/paulo_carvalho/32/370_2.png) [@Paulo\_Carvalho](https://discourse.vtk.org/u/Paulo_Carvalho)
#### Post date: [July 14, 2023, 2:13pm UTC](https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927/5 "2023-07-14T14:13:07Z")

</div>

You seem to have a performance problem with point cloud rendering. Multiple graphics cards rendering is a far-fetched approach when it comes to interactive graphics. There are smarter ways to improve performance which I pointed above.

Still, if you are quite very firmly sure that is the only absolute single one way to solve your issue, please refer to this: [Rendering on multiple GPUs? - #4 by jaswantp](https://discourse.vtk.org/t/rendering-on-multiple-gpus/837/4)

best,

PC

---

<div class="post-metadata">

### Author: ![Paulo\_Carvalho](https://discourse.vtk.org/user_avatar/discourse.vtk.org/paulo_carvalho/32/370_2.png) [@Paulo\_Carvalho](https://discourse.vtk.org/u/Paulo_Carvalho)
#### Post date: [July 14, 2023, 2:18pm UTC](https://discourse.vtk.org/t/multiple-graphics-card-rendering/11927/6 "2023-07-14T14:18:44Z")

</div>

A 30-60 f.p.s. of a few million points is perfectly doable in a single machine. You just have to scratch your head a little. Multiple node rendering for that figure is a quite inneficient solution. When I think rendering in a cluster I think of billions of elements.
