Rev 33 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
154 | pmbaty | 1 | #pragma once |
33 | pmbaty | 2 | /* *INDENT-OFF* */ |
3 | /*>>> epd.h: subprogram prototypes for epd.c */ |
||
4 | /* Revised: 1996.06.23 */ |
||
5 | /* |
||
6 | Copyright (C) 1996 by Steven J. Edwards (sje@mv.mv.com) |
||
7 | All rights reserved. This code may be freely redistibuted and used by |
||
8 | both research and commerical applications. No warranty exists. |
||
9 | */ |
||
10 | /* |
||
11 | Everything in this source file is independent of the host program. |
||
12 | Requests for changes and additions should be communicated to the author |
||
13 | via the e-mail address given above. |
||
14 | */ |
||
15 | /* |
||
16 | This file was originally prepared on an Apple Macintosh using the |
||
17 | Metrowerks CodeWarrior 6 ANSI C compiler. Tabs are set at every |
||
18 | four columns. Further testing and development was performed on a |
||
19 | generic PC running Linux 1.3.20 and using the gcc 2.7.0 compiler. |
||
20 | */ |
||
21 | void EPDFatal(charptrT s); |
||
22 | void EPDSwitchFault(charptrT s); |
||
23 | voidptrT EPDMemoryGrab(liT n); |
||
24 | void EPDMemoryFree(voidptrT ptr); |
||
25 | charptrT EPDStringGrab(charptrT s); |
||
26 | void EPDStringFree(charptrT s); |
||
27 | charptrT EPDStringAppendChar(charptrT s, char c); |
||
28 | charptrT EPDStringAppendStr(charptrT s0, charptrT s1); |
||
29 | liT EPDMapFromDuration(charptrT s); |
||
30 | charptrT EPDMapToDuration(liT seconds); |
||
31 | gamptrT EPDGameOpen(void); |
||
32 | void EPDGameClose(gamptrT gamptr); |
||
33 | void EPDGameAppendMove(gamptrT gamptr, mptrT mptr); |
||
34 | void EPDTokenize(charptrT s); |
||
35 | siT EPDTokenCount(void); |
||
36 | charptrT EPDTokenFetch(siT n); |
||
37 | siT EPDCICharEqual(char ch0, char ch1); |
||
38 | pT EPDPieceFromCP(cpT cp); |
||
39 | siT EPDCheckPiece(char ch); |
||
40 | pT EPDEvaluatePiece(char ch); |
||
41 | siT EPDCheckColor(char ch); |
||
42 | cT EPDEvaluateColor(char ch); |
||
43 | siT EPDCheckRank(char ch); |
||
44 | rankT EPDEvaluateRank(char ch); |
||
45 | siT EPDCheckFile(char ch); |
||
46 | fileT EPDEvaluateFile(char ch); |
||
47 | eovptrT EPDNewEOV(void); |
||
48 | void EPDReleaseEOV(eovptrT eovptr); |
||
49 | void EPDAppendEOV(eopptrT eopptr, eovptrT eovptr); |
||
50 | eovptrT EPDCreateEOVStr(charptrT str); |
||
51 | eovptrT EPDCreateEOVSym(charptrT sym); |
||
52 | eovptrT EPDCreateEOVInt(liT lval); |
||
53 | eovptrT EPDLocateEOV(eopptrT eopptr, charptrT strval); |
||
54 | siT EPDCountEOV(eopptrT eopptr); |
||
55 | void EPDReplaceEOVStr(eovptrT eovptr, charptrT str); |
||
56 | eopptrT EPDNewEOP(void); |
||
57 | void EPDReleaseEOP(eopptrT eopptr); |
||
58 | void EPDAppendEOP(epdptrT epdptr, eopptrT eopptr); |
||
59 | eopptrT EPDCreateEOP(charptrT opsym); |
||
60 | eopptrT EPDCreateEOPCode(epdsoT epdso); |
||
61 | eopptrT EPDLocateEOP(epdptrT epdptr, charptrT opsym); |
||
62 | eopptrT EPDLocateEOPCode(epdptrT epdptr, epdsoT epdso); |
||
63 | siT EPDCountEOP(epdptrT epdptr); |
||
64 | void EPDDropIfLocEOP(epdptrT epdptr, charptrT opsym); |
||
65 | void EPDDropIfLocEOPCode(epdptrT epdptr, epdsoT epdso); |
||
66 | void EPDAddOpInt(epdptrT epdptr, epdsoT epdso, liT val); |
||
67 | void EPDAddOpStr(epdptrT epdptr, epdsoT epdso, charptrT s); |
||
68 | void EPDAddOpSym(epdptrT epdptr, epdsoT epdso, charptrT s); |
||
69 | epdptrT EPDNewEPD(void); |
||
70 | void EPDReleaseOperations(epdptrT epdptr); |
||
71 | void EPDReleaseEPD(epdptrT epdptr); |
||
72 | charptrT EPDFetchOpsym(epdsoT epdso); |
||
73 | epdptrT EPDCloneEPDBase(epdptrT epdptr); |
||
74 | eovptrT EPDCloneEOV(eovptrT eovptr); |
||
75 | eopptrT EPDCloneEOP(eopptrT eopptr); |
||
76 | epdptrT EPDCloneEPD(epdptrT epdptr); |
||
77 | epdptrT EPDSet(rbptrT rbptr, cT actc, castT cast, sqT epsq); |
||
78 | void EPDSetCurrentPosition(rbptrT rbptr, cT actc, castT cast, sqT epsq, |
||
79 | siT hmvc, siT fmvn); |
||
80 | epdptrT EPDGetCurrentPosition(void); |
||
81 | cT EPDFetchACTC(void); |
||
82 | castT EPDFetchCAST(void); |
||
83 | sqT EPDFetchEPSQ(void); |
||
84 | siT EPDFetchHMVC(void); |
||
85 | siT EPDFetchFMVN(void); |
||
86 | rbptrT EPDFetchBoard(void); |
||
87 | cpT EPDFetchCP(sqT sq); |
||
88 | charptrT EPDFetchBoardString(void); |
||
89 | gtimT EPDGetGTIM(gamptrT gamptr); |
||
90 | void EPDPutGTIM(gamptrT gamptr, gtimT gtim); |
||
91 | charptrT EPDGenBasic(rbptrT rbptr, cT actc, castT cast, sqT epsq); |
||
92 | charptrT EPDGenBasicCurrent(void); |
||
93 | epdptrT EPDDecodeFEN(charptrT s); |
||
94 | charptrT EPDEncodeFEN(epdptrT epdptr); |
||
95 | epdptrT EPDDecode(charptrT s); |
||
96 | charptrT EPDEncode(epdptrT epdptr); |
||
97 | void EPDRealize(epdptrT epdptr); |
||
98 | void EPDInitArray(void); |
||
99 | charptrT EPDPlayerString(cT c); |
||
100 | void EPDSANEncode(mptrT mptr, sanT san); |
||
101 | mptrT EPDSANDecodeAux(sanT san, siT strict); |
||
102 | siT EPDIsLegal(void); |
||
103 | siT EPDIsCheckmate(void); |
||
104 | siT EPDIsStalemate(void); |
||
105 | siT EPDIsInsufficientMaterial(void); |
||
106 | siT EPDIsFiftyMoveDraw(void); |
||
107 | siT EPDIsThirdRepeatIndex(gamptrT gamptr); |
||
108 | siT EPDIsDraw(gamptrT gamptr); |
||
109 | mptrT EPDMateInOne(void); |
||
110 | void EPDExecuteUpdate(mptrT mptr); |
||
111 | void EPDRetractUpdate(void); |
||
112 | void EPDRetractAll(void); |
||
113 | void EPDCollapse(void); |
||
114 | void EPDReset(void); |
||
115 | void EPDGenMoves(void); |
||
116 | siT EPDFetchMoveCount(void); |
||
117 | mptrT EPDFetchMove(siT index); |
||
118 | void EPDSetMoveFlags(mptrT mptr); |
||
119 | void EPDSortSAN(void); |
||
120 | siT EPDPurgeOpFile(charptrT opsym, charptrT fn0, charptrT fn1); |
||
121 | siT EPDRepairEPD(epdptrT epdptr); |
||
122 | siT EPDRepairFile(charptrT fn0, charptrT fn1); |
||
123 | siT EPDNormalizeFile(charptrT fn0, charptrT fn1); |
||
124 | siT EPDScoreFile(charptrT fn, bmsptrT bmsptr); |
||
125 | siT EPDEnumerateFile(siT depth, charptrT fn0, charptrT fn1, liptrT totalptr); |
||
126 | charptrT EPDMoveList(gamptrT gamptr); |
||
127 | pgnstrT EPDPGNFetchTagIndex(charptrT s); |
||
128 | charptrT EPDPGNFetchTagName(pgnstrT pgnstr); |
||
129 | charptrT EPDPGNGetSTR(gamptrT gamptr, pgnstrT pgnstr); |
||
130 | void EPDPGNPutSTR(gamptrT gamptr, pgnstrT pgnstr, charptrT s); |
||
131 | charptrT EPDPGNGenSTR(gamptrT gamptr); |
||
132 | charptrT EPDPGNHistory(gamptrT gamptr); |
||
133 | void EPDCopyInPTP(gamptrT gamptr, epdptrT epdptr); |
||
134 | void EPDCopyOutPTP(gamptrT gamptr, epdptrT epdptr); |
||
135 | charptrT EPDFetchRefcomStr(refcomT refcom); |
||
136 | charptrT EPDFetchRefreqStr(refreqT refreq); |
||
137 | refcomT EPDFetchRefcomIndex(charptrT s); |
||
138 | refreqT EPDFetchRefreqIndex(charptrT s); |
||
139 | refcomT EPDExtractRefcomIndex(epdptrT epdptr); |
||
140 | refreqT EPDExtractRefreqIndex(epdptrT epdptr); |
||
141 | siT EPDComm(refintptrT refintptr, charptrT pipebase); |
||
142 | void EPDInit(void); |
||
143 | void EPDTerm(void); |
||
144 | /* *INDENT-ON* */ |