OK. I will update the code tomorrow. It is a little bit late here at my location. Before writing down the code lets define center point P. It is supposed to be placed at P(0,0).
Is this some arbitrary point or it has to be something like center of mass to enclosing object. Instead creating red lines to go across whole object we will have a set of lines that spreed from point P. Are this lines needed in your further work, or we can create intersection points for a set of line that enclose some angle (let say every 5 deg).
Do you want to have a point P selected from a script, or let me assume it is 0,0.
Do you need point object created at intersection or just label text displaced for some distance in direction of a red line?
Since this is a 2D problem is Z coordonate needed?
What precision you need (2 3 or more decimal places)?
Are corner point of enclosing object also needed?
Angle from point p to intersection point added to table?
What about dividing each segment of enclosing object at peaces of equal length (some step value).
With your method as stated now you will have a segments of enclosing object in "shaddow" zone, so it meigth
happen you won't have intersection points at that position. See upper right corner of your sample for clearance.
Answer this questions line by line after quoting separately each my question.
Miljenko Hatlak

Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.