any solution to fix spline uv getting stretched at corners ?

hello ,, allot of time i face this issue , texture getting stretched at hard corners when sweeping a spline like the attached image :



what i do to reduce the ammount of the stritch is to refine the shape in these corners :



the resault will be like :

there still a little stritch , to fix it it needs some unwrap and it will take allot of time if u have more complex shape with more than 100 corners like these .

so does any one know a better solution to get the problem fixed ? i am sure there are some ideas  :D