Open Inventor Reference
SbSystem.h
Go to the documentation of this file.
1/*
2 *
3 * Copyright (C) 2006 MeVis Research GmbH All Rights Reserved.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
21 *
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
26 * Contact information: MeVis, Center for Medical Diagnostic Systems and
27 * Visualization GmbH, Universitätsallee 29, D-28359 Bremen, GERMANY, or:
28 *
29 * http://www.mevis.de
30 *
31 */
32
33/*
34 * Copyright (C) 2006 MeVis Research GmbH
35 *
36 _______________________________________________________________________
37 _______________ M E V I S R E S E A R C H G M B H _______________
38 |
39 | Description:
40 | The file defines some platform specific macros
41 |
42 | Author(s) : Felix Ritter
43 |
44 _______________ M E V I S R E S E A R C H G M B H _______________
45 _______________________________________________________________________
46 */
47
48#ifndef _SB_SYSTEM_
49#define _SB_SYSTEM_
50
52
53#ifdef WIN32
54
56#ifdef _MSC_VER
57# pragma warning(disable:4244) // float, double
58# pragma warning(disable:4305) // float, double
59# pragma warning(disable:4309) // float, double
60# pragma warning(disable:4251) // export
61# pragma warning(disable:4291) // no delete destructor
62#endif
63
64#include <windows.h>
65#include <winsock.h> // declares many unix types
66#include <math.h>
67
74#if defined(INVENTOR_EXPORTS) && !defined(INVENTOR_IMPORTS)
75# define INVENTOR_API __declspec(dllexport)
76#else
77# define INVENTOR_API __declspec(dllimport)
78#endif
79
80#ifdef _DEBUG
81# define SGIOIVDLL "Inventor_d.dll"
82# define SGIOIVLIB "Inventor_d.lib"
83#else
84# define SGIOIVDLL "Inventor.dll"
85# define SGIOIVLIB "Inventor.lib"
86#endif
87
89#if defined(_MSC_VER) && !defined(__SGIOIV_BUILD_DLL)
90# pragma comment(lib,SGIOIVLIB)
91#endif
92
93#else // not WIN32
94
95#define INVENTOR_API
96
97#ifndef CALLBACK
98# define CALLBACK
99#endif
100
101#endif // WIN32
102
104
105#ifdef __APPLE__
106
107#include <AvailabilityMacros.h>
108
109#if defined(__APPLE_CC__) && (__APPLE_CC__ < 5400)
110# define OPENGL_CALLBACKFUNC GLvoid (CALLBACK *)(...)
111#else
112# define OPENGL_CALLBACKFUNC GLvoid (CALLBACK *)()
113#endif
114
115#else // not __APPLE__
116
117#define OPENGL_CALLBACKFUNC GLvoid (CALLBACK *)()
118
119#endif // __APPLE__
120
122
123#if defined(WIN32)
124
125#define IV_DEFAULT_FONTNAME "Times"
126
127#elif defined(__APPLE__)
128
129#define IV_DEFAULT_FONTNAME "Times-Roman"
130
131#else
132
133#define IV_DEFAULT_FONTNAME "Utopia-Regular"
134
135#endif
136
137#endif // _SB_SYSTEM_