nberliner / PointObject

Analysing pipeline for localisation super-resolution data.
1 stars 0 forks source link

Improve curvature calculation at contour "boundaries" #7

Closed nberliner closed 9 years ago

nberliner commented 9 years ago

The contour is stored as a series of points. Calculating the curvature on this series of points will have two "boundaries" where the contour "starts" and "ends".

In the following figure the red dot represents the "start" and the "end" of the contour. At this position the curvature calculation will be incorrect.

150721_issue7_contour_start_end

nberliner commented 9 years ago

I am now extra bits at the "start" and "end" of the curvature to simulate a smooth continuation. After calculating the curvature this extra bit is removed effectively removing the boundary effects.

It is not the most elegant solution as it doubles computation time but for the moment it will do.