This plugin is wonderful. I'm now planning to make a plugin to export an hourly data of the shadow ratio.
And now checking the code of yours.
Since sketchup API doesn't have enough kind of shadow API,
it would very helpful if you could explain the algorithm to get the shadow.
Anyway thanks for your masterpiece.
Read the .rb file's code to see how it works...
The sun has a 'direction' [to get the direction of the rays of sunlight we reverse that vector].
The selected faces are processed in turn - 'selected face'...
It finds the edges of all faces in the model or groups/instances that might shine onto that 'selected face'.
It extrudes these edges into a grouped 'tube' with a very long set of faces, which it then intersects with the 'selected face' and adds faces temporarily.
The tube is erased.
It then has a set of edges representing the outer limits of the 'selected face's' shadows; internal 'coplanar' edges are erased so it's as simple as possible.
Each 'shadow' group is formated as the options set, text added etc...
Obviously it's much
more complicated than that [e.g. how to spot if there's a 'hole' in a face], but the principle is as stated...