git: 65b2a687cce3 - main - graphics/py-trimesh: New port: Python library for loading and using triangular meshes
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 24 Oct 2026 20:58:19 UTC
The branch main has been updated by yuri:
URL: https://cgit.FreeBSD.org/ports/commit/?id=65b2a687cce3ac3a21b6569bb707eb9757297825
commit 65b2a687cce3ac3a21b6569bb707eb9757297825
Author: Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2026-10-23 06:35:02 +0000
Commit: Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2026-10-24 20:14:35 +0000
graphics/py-trimesh: New port: Python library for loading and using triangular meshes
PR: 299667
Approved by: no need for approval according to bapt@
---
graphics/Makefile | 1 +
graphics/py-trimesh/Makefile | 56 +++++++++++++++++++++++++++++++++++++++++++
graphics/py-trimesh/distinfo | 3 +++
graphics/py-trimesh/pkg-descr | 5 ++++
4 files changed, 65 insertions(+)
diff --git a/graphics/Makefile b/graphics/Makefile
index 33a95ade0794..6c9b84a180d4 100644
--- a/graphics/Makefile
+++ b/graphics/Makefile
@@ -1090,6 +1090,7 @@
SUBDIR += py-tkcolorpicker
SUBDIR += py-toyplot
SUBDIR += py-traitsui
+ SUBDIR += py-trimesh
SUBDIR += py-ueberzug
SUBDIR += py-urbanaccess
SUBDIR += py-urbansim
diff --git a/graphics/py-trimesh/Makefile b/graphics/py-trimesh/Makefile
new file mode 100644
index 000000000000..ed4113e479c6
--- /dev/null
+++ b/graphics/py-trimesh/Makefile
@@ -0,0 +1,56 @@
+PORTNAME= trimesh
+DISTVERSION= 5.1.1
+CATEGORIES= graphics python
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= yuri@FreeBSD.org
+COMMENT= Python library for loading and using triangular meshes
+WWW= https://trimesh.org/ \
+ https://github.com/mikedh/trimesh
+
+LICENSE= MIT
+LICENSE_FILE= ${WRKSRC}/LICENSE.md
+
+BUILD_DEPENDS= ${PY_SETUPTOOLS} \
+ ${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR}
+RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}numpy>=1.21:math/py-numpy@${PY_FLAVOR}
+TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}charset-normalizer>0:textproc/py-charset-normalizer@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}colorlog>0:devel/py-colorlog@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}httpx>0:www/py-httpx@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}jsonschema>0:devel/py-jsonschema@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}lxml>0:devel/py-lxml@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}mapbox-earcut>=1.0.2:math/py-mapbox-earcut@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}networkx>0:math/py-networkx@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}pillow>0:graphics/py-pillow@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}pycollada>0:graphics/py-pycollada@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}pytest-xdist>0:devel/py-pytest-xdist@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}rtree>0:devel/py-rtree@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}scipy>0:science/py-scipy@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}shapely>0:devel/py-shapely@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}xxhash>0:devel/py-xxhash@${PY_FLAVOR}
+
+USES= python
+USE_PYTHON= pep517 autoplist pytest
+
+USE_GITHUB= yes
+GH_ACCOUNT= mikedh
+
+NO_ARCH= yes
+
+# skipped tests need unavailable optional modules (pyinstrument, manifold3d, a working svg.path, matplotlib),
+# test_obb_mesh_large is a timing test that fails on slow machines
+TEST_ARGS= --disable-plugin-autoload \
+ -p xdist -n 8 \
+ --ignore=tests/test_svg.py \
+ --ignore=tests/test_sweep.py \
+ --deselect=tests/test_bounds.py::BoundsTest::test_obb_mesh_large \
+ --deselect=tests/test_meta.py::MetaTest::test_svg \
+ --deselect=tests/test_paths.py::test_plot \
+ --deselect=tests/test_paths.py::test_svg_arc_snap \
+ --deselect=tests/test_ray.py::test_contains_cavity \
+ --deselect=tests/test_splines.py::SplineTests::test_bezier_example
+TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
+
+# tests as of 5.1.1: 742 passed, 3 skipped, 292 warnings in 252.21s
+
+.include <bsd.port.mk>
diff --git a/graphics/py-trimesh/distinfo b/graphics/py-trimesh/distinfo
new file mode 100644
index 000000000000..6047bc063887
--- /dev/null
+++ b/graphics/py-trimesh/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1792342571
+SHA256 (mikedh-trimesh-5.1.1_GH0.tar.gz) = a88325d214f30644d46d192ca80fa483d4a7473ec5d267e94fc6d29c73c32e2d
+SIZE (mikedh-trimesh-5.1.1_GH0.tar.gz) = 13758012
diff --git a/graphics/py-trimesh/pkg-descr b/graphics/py-trimesh/pkg-descr
new file mode 100644
index 000000000000..45989ad95f91
--- /dev/null
+++ b/graphics/py-trimesh/pkg-descr
@@ -0,0 +1,5 @@
+Trimesh is a pure Python library for loading and using triangular meshes with
+an emphasis on watertight surfaces. The goal of the library is to provide a
+full featured and well tested Trimesh object which allows for easy
+manipulation and analysis, in the style of the Polygon object in the
+Shapely library.