ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/cv/bsdf2rad.c
(Generate patch)

Comparing ray/src/cv/bsdf2rad.c (file contents):
Revision 2.20 by greg, Mon Apr 10 06:09:14 2017 UTC vs.
Revision 2.21 by greg, Mon Apr 10 15:44:19 2017 UTC

# Line 540 | Line 540 | put_source(void)
540   static void
541   put_hemispheres(void)
542   {
543 +        const int       nsegs = 131;
544 +
545          printf("\n# Hemisphere(s) for showing BSDF appearance (if XML file)\n");
544        printf("\nvoid antimatter anti_sph\n2 void %s\n0\n0\n", sph_mat);
546          if (front_comp) {
547 <                printf("\n%s sphere Front\n0\n0\n4 %f 0 0 %f\n",
548 <                                sph_mat, sph_xoffset, sph_rad);
549 <                printf("\n!genbox anti_sph sph_eraser %f %f %f | xform -t %f %f %f\n",
549 <                                2.02*sph_rad, 2.02*sph_rad, 1.02*sph_rad,
550 <                                -1.01*sph_rad + sph_xoffset, -1.01*sph_rad, -1.01*sph_rad);
547 >                printf(
548 > "\n!genrev %s Front \"R*sin(A*t)\" \"R*cos(A*t)\" %d -e \"R:%g;A:%f\" -s | xform -t %g 0 0\n",
549 >                                sph_mat, nsegs, sph_rad, 0.495*PI, sph_xoffset);
550                  printf("\nvoid brighttext front_text\n3 helvet.fnt . FRONT\n0\n");
551                  printf("12\n\t%f %f 0\n\t%f 0 0\n\t0 %f 0\n\t.01 1 -.1\n",
552                                  -.22*sph_rad + sph_xoffset, -1.4*sph_rad,
# Line 561 | Line 560 | put_hemispheres(void)
560                                  .25*sph_rad + sph_xoffset, -1.3*sph_rad );
561          }
562          if (back_comp) {
563 <                printf("\n%s bubble Back\n0\n0\n4 %f 0 0 %f\n",
564 <                                sph_mat, -sph_xoffset, sph_rad);
565 <                printf("\n!genbox anti_sph sph_eraser %f %f %f | xform -t %f %f %f\n",
567 <                                2.02*sph_rad, 2.02*sph_rad, 1.02*sph_rad,
568 <                                -1.01*sph_rad - sph_xoffset, -1.01*sph_rad, -1.01*sph_rad);
563 >                printf(
564 > "\n!genrev %s Back \"R*cos(A*t)\" \"R*sin(A*t)\" %d -e \"R:%g;A:%f\" -s | xform -t %g 0 0\n",
565 >                                sph_mat, nsegs, sph_rad, 0.495*PI, -sph_xoffset);
566                  printf("\nvoid brighttext back_text\n3 helvet.fnt . BACK\n0\n");
567                  printf("12\n\t%f %f 0\n\t%f 0 0\n\t0 %f 0\n\t.01 1 -.1\n",
568                                  -.22*sph_rad - sph_xoffset, -1.4*sph_rad,

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines