# Difference between VTK widgets and 3D Slicer widgets

**URL:** <https://discourse.slicer.org/t/difference-between-vtk-widgets-and-3d-slicer-widgets/29916>\
**Category:** Development\
**Created:** [June 8, 2023, 11:03am UTC](https://discourse.slicer.org/t/difference-between-vtk-widgets-and-3d-slicer-widgets/29916 "2023-06-08T11:03:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mazurkin.daniel](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/mazurkin.daniel/32/66512_2.png) [@mazurkin.daniel](https://discourse.slicer.org/u/mazurkin.daniel)\
**Post date:** [June 8, 2023, 11:03am UTC](https://discourse.slicer.org/t/difference-between-vtk-widgets-and-3d-slicer-widgets/29916/1 "2023-06-08T11:03:15Z")

</div>

Hello, what’s the difference between VTK widgets and 3D Slicer widgets in terms of rendering? When trying to compile to wasm, the vtk widget is successfully displayed, when trying to get the widget from the 3D Slicer, WebGL gives errors with shaders. I try get LineWidget from VTK (success in web assembly) and 3D Slicer (not success in web assembly). Thanks in advance for your reply.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/5/f/5fcd15b9ae00db8a529b4d0bad2ec09c3719f546.png)  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/e/5/e578b99362a7726367ae354ab0c91377e0ba2430.jpeg)

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [June 16, 2023, 2:56pm UTC](https://discourse.slicer.org/t/difference-between-vtk-widgets-and-3d-slicer-widgets/29916/2 "2023-06-16T14:56:12Z")

</div>

The main difference is that Slicer widgets represent MRML nodes, while VTK widgets represent VTK objects.
