Revision: 54429
http://brlcad.svn.sourceforge.net/brlcad/?rev=54429&view=rev
Author: carlmoore
Date: 2013-02-15 22:03:07 +0000 (Fri, 15 Feb 2013)
Log Message:
-----------
make use of defined constants
Modified Paths:
--------------
brlcad/trunk/src/liboptical/sh_toyota.c
Modified: brlcad/trunk/src/liboptical/sh_toyota.c
===================================================================
--- brlcad/trunk/src/liboptical/sh_toyota.c 2013-02-15 21:52:10 UTC (rev
54428)
+++ brlcad/trunk/src/liboptical/sh_toyota.c 2013-02-15 22:03:07 UTC (rev
54429)
@@ -1653,7 +1653,7 @@
/* to a given luminance. Units: K */
x, y; /* 1931 CIE chromaticity coordinates. */
- sun_alt = 90 - acos(VDOT(Sun, Zenith))*180/M_PI;
+ sun_alt = 90 - acos(VDOT(Sun, Zenith))*RAD2DEG;
lz = zenith_luminance(sun_alt, t_vl);
/* Get luminance distribution */
switch (weather) {
@@ -2176,7 +2176,7 @@
VSETALL(Sky_elmnt, 0.0);
/* Angular spread between vectors used in solid angle integration. */
-#define SPREAD (10*M_PI/180)
+#define SPREAD (10*DEG2RAD)
/* Differential solid angle. */
del_omega = M_PI*sin(SPREAD/2)*sin(SPREAD/2);
@@ -2348,7 +2348,7 @@
/* Direct sunlight contribution. */
direct_sunlight =
- 1./M_PI
+ M_1_PI
* reflectance(ts->wavelength, acos(i_dot_n)*bn_radtodeg,
ts->refl, ts->refl_lines)
* sun_radiance(ts->wavelength, ts->alpha, ts->beta,
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
The Go Parallel Website, sponsored by Intel - in partnership with Geeknet,
is your hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials, tech docs,
whitepapers, evaluation guides, and opinion stories. Check out the most
recent posts - join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits