Skip to content

Restore bearing-aware cheirality for DLT triangulation - #2445

Merged
pmoulon merged 1 commit into
openMVG:developfrom
Afloat16:fix-bearing-cheirality-dlt-20261011
Nov 7, 2026
Merged

pmoulon merged 1 commit into
openMVG:developfrom
Afloat16:fix-bearing-cheirality-dlt-20261011

Conversation

@Afloat16

Copy link
Copy Markdown
Contributor

TriangulateDLT's rotation/translation overload tests camera-space z for cheirality. Spherical-camera bearings cover the whole sphere, so this rejects valid rear-hemisphere observations and can accept antipodal observations even though the point lies behind an observed ray. This affects callers selecting DIRECT_LINEAR_TRANSFORM.

Check depth along each bearing with x.dot(R * X + t). This retains the transpose removal discussed in #2229. #2332 discussed using Triangulate2View with spherical bearings and closed after the caller corrected their bearings. The native regression uses the actual spherical camera's projection and bearing conversion, with front/rear/mixed hemispheres, rotated and translated cameras, positive bearing scaling, antipodal observations, and subpixel image noise.

Validation: the unchanged upstream triangulation target passes; the new regression fails against baseline with 15 cheirality assertions in one added native case; after the fix, five native CTest executables pass (12 native cases): triangulation, triangulation_nview, solver_essential, Camera_Spherical, and Camera_Pinhole.

Tested with the project's Release CMake build on GCC 14.2.0, bundled Eigen/Ceres, and tests enabled. Rerun, LiGT, examples, software, documentation, GUI, and SoPlex are disabled; Schur specializations are disabled. The configured CTest inventory has 84 executables; the remaining 79 were not run. The full platform/default CI matrix was not run locally.

Prepared with AI assistance and validated using the project's native CMake/CTest targets.

@Afloat16
Afloat16 marked this pull request as ready for review October 14, 2026 13:33
@pmoulon

pmoulon commented Nov 7, 2026

Copy link
Copy Markdown
Member

LGTM

@pmoulon
pmoulon merged commit 5f84739 into openMVG:develop Nov 7, 2026
1 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants