How to to calculate view factor

Hi.

I want to calculate a simple view factor.
In other words, I fire rays from a certain point and want to know what the object the ray hits first.

However, if you use “Mesh | Ray”, each object is calculated separately, so the ray will pass through it. If you use “ShootRay”, you only know the coordinates.
Is there a good way to do it?

Thanks.

view_factor.gh (24.6 KB)

Isn’t that exactly what “IsoVist Ray” component does?
You need a specific solution inside python?

Is this what you want?

view_factor_re.gh (26.9 KB)

2 Likes

Thanks for the fast reply!

It is exactly what I was looking for.

Thank you for attaching an easy-to-understand sample.

It seems that we are finally able to proceed to the next step.