You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+3-2Lines changed: 3 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -169,10 +169,11 @@ If called from inside a `jupyter` or `marimo` notebook, `mesh.show()` displays a
169
169
170
170
## Additional Notes
171
171
172
-
- Check out some cool stuff people have done in the [GitHub network](https://github.com/mikedh/trimesh/network/dependents)
173
-
- Generally API changes should have a one-year period of [printing a `warnings.DeprecationWarning`](https://trimesh.org/contributing.html#deprecations)unless it's not possible for some reason.
172
+
- Check out some cool stuff people have done in the [GitHub network](https://github.com/mikedh/trimesh/network/dependents).
173
+
- Generally `trimesh`API changes should have a one-year period of [printing a `warnings.DeprecationWarning`](https://trimesh.org/contributing.html#deprecations)although that's not always possible (i.e. the pyglet2 viewer rewrite that's been back-burnered for several years.)
174
174
- Docker containers are available on Docker Hub as [`trimesh/trimesh`](https://hub.docker.com/r/trimesh/trimesh/tags) and there's a [container guide](https://trimesh.org/docker.html) in the docs.
175
175
- If you're choosing which format to use, you may want to try [GLB](https://trimesh.org/formats.html) as a fast modern option.
Copy file name to clipboardExpand all lines: docs/content/formats.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,15 +6,15 @@ There's lots of mesh formats out there!
6
6
7
7
## Which Mesh Format Should I Use?
8
8
9
-
Quick recommendation: `GLB`. If you're looking for "the simplest possible format because I have to write an importer in another language" you should take a look at `OFF`.
9
+
Quick recommendation: `GLB`. If you're looking for "the simplest possible ASCII format because I have to write an importer in another language" you should take a look at `OFF`.
10
10
11
-
The GLTF is nice because it has a [well defined specification](https://github.com/KhronosGroup/glTF/tree/main/specification/2.0), supports most things people would want, and is very fast to load. The format has a JSON header which defines the layout of a binary blob, which allows the large arrays to be loaded with `numpy.frombuffer` which is extremely fast.
11
+
GLTF is nice because it has a [well defined specification](https://github.com/KhronosGroup/glTF/tree/main/specification/2.0), supports most things people would want, and is very fast to load. It's fast because the format has a small JSON header which defines the layout of a packed binary blob, so the arrays can be loaded with `numpy.frombuffer` which is extremely fast. As a counterpoint a format like `3MF` defines each vertex as an `<vertex><x>"1.0123312"</x> ...`, which is almost as far from fast as it is possible to get.
12
12
13
-
Wavefront `OBJ` is also widely used and supported across many tools, although it lacks a specification and has a slightly unusual internal data structure, which can lead to compatibility and indexing issues.
13
+
A very popular format is Wavefront `OBJ`. It's supported across many tools, although it lacks a specification and has an internal data structure that requires some pretty heavy conversion to the `trimesh` flat-array format which can lead to some confusion: for example `f 1/2/3 4/5/6 7//7 9/9/9` is a valid face. It's not a bad choice, but going with GLB is probably advisable in most cases.
14
14
15
15
## Supported Formats
16
16
17
-
No dependencies indicates a minimal install of just `trimesh` and `numpy` can load the format.
17
+
No dependencies indicates a minimal install of just `trimesh` and `numpy` can load the format. If you are working with the textures, images are handled using `pip install pillow`.
18
18
19
19
| Format | Dependencies | Notes |
20
20
| ------ | ------------ | ----- |
@@ -29,5 +29,5 @@ No dependencies indicates a minimal install of just `trimesh` and `numpy` can lo
29
29
|`STEP`/`STP`|`cascadio`| The only boundary representation format with open-source loaders available. `cascadio` uses OpenCASCADE to convert to GLB before loading. |
30
30
|`XAML`|`lxml`| Microsoft's 3D XAML format which exports from Solidworks |
31
31
|`DXF`|| AutoCAD's drawing format, we only support the ASCII version with 2D geometry. |
32
-
|`SVG`|| We import 2D paths as `trimesh.Path2D` from these, discarding pretty much all visual information other than the curves. |
32
+
|`SVG`|`svg.path`| We import 2D paths as `trimesh.Path2D` from these, discarding pretty much all visual information other than the curves. |
33
33
|`XYZ`|| Simple ASCII point cloud format with just one coordinate per line. |
0 commit comments