Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor ear clipping algorithm to improve concave and flat triangle detection #2841

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Commits on May 30, 2024

  1. Refactor ear clipping algorithm to improve concave and flat triangle …

    …detection
    
    - Updated the condition to detect concave vertices:
      If the z component of the cross product is less than or equal to zero,
      the triangle is considered concave, indicating that the angle between the vectors is greater than 180 degrees.
    
    - Improved the condition to detect flat triangles:
      If the norm (length) of the cross product is close to zero, the vectors are collinear, making the triangle flat with no area.
    
    - Added detailed comments to explain the conditions for concave and flat triangles for better readability and maintainability.
    iory committed May 30, 2024
    Configuration menu
    Copy the full SHA
    7056649 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f89e754 View commit details
    Browse the repository at this point in the history

Commits on Oct 22, 2024

  1. Configuration menu
    Copy the full SHA
    727b6c1 View commit details
    Browse the repository at this point in the history