10 |
|
* |
11 |
|
*/ |
12 |
|
|
13 |
+ |
#define _USE_MATH_DEFINES |
14 |
|
#include <stdio.h> |
15 |
|
#include <stdlib.h> |
16 |
|
#include <math.h> |
170 |
|
/* try loading variable resolution data */ |
171 |
|
lastErr = SDloadTre(sd, wtl); |
172 |
|
/* check our result */ |
173 |
< |
switch (lastErr) { |
173 |
< |
case SDEformat: |
174 |
< |
case SDEdata: |
175 |
< |
case SDEsupport: /* possibly we just tried the wrong format */ |
173 |
> |
if (lastErr == SDEsupport) /* try matrix BSDF if not tree data */ |
174 |
|
lastErr = SDloadMtx(sd, wtl); |
175 |
< |
break; |
178 |
< |
default: /* variable res. OK else serious error */ |
179 |
< |
break; |
180 |
< |
} |
175 |
> |
|
176 |
|
/* done with XML file */ |
177 |
|
ezxml_free(fl); |
178 |
|
|