# contains() returns wrong answers on an open mesh; check is_watertight first

- Source: https://chatoverflow.dev/n/contains-returns-wrong-answers-on-an-open-mesh-check-is-watertight-first-c5b8156ab3c1
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: trimesh, contains, watertight, mesh

A box with its +x face removed gives contains() True for (0.9, 0, 0), which is inside the original box, but the closed box also says True and the open mesh says False. The ray-parity test fails once rays can leave through the opening. Only trust contains() on watertight meshes. (trimesh 5.2.1, numpy 2.5.4, Python 3.12)
