-
Notifications
You must be signed in to change notification settings - Fork 67
/
extern.h
1096 lines (979 loc) · 43.2 KB
/
extern.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/*
** Astrolog (Version 7.70) File: extern.h
**
** IMPORTANT NOTICE: Astrolog and all chart display routines and anything
** not enumerated below used in this program are Copyright (C) 1991-2024 by
** Walter D. Pullen ([email protected], http://www.astrolog.org/astrolog.htm).
** Permission is granted to freely use, modify, and distribute these
** routines provided these credits and notices remain unmodified with any
** altered or distributed versions of the program.
**
** The main ephemeris databases and calculation routines are from the
** library SWISS EPHEMERIS and are programmed and copyright 1997-2008 by
** Astrodienst AG. Use of that source code is subject to license for Swiss
** Ephemeris Free Edition at https://www.astro.com/swisseph/swephinfo_e.htm.
** This copyright notice must not be changed or removed by any user of this
** program.
**
** Additional ephemeris databases and formulas are from the calculation
** routines in the program PLACALC and are programmed and Copyright (C)
** 1989,1991,1993 by Astrodienst AG and Alois Treindl ([email protected]). The
** use of that source code is subject to regulations made by Astrodienst
** Zurich, and the code is not in the public domain. This copyright notice
** must not be changed or removed by any user of this program.
**
** The original planetary calculation routines used in this program have
** been copyrighted and the initial core of this program was mostly a
** conversion to C of the routines created by James Neely as listed in
** 'Manual of Computer Programming for Astrologers', by Michael Erlewine,
** available from Matrix Software.
**
** Atlas composed using data from https://www.geonames.org/ licensed under a
** Creative Commons Attribution 4.0 License. Time zone changes composed using
** public domain TZ database: https://data.iana.org/time-zones/tz-link.html
**
** The PostScript code within the core graphics routines are programmed
** and Copyright (C) 1992-1993 by Brian D. Willoughby ([email protected]).
**
** More formally: This program is free software; you can redistribute it
** and/or modify it under the terms of the GNU General Public License as
** published by the Free Software Foundation; either version 2 of the
** License, or (at your option) any later version. This program is
** distributed in the hope that it will be useful and inspiring, but
** WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** General Public License for more details, a copy of which is in the
** LICENSE.HTM file included with Astrolog, and at http://www.gnu.org
**
** Initial programming 8/28-30/1991.
** X Window graphics initially programmed 10/23-29/1991.
** PostScript graphics initially programmed 11/29-30/1992.
** Last code change made 4/22/2024.
*/
/*
******************************************************************************
** Function Declarations.
******************************************************************************
*/
#ifdef PROTO
#define P(t) t
#else
#define P(t) ()
#endif
// From astrolog.cpp
extern void InitColors P((void));
extern void Action P((void));
extern void InitVariables P((void));
extern flag FProcessCommandLine P((CONST char *));
extern int NParseCommandLine P((char *, char **));
extern int NPromptSwitches P((char *, char *[MAXSWITCHES]));
extern int NProcessSwitchesRare P((int, char **, int, flag, flag, flag));
extern flag FProcessSwitches P((int, char **));
extern void InitProgram P((void));
extern void FinalizeProgram P((flag));
// From data.cpp
#define MM ciCore.mon
#define DD ciCore.day
#define YY ciCore.yea
#define TT ciCore.tim
#define ZZ ciCore.zon
#define SS ciCore.dst
#define OO ciCore.lon
#define AA ciCore.lat
#define Mon ciMain.mon
#define Day ciMain.day
#define Yea ciMain.yea
#define Tim ciMain.tim
#define Zon ciMain.zon
#define Dst ciMain.dst
#define Lon ciMain.lon
#define Lat ciMain.lat
#define MonT ciTran.mon
#define DayT ciTran.day
#define YeaT ciTran.yea
#define TimT ciTran.tim
#define ZonT ciTran.zon
#define DstT ciTran.dst
#define LonT ciTran.lon
#define LatT ciTran.lat
#define planet cp0.obj
#define planetalt cp0.alt
#define ret cp0.dir
#define retalt cp0.diralt
#define retlen cp0.dirlen
#define space cp0.pt
#define chouse cp0.cusp
#define chouse3 cp0.cusp3
#define inhouse cp0.house
#define planetval(o) \
(us.fParallel ? cp0.alt[o] : (us.fDistance ? cp0.dist[o] : cp0.obj[o]))
#define planetdir(o) \
(us.fParallel ? cp0.diralt[o] : (us.fDistance ? cp0.dirlen[o] : cp0.dir[o]))
#define planetval1(o) \
(us.fParallel ? cp1.alt[o] : (us.fDistance ? cp1.dist[o] : cp1.obj[o]))
#define planetdir1(o) \
(us.fParallel ? cp1.diralt[o] : (us.fDistance ? cp1.dirlen[o] : cp1.dir[o]))
#define planetval2(o) \
(us.fParallel ? cp2.alt[o] : (us.fDistance ? cp2.dist[o] : cp2.obj[o]))
#define planetdir2(o) \
(us.fParallel ? cp2.diralt[o] : (us.fDistance ? cp2.dirlen[o] : cp2.dir[o]))
#define FIgnoreA(a) (ignorea[a] || rAspOrb[a] < 0.0)
#define DEFAULT_LOC DMS(122, 19, 55), DMS(47, 36, 22)
#define FProperGraph(o) !(!us.fGraphAll && (FCusp(o) || \
(us.fInDayMonth && ((o) == oMoo || (us.fInDayYear && (o) <= oMar)))))
#define FProperEphem2(o) (!(us.nRel <= rcTransit ? ignore2[o] : ignore[o]) && \
!(gs.fAlt && ((o) == oMoo || (o) == oFor)))
#define FCmSwissAny() (us.fEphemFiles && !us.fPlacalcPla)
#define FCmSwissEph() (us.fEphemFiles && !us.fPlacalcPla && us.nSwissEph <= 0)
#define FCmSwissMosh() (us.fEphemFiles && !us.fPlacalcPla && us.nSwissEph == 1)
#define FCmSwissJPL() (us.fEphemFiles && !us.fPlacalcPla && us.nSwissEph == 2)
#define FCmSwissStar() (us.fEphemFiles && !us.fPlacalcPla && !us.fMatrixStar)
#define FCmPlacalc() (us.fEphemFiles && us.fPlacalcPla)
#define FCmMatrix() (!us.fEphemFiles && us.fMatrixPla)
#define FCmJPLWeb() (us.fEphemFiles && !us.fPlacalcPla && us.nSwissEph >= 3)
extern US us;
extern IS is;
extern CI ciCore, ciMain, ciTwin, ciThre, ciFour, ciFive, ciHexa,
ciDefa, ciTran, ciSave, ciGreg;
extern CP cp0, cp1, cp2, cp3, cp4, cp5, cp6;
extern CP * CONST rgpcp[cRing+1];
extern CI * CONST rgpci[cRing+1];
extern flag rgfProg[cRing+1];
extern real force[objMax];
extern GridInfo *grid;
extern int rgobjList[objMax], rgobjList2[objMax], starname[cStar+1],
kObjA[objMax];
extern byte ignore[objMax], ignore2[objMax], ignorea[cAspect+1],
ignorez[arMax], ignore7[rrMax], pluszone[cSector+1];
extern byte ignoreMem[objMax], ignore2Mem[objMax], ignoreaMem[cAspect+1],
ignorezMem[arMax], ignore7Mem[rrMax], ignorefMem[6];
extern real rAspAngle[cAspect+1], rAspOrb[cAspect+1], rObjOrb[oNorm+2],
rObjAdd[oNorm+2];
extern int ruler1[oNorm+1], ruler2[oNorm+1], exalt[oNorm+1],
rules[cSign+1], rules2[cSign+1],
kMainA[9], kRainbowA[cRainbow+1], kElemA[cElem], kAspA[cAspect+1],
kObjU[oNorm+2];
extern real rObjInf[oNorm1+6], rHouseInf[cSign+6], rAspInf[cAspect+1],
rTransitInf[oNorm1+1];
#define kBlackA kMainA[0]
#define kWhiteA kMainA[1]
#define kLtGrayA kMainA[2]
#define kDkGrayA kMainA[3]
#define kMaroonA kMainA[4]
#define kDkGreenA kMainA[5]
#define kDkCyanA kMainA[6]
#define kDkBlueA kMainA[7]
#define kMagentaA kMainA[8]
#define kRedA kRainbowA[1]
#define kOrangeA kRainbowA[2]
#define kYellowA kRainbowA[3]
#define kGreenA kRainbowA[4]
#define kCyanA kRainbowA[5]
#define kBlueA kRainbowA[6]
#define kPurpleA kRainbowA[7]
#define KStarA(mag) ((mag) < 1.0 ? kOrangeA : kMaroonA)
#define KStar2A(mag) \
((mag) < 2.0 ? kWhiteA : ((mag) < 4.0 ? kLtGrayA : kDkGrayA))
extern CONST char *szAppName, *szSignName[cSign+1], *szSignAbbrev[cSign+1],
*szSignEnglish[cSign+1], *szHouseTradition[cSign+1], *szSystem[cSystem],
*szAspectName[cAspect2+1], *szAspectAbbrev[cAspect2+1],
*szAspectGlyph[cAspect2+1], *szAspectConfig[cAspConfig],
*szElem[cElem], *szMode[3], *szMonth[cSign+1], *szDay[cWeek], *szZon[cZone],
*rgszDir[4], *szSuffix[cSign+1], *szEphem[cmMax];
extern CONST int rgAspConfig[cAspConfig];
extern CONST real rZon[cZone];
extern CONST char *szObjName[objMax+4], *szCnstlName[cCnstl+1],
*szCnstlAbbrev[cCnstl+1], *szCnstlMeaning[cCnstl+1],
*szCnstlGenitive[cCnstl+1];
extern CONST real rStarBrightMatrix[cStar+1], rStarData[cStar*6];
extern CONST char *szMindPartDef[objMax], *szDescDef[cSign+1],
*szDesireDef[cSign+1], *szLifeAreaDef[cSign+1], *szInteractDef[cAspect+1],
*szThereforeDef[cAspect+1], *szModify[3][cAspect];
extern CONST char *szMindPart[objMax], *szDesc[cSign+1], *szDesire[cSign+1],
*szLifeArea[cSign+1], *szInteract[cAspect+1], *szTherefore[cAspect+1];
extern CONST StrLook rgObjName[], rgSystem[], rgAspectName[];
extern CONST StrLookR rgZodiacOffset[];
extern CONST char *szNakshatra[27+1], *szEclipse[etMax], rgchEclipse[etMax+1],
*szAppSep[6], rgchAppSep[6+1];
extern real rStarBrightDef[cStar+1], rStarBright[cStar+1],
rStarBrightDistDef[cStar+1];
extern char *szStarCustom[cStar+1];
extern CONST char *szObjDisp[objMax], *szAspectDisp[cAspect2+1],
*szAspectAbbrevDisp[cAspect2+1], *szAspectGlyphDisp[cAspect2+1];
extern CONST real rObjDist[oNorm+1], rObjYear[oNorm+1], rObjDay[oNorm+1],
rObjMass[oPlu+1], rObjAxis[oPlu+1];
extern real rObjDiam[oNorm+1];
extern CONST int cSatellite[oPlu+1], nMooMap[6][8], rgobjHasMoons[cHasMoons];
extern CONST AI ai[cPart];
extern char *szWheel[cRing+1];
extern CONST char *szColor[cColor+4], *szColorHTML[cColor];
extern int rgObjRay[oNorm+1], rgSignRay[cSign+1], rgSignRay2[cSign+1][cRay+1],
rgObjEso1[oNorm+1], rgObjEso2[oNorm+1], rgObjHie1[oNorm+1],
rgObjHie2[oNorm+1], rgSignEso1[cSign+1], rgSignEso2[cSign+1],
rgSignHie1[cSign+1], rgSignHie2[cSign+1], kRayA[cRay+2];
extern CONST char *szRayName[cRay+1], *szRayWill[cRay+1];
// From general.cpp
#define FEqSz(sz1, sz2) (NCompareSz(sz1, sz2) == 0)
#define FEqSzI(sz1, sz2) (NCompareSzI(sz1, sz2) == 0)
#define RgAllocate(n, t, sz) ((t *)PAllocate((n) * sizeof(t), sz))
#define FCloneSz(szSrc, pszDst) FCloneSzCore(szSrc, pszDst, fFalse)
#define PrintAltitude(deg) PrintSz(SzAltitude(deg))
#define FEqCI(ci1, ci2) (\
ci1.mon == ci2.mon && ci1.day == ci2.day && ci1.yea == ci2.yea && \
ci1.tim == ci2.tim && ci1.dst == ci2.dst && ci1.zon == ci2.zon && \
ci1.lon == ci2.lon && ci1.lat == ci2.lat && \
(ci1.nam == ci2.nam || FEqSz(ci1.nam, ci2.nam)) && \
(ci1.loc == ci2.loc || FEqSz(ci1.loc, ci2.loc)))
#define PtZero(pt) pt.x = pt.y = pt.z = 0.0;
#define PtSet(pt, a, b, c) pt.x = a; pt.y = b; pt.z = c;
#define PtLen(pt) RLength3(pt.x, pt.y, pt.z)
#define PtMul(pt, r) pt.x *= (r); pt.y *= (r); pt.z *= (r);
#define PtDiv(pt, r) pt.x /= (r); pt.y /= (r); pt.z /= (r);
#define PtAdd2(pt, pt2) pt.x += pt2.x; pt.y += pt2.y; pt.z += pt2.z;
#define PtSub2(pt, pt2) pt.x -= pt2.x; pt.y -= pt2.y; pt.z -= pt2.z;
#define PtNeg2(pt, pt2) pt.x = -pt2.x; pt.y = -pt2.y; pt.z = -pt2.z;
#define PtVec(pt, pt1, pt2) pt = pt2; PtSub2(pt, pt1);
#define PtDot(pt1, pt2) (pt1.x*pt2.x + pt1.y*pt2.y + pt1.z*pt2.z)
#define PtCross(pt, pt1, pt2) pt.x = pt1.y*pt2.z - pt1.z*pt2.y; \
pt.y = pt1.z*pt2.x - pt1.x*pt2.z; pt.z = pt1.x*pt2.y - pt1.y*pt2.x;
extern void SwapR P((real *, real *));
extern int CchSz P((CONST char *));
extern int CwchSz P((CONST char *));
extern int NCompareSz P((CONST char *, CONST char *));
extern int NCompareSzI P((CONST char *, CONST char *));
extern flag FEqRgch P((CONST char *, CONST char *, int, flag));
extern flag FMatchSz P((CONST char *, CONST char *));
extern CONST char *SzInList P((CONST char *, CONST char *, int *));
extern void ClearB P((pbyte, int));
extern void CopyRgb P((CONST byte *, byte *, int));
extern void CopyRgchToSz P((CONST char *, int, char *, int));
extern real RSgn P((real));
extern real RAngle P((real, real));
extern real VAngle P((CONST PT3R *, CONST PT3R *));
extern real Mod P((real));
extern long Dvd P((long, long));
extern int SzLookup P((CONST StrLook *, CONST char *));
extern flag FEqSzSubI P((CONST char *, CONST char *));
extern void FormatR P((char *, real, int));
extern KV KvBlend P((KV, KV, real));
extern KV KvHue P((real));
extern KV KvHue2 P((real));
extern int Mod12 P((int));
extern real DecToDeg P((real));
extern real DegToDec P((real));
extern real MinDistance P((real, real));
extern real MinDifference P((real, real));
extern real Midpoint P((real, real));
extern real SphDistance P((real, real, real, real));
extern void SphRatio P((real, real, real, real, real, real *, real *));
extern char *Dignify P((int, int));
extern void EnsureRay P((void));
extern void EnsureStarBright P((void));
extern int DayInMonth P((int, int));
extern int DaysInMonth P((int, int));
extern int DayOfWeek P((int, int, int));
extern int AddDay P((int, int, int, int));
extern void AddTime P((CI *, int, int));
extern real GetOffsetCI P((CONST CI *));
extern real GetOrb P((int, int, int));
extern CONST char *SzAspect P((int));
extern CONST char *SzAspectAbbrev P((int));
extern void RedoRestrictions P((void));
extern void SetCentric P((int));
extern int ObjOrbit P((int));
extern int ObjMoons P((int));
extern real RObjDiam P((int));
extern void PrintSz P((CONST char *));
extern void PrintCh P((char));
extern void PrintTab P((char, int));
extern void PrintCh2 P((char));
extern void PrintTab2 P((char, int));
extern void PrintSzScreen P((CONST char *));
extern void PrintSzFormat P((CONST char *, flag));
extern void PrintProgress P((CONST char *));
extern void PrintNotice P((CONST char *));
extern void PrintWarning P((CONST char *));
extern void PrintError P((CONST char *));
extern flag FErrorArgc P((CONST char *, int, int));
extern flag FErrorValN P((CONST char *, flag, int, int));
extern flag FErrorValR P((CONST char *, flag, real, int));
extern void ErrorArgv P((CONST char *));
extern void ErrorSwitch P((CONST char *));
extern flag FErrorSubswitch P((CONST char *, char, flag));
extern void ErrorEphem P((CONST char *, long));
extern void AnsiColor P((int));
extern void PrintZodiac P((real));
extern char *SzZodiac P((real));
extern char *SzAltitude P((real));
extern char *SzDegree P((real));
extern char *SzDegree2 P((real));
extern char *SzHMS P((int));
extern char *SzDate P((int, int, int, int));
extern char *SzTime P((int, int, int));
extern char *SzTim P((real));
extern char *SzZone P((real));
extern char *SzLocation P((real, real));
extern char *SzElevation P((real));
extern char *SzTemperature P((real));
extern char *SzLength P((real));
extern void GetTimeNow P((int *, int *, int *, real *, real, real));
extern int NFromAltN P((int));
extern char *SzProcessProgname P((char *));
extern flag FAppendCIList P((CONST CI *));
extern flag FSortCIList P((int));
extern void FilterCIList P((CONST char *, CONST char *));
extern flag FEnumerateCIList P((int));
extern int UTF8ToWch P((CONST uchar *, wchar *));
extern int WchToUTF8 P((wchar, char *));
extern wchar WchFromChLatin P((uchar));
extern wchar WchFromChIBM P((uchar));
extern uchar ChLatinFromWch P((wchar));
extern uchar ChIBMFromWch P((wchar));
extern void UTF8ToLatinSz P((char *));
extern void UTF8ToIBMSz P((char *));
extern void ConvertSzFromUTF8 P((char *));
extern CONST char *ConvertSzToLatin P((CONST char *, char *, int));
extern flag FCloneSzCore P((CONST char *, char **, flag));
extern char *SzClone P((char *));
extern pbyte PAllocate P((long, CONST char *));
extern void DeallocateP P((void *));
extern pbyte RgReallocate P((void *, int, int, int, CONST char *));
extern flag FEnsureMacro P((int));
#ifdef DEBUG
extern void Assert P((flag));
#else
#define Assert(f)
#endif
extern void Terminate P((int));
// From io.cpp
#define getbyte() BRead(file)
#define AdvancePast(ch) while (*pch && *pch != (ch)) pch++; \
if (*pch == (ch)) pch++;
extern FILE *FileOpen P((CONST char *, int, char *));
extern byte BRead P((FILE *));
extern word WRead P((FILE *));
extern dword LRead P((FILE *));
extern flag FProcessSwitchFile P((CONST char *, FILE *));
extern flag FOutputData P((void));
extern flag FOutputAAFFile P((void));
extern flag FOutputQuickFile P((void));
extern flag FOutputChartList P((void));
#ifdef SWISSGRAPH
extern flag FOutputDaedalusStar P((void));
#endif
extern flag FOutputSettings P((void));
extern void OpenDir P((CONST char *));
extern int NFromSz P((CONST char *));
extern real RFromSz P((CONST char *));
extern int NParseSz P((CONST char *, int));
extern real RParseSz P((CONST char *, int));
extern void InputString P((CONST char *, char *));
extern int NInputRange P((CONST char *, int, int, int));
extern real RInputRange P((CONST char *, real, real, int));
extern flag FInputData P((CONST char *));
#ifdef JPLWEB
extern flag GetJPLHorizons P((int,
real *, real *, real *, real *, real *, real *, char *));
#endif
// From calc.cpp
#define JulianDayFromTime(t) ((t)*36525.0+2415020.0)
#define NHousePlaceIn2D(deg) NHousePlaceIn(deg, 0.0)
#define EclToEqu(Z, L) CoorXform(Z, L, is.OB)
#define EquToEcl(Z, L) CoorXform(Z, L, -is.OB)
#define EquToLocal(Z, L, T) CoorXform(Z, L, T)
#define Tropical(deg) ((deg) - is.rSid)
#define Untropical(deg) ((deg) + is.rSid)
#define ObjCOB(i) (FBetween(i, oJup, oPlu) ? cobLo + ((i)-oJup) : (i))
#define AdjustRestrictions() for (is.nObj = cObj; is.nObj >= 0 && \
ignore[is.nObj] && ignore2[is.nObj] && force[is.nObj] == 0.0; is.nObj--);
extern CONST int rgnTermEgypt[cSign*2], rgnTermPtolemy[cSign*2];
extern CONST char *szStarNameSwiss[cStar+1];
extern long MdyToJulian P((int, int, int));
extern real MdytszToJulian P((int, int, int, real, real, real));
extern void JulianToMdy P((real, int *, int *, int *));
extern real RHousePlaceIn3DCore P((real, real));
extern real RHousePlaceIn3D P((real, real));
extern int NHousePlaceIn P((real, real));
extern void ComputeInHouses P((void));
extern void ComputeHouses P((int));
extern void ComputeStars P((real, real));
extern real Decan P((real));
extern real Navamsa P((real));
extern real Dwad P((real));
extern int ObjTerm P((real, int));
extern void RecToPol P((real, real, real *, real *));
extern void SphToRec P((real, real, real, real *, real *, real *));
extern void RecToSph3 P((real, real, real, real *, real *));
extern void CoorXform P((real *, real *, real));
extern void CoorXformFast P((real *, real *,
real, real, real, real, real, real));
extern void ProcessPlanet P((int, real));
extern void ComputeEphem P((real));
extern real CastChart P((int));
extern void CastSectors P((void));
extern flag FEnsureGrid P((void));
extern flag FAcceptAspect P((int, int, int));
extern int GetAspect P((CONST real *, CONST real *, CONST real *,
CONST real *, CONST real *, CONST real *, int, int, real *));
extern int GetParallel P((CONST real *, CONST real *, CONST real *,
CONST real *, CONST real *, CONST real *, int, int, real *));
extern flag FCreateGrid P((flag));
extern flag FCreateGridRelation P((flag));
extern int NCheckEclipse P((int, int, real *));
extern int NCheckEclipseLunar P((int, int, int, real *));
extern int NCheckEclipseAny P((int, int, int, real *));
extern void CreateElemTable P((ET *));
#ifdef SWISS
extern CONST int rgObjSwissDef[cCust], rgTypSwissDef[cCust];
extern int rgObjSwiss[cCust], rgTypSwiss[cCust], rgPntSwiss[cCust],
rgFlgSwiss[cCust];
extern flag FSwissPlanet
P((int, real, int, real *, real *, real *, real *, real *, real *));
extern void SwissHouse P((real, real, real, int,
real *, real *, real *, real *, real *, real *, real *, real *));
extern void SwissComputeStars P((real, flag));
extern flag SwissComputeStar P((real, ES *));
extern flag SwissTestStar P((char *));
extern flag SwissComputeAsteroid P((real, ES *, flag));
extern void SwissGetObjName P((char *, int));
extern flag FSwissPlanetData P((real, int, real *, real *, real *));
extern real SwissRefract P((real));
extern void SwissGetFileData P((real *, real *));
extern real SwissLatLmt P((real));
extern real SwissJulDay P((int, int, int, real, int));
extern void SwissRevJul P((real, int, int *, int *, int *, real *));
#else
#define SwissRefract(r) (r)
#define SwissLatLmt(r) 0.0
#endif
#ifdef MATRIX
// From matrix.cpp
#define IoeFromObj(obj) \
((obj) < oMoo ? 0 : ((obj) <= cPlanet ? (obj)-2 : (obj)-uranLo+cPlanet-2))
extern OE rgoe[oVes+cUran-2];
extern long MatrixMdyToJulian P((int, int, int));
extern void MatrixJulianToMdy P((real, int *, int *, int *));
extern real ProcessInput P((void));
extern void PolToRec P((real, real, real *, real *));
extern real RecToSph P((real, real, real));
extern void ComputeVariables P((real *));
extern real CuspMidheaven P((void));
extern real CuspAscendant P((void));
extern real CuspEastPoint P((void));
extern void HousePlacidus P((void));
extern void HouseKoch P((void));
extern void HouseCampanus P((void));
extern void HouseMeridian P((void));
extern void HouseRegiomontanus P((void));
extern void HouseMorinus P((void));
extern void HouseTopocentric P((void));
extern real ReadThree P((real, real, real));
extern void RecToSph2 P((real, real, real, real *, real *, real *));
extern void ErrorCorrect P((int, real *, real *, real *));
extern void ComputePlanets P((void));
extern void ComputeLunar P((real *, real *, real *, real *));
#endif
#ifdef PLACALC
// From placalc2.cpp
extern flag FPlacalcPlanet
P((int, real, flag, real *, real *, real *, real *, real *, real *));
extern double julday P((int, int, int, double, int));
extern void revjul P((double, int, int *, int *, int *, double *));
#endif
// From charts0.cpp
extern void PrintW P((CONST char *, int));
extern void DisplayCredits P((void));
extern void PrintS P((CONST char *));
extern void DisplaySwitches P((void));
extern void DisplaySwitchesRare P((void));
extern void PrintObjects P((void));
extern void PrintAspects P((void));
extern void PrintSigns P((void));
#ifdef CONSTEL
extern CONST char *GetSzGenitive P((char *, CONST char *));
extern void GetSzConstel P((char *, int));
extern void PrintConstellations P((void));
#endif
extern void PrintOrbit P((void));
extern int NCompareSzPart P((int, int));
extern void DisplayArabic P((void));
#ifdef GRAPH
extern void DisplayKeysX P((void));
extern void DisplaySwitchesX P((void));
#ifdef WIN
extern void DisplaySwitchesW P((void));
#endif
#endif // GRAPH
extern flag FPrintTables P((void));
// From charts1.cpp
#define FCrossAscMC(x, y, z) (RAbs(x-y) < rDegHalf && RSgn(z-x) != RSgn(z-y))
#define FCrossAscAsc(w, x, y, z) \
(RAbs(x-y) + RAbs(w-z) < rDegHalf && RSgn(w-x) != RSgn(z-y))
extern void PrintHeader P((int));
extern void ChartListing P((void));
extern void PrintGridCell P((int, int, int, int));
extern void ChartGrid P((void));
extern void DisplayAspectConfigs P((void));
extern void ChartWheel P((void));
extern void PrintAspectSummary P((int *, int *, int, real));
extern void ChartAspect P((void));
extern void PrintAspectsToPoint P((real, int, real, char *));
extern void PrintMidpointSummary P((int *, int, real));
extern void ChartMidpoint P((void));
extern void ChartHorizon P((void));
extern void ChartOrbit P((void));
extern int ChartEsoteric P((flag));
extern void ChartSector P((void));
extern flag ChartAstroGraph P((void));
extern void PrintChart P((flag));
// From charts2.cpp
#define RBiorhythm(day, rate) (RSin(((day)/(rate))*rPi2)*100.0)
extern void ChartListingRelation P((void));
extern void ChartGridRelation P((void));
extern void ChartAspectRelation P((void));
extern void ChartMidpointRelation P((void));
extern void CastRelation P((void));
extern void PrintInDayEvent P((int, int, int, int));
extern void PrintAspect P((int, real, real, int, int, real, real, char));
extern void ChartInDayInfluence P((void));
extern void ChartTransitInfluence P((flag));
extern void ChartTransitGraph P((flag, flag));
extern flag ChartAstroGraphRelation P((void));
extern void EclToHoriz P((real *, real *, real, real, real, real));
extern void ChartCalendarMonth P((void));
extern void ChartCalendarYear P((void));
extern void DisplayRelation P((void));
// From charts3.cpp
#define FAspectVoid(obj1, obj2, asp) (FBetween(asp, aCon, aSex) && \
((obj1) == oMoo || (obj2) == oMoo) && (obj1) <= oPlu && (obj2) <= oPlu)
extern void ChartInDaySearch P((flag));
extern void ChartTransitSearch P((flag));
extern void ChartHorizonRising P((void));
extern void ChartEphemeris P((void));
extern flag ChartExoplanet P((flag));
// From intrpret.cpp
#define RObjInf(i) rObjInf[Min(i, oNorm1)]
#define RTransitInf(i) rTransitInf[Min(i, oNorm1)]
extern CONST char *rgEsoRayArea[5];
#ifdef INTERPRET
extern void FieldWord P((CONST char *));
extern void InterpretGeneral P((void));
extern void InterpretAspectGeneral P((void));
extern void InterpretLocation P((void));
extern void InterpretAspectCore P((int, int, int, int));
extern void InterpretAspect P((int, int));
extern void InterpretGrid P((void));
extern void InterpretMidpoint P((int, int));
extern void InterpretInDay P((int, int, int));
extern void InterpretTransit P((int, int, int));
extern void InterpretSynastry P((void));
extern void InterpretAspectRelation P((int, int));
extern void InterpretGridRelation P((void));
extern void InterpretMidpointRelation P((int, int));
extern void InterpretAstroGraph P((int, int, int, int));
extern int InterpretEsoteric P((flag));
extern void PrintEsoteric P((void));
#endif
extern void SortRank P((real *, int *, int, flag));
extern void ComputeInfluence P((real[oNorm+1], real[oNorm+1]));
extern void ChartInfluence P((void));
#ifdef ATLAS
// From atlas.cpp
extern char *SzCity P((int));
extern flag FEnsureAtlas P((void));
extern flag FEnsureTimezoneChanges P((void));
extern flag FLoadAtlas P((FILE *, int));
extern flag FLoadZoneRules P((FILE *, int, int));
extern flag FLoadZoneChanges P((FILE *, int, int));
extern flag FLoadZoneLinks P((FILE *, int));
extern flag DisplayAtlasLookup P((CONST char *, size_t, int *));
extern flag DisplayAtlasNearby P((real, real, size_t, int *, flag));
extern flag DisplayTimezoneChanges P((int, size_t, CI *));
extern real ZondefFromIzn P((int));
#endif
#ifdef EXPRESS
// From express.cpp
#define ParseExpression(sz) NParseExpression(sz)
extern long NParseExpression P((CONST char *));
extern real RParseExpression P((CONST char *));
extern flag ShowParseExpression P((CONST char *));
extern int NExpGet P((int));
extern real RExpGet P((int));
extern flag ExpSetN P((int, int));
extern flag ExpSetR P((int, real));
extern flag ExpSetMacro P((int, char *));
extern flag ExpSetString P((int, char *, flag));
extern char *ExpGetString P((int));
extern char *PchFormatExpression P((char *, int));
extern char *PchFormatString P((char *, int));
extern void ExpFinalize P((void));
#endif
#ifdef GRAPH
// From xdata.cpp
extern GS gs;
extern GI gi;
#ifdef X11
extern XSizeHints hint;
extern char xkey[];
extern KV rgbind[cColor];
extern KV fg, bg;
#endif
#ifdef WIN
extern CONST int ikPalette[cColor];
extern CONST int rgcmdMode[gMax];
#endif
#ifdef WCLI
extern WI wi;
#endif
extern char *szWheelX[cRing+1];
extern CONST KV rgbbmpDef[cColor], rgbbmpDef2[cColor];
extern KV rgbbmp[cColor];
extern KI kMainB[9], kRainbowB[cRainbow+1], kElemB[cElem], kAspB[cAspect+1],
kObjB[objMax], kRayB[cRay+2];
extern CONST char *rgszFontName[cFont], rgszFontAllow[6][cFont+1];
extern CONST real rgrObjRing[oNep-oJup+3][2];
extern CONST PT3R rgvObjRing[oNep-oJup+3];
extern CONST char
*szDrawSign[cSign+2], *szDrawSign2[cSign+2], *szDrawSign3[cSign+2],
*szDrawObjectDef[objMaxG], *szDrawObjectDef2[objMaxG],
*szDrawHouse[cSign+1], *szDrawHouse2[cSign+1], *szDrawHouse3[cSign+1],
*szDrawAspectDef[cAspect3+1], *szDrawAspectDef2[cAspect3+1],
*szDrawCh[256-32], *szDrawCh2[256-32],
*szWorldData[62*3], *szDrawConstel[cCnstl+1];
extern CONST char *szDrawObject[objMaxG], *szDrawObject2[objMaxG],
*szDrawAspect[cAspect3+1], *szDrawAspect2[cAspect3+1];
#define kBlackB kMainB[0]
#define kWhiteB kMainB[1]
#define kLtGrayB kMainB[2]
#define kDkGrayB kMainB[3]
#define kMaroonB kMainB[4]
#define kDkGreenB kMainB[5]
#define kDkCyanB kMainB[6]
#define kDkBlueB kMainB[7]
#define kMagentaB kMainB[8]
#define kRedB kRainbowB[1]
#define kOrangeB kRainbowB[2]
#define kYellowB kRainbowB[3]
#define kGreenB kRainbowB[4]
#define kCyanB kRainbowB[5]
#define kBlueB kRainbowB[6]
#define kPurpleB kRainbowB[7]
#define KStarB(mag) \
((mag) < 2.0 ? gi.kiOn : ((mag) < 4.0 ? gi.kiLite : gi.kiGray))
#define IObjRing(i) ((i) < oHau ? (i)-oJup : \
((i) == oHau ? (i)-oHau+oNep-oJup+1 : (i)-oQua+oNep-oJup+2))
#define nGlyphAll (gs.nGlyphCap*100000 + gs.nGlyphUra*10000 + \
gs.nGlyphPlu*1000 + gs.nGlyphLil*100 + gs.nGlyphVer*10 + gs.nGlyphEri)
// From xgeneral.cpp
#define BBmGet(rg, x, y) ((rg)[(y)*gi.cbBmpRow + ((x) >> 1)])
#define FBmGet(rg, x, y) (BBmGet(rg, x, y) >> (((x)&1^1) << 2) & 15)
#define BmSet(rg, x, y, o) BBmGet(rg, x, y) = BBmGet(rg, x, y) & \
15 << (((x)&1) << 2) | (o) << (((x)&1^1) << 2)
#define DrawEdge(x1, y1, x2, y2) \
DrawBox(x1, y1, x2, y2, gi.nScaleT, gi.nScaleT)
#define DrawEdgeAll() DrawEdge(0, 0, gs.xWin-1-gs.fThick, gs.yWin-1-gs.fThick)
#define DrawLine(x1, y1, x2, y2) DrawDash(x1, y1, x2, y2, 0)
#define DrawClip(x1, y1, x2, y2, xl, yl, xh, yh, skip) \
FDrawClip(x1, y1, x2, y2, xl, yl, xh, yh, skip, NULL, NULL)
#define DrawLineX(x1, x2, y) DrawBlock(x1, y, x2, y)
#define DrawLineY(x, y1, y2) DrawBlock(x, y1, x, y2)
#define DrawEllipse(x1, y1, x2, y2) DrawArc(x1, y1, x2, y2, 0.0, 0.0, rDegMax)
#define DrawCircle(x, y, xr, yr) \
DrawEllipse((x)-(xr), (y)-(yr), (x)+(xr), (y)+(yr))
#define DrawCircle2(x, y, xr, yr) \
DrawEllipse2((x)-(xr), (y)-(yr), (x)+(xr), (y)+(yr))
extern void DrawColor P((KI));
extern void DrawThick P((flag));
extern void DrawPoint P((int, int));
extern void DrawSpot P((int, int));
extern void DrawBlock P((int, int, int, int));
extern void DrawBox P((int, int, int, int, int, int));
extern void WinClearScreen P((KI));
extern void DrawClearScreen P((void));
extern void DrawDash P((int, int, int, int, int));
extern void DrawWrap P((int, int, int, int, int, int));
extern void ClipLesser P((int *, int *, int *, int *, int));
extern void ClipGreater P((int *, int *, int *, int *, int));
extern flag FDrawClip P((int, int, int, int, int, int, int, int, int,
int *, int *));
extern void DrawArc P((int, int, int, int, real, real, real));
extern void DrawEllipse2 P((int, int, int, int));
extern void DrawCrescent P((int, int, int, int, real, real, KI, KI));
extern void DrawFill P((int, int, KV));
extern void DrawSz P((CONST char *, int, int, int));
extern void DrawSign P((int, int, int));
extern void DrawHouse P((int, int, int));
extern void DrawObject P((int, int, int));
extern void DrawStar P((int, int, CONST ES *));
extern void DrawAspect P((int, int, int));
extern void DrawNakshatra P((int, int, int));
extern int NFromPch P((CONST char **));
extern void DrawTurtle P((CONST char *, int, int));
extern KI KiCity P((int));
// From xdevice.cpp
#define PutByte(n) putc((byte)(n), file)
#define PutWord(n) PutByte(BLo(n)); PutByte(BHi(n))
#define PutLong(n) PutWord(WLo(n)); PutWord(WHi(n))
#define getword() WRead(file)
#define getlong() LRead(file)
#define skipbyte() ch = getbyte()
#define skipword() skipbyte(); skipbyte()
#define skiplong() skipword(); skipword()
#ifdef PS
#define PsEscape(ch) ((ch) == '(' || (ch) == ')' || (ch) == '\\' ? "\\" : "")
#endif
#ifdef META
// Macros to output the various metafile commands used.
#define MetaRecord(S, R) MetaLong((long)(S)); MetaWord(R)
#define MetaSelectObject(O) MetaRecord(4, 0x12D); MetaWord(O)
#define MetaDeleteObject(O) MetaRecord(4, 0x1F0); MetaWord(O)
#define MetaSaveDc() MetaRecord(3, 0x01E)
#define MetaRestoreDc() MetaRecord(4, 0x127); MetaWord((word)-1)
#define MetaWindowOrg(X, Y) MetaRecord(5, 0x20B); MetaWord(Y); MetaWord(X)
#define MetaWindowExt(X, Y) MetaRecord(5, 0x20C); MetaWord(Y); MetaWord(X)
#define MetaCreatePen(S, W, C) MetaRecord(8, 0x2FA); MetaWord(S); \
MetaWord(W); MetaWord(W); MetaLong(C)
#define MetaCreateBrush(S, C) MetaRecord(7, 0x2FC); \
MetaWord(S); MetaLong(C); MetaWord(0 /* Not used */);
#define MetaCreateFont(S, X, Y, C) MetaRecord(12+(S), 0x2FB); MetaWord(Y); \
MetaWord(X); MetaWord(0 /* Angle */); MetaWord(0 /* Not used */); \
MetaWord(400 /* Normal Weight */); MetaWord(0 /* Italic, Underline */); \
MetaWord(WFromBB(0 /* Strikeout */, C)); \
MetaWord(WFromBB(4 /* TrueType */, 0 /* Clip */))
#define MetaBkMode(M) MetaRecord(4, 0x102); MetaWord(M)
#define MetaTextAlign(A) MetaRecord(4, 0x12E); MetaWord(A)
#define MetaTextColor(C) MetaRecord(5, 0x209); MetaLong(C);
#define MetaTextOut(X, Y, S) MetaRecord(7+((S)+1)/2, 0xA32); \
MetaWord(Y); MetaWord(X); MetaWord(S); MetaWord(0 /* ETO */)
#define MetaPoint(X, Y, C) MetaRecord(7, 0x41F); MetaLong(C); \
MetaWord(Y); MetaWord(X);
#define MetaRectangle(X1, Y1, X2, Y2) MetaRecord(7, 0x41B); \
MetaWord(Y2); MetaWord(X2); MetaWord(Y1); MetaWord(X1)
#define MetaEllipse(X1, Y1, X2, Y2) MetaRecord(7, 0x418); \
MetaWord(Y2); MetaWord(X2); MetaWord(Y1); MetaWord(X1)
#define MetaFill(X, Y, C) MetaRecord(8, 0x548); \
MetaWord(1 /* FLOODFILLSURFACE */); MetaLong(C); MetaWord(Y); MetaWord(X);
#define MetaEscape(S) MetaRecord(S, 0x626); \
MetaWord(15 /* MFCOMMENT */); MetaWord(((S)-5)*2 /* Bytes in comment */);
#endif // META
#define WirePoint(x, y, z) WireLine(x, y, z, x, y, z)
extern void BmpSetXY P((Bitmap *, int, int, KV));
extern KV BmpGetXY P((Bitmap *, int, int));
extern void SetXY P((int, int, KI));
extern KI GetXY P((int, int));
extern KI BmGetXY P((int, int));
extern flag FAllocateBmp P((Bitmap *, int, int));
extern flag FLoadBmp P((CONST char *, Bitmap *, flag));
extern void BmpCopyBlock P((CONST Bitmap *, int, int, int, int,
Bitmap *, int, int, int, int));
#ifdef WINANY
extern void BmpCopyWin P((CONST Bitmap *, HDC, int, int));
#endif
extern flag FBmpDrawBack P((Bitmap *));
extern flag FBmpDrawMap P((void));
extern flag FBmpDrawMap2 P((int, int, int, int, real, real, real, real));
extern void WriteXBitmap P((FILE *, CONST char *, char));
extern void WriteAscii P((FILE *));
extern void WriteBmp P((FILE *));
extern flag BeginFileX P((void));
extern void EndFileX P((void));
extern void PsStrokeForce P((void));
extern void PsStroke P((int));
extern void PsLineCap P((flag));
extern void PsDash P((int));
extern void PsLineWidth P((int));
extern void PsFont P((int));
extern void PsBegin P((void));
extern void PsEnd P((void));
extern void MetaWord P((word));
extern void MetaLong P((long));
extern void MetaSz P((CONST char *));
extern void MetaSelect P((void));
extern void MetaInit P((void));
extern void WriteMeta P((FILE *));
extern void WriteWire P((FILE *));
extern void WireLine P((int, int, int, int, int, int));
extern void WireGlobeCalc P((real, real, int *, int *, int *, int, real));
extern void WireDrawGlobe P((flag, real));
extern void WireChartOrbit P((void));
extern void WireChartSphere P((void));
// From xcharts0.cpp
extern int DrawPrint P((CONST char *, int, int));
extern void DrawSidebar P((void));
extern flag DrawFillWheel P((int, int, int, int));
extern void DrawWheel P((real *, real *, int, int, real, real,
real, real, real));
extern void DrawRing P((int, int, real *, real *, int, int, real,
real, real, real, real, real, real, real));
extern void DrawObjects P((ObjDraw *, int, int));
extern void DrawAspectLine
P((int, int, int, int, real, real, real, real, real));
extern flag EnumWorldLines P((int *, int *, int *, int *, int *));
#ifdef CONSTEL
extern flag EnumConstelLines P((int *, int *, int *, int *, int *));
#endif
extern flag FReadWorldData P((CONST char **, CONST char **, CONST char **));
extern flag FGlobeCalc P((real, real, int *, int *, CONST CIRC *, real));
#ifdef SWISS
extern flag EnumStarsLines P((flag, ES **, ES **));
#endif
extern flag EnumExoplanets P((ES *));
extern void DrawLeyLine P((real, real, real, real));
extern void DrawLeyLines P((real));
extern void DrawMapTriangles P((flag, int, CIRC *, real));
extern void DrawMap P((flag, flag, real));
extern void DrawChartX P((void));
// From xcharts1.cpp
extern void LocToHorizon P((real, real, int, int, int, int, int *, int *));
extern void EquToHorizon P((real, real, int, int, int, int, int *, int *));
extern void EclToHorizon P((real, real, int, int, int, int, int *, int *));
extern void LocToHorizonSky P((real, real, CONST CIRC *, int *, int *));
extern void EquToHorizonSky P((real, real, CONST CIRC *, int *, int *));
extern void EclToHorizonSky P((real, real, CONST CIRC *, int *, int *));
extern void LocToTelescope P((real, real, TELE *, int *, int *, real*, real*));
extern void EquToTelescope P((real, real, TELE *, int *, int *, real*, real*));
extern void EclToTelescope P((real, real, TELE *, int *, int *, real*, real*));
extern void XChartWheel P((void));
extern void XChartAstroGraph P((void));
extern KI FormatGridCell P((char *, int, int, int, flag));
extern void XChartGrid P((int, int));
extern void XChartHorizon P((void));
extern void XChartHorizonSky P((void));
extern void XChartTelescope P((void));
extern void XChartLocal P((void));
extern void OrbitPlot P((real *, real *, real *, real, int, PT3R *));
extern void OrbitRecord P((void));
extern void XChartOrbit P((void));
extern void XChartSector P((void));
extern void XChartMidpoint P((void));
extern void DrawArrow P((int, int, int, int));
extern void XChartDispositor P((void));
extern flag DrawCalendarAspect P((CONST InDayInfo *, int, int, int, int));
extern void XChartCalendar P((void));
extern void XChartMoons P((void));
extern void XChartIndian P((void));
extern void XChartSphere P((void));
// From xcharts2.cpp
extern flag FProper P((int));
extern void FillSymbolRing P((real *, real));
extern void FillSymbolRingM P((int, real *, real));
extern void FillSymbolLine P((real *));
extern real PlaceInX P((real));
extern real HousePlaceInX P((real, real));
extern void XChartWheelRelation P((void));
extern void XChartWheelMulti P((void));
extern void XChartGridRelation P((void));
extern void XChartEphemeris P((void));
extern void XChartEsoteric P((void));
extern void XChartTransit P((flag, flag));
extern flag XChartRising P((void));
extern void XChartBiorhythm P((void));
// From xscreen.cpp
extern void InitColorPalette P((int));
extern void InitColorsX P((void));
#ifdef ISG
extern void ResizeWindowToChart P((void));
extern void BeginX P((void));
extern void Animate P((int, int));
extern void CommandLineX P((void));
extern void SquareX P((int *, int *, flag));
extern void InteractX P((void));
extern void EndX P((void));
#endif
extern int NProcessSwitchesX P((int, char **, int, flag, flag, flag));
extern int NProcessSwitchesRareX P((int, char **, int, flag, flag, flag));
extern int DetectGraphicsChartMode P((void));
extern flag FActionX P((void));
#endif // GRAPH
#ifdef WIN
// From wdriver.cpp
extern WI wi;