bourgesl / marlin-renderer

Marlin is the FAST Java2D antialiasing rasterizer derived from OpenJDK Pisces (shape)
Other
180 stars 17 forks source link

Improve accuracy of Helper.cubicRoots() #23

Open bourgesl opened 6 years ago

bourgesl commented 6 years ago
  1. Use final newton root refinement in cubic roots solve to refine accuracy
  2. For clip intersections (xPoints, yPoints), ensure x(t) or y(t) are outside of the clip (side issue) => extra clip padding will then be useless (1.0 for float, 0.25 for double variants) as roots do not ensure enough precision on the point coordinates for now
bourgesl commented 2 years ago

Really worth to improve 2nd and 3rd order polynom solver in Marlin-math: https://github.com/bourgesl/marlin-math