Kstars

SpatialGeneral.h
1#if !defined(_SpatialGeneral_h)
2#define _SpatialGeneral_h
3//# Filename: SpatialGeneral.h
4//#
5//# This file contains all SDSS Science Archive global information,
6//# including Global Type Definitions, Global Macros, and Global Inlines
7//#
8//# Author: Peter Z. Kunszt
9//#
10//# Date: October 19, 1999
11//#
12//# SPDX-FileCopyrightText: 2000 Peter Z. Kunszt Alex S. Szalay, Aniruddha R. Thakar
13//# The Johns Hopkins University
14//#
15//# Modification History:
16//#
17//# Oct 18, 2001 : Dennis C. Dinge -- Replaced ValVec with std::vector:
18//#
19
20// Type Definitions
21
22// define portable int and float types where not already defined
23// The SDSS Science Archive and Objectivity define the very same thing.
24// Objectivity defines these in ooMachine.h (version 4) and
25// in ooConfig.h (version 5).
26//
27
28// The following list is for different machines:
29//
30// ------------------------------------------------------------------------
31// MACHINE | CHAR | SHORT | INT | LONG | FLOAT | DOUBLE | LONG DOUBLE |
32// ------------------------------------------------------------------------
33// SUN | 8 | 16 | 32 | 32 | 32 | 64 | 128 |
34// ------------------------------------------------------------------------
35// ALPHA | 8 | 16 | 32 | 64 | 32 | 64 | 64 |
36// ------------------------------------------------------------------------
37// SGI-n32| 8 | 16 | 32 | 32 | 32 | 64 | 128 |
38// ------------------------------------------------------------------------
39// SGI | 8 | 16 | 32 | 32 | 32 | 64 | 64 |
40// ------------------------------------------------------------------------
41// NT | 8 | 16 | 32 | 32 | 32 | 64 | 64 |
42// ------------------------------------------------------------------------
43// LINUX | 8 | 16 | 32 | 32 | 32 | 64 | 96 |
44// ------------------------------------------------------------------------
45//
46
47/* get all the standard defines from the platform */
48#include <cstdlib>
49
50#if !defined(OO_MACHINE_H) && !defined(OO_CONFIG_H) && !defined(SXGENERAL_H)
51typedef char int8;
52typedef unsigned char uint8;
53typedef short int int16;
54typedef unsigned short int uint16;
55typedef int int32;
56typedef unsigned int uint32;
57typedef float float32;
58typedef double float64;
59#ifdef _WIN32
60#ifdef _MSC_VER
61typedef __int64 int64;
62typedef unsigned __int64 uint64;
63#else
64typedef long long int64;
65typedef unsigned long long uint64;
66#endif
67#else
68typedef long long int64;
69typedef unsigned long long uint64;
70#endif
71#endif
72
73#if defined(__sun) || defined(__sgi)
74#define SPATIALBIGENDIAN
75#endif
76
77#define IDSIZE 64
78#define HTMNAMEMAX 32
79#define HTMMAXDEPTH 25
80#define MAX_SQL_DEPTH 20
81#define HTMMAXKEEP 12
82#define HTMMAXBIT 14
83
84// Global Math Constants
85
86const float64 gPi = 3.1415926535897932385E0;
87const float64 gPr = gPi / 180.0;
88const float64 gEpsilon = 1.0E-15;
89// CVSversion = "$Name: $";
90
91//
92// To Simplify Porting, define our platforms:
93// Digital UNIX -> SpatialDigitalUnix
94// SGI -> SpatialSGI
95// WINNT -> SpatialWinNT
96//
97// These are set here, and then included by everything else.
98
99// Flag SpatialStandardTemplate: Defined to indicating proper method
100// for explicit template instantiation. If a compiler supports the
101// standard explicit template instantiation, define.
102//
103
104#if defined(__APPLE__)
105#define LINKAGE
106#endif
107
108#if defined(__unix__) || defined(__unix)
109#define LINKAGE
110#elif defined(_WIN32)
111#define SpatialWinNT 1
112// This warning is about template instances being exported in the dll...
113#pragma warning(disable : 4251)
114
115// Define LINKAGE for NT VC++6 compiler
116
117#ifdef _EXPORTING
118#define LINKAGE __declspec(dllexport)
119#else
120#define LINKAGE __declspec(dllimport)
121#endif
122
123#endif /* _WIN32 */
124
125#ifndef SpatialWinNT
126#define IDHIGHBIT 0x8000000000000000LL
127#define IDHIGHBIT2 0x4000000000000000LL
128#endif
129
130#endif /* SPATIALGENERAL_H */
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 22 2024 12:11:15 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.