Skip to content

Commit

Permalink
Merge pull request #18 from Kitware/fix-camera-orientation-widget-exa…
Browse files Browse the repository at this point in the history
…mple

Fix camera orientation widget example
  • Loading branch information
jourdain authored Dec 5, 2024
2 parents 3967f11 + d2eb35c commit a6f1d12
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ Running examples
# We need a VTK that has its wasm counterpart
# This is the first version available with it
# For ParaView (not yet supported), VTK don't need to be installed
pip install "vtk==9.3.20240810.dev0" --extra-index-url https://wheels.vtk.org
pip install "vtk==9.4.20241123.dev0" --extra-index-url https://wheels.vtk.org
# regular trame app
python ./examples/vtk/cone.py
Expand Down
5 changes: 3 additions & 2 deletions examples/vtk/widgets_camera.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def create_vtk_pipeline(path):

ren_win.Render()

return ren_win
return ren_win, cam_orient_manipulator


# -----------------------------------------------------------------------------
Expand All @@ -82,7 +82,7 @@ def __init__(self, server=None):

self.server.cli.add_argument("--data")
args, _ = self.server.cli.parse_known_args()
self.render_window = create_vtk_pipeline(args.data)
self.render_window, self.widget = create_vtk_pipeline(args.data)
self.html_view = None
self.ui = self._ui()

Expand All @@ -94,6 +94,7 @@ def _ui(self):
):
if WASM:
self.html_view = vtklocal.LocalView(self.render_window)
self.widget_id = self.html_view.register_widget(self.widget)
else:
self.html_view = vtk_widgets.VtkRemoteView(self.render_window)

Expand Down
2 changes: 1 addition & 1 deletion utils/build_vtk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ case "$build_target" in
-DBUILD_SHARED_LIBS=OFF \
-DVTK_WRAP_SERIALIZATION=ON \
-DVTK_BUILD_TESTING=ON \
-DVTK_ENABLE_LOGGING=OFF \
-DVTK_ENABLE_LOGGING=ON \
-DVTK_BUILD_EXAMPLES=OFF \
-DVTK_MODULE_ENABLE_VTK_RenderingLICOpenGL2=NO

Expand Down

0 comments on commit a6f1d12

Please sign in to comment.