ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/doc/ray.1
(Generate patch)

Comparing ray/doc/ray.1 (file contents):
Revision 1.9 by greg, Wed May 10 19:50:30 2006 UTC vs.
Revision 1.47 by greg, Mon Dec 9 19:21:38 2024 UTC

# Line 1 | Line 1
1 < .\" RCSid "$Id"
1 > .\" RCSid "$Id$"
2   .\" Print using the -ms macro package
3 < .DA 1/20/99
3 > .DA 12/09/2024
4   .LP
5 < .tl """Copyright \(co 2003 Regents, University of California
5 > .tl """Copyright \(co 2024 Regents, University of California
6   .sp 2
7   .TL
8   The
# Line 491 | Line 491 | a perfectly scattering medium (no absorption).
491   The scattering eccentricity parameter will likewise override the global
492   setting if it is present.
493   Scattering eccentricity indicates how much scattered light favors the
494 < forward direction, as fit by the Heyney-Greenstein function:
494 > forward direction, as fit by the Henyey-Greenstein function:
495   .DS
496   P(theta) = (1 - g*g) / (1 + g*g - 2*g*cos(theta))^1.5
497   .DE
# Line 622 | Line 622 | mod trans2 id
622   8 red green blue spec urough vrough trans tspec
623   .DE
624   .LP
625 + .UL Ashik2
626 + .PP
627 + Ashik2 is the anisotropic reflectance model by Ashikhmin & Shirley.
628 + The string arguments are the same as for plastic2, but the real
629 + arguments have additional flexibility to specify the specular color.
630 + Also, rather than roughness, specular power is used, which has no
631 + physical meaning other than larger numbers are equivalent to a smoother
632 + surface.
633 + Unlike other material types, total reflectance is the sum of
634 + diffuse and specular colors, and should be adjusted accordingly.
635 + .DS
636 + mod ashik2 id
637 + 4+ ux uy uz funcfile transform
638 + 0
639 + 8 dred dgrn dblu sred sgrn sblu u-power v-power
640 + .DE
641 + .LP
642 + .UL WGMDfunc
643 + .PP
644 + WGMDfunc is a more programmable version of trans2,
645 + with separate modifier paths and variables to control each component.
646 + (WGMD stands for Ward-Geisler-Moroder-Duer, which is the basis for
647 + this empirical model, similar to the previous ones beside Ashik2.)\0
648 + The specification of this material is given below.
649 + .DS
650 + mod WGMDfunc id
651 + 13+ rs_mod  rs  rs_urough rs_vrough
652 +    ts_mod  ts  ts_urough ts_vrough
653 +    td_mod
654 +    ux uy uz  funcfile  transform
655 + 0
656 + 9+  rfdif gfdif bfdif
657 +    rbdif gbdif bbdif
658 +    rtdif gtdif btdif
659 +    A10 ..
660 + .DE
661 + The sum of specular reflectance (
662 + .I rs
663 + ), specular transmittance (
664 + .I ts
665 + ), diffuse reflectance (
666 + .I "rfdif gfdif bfdif"
667 + for front and
668 + .I "rbdif gbdif bbdif"
669 + for back)
670 + and diffuse transmittance (
671 + .I "rtdif gtdif btdif"
672 + ) should be less than 1 for each
673 + channel.
674 + .PP
675 + Unique to this material, separate modifier channels are
676 + provided for each component.
677 + The main modifier is used on the diffuse reflectance, both
678 + front and back.
679 + The
680 + .I rs_mod
681 + modifier is used for specular reflectance.
682 + If "void" is given for
683 + .I rs_mod,
684 + then the specular reflection color will be white.
685 + The special "inherit" keyword may also be given, in which case
686 + specular reflectance will share the main modifier.
687 + This behavior is replicated for the specular transmittance modifier
688 + .I ts_mod,
689 + which has its own independent roughness expressions.
690 + Finally, the diffuse transmittance modifier is given as
691 + .I td_mod,
692 + which may also be "void" or "inherit".
693 + Note that any spectra or color for specular components must be
694 + carried by the named modifier(s).
695 + .PP
696 + The main advantage to this material over BRTDfunc and
697 + other programmable types described below is that the specular sampling is
698 + well-defined, so that all components are fully computed.
699 + .LP
700   .UL Dielectric
701   .PP
702   A dielectric material is transparent, and it refracts light
# Line 865 | Line 940 | mod transdata id
940   6+ red green blue rspec trans tspec A7 ..
941   .DE
942   .LP
943 + .UL BSDF
944 + .PP
945 + The BSDF material type loads an XML (eXtensible Markup Language)
946 + file describing a bidirectional scattering distribution function.
947 + Real arguments to this material may define additional
948 + diffuse components that augment the BSDF data.
949 + String arguments are used to define thickness for proxied
950 + surfaces and the "up" orientation for the material.
951 + .DS
952 + mod BSDF id
953 + 6+ thick BSDFfile ux uy uz funcfile transform
954 + 0
955 + 0|3|6|9
956 +     rfdif gfdif bfdif
957 +     rbdif gbdif bbdif
958 +     rtdif gtdif btdif
959 + .DE
960 + The first string argument is a "thickness" parameter that may be used
961 + to hide detail geometry being proxied by an aggregate BSDF material.
962 + If a view or shadow ray hits a BSDF proxy with non-zero thickness,
963 + it will pass directly through as if the surface were not there.
964 + Similar to the illum type, this permits direct viewing and
965 + shadow testing of complex geometry.
966 + The BSDF is used when a scattered (indirect) ray hits the surface,
967 + and any transmitted sample rays will be offset by the thickness amount
968 + to avoid the hidden geometry and gather samples from the other side.
969 + In this manner, BSDF surfaces can improve the results for indirect
970 + scattering from complex systems without sacrificing appearance or
971 + shadow accuracy.
972 + If the BSDF has transmission and back-side reflection data,
973 + a parallel BSDF surface may be
974 + placed slightly less than the given thickness away from the front surface
975 + to enclose the complex geometry on both sides.
976 + The sign of the thickness is important, as it indicates whether the
977 + proxied geometry is behind the BSDF surface (when thickness is positive)
978 + or in front (when thickness is negative).
979 + .LP
980 + The second string argument is the name of the BSDF file, which is
981 + found in the usual auxiliary locations.
982 + The following three string parameters name variables for an "up" vector,
983 + which together with the surface normal, define the
984 + local coordinate system that orients the BSDF.
985 + These variables, along with the thickness, are defined in a function
986 + file given as the next string argument.
987 + An optional transform is used to scale the thickness and reorient the up vector.
988 + .LP
989 + If no real arguments are given, the BSDF is used by itself to determine
990 + reflection and transmission.
991 + If there are at least 3 real arguments, the first triplet is an
992 + additional diffuse reflectance for the front side.
993 + At least 6 real arguments adds diffuse reflectance to the rear side of the surface.
994 + If there are 9 real arguments, the final triplet will be taken as an additional
995 + diffuse transmittance.
996 + All diffuse components as well as the non-diffuse transmission are
997 + modified by patterns applied to this material.
998 + The non-diffuse reflection from either side are unaffected.
999 + Textures perturb the effective surface normal in the usual way.
1000 + .LP
1001 + The surface normal of this type is not altered to face the incoming ray,
1002 + so the front and back BSDF reflections may differ.
1003 + (Transmission is identical front-to-back by physical law.)\0
1004 + If back visibility is turned off during rendering and there is no
1005 + transmission or back-side reflection, only then the surface will be
1006 + invisible from behind.
1007 + Unlike other data-driven material types, the BSDF type is fully
1008 + supported and all parts of the distribution are properly sampled.
1009 + .LP
1010 + .UL aBSDF
1011 + .PP
1012 + The aBSDF material is identical to the BSDF type with two important
1013 + differences.
1014 + First, proxy geometry is not supported, so there is no thickness parameter.
1015 + Second, an aBSDF is assumed to have some specular through component
1016 + (the 'a' stands for "aperture"), which
1017 + is treated specially during the direct calculation and when viewing the
1018 + material.
1019 + Based on the BSDF data, the coefficient of specular transmission is
1020 + determined and used for modifying unscattered shadow and view rays.
1021 + .DS
1022 + mod aBSDF id
1023 + 5+ BSDFfile ux uy uz funcfile transform
1024 + 0
1025 + 0|3|6|9
1026 +     rfdif gfdif bfdif
1027 +     rbdif gbdif bbdif
1028 +     rtdif gtdif btdif
1029 + .DE
1030 + .LP
1031 + If a material has no specular transmitted component, it is much better
1032 + to use the BSDF type with a zero thickness than to use aBSDF.
1033 + .LP
1034   .UL Antimatter
1035   .PP
1036   Antimatter is a material that can "subtract" volumes from other volumes.
# Line 879 | Line 1045 | N mod1 mod2 .. modN
1045   The first modifier will also be used to shade the area leaving the
1046   antimatter volume and entering the regular volume.
1047   If mod1 is void, the antimatter volume is completely invisible.
1048 < Antimatter does not work properly with the material type "trans",
1049 < and multiple antimatter surfaces should be disjoint.
1048 > If shading is desired at antimatter surfaces, it is important
1049 > that the related volumes are closed with outward-facing normals.
1050 > Antimatter surfaces should not intersect with other antimatter boundaries,
1051 > and it is unwise to use the same modifier in nested antimatter volumes.
1052   The viewpoint must be outside all volumes concerned for a correct
1053   rendering.
1054   .NH 3
# Line 1084 | Line 1252 | A section of text meant to depict a picture, perhaps u
1252   font such as hexbit4x1.fnt, calls for uniform spacing.
1253   Reasonable magnitudes for proportional spacing are
1254   between 0.1 (for tightly spaced characters) and 0.3 (for wide spacing).
1255 + .LP
1256 + .UL Spectrum
1257 + .PP
1258 + The spectrum primitive is the most basic type for introducing spectral
1259 + color to a material.
1260 + Since materials only provide RGB parameters, spectral patterns
1261 + are the only way to superimpose wavelength-dependent behavior.
1262 + .DS
1263 + mod spectrum id
1264 + 0
1265 + 0
1266 + 5+ nmA nmB s1 s2 .. sN
1267 + .DE
1268 + The first two real arguments indicate the extrema of the
1269 + spectral range in nanometers.
1270 + Subsequent real values correspond to multipliers at each wavelength.
1271 + The nmA wavelength may be greater or less than nmB,
1272 + but they may not be equal, and their ordering matches
1273 + the order of the spectral values.
1274 + A minimum of 3 values must be given, which would act
1275 + more or less the same as a constant RGB multiplier.
1276 + As with RGB values, spectral quantities normally range between 0
1277 + and 1 at each wavelength, or average to 1.0 against a standard
1278 + sensitivity functions such as V(lambda).
1279 + The best results obtain when the spectral range and number
1280 + of samples match rendering options, though resampling will handle
1281 + any differences, zero-filling wavelenths outside the nmA to nmB
1282 + range.
1283 + A warning will be issued if the given wavelength range does not
1284 + adequately cover the visible spectrum.
1285 + .LP
1286 + .UL Specfile
1287 + .PP
1288 + The specfile primitive is equivalent to the spectrum type, but
1289 + the wavelength range and values are contained in a 1-dimensional
1290 + data file.
1291 + This may be a more convenient way to specify a spectral color,
1292 + especially one corresponding to a standard illuminant such as D65
1293 + or a library of measured spectra.
1294 + .DS
1295 + mod specfile id
1296 + 1 datafile
1297 + 0
1298 + 0
1299 + .DE
1300 + As with the spectrum type, rendering wavelengths outside the defined
1301 + range will be zero-filled.
1302 + Unlike the spectrum type, the file may contain non-uniform samples.
1303 + .LP
1304 + .UL Specfunc
1305 + .PP
1306 + The specfunc primitive offers dynamic control over a spectral
1307 + pattern, similar to the colorfunc type.
1308 + .DS
1309 + mod specfunc id
1310 + 2+ sfunc funcfile transform
1311 + 0
1312 + 2+ nmA nmB A3 ..
1313 + .DE
1314 + Like the spectrum primitive, the wavelength range is specified
1315 + in the first two real arguments, and additional real values are
1316 + set in the evaluation context.
1317 + This function is fed a wavelenth sample
1318 + between nmA and nmB as its only argument,
1319 + and it returns the corresponding spectral intensity.
1320 + .LP
1321 + .UL Specdata
1322 + .PP
1323 + Specdata is like brightdata and colordata, but with more
1324 + than 3 specular samples.
1325 + .DS
1326 + mod specdata id
1327 + 3+n+
1328 +        func datafile
1329 +        funcfile x1 x2 .. xn transform
1330 + 0
1331 + m A1 A2 .. Am
1332 + .DE
1333 + The data file must have one more dimension than the coordinate
1334 + variable count, as this final dimension corresponds to the covered
1335 + spectrum.
1336 + The starting and ending wavelengths are specified in "datafile"
1337 + as well as the number of spectral samples.
1338 + The function "func" will be called with two parameters, the
1339 + interpolated spectral value for the current coordinate and the
1340 + associated wavelength.
1341 + If the spectrum is broken into 12 components, then 12 calls
1342 + will be made to "func" for the relevant ray evaluation.
1343 + .LP
1344 + .UL Specpict
1345 + .PP
1346 + Specpict is a special case of specdata, where the pattern is
1347 + a hyperspectral image stored in the common-exponent file format.
1348 + The dimensions of the image data are determined by the picture
1349 + just as with the colorpict primitive.
1350 + .DS
1351 + mod specpict id
1352 + 5+
1353 +        func specfile
1354 +        funcfile u v transform
1355 + 0
1356 + m A1 A2 .. Am
1357 + .DE
1358 + The function "func" is called with the interpolated pixel value
1359 + and the wavelength sample in nanometers, the same as specdata,
1360 + with as many calls made as there are components in "specfile".
1361   .NH 3
1362   Mixtures
1363   .PP
1364   A mixture is a blend of one or more materials or textures and patterns.
1365 + Blended materials should not be light source types or virtual source types.
1366   The basic types are given below.
1367   .LP
1368   .UL Mixfunc
# Line 1109 | Line 1384 | which serves as a form of opacity control when used wi
1384   Vname is the coefficient defined in funcfile that determines the influence
1385   of foreground.
1386   The background coefficient is always (1-vname).
1112 Since the references are not resolved until runtime, the last
1113 definitions of the modifier id's will be used.
1114 This can result in modifier loops, which are detected by the
1115 renderer.
1387   .LP
1388   .UL Mixdata
1389   .PP
# Line 1239 | Line 1510 | If no file is needed by a given primitive because all
1510   variables are global, a period (`.') can be given in
1511   place of the file name.
1512   It is also possible to give an expression instead of a straight
1513 < variable name in a scene file, although such expressions should
1514 < be kept simple if possible.
1244 < Also, functions (requiring parameters)
1513 > variable name in a scene file.
1514 > Functions (requiring parameters)
1515   must be given as names and not as expressions.
1516   .PP
1517   Constant expressions are used as an optimization in function
# Line 1405 | Line 1675 | converts a picture to and from simpler formats.
1675   Pictures may be displayed directly under X11 using the program
1676   .I ximage,
1677   or converted a standard image format.
1678 < .I Ra_avs
1679 < converts to and from AVS image format.
1410 < .I Ra_pict
1411 < converts to Macintosh 32-bit PICT2 format.
1678 > .I Ra_bmp
1679 > converts to and from Microsoft Bitmap images.
1680   .I Ra_ppm
1681   converts to and from Poskanzer Portable Pixmap formats.
1414 .I Ra_pr
1415 converts to and from Sun 8-bit rasterfile format.
1416 .I Ra_pr24
1417 converts to and from Sun 24-bit rasterfile format.
1682   .I Ra_ps
1683   converts to PostScript color and greyscale formats.
1684   .I Ra_rgbe
# Line 1433 | Line 1697 | License
1697   .DS
1698   The Radiance Software License, Version 1.0
1699  
1700 < Copyright (c) 1990 - 2002 The Regents of the University of California,
1700 > Copyright (c) 1990 - 2008 The Regents of the University of California,
1701   through Lawrence Berkeley National Laboratory.   All rights reserved.
1702  
1703   Redistribution and use in source and binary forms, with or without
# Line 1495 | Line 1759 | the Ecole Polytechnique Federale de Lausanne (EPFL Uni
1759   in Lausanne, Switzerland.
1760   .NH 1
1761   References
1762 + .LP
1763 + Ward, Gregory J., Bruno Bueno, David Geisler-Moroder,
1764 + Lars O. Grobe, Jacob C. Jonsson, Eleanor
1765 + S. Lee, Taoning Wang, Helen Rose Wilson,
1766 + ``Daylight Simulation Workflows Incorporating
1767 + Measured Bidirectional Scattering Distribution Functions,''
1768 + .I "Energy & Buildings",
1769 + Vol. 259, No. 111890, 2022.
1770 + .LP
1771 + Wang, Taoning, Gregory Ward, Eleanor Lee,
1772 + ``Efficient modeling of optically-complex, non-coplanar
1773 + exterior shading: Validation of matrix algebraic methods,''
1774 + .I "Energy & Buildings",
1775 + vol. 174, pp. 464-83, Sept. 2018.
1776 + .LP
1777 + Lee, Eleanor S., David Geisler-Moroder, Gregory Ward,
1778 + ``Modeling the direct sun component in buildings using matrix
1779 + algebraic approaches: Methods and validation,''
1780 + .I Solar Energy,
1781 + vol. 160, 15 January 2018, pp 380-395.
1782 + .LP
1783 + Ward, G., M. Kurt & N. Bonneel,
1784 + ``Reducing Anisotropic BSDF Measurement to Common Practice,''
1785 + .I Workshop on Material Appearance Modeling,
1786 + 2014.
1787 + .LP
1788 + McNeil, A., C.J. Jonsson, D. Appelfeld, G. Ward, E.S. Lee,
1789 + ``A validation of a ray-tracing tool used to generate
1790 + bi-directional scattering distribution functions for
1791 + complex fenestration systems,''
1792 + .I "Solar Energy",
1793 + 98, 404-14, November 2013.
1794 + .LP
1795 + Ward, G., R. Mistrick, E.S. Lee, A. McNeil, J. Jonsson,
1796 + ``Simulating the Daylight Performance of Complex Fenestration Systems
1797 + Using Bidirectional Scattering Distribution Functions within Radiance,''
1798 + .I "Leukos",
1799 + 7(4),
1800 + April 2011.
1801 + .LP
1802 + Cater, K., A. Chalmers, G. Ward,
1803 + ``Detail to Attention: Exploiting Visual Tasks for Selective Rendering,''
1804 + .I "Eurograhics Symposium on Rendering",
1805 + June 2003.
1806   .LP
1807   Ward, G., Elena Eydelberg-Vileshin,
1808   ``Picture Perfect RGB Rendering Using Spectral Prefiltering and

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines