# Difference between vtkViewProxy and vtkOpenGLRenderWindow

**URL:** https://discourse.vtk.org/t/difference-between-vtkviewproxy-and-vtkopenglrenderwindow/5585
**Category:** Web
**Created:** [April 19, 2021, 6:20pm UTC](https://discourse.vtk.org/t/difference-between-vtkviewproxy-and-vtkopenglrenderwindow/5585 "2021-04-19T18:20:30Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![joaomlap](https://discourse.vtk.org/user_avatar/discourse.vtk.org/joaomlap/32/3201_2.png) [@joaomlap](https://discourse.vtk.org/u/joaomlap)
#### Post date: [April 19, 2021, 6:20pm UTC](https://discourse.vtk.org/t/difference-between-vtkviewproxy-and-vtkopenglrenderwindow/5585/1 "2021-04-19T18:20:30Z")

</div>

Hi I have been following the tutorial ImageStream for VTK.js and I couldn’t get it to work because I got some errors with the renderWindow methods.  
So I started checking the code for `react-vtk-js` and `paraview-lite` to see what each project does for renderWindow and I noticed this difference. One uses vtkViewProxy and the other vtkOpenGLRenderWindow. I couldn’t find any explanation on why would I use one over the other. Could someone please help me understand? My ultimate goal would be to replicate the example for ImageStream.

---

<div class="post-metadata">

### Author: ![Sebastien\_Jourdain](https://discourse.vtk.org/user_avatar/discourse.vtk.org/sebastien_jourdain/32/100_2.png) [@Sebastien\_Jourdain](https://discourse.vtk.org/u/Sebastien_Jourdain)
#### Post date: [April 19, 2021, 6:52pm UTC](https://discourse.vtk.org/t/difference-between-vtkviewproxy-and-vtkopenglrenderwindow/5585/2 "2021-04-19T18:52:31Z")

</div>

vtkOpenGLRenderWindow is meant for letting vtk.js do the rendering using WebGL, while vtkRemoteView is for letting a server send an image to the client using the ImageStream mechanism.  
The vtkViewProxy is just a wrapping around RenderWindow/GLRenderWindow/Interactor/Style…  
In general, you can connect a vtkOpenGLRenderWindow to an ImageStream, but in that setup if you don’t plan to render any 3D locally, you can use a more light weight RW by using the vtkRemoteView.

You can find a better example than ParaViewLite for that remote view [here](https://github.com/Kitware/web-project-templates/tree/master/vue-vtkjs-pvw-template).

HTH,

Seb

---

<div class="post-metadata">

### Author: ![joaomlap](https://discourse.vtk.org/user_avatar/discourse.vtk.org/joaomlap/32/3201_2.png) [@joaomlap](https://discourse.vtk.org/u/joaomlap)
#### Post date: [April 19, 2021, 8:56pm UTC](https://discourse.vtk.org/t/difference-between-vtkviewproxy-and-vtkopenglrenderwindow/5585/3 "2021-04-19T20:56:53Z")

</div>

Thank you very much, it certainly helped! I managed to get a very weird rendering but it is working at least 🙂

Just leaving a note for anyone who might use React + VTK.JS/Paraview. You might want to have a look at [GitHub - thewtex/craco-vtk: A plugin for craco to use vtk.js with create-react-app](https://github.com/thewtex/craco-vtk), it worked out of the box for me.
