Skip to content

Minimize crossings when shifting overlapping traces#370

Open
garrettparker245-code wants to merge 1 commit into
tscircuit:mainfrom
garrettparker245-code:codex-minimize-overlap-crossings
Open

Minimize crossings when shifting overlapping traces#370
garrettparker245-code wants to merge 1 commit into
tscircuit:mainfrom
garrettparker245-code:codex-minimize-overlap-crossings

Conversation

@garrettparker245-code
Copy link
Copy Markdown

Fixes #83.

Summary

  • Evaluates both offset directions when separating overlapping trace islands.
  • Chooses the candidate with the fewest resulting crossings against surrounding trace geometry.
  • Adds a regression test for choosing the lower-crossing offset direction.
  • Updates affected example snapshots.

Tests

  • npx --cache .npm-cache bun test tests\solvers\TraceOverlapShiftSolver\TraceOverlapShiftSolver.test.ts
  • npx --cache .npm-cache -p typescript@5.9.3 tsc --noEmit
  • .\node_modules\.bin\biome format lib\solvers\TraceOverlapShiftSolver\TraceOverlapIssueSolver\TraceOverlapIssueSolver.ts tests\solvers\TraceOverlapShiftSolver\TraceOverlapShiftSolver.test.ts
  • npx --cache .npm-cache bun test

@vercel
Copy link
Copy Markdown

vercel Bot commented May 20, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
schematic-trace-solver Ready Ready Preview, Comment May 20, 2026 1:25am

Request Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

In the case of multiple overlaps on a parallel line, choose to offset to minimize crossings

1 participant