Repository navigation
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 43409e7. Configure here.
|
@charlieforward9 Thanks for connecting these. I compared the current diffs: this PR does not supersede #10350 or close #10011 by itself. #10836 adds opt-in adaptive UV mesh subdivision for CPU preprojecting viewports (such as CustomProjectionView), using a sampled error tolerance in map meters. Its default is off, and the refinement path is not enabled for the current GlobeView. #10350 addresses separate correctness issues: rebuilding bitmap geometry and coordinate-conversion uniforms when the viewport mesh resolution changes, plus remapping Mercator-spaced TerrainLayer rows for curved rendering. Neither fix is included here. These changes can coexist. The reusable math.gl subdivision utility provides a useful foundation for future globe refinement, but the GlobeView lifecycle and terrain coordinate fixes still need their own validation. I would keep #10350 and #10011 open until that work lands and the low-zoom reproduction is verified. |

Follow up of #10835
Background
Uniform bitmap grids spend vertices in areas with little distortion. Adaptive subdivision in UV space preserves bilinear quadrilateral bounds while refining projection curvature, including triangle interiors. This PR is independent of the converter adapter.
Change List
BitmapLayer._projectionTolerancein map meterssubdivideTriangleMeshVerified with
yarn exec ocular-build layersandyarn lint. Passed 7 bitmap headless tests. Visual checks were not run.Note
Medium Risk
Touches core bitmap mesh generation and vertex attributes for custom projections; opt-in and default-off, but bad tolerance or seams can throw or increase vertex counts up to math.gl caps.
Overview
Adds an experimental
BitmapLayer._projectionToleranceoption (map meters, default0) so bitmap geometry can be adaptively subdivided on preprojecting viewports (e.g.CustomProjectionView) instead of relying only on a uniform resolution grid.Refinement runs in UV space via
@math.gl/polygon’ssubdivideTriangleMesh, keeping bilinear bounds-to-texture mapping (including non-rect quads and altitude) while sampling projected error through the layer’s position transform. Refined meshes exposeprojectedPositionsso the position attribute skips re-applying model matrix/projection. Meshes rebuild when bounds, tolerance, coordinate system, projection, or (on preproject viewports)modelMatrixchange; tolerance without a preprojecting viewport throws.Docs describe limits, seam/domain requirements, and incompatibility with
coordinateSystem: 'cartesian'. Tests cover UV/altitude preservation,modelMatrixrebuilds, and turning refinement off.Reviewed by Cursor Bugbot for commit d81d0c5. Bugbot is set up for automated code reviews on this repo. Configure here.