Skip to content

Commit 067bcaa

Browse files
committed
update doc
1 parent 4a50f92 commit 067bcaa

File tree

2 files changed

+52
-3
lines changed

2 files changed

+52
-3
lines changed

docs/REFERENCES.md

Lines changed: 49 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,15 @@
77
- [FieldData](#FieldData)
88
- [GeometryRepresentation](#GeometryRepresentation)
99
- [ImageData](#ImageData)
10+
- [Mesh](#Mesh)
1011
- [PointCloudRepresentation](#PointCloudRepresentation)
1112
- [PointData](#PointData)
1213
- [PolyData](#PolyData)
1314
- [Reader](#Reader)
1415
- [ShareDataSet](#ShareDataSet)
1516
- [SliceRepresentation](#SliceRepresentation)
1617
- [View](#View)
18+
- [Volume](#Volume)
1719
- [VolumeController](#VolumeController)
1820
- [VolumeDataRepresentation](#VolumeDataRepresentation)
1921
- [VolumeRepresentation](#VolumeRepresentation)
@@ -169,6 +171,27 @@ Keyword arguments:
169171
[Back to menu](#components-reference)
170172

171173

174+
## Mesh
175+
176+
```python
177+
dash_vtk.Mesh(id, port, state, **kwargs)
178+
```
179+
180+
A Mesh component.
181+
Mesh is exposing a vtkPolyData to a downstream filter
182+
It takes the following set of properties:
183+
- state: { mesh: { ...polydata-props }, field: { ...dataArray } }
184+
185+
Keyword arguments:
186+
- id (string; optional): The ID used to identify this component.
187+
- port (number; default 0): downstream connection port
188+
- state (dict; default {
189+
mesh: { points: [] },
190+
}): State of the mesh
191+
192+
[Back to menu](#components-reference)
193+
194+
172195
## PointCloudRepresentation
173196

174197
```python
@@ -321,7 +344,7 @@ Keyword arguments:
321344
## View
322345

323346
```python
324-
dash_vtk.View(children, id, background, interactorSettings, cameraPosition, cameraViewUp, cameraParallelProjection, **kwargs)
347+
dash_vtk.View(children, id, background, interactorSettings, cameraPosition, cameraViewUp, cameraParallelProjection, triggerRender, triggerResetCamera, **kwargs)
325348
```
326349

327350
A View component.
@@ -376,6 +399,29 @@ between 0-1 of Red, Green, Blue component.
376399
- cameraPosition (list; default [0, 0, 1]): Initial camera position from an object in [0,0,0]
377400
- cameraViewUp (list; default [0, 1, 0]): Initial camera position from an object in [0,0,0]
378401
- cameraParallelProjection (boolean; default False): Use parallel projection (default: false)
402+
- triggerRender (number; default 0): Property use to trigger a render when changing.
403+
- triggerResetCamera (number; default 0): Property use to trigger a resetCamera when changing.
404+
405+
[Back to menu](#components-reference)
406+
407+
408+
## Volume
409+
410+
```python
411+
dash_vtk.Volume(id, port, state, **kwargs)
412+
```
413+
414+
A Volume component.
415+
Volume is exposing a vtkImageData to a downstream filter
416+
It takes the following set of properties:
417+
- state: { image: { ...imagedata-props }, field: { ...dataArray } }
418+
419+
Keyword arguments:
420+
- id (string; optional): The ID used to identify this component.
421+
- port (number; default 0): downstream connection port
422+
- state (dict; default {
423+
image: { dimension: [10, 10, 10] },
424+
}): State of the volume
379425

380426
[Back to menu](#components-reference)
381427

@@ -400,7 +446,7 @@ Keyword arguments:
400446
## VolumeDataRepresentation
401447

402448
```python
403-
dash_vtk.VolumeDataRepresentation(dimensions, spacing, origin, rgb, rgba, scalars, scalarsType, mapper, volume, property, colorMapPreset, volumeController, controllerSize, rescaleColorMap, colorDataRange, **kwargs)
449+
dash_vtk.VolumeDataRepresentation(id, dimensions, spacing, origin, rgb, rgba, scalars, scalarsType, mapper, volume, property, colorMapPreset, volumeController, controllerSize, rescaleColorMap, colorDataRange, **kwargs)
404450
```
405451

406452
A VolumeDataRepresentation component.
@@ -414,6 +460,7 @@ VolumneDataRepresentation expect the following set of properties
414460
- scalarsType: Float32Array
415461

416462
Keyword arguments:
463+
- id (string; optional): The ID used to identify this component.
417464
- dimensions (list of numbers; optional): Number of points along x, y, z
418465
- spacing (list of numbers; optional): Spacing along x, y, z between points in world coordinates
419466
- origin (list of numbers; optional): World coordinate of the lower left corner of your vtkImageData (i=0, j=0, k=0).

docs/generate_references.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,15 @@ def create_signature(c, prefix='dash_vtk.'):
2222
dash_vtk.FieldData,
2323
dash_vtk.GeometryRepresentation,
2424
dash_vtk.ImageData,
25+
dash_vtk.Mesh,
2526
dash_vtk.PointCloudRepresentation,
2627
dash_vtk.PointData,
2728
dash_vtk.PolyData,
2829
dash_vtk.Reader,
2930
dash_vtk.ShareDataSet,
3031
dash_vtk.SliceRepresentation,
3132
dash_vtk.View,
33+
dash_vtk.Volume,
3234
dash_vtk.VolumeController,
3335
dash_vtk.VolumeDataRepresentation,
3436
dash_vtk.VolumeRepresentation
@@ -43,4 +45,4 @@ def create_signature(c, prefix='dash_vtk.'):
4345
f.write(f"\n## {c.__name__}\n\n")
4446
f.write(f"```python\n{create_signature(c)}\n```\n\n")
4547
f.write(c.__doc__ + '\n\n')
46-
f.write("[Back to menu](#components-reference)\n\n")
48+
f.write("[Back to menu](#components-reference)\n\n")

0 commit comments

Comments
 (0)