[Radiance-general] Re: graphing radiance raytrace paths

Greg Ward gregoryjward at gmail.com
Wed Jan 26 16:27:41 CET 2005


Hi Jelle,

You can get much closer to what you want if you simply add a 't' in 
your rtrace's -o option, like so:

% ximage someRendering.pic | rtrace -ab 5 -otodLpnsm -h -x 1 -i  
someOct.oct > rays.txt

This is going to give you more rays than you can possibly want, so I'd 
also set -ad 32 or so to reduce the number of interreflected rays 
generated.  Any other trimming, you'll have to do yourself.

Also, this will not show all the rays returning to the light sources, 
as this part of the calcuation never gets fully 'traced', the reason 
being that the direct calculation in Radiance attempts to minimize the 
actual number of rays followed to sources as an optimization.  If you 
want to see the paths all the way back to the sources, you'll have to 
get into the rt/source.c file and start modifying the code directly.

Regarding the -s option in xshowtrace, you can go in and change it 
yourself.  The sleep call is on line 260 in px/xshowtrace.c.  
Unfortunately, sleep only takes integer arguments, but you can replace 
it with a call to nanosleep() on most systems.

-Greg

> From: "Jelle Feringa // EZCT / Paris" <jelle.feringa at ezct.net>
> Date: January 26, 2005 4:32:11 AM PST
>
> Hi Greg,
>
> Wow! Thanks for pointing that out to me, that seems quite close to 
> what I
> intend to do. I think 'graph' wasn't necessarily the appropriate term, 
> since
> often it implies 2d. In fact I'm looking for a way to capture the rays
> traced in a rendering to a 3d (polygon) file, preferable colored 
> according
> to their illumination value. Maybe you've seen the Maya 6 feauture 
> where
> your able to visualize the global illumination cache in coloured 
> points. (if
> you haven't it might be interesting that I upload an image to my 
> server)
> I'd like to do something similar like that, but its important to trace 
> the
> whole path, right from the camera, all the way back to the light 
> source it
> emitted (sure, a lot of them will end up at the wall, but the more 
> rays can
> be traced to the source, the better)
>
> As I understood from the man pages, piping ximage (t) to rtrace is 
> close to
> what xshowtrace does, except that its output is numbers instead of 
> graphic
> lines superimposed on the rendering (by the way, there's no way to 
> control
> the interval of xshowtrace -s is there? Awesome soft! Thanks so much!)
>
> So here's what I tried using this approach:
>
> ximage someRendering.pic rtrace -ab 5 -oodLpnsm -h -x 1 -i   
> someOct.oct >
> rays.txt
> ...




More information about the Radiance-general mailing list