[Radiance-general] Re: trans dashboard widget

Andy McNeil amcneil at lbl.gov
Fri Apr 30 14:06:54 PDT 2010


Hi Greg,
Thanks, that's quite the pcomb function.  I'll see what I can do to get a color picker in the widget.  Thanks!
Andy


On Apr 30, 2010, at 11:55 AM, Gregory J. Ward wrote:

> Hi Andy,
> 
> This was more of a struggle than I expected.  I don't know what I did with my old color wheel, so I tried to come up with an expression to generate a new one based on the Wikipedia page on HSV conversions.  It's not quite what I was going for, but it's OK:
> 
> pcomb -x 512 -y xres \
> -e 'xc:xres/2;yc:yres/2;xr=(x-xc)/xc;yr=(y-yc)/yc' \
> -e 'rv=.7349*xr-.3495*yr;gv=-.2651*xr+.2279*yr;bv=-.2651*xr-.9268*yr' \
> -e 'max(a,b):if(a-b,a,b);Y=1-max(rv,max(gv,bv))' \
> -e 'in=1-xr*xr-yr*yr' \
> -e 'ro=if(in,Y+rv,.5);go=if(in,Y+gv,.5);bo=if(in,Y+bv,.5)' \
> | ra_tiff - color_wheel.tif
> 
> When the user chooses a color, you'll have to map back to linear RGB (undoing the 2.2 gamma) and normalize.
> 
> Hope it works!
> 
> -Greg
> 
> P.S.  I didn't notice the trick of going to "plastic" when transmission is zero -- very nice!
> 
>> From: Andy McNeil <amcneil at lbl.gov>
>> Date: April 30, 2010 9:22:17 AM PDT
>> 
>> Hi Greg,
>> 
>> You're right, the ability to specify color would be nice.  Yes, please send your image.
>> Did you notice what happens when Td & Ts are set to zero?
>> 
>> Thanks,
>> Andy
> 
> _______________________________________________
> Radiance-general mailing list
> Radiance-general at radiance-online.org
> http://www.radiance-online.org/mailman/listinfo/radiance-general




More information about the Radiance-general mailing list