Path: utzoo!utgpu!watmath!clyde!att!pacbell!ames!pasteur!agate!eris.berkeley.edu!mwm
From: mwm@eris.berkeley.edu (Mike (I'll think of something yet) Meyer)
Newsgroups: comp.sys.amiga.tech
Subject: Re: IFF.LIBRARY
Message-ID: <17861@agate.BERKELEY.EDU>
Date: 6 Dec 88 02:53:42 GMT
References: <62827UH2@PSUVM> <587@wuphys.UUCP>
Sender: usenet@agate.BERKELEY.EDU
Organization: Missionaria Phonibalonica
Lines: 114


I'd add a "#ifndef" around those pragmas. I also turned the function
declarations into prototypes:


/************** F U N C T I O N   D E C L A R A T I O N S ***************/

APTR OpenIFF(char *);
void CloseIFF(APTR);
struct Chunk *FindChunk(APTR, char *);
struct BitMapHeader *GetBMHD(APTR);
LONG GetColorTab(APTR, UWORD *);
BOOL DecodePic(APTR, struct BitMap *);
BOOL SaveBitMap(char *, struct BitMap *, UWORD *, long);
BOOL SaveClip(char *, struct BitMap *, UWORD *, int, int, int, int, int);
LONG IffError(void);


/************** F U N C T I O N   P R A G M A S ***************/

#ifndef NOPRAGMA
#pragma libcall IFFBase OpenIFF 1e 801
#pragma libcall IFFBase CloseIFF 24 901
#pragma libcall IFFBase FindChunk 2a 0902
#pragma libcall IFFBase GetBMHD 30 901
#pragma libcall IFFBase GetColorTab 36 8902
#pragma libcall IFFBase DecodePic 3c 8902
#pragma libcall IFFBase SaveBitMap 42 0A9804
#pragma libcall IFFBase SaveClip 48 43210A9808
#pragma libcall IFFBase IffError 4e 00
#pragma libcall IFFBase GetViewModes 54 901
#endif


Finally, for those who want it, here's the assembler interface for
Lattice. Just asm it, copy the library into lib: as lib.o, and then
link it with programs that need the iff.library (assuming you compiled
with NOPRAGMA defined).