Vedo

Latest version: v2024.5.2

Safety actively analyzes 682244 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 4 of 10

2021.0.3

Main changes

- General improvements to the `vedo` command line
- `colorcet` [colormaps](https://colorcet.holoviz.org) are directly usable in `vedo`.
Check example `basic/mesh_custom.py`

- general tool for free-hand cutting a mesh can be invoked from command line:
`vedo --edit https://vedo.embl.es/examples/data/porsche.ply`

- added example search by command line e.g.:
`vedo --search triangle -i` (`-i` to ignore capital letters)

- added file(s) info dump by command line e.g.:
`vedo --info some_image.jpg https://vedo.embl.es/examples/data/porsche.ply`

- pressing `shift-A` toggles antialiasing for the whole rendering window
- pressing `shift-D` toggles depth-peeling algorithm for the current renderer

- antialiasing set by default on vtk9
- balloon-style flags are disabled because of a bug in vtk9

**Consider installing VTK 8.1.2 for better visualisations when possible (unfortunately this slightly older version is no more available for python >=3.8)**

---
`base.py`
- corrected bug on `diagonalSize()` returning a wrong value

---
`addons.py`
- added `addSplineTool()` to interactively spline points in space
- added `labelRotation` in addScalarBar3D
- added `xShiftAlongY` keywords in `Axes` to slide the whole axis position along another axis
- added `xAxisRotation` to rotate the whole axis (ticks and labels)
- `addScalarBar3D()` can now render categorical data



---
`colors.py`
- fixed small issue in `printc` to support different terminals

---
`mesh.py`
- `computeNormals()` is no more changing the nr of mesh points unless `featureAngle` is specified
- added keywords: `featureAngle=None, consistency=True`
- `intersectWithLine()` can now return cell ids, not just points

---
`plotter.py`
- improved automatic text management in `show("some text")`
- added `computeWorldPosition(point2d)` to get the 3d point in the scene from a screen 2d point
- added `addSplineTool()` to interactively spline points in space
- small fix in `plotter.add()` for offscreen mode.
- added `topicture()` to render a scene into a `Picture` object (to crop, mirror etc)

---
`picture.py`
- added FFT and RFFT, added example `fft2d.py`
- can save `Picture` obj to file as jpg or png

---
`pointcloud.py`
- added `cutWithBox()`, `cutWithLine()`, `cutWithSphere()` and `cutWithCylinder()` methods

---
`shapes.py`
- fixed small bug in `Glyph`

---
`volume.py`
- added class `VolumeSlice` for volume-sliced visualization.

---
`utils.py`
- added `roundToDigit(x,p)`, round number x to significant digit


-------------------------

New/Revised examples:
- `vedo -r koch_fractal`
- `vedo -r mesh_custom`
- `vedo -r fft2d`
- `vedo -r lines_intersect`
- `vedo -r cutFreeHand`
- `vedo -r spline_tool`
- `vedo -r legendbox`
- `vedo -r read_volume3`
- `vedo -r multi_viewer2`

2021.0.2

A new web page is avaialble! check it out at [https://vedo.embl.es](https://vedo.embl.es)

- python2 is no more supported
- A dangerous bug in `mesh.closestPoint(returnIds=True)` has been fixed
- Added interfaces and examples to libraries [iminuit](https://github.com/scikit-hep/iminuit)
and [pymeshlab](https://github.com/cnr-isti-vclab/PyMeshLab)
- variable `datadir` changed to `dataurl`
- added `ipyvtk_simple` option for notebooks rendering


---
`base.py`
- method `addPos()` (obsolete but still valid) renamed to `shift()`
- added shortcut to input the opacity with syntax `mesh.color("blue", 0.5)`
- arrays with name "Normals" are set as active normals automatically ( theponpon )
- added keyword invert in `getTransform()` ( Tai-Hsien )
- added `deleteCells()` method

---
`addons.py`
- added mesh cutter with planes and spheres in addition to boxes ( nantille )
- major revision of the `Axes` class. with new added feature like axes inversion, free rotations
- keyword `xFlipText` disappeared as is now substituted by `xLabelRotation`
- Added `xyShift` to shift the whole cartesian plane along one axis ( JGarrett7 )
- Axes can be flipped with their range with `xInverted` (caveat: this does not at all affect the world coordinate system!)
- new class `LegendBox` to show a legend with icons

---
`colors.py`
- `vedo` is now independent of matplotlib for colormaps
- added new bootstrap5 [color scheme](https://user-images.githubusercontent.com/98681/84801339-e5585680-afb3-11ea-8743-29647ff3f3a9.png)
(e.g. `c='red1', 'red2', ..., 'red9'`, or in short: `c='r1', 'r2', ..., 'r9'`)
Lower index means darker.
- added `rgb2hex()` and `hex2rgb()` functions
- fixed bug on `printc()` and added `settings.enablePrintColor`. 337

---
`mesh.py`
- fixed bug in `splitByConnectivity()` ( jsanchez679 )
- added method `addConnectivity()` to add a connectivity array to mesh points
- added method `isClosed()` ti return if mesh is watertight (no holes)

---
`plotter.py`
- improved `resetcam` behaviour
- passing camera no more empties the passed dictionary (thanks icemtel )
- `verbose` keyword has been removed (as hard to maintain)
- mouse clicking can now pick `Picture` not only `Mesh`
- revised and improved callback functionality with `plotter.addCallback()`
(see examples `mousehighlight`, `mousehover`)
- new way of creating a callback loop with a timer (thanks nantille - see examples `timer_callback`)

---
`picture.py`
- attribute `picture.shape` holds the shape of the picture in pixels
- added `gif` file reader to return a list of `Picture` objs.
- added `clone()` method.

---
`pointcloud.py`
- added `fitCircle()` to fit a circle to a line in 3D.
- added a revision of `self.densify()`. Removed `densifyCloud()`. 338


---
`pyplot.py`
- a brand new function `fit()` to perform polynomial fitting to data with error bars in both x and y with correct estimation of error bands via bootstrap method (there are out there soo many wrong scripts in matplotlib!)
- added `pyplot.matrix()` to plot numpy matrices (eg. correlation/covariance matrix)
- various minor fixes

---
`shapes.py`
- `Spline` can control the *easing*, the density of points along the line.
- support for closed splines.
- `Text2D` completely rewritten. Can now update it after creation (e.g. `mytxt.text("test").color("g")`)

---
`volume.py`
- added `volume.shade()` which can be `True` or `False`. Disable by default (was previously enabled)
to be used in conjunction with `volume.lighting()` to create a mesh-like rendering of the volume.
(thanks to nantille for debugging)
- fixed example `interpolateVolume` (thanks rafaelmarch3 )


New/Revised examples:
- `vedo -r colorcubes`
- `vedo -r cutter`
- `vedo -r spline_ease`
- `vedo -r gyroid`
- `vedo -r align6`
- `vedo -r colormap_list`
- `vedo -r bloch`
- `vedo -r slicePlane1`
- `vedo -r slicePlane2`
- `vedo -r pygmsh_cut`

- `vedo -r mousehighlight`
- `vedo -r mousehover`
- `vedo -r line2mesh_quads`
- `vedo -r line2mesh_tri`
- `vedo -r pointsCutMesh2`

- `vedo -r hoverLegend`

- `vedo -r iminuit`
- `vedo -r pymeshlab1`

- `vedo -r timer_callback1`
- `vedo -r timer_callback2`

- `vedo -r fitCircle`
- `vedo -r anim_lines`
- `vedo -r earthquake_browser`
- `vedo -r np_matrix`
- `vedo -r customAxes2`
- `vedo -r customAxes3`
- `vedo -r glyphs3`
- `vedo -r fitPolynomial1`
- `vedo -r fitPolynomial2`
- `vedo -r histo_gauss`
- `vedo -r plot_polar`
- `vedo -r densifycloud`
- `vedo -r interpolateVolume`

2020.4.2

Main changes

- Removed restriction VTK<9. Even so, VTK9 seems significantly slower and unexpected behaviors are still possible.

- Various minor issues have been fixed.

---
addons.py:

- name change `addLight()` -> `Light()`. Improved API. Revised example `basic/lights.py`
(thanks to mit10000 and theponpon input 249)
- added size keyword for `addScalarBar()` to control size in pixels (RubendeBruin 237)


---
io.py:

- added default bitrate specification `Video.options="-b:v 8000k"` (for `ffmpeg`)
seems to produce much better quality results - tested on linux system only.

---
plotter.py:

- modified plotter.addLight()
- added warning to non-existing camera keywords (FedeClaudi 244)
- In rendering window:
- pressing `3` cycles over predefined set of textures for clicked Mesh objects
- pressing `I` picks the color under the mouse (uses `colors.pickColor()`)


---
shapes.py:

- added class `Brace` (see example scatter3.py)
- can `sweep()` a `Line` object to create a surface


New/Revised examples:

`vedo -r rgbaImage`
`vedo -r cutWithMesh2`
`vedo -r scatter3`
`vedo -r lights`
`vedo -r plot_density4d` (thanks to edmontz)
`vedo -r app_raycaster`
`vedo -r app_isobrowser`

2020.4.1

- Fixed `pip` problem (hopefully solving issue 185 raised by RizzerOnGitHub)
- Typo in readme fixed (thanks to danielhrisca)
- Global variable `settings.collectable_actors` is now obsolete and void.
- Various minor issues have been fixed too.

---

addons.py:
- `buildAxes()` now admits a header title
- `addScalarBar3D()` returns `self`, use self.scalarbar to access the scalarbar
object (e.g for scaling, rotating and repositioning it)
- `makeLUT()` renamed to `buildLUT()` with new examples, which includes
indicators for NaN's and out of scale values:

![](https://user-images.githubusercontent.com/32848391/95255899-5c934e00-0822-11eb-9b07-fc3f31e2b6da.png)

---
base.py:
- `setTransform()` -> `applyTransform()` accepts now a python or numpy matrix
(thanks to FedeClaudi input)
- added removePointArray() and removeCellArray() methods
- added `divergence()`, `vorticity()` methods
- added `removePointArray()` and `removeCellArray()` methods (thanks to Tai-Hsien input)

---
colors.py:
- added `ask()` method to prompt user input from command line
- added `printc(dbg=1)` mode to help debugging

---
io.py:
- `load()` method can load and return normal npy or npz numpy data files

---
mesh.py:
- `clone(deep=True)`, `deep` can be False to generate a shallow copy of the obj.

---
picture.py:
- `polygonize()`, create a polygonal Mesh from a Picture by filling regions
above a specified threshold

---
plotter.py:
- `flyTo()`, fly camera to the specified point.
- `export()`, to export scene.npz

---
pointscloud.py
- `interpolateDataFrom()`, Interpolate over source to port its data
onto the current object using various kernels.

---
pyplot.py:
- removed directedgraph.clean() because it's just wrong (might marginally affect DeepaMahm)
- added `whisker()` function to generate [whisker-style plots](https://github.com/marcomusy/vedo/blob/master/examples/pyplot/whiskers.py)

![](https://user-images.githubusercontent.com/32848391/95772479-170cd000-0cbd-11eb-98c4-20c5ca342cb8.png)

---
shapes.py:
- added `CSpline` class, to generate a Cardinal Spline object.

---

New examples:
`vedo -r interpolateMeshArray`
`vedo -r interpolateScalar1`
`vedo -r spline_draw`
`vedo -r mesh_lut`
`vedo -r whiskers`

2020.4.0

**Main changes**
- mesh and volume data is moved from the package to vedo.embl.es/examples/data
https://vedo.embl.es/examples/data/
they are downloaded on the fly and cached
- 14 new polygonized 3D fonts are available, making the old vtk default obsolete
Font: Bongas
Font: Calco
Font: Comae
Font: Glasgo
Font: Inversionz
Font: Kanopus
Font: LionelOfParis
Font: LogoType (supports Russian, Japanese and Chinese chars)
Font: Normografo
Font: Quikhand
Font: SmartCouric
Font: Theemim
Font: VictorMono

Default font is *Normografo*, can be changed with e.g.
`settings.useDefaultFont = "Theemim"`

![](https://user-images.githubusercontent.com/32848391/90966829-9bba4980-e4d7-11ea-9ec8-23bac4b7448e.png)

![](https://user-images.githubusercontent.com/32848391/90437540-dd5f8480-e0d2-11ea-8ddc-8839688979d0.png)

Latex-like syntax is supported in `Text()` allowing to use Greek and math symbols in axes and plot titles:
Type `vedo -r fonts` to generate the above tables.

**addons**:
- `Ruler()`: create a 3D ruler to indicate the distance of two points
- `buildRulerAxes()`: a new axis style (7) formed by 3 rulers
![](https://user-images.githubusercontent.com/32848391/90437544-dd5f8480-e0d2-11ea-8321-b52d073444c4.png)
- many improvements to default axis style 1
- New axis style 11: generates a thin lined square floor

**Plotter**:
- `show(..., newplotter=True)` -> `show(..., new=True)`
- added methods: `render(), resetCamera()` and `backgroundColor(c1, c2, at)`
- can now change transparency using arrow keys instead of "m,./"
Pressing -+ cycles through available axes styles.

**utils**:
- added `resampleArrays()`
- `systemReport()`
- class dotdict: A dictionary supporting dot notation.
- `trimesh2vtk()` -> `trimesh2vedo()` (check YimingXu1213)
- `vtk2trimesh()` -> `vedo2trimesh()`

**io**:
- can now save and load object transformation to .mat file

**mesh** and **pointclouds**:
- coloring with `pointColors()` and `cellColors()` is merged into method `cmap()`
- meshes can be described by new `vignette()` and `caption()`
![](https://user-images.githubusercontent.com/32848391/90437536-dc2e5780-e0d2-11ea-8951-f905ffb54f54.png)
- `useBounds()` tells the camera to keep inot account mesh when resetting
- added `gradient()` to return the gradient of the input scalar as numpy array

**shapes**:
- `convexHull()` -> `ConvexHull()`
- added `VedoLogo()` to generate the 3D logo of the package
- major improvements to `Text()`

**examples**:
- new or updated examples are:
`vedo -r isolines`
`vedo -r silhouette2` (thanks to zhouzq-thu )
`vedo -r meshquality `
`vedo -r mesh_smoother2`
`vedo -r vpolyscope` (needs pip install polyscope)
`vedo -r flag_labels`
`vedo -r customAxes`
`vedo -r fonts3d`
`vedo -r scatter2`
`vedo -r scatter3`
`vedo -r covid19`
`vedo -r caption`

2020.3.4

Various improvements
- new examples:
`vedo -r multi_viewer`
`vedo -r clone2d`
`vedo -r plot_density`
- read files and scenes from dropbox and/or web links
- `vtkio.py` moved to `io.py`
- fixed bug jsanchez679 in `cutWithMesh()`
- `mesh.normalize()` does not shift to origin the mesh anymore
- improved axes=10 and axes=5 customization
- requires vtk<=8.1.2 as vtk-9 seems to have a lot of issues

Page 4 of 10

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.