You are looking for a funnel algorithm.
Here you are a simple one
Basically, the algorithm identify edges as portals, and build a funnel that is tested against the vertex of the edges to check if they are inside funnel or not.
In step A the funnel is built with the start position and the portal crossed by yellow line.
In step B the next portal is checked, the upper vertex is inside the funnel, so the funnel upper line now pass though it. But the bottom vertex is out of the funnel because red line in under green line, so bottom line will not pass though it, it will continue passing through the bottom vertex of previous portal.
As you can check the funnel will be smaller, and smaller, until step F, where the funnel is not possible to be build, because red line makes a bad funnel, so the upper vertex is choosed as new start point and a new funnel would be build if the end point is not in that mesh.
Realize that this kind of algorithm lets a simple solution to the model size problem too, because you can consider that the portals are smaller by the 2xradius of your model.