home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.amiga.programmer
- Path: sparky!uunet!caen!uri.csmil.umich.edu!chymes
- From: chymes@uri.csmil.umich.edu (Charles Hymes)
- Subject: Impulse FORM TDDD is crummy. was: IFF 3D standard? (DR3D?)
- Message-ID: <tKR-ft_@engin.umich.edu>
- Date: Tue, 21 Jul 92 12:45:04 EDT
- Organization: Cognitive Science and Machine Intelligence Lab, U. of MIichigan
- References: <1992Jul21.135437.1@economics.adelaide.edu.au> <1992Jul21.055017.2772@wam.umd.edu>
- Keywords: n
- Nntp-Posting-Host: uri.csmil.umich.edu
- Lines: 50
-
-
- Impulse's FORM TDDD is a crummy IFF is I heartily incourage is
- upgrading. My promlem with it is that while it is a LEAGL IFF it is a
- NON-STANDARD IFF. It is non-standard to the point that
- parseiff.library is won't read any of its chunks. The problem is that
- it has sub-chunks and sub-sub chunks, without any of the encapulating
- FORMs LISTs or PROPs. TDDD's look like this:
- FORM TDDD
- OBJ
- DESC
- PNTS
- EDGE
- FACE
- ...
- TERM
- ...
-
- When it should look like this:
-
- LIST TDDD
- FORM OBJ
- FORM DESC
- PNTS
- EDGE
- FACE
- ...
- TERM
- ....
-
- The problem is that IFFParse.library never enters the contents of a
- chunk. So to it, (and any other IFF reader that is not TDDD specific)
- a TDDD is only made of one large OBJ chunk, which it will never parse
- again. If the TDDD form was standard, iffparse could decend into each
- sub chunk, and retreve the ones wanted ones, perserving context and
- all that jazz. To parse TDDDs, one has to treat OBJ chunks and DESC chunks as
- seperate, *NON STANDARD* IFF files, and parse each seperately. This is
- what I have done. I wrote a TDDD reader that reads uses Iffparse to
- get each OBJ chunk, copys the chunk to a buffer and prefixes "FORM
- TDDD" and the size to each OBJ, calls iffparse on each (now-legal) OBJ
- chunk, gets each DESC sub-chunk, prefixes "FORM TDDD" and the size to
- each DESC chunk, and finally one can then get at the data for the 3d
- objects. Yuck.
-
- One could argue that the problem is with Iffparse, but this is not the
- case. A standard IFF should expicitly state which chunks are
- sub-chunks, and not expect the parser to look inside each chunk and
- guess that it is a sub-chunk becuse the first four bytes happen to be
- upper case ASCII. That is what FORM LIST, and PROP chunks are for.
-
- Charweed Hymerfan
-