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

Comparing ray/src/util/rmatrix.c (file contents):
Revision 2.70 by greg, Tue Dec 5 01:06:10 2023 UTC vs.
Revision 2.71 by greg, Tue Dec 5 21:13:38 2023 UTC

# Line 374 | Line 374 | rmx_load(const char *inspec, RMPref rmp)
374                  fp = stdin;
375          else if (inspec[0] == '!')
376                  fp = popen(inspec+1, "r");
377 <        else if (rmp != RMPnone) {
377 >        else {
378                  const char      *sp = inspec;   /* check suffix */
379                  while (*sp)
380                          ++sp;
381                  while (sp > inspec && sp[-1] != '.')
382                          --sp;
383                  if (!strcasecmp(sp, "XML")) {   /* assume it's a BSDF */
384 <                        CMATRIX *cm = rmp==RMPtrans ? cm_loadBTDF(inspec) :
384 >                        CMATRIX *cm = rmp==RMPnone ? (CMATRIX *)NULL :
385 >                                        rmp==RMPtrans ? cm_loadBTDF(inspec) :
386                                          cm_loadBRDF(inspec, rmp==RMPreflB) ;
387                          if (!cm)
388                                  return(NULL);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines