Now we have a compact closed simple smooth curve in $\Bbb R^2$ and the curve's bounding box is known. But the curve is given implicitly by a signed distance function $f(x, y)$. Note that we don't have a global formula for $f(x, y)$, but we can sample $f(x, y)$ at arbitrary points.
definition of signed distance function can be found here
The question is: Given a point $P$, how can we find all the points on the curve whose tangent line pass through $P$. Can you give me an algorithm for this process?
Here is an illustration.
Points on the red curve whose tangent line pass through $P$ are $A, B, C, D$.

Ideas too long for a comment.
You are assuming that the signed distance function actually calculates the distance to a smooth curve (since topologically that curve it its own boundary). If I read the linked definition correctly, the signed difference function will always be nonnegative (since the curve as a set has empty interior and is all boundary).
Sample the bounding box until you find a point where the distance function is 0 (or within $\epsilon$ of $0$). Then by sampling near that point for more points on the curve you can essentially trace out the curve as a sequence of close together points at distance near $0$.
With that data you can calculate slopes of short secants and look for lines that pass through $P$.
Whether this is numerically stable or efficient depends on the complexity of the curve. You will have trouble if it's self intersecting.