Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade itk vtk viewer and add switch widget tab #50

Draft
wants to merge 20 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog

**v0.1.40**
* Upgrade ITK/VTK viewer with multiscale pyramid support
* Allow instant stroke width change
* Import itk-vtk-viewer as a node module

**v0.1.34**
* Add `text_displacement`, and hide the labels by default
* Support customizing the style of the `selectButton`
Expand Down
12 changes: 12 additions & 0 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,20 @@ api.export(ImJoyPlugin())

Add an image layer

**Arguments**

- `image`: an image URL, base64 encoded image or a numpy array in Python
- options:
- `type`: String, image layer type, currently supports `2d-image`(OpenLayers 2D image layer), `itk-vtk` (ITK/VTK Viewer 2D/3D layer) or `vector`(OpenLayers vector feature layer).
- `name`: String, name of the image layer
**Returns**
A layer object with the following fields:
- `id`: String, the id of the layer
- `name`: String, the name of the layer
- `set_image`: Function, a function used to update the image in the layer
- `set_blending`: Function, a function used to update the blending model of the layer
- `set_opacity`: Function, a function used to update the opacity of the layer
- Other ITK/VTK Viewer functions defined at https://kitware.github.io/itk-vtk-viewer/api/ (Note: the function names should be converted from camel case to snake case, e.g. `setUnits` will become `set_units`)

Example in Python:

Expand Down Expand Up @@ -596,6 +606,8 @@ A simple wrapper to the `setTimeout` function in Javascript

A simple wrapper to the `clearTimeout` function in Javascript

### select_widget_tab(tab_index)
Activate a specific widget tab
## Example 1: Skin image annotation

The follow code block shows a simple example on annotating skin image with a form widget.
Expand Down
Loading