Robert D. King (king++at++ait.nrl.navy.mil)
Tue, 13 Dec 1994 04:51:24 -0500 (EST)
> I have been trying to get perfly to read a simple Inventor file but
> have had no luck. I saw in the Performer FAQ that an updated LoadIV
> program was to be distributed "at a future date." Has that happened
> yet? If so, how can I get it? If not, when?
>
Tom,
The problem is in the way that pfiv.c treats an empty set of braces
when encountering the inventor command to create a tristrip out of
the previously loaded vertices. The 'fix' I am including works
around that for simple shapes by testing for the T_COMPLETE code
from the tokenizing routine, and setting the striplength to the
current number of unprocessed vertices (vCount) if so.
With this patch, you should be able to use most of the objects made
by id3m (at least as far as my limited testing has put demands on
the 'fix').
diff between my new pfiv.c and the old pfiv.c:
336d335
< int doAll = 0;
340,345c339
< {
< if (tokenType == T_COMPLETE) {
< doAll = 1;
< break;
< }
< }
---
> /* EMPTY */ {;}
350c344
< int stripLength = -1;
---
> int stripLength;
352,356c346
< if (!doAll)
< sscanf(token, "%d", &stripLength);
<
< if (stripLength <= 0)
< stripLength = vCount;
---
> sscanf(token, "%d", &stripLength);
Regards,
Rob
This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:50:44 PDT