[Radiance-general] sky visibility

Lars O. Grobe grobe at gmx.net
Sat Oct 20 01:05:03 PDT 2012


Hi Patrick,

Did you consider genklemsamp?

If you just want to not apply the cosine but get either 1 or 0 for rays 
hitting the sky or not, pipe the output from rtrace to rcalc. E.g. sum 
the rays that are above the treshold (0.00001 here) and total number of 
rays traced, and then get the fraction of rays over the treshold using 
rtrace again:

<your rtrace command> | rcalc -e ´$1=if($1-.00001,1,0); $2=1´ | total | 
rcalc -e ´$1=$1/$2´

That could be done using binary floats instead of ascii to make it a bit 
more efficient using proper -if3, -of options for all commands. The same 
can be done on e.g. fisheye images using pcomb.

A general hint, you can also get the surface identifier (-os) at the 
first ray intersection instead of e.g. the radiance value from rtrace 
and pass that through grep.

Cheers, Lars.



More information about the Radiance-general mailing list