RflySimSDK v3.05
RflySimSDK说明文档
载入中...
搜索中...
未找到
vrpn_Configure.h
1// -*- c++ -*-
2
3#ifndef VRPN_USING_CMAKE
4// Only using this configuration file if not using CMake.
5// An #else follows at the bottom of the file.
6
7#ifndef VRPN_CONFIGURE_H
8
9//--------------------------------------------------------------
10/* IMPORTANT NOTE: If you are using CMake to build VRPN, this
11 file DOES NOT affect your build. vrpn_Configure.h.cmake_in
12 is processed automatically into a vrpn_Configure.h file
13 placed in your build directory using the choices you make in
14 CMake. Until all modules are fully configured using CMake,
15 you may have to edit the paths that are listed near the
16 bottom of the first section of that file, then re-run CMake
17 to regenerate vrpn_Configure.h. */
18//--------------------------------------------------------------
19
20//--------------------------------------------------------------
21/* This file contains configuration options for VRPN. The first
22 section has definition lines that can be commented in or out
23 at build time. The second session has automaticly-generated
24 directives and should not be edited. */
25//--------------------------------------------------------------
26
27//--------------------------------------------------------//
28// EDIT BELOW THIS LINE FOR NORMAL CONFIGURATION SETTING. //
29//--------------------------------------------------------//
30
31//-----------------------
32// Default port to listen on for a server. It used to be 4500
33// up through version 6.03, but then all sorts of VPNs started
34// using this, as did Microsoft. Port 3883 was assigned to VRPN
35// by the Internet Assigned Numbers Authority (IANA) October, 2003.
36// Change this to make a location-specific default if you like.
37// The parentheses are to keep it from being expanded into something
38// unexpected if the code has a dot after it.
39#define vrpn_DEFAULT_LISTEN_PORT_NO (3883)
40
41//-----------------------
42// Use compile-time static asserts.
43// Should be reasonably portable, but off by default because they
44// haven't been tested for extreme portability.
45//#define VRPN_USE_STATIC_ASSERTIONS
46
47//-----------------------
48// Use Winsock2 library rather than Winsock.
49#define VRPN_USE_WINSOCK2
50
51//-----------------------
52// Instructs VRPN to expose the vrpn_gettimeofday() function also
53// as gettimeofday() so that external programs can use it. This
54// has no effect on any system that already has gettimeofday()
55// defined, and is put here for Windows. This function should
56// not really be implemented within VRPN, but it was expedient to
57// include it when porting applications to Windows. Turn this
58// off if you have another implementation, or if you want to call
59// vrpn_gettimeofday() directly.
60#define VRPN_EXPORT_GETTIMEOFDAY
61
62//-----------------------
63// Tells VRPN to compile with support for the Message-Passing
64// Interface (MPI) library. There is a configuration section below
65// that has a library path for the MPI library to link against.
66// You will need to add the path to mpi.h and other needed files
67// into your Visual Studio Tools/Options/Projects and Solutions/
68// C++ Directories include path. The original implementation is
69// done with MPICH2, but an attempt has been made to use only
70// MPI version 1 basic functions.
71//#define VRPN_USE_MPI
72
73//-----------------------
74// Tells VRPN to compile with support for the Modbus
75// library. There is a configuration section below
76// that has a library path for the Modbus library to link against.
77// You will need to add the path to modbus.h and other needed files
78// into your Visual Studio Tools/Options/Projects and Solutions/
79// C++ Directories include path.
80//#define VRPN_USE_MODBUS
81
82//-----------------------
83// Instructs VRPN to use phantom library to construct a unified
84// server, using phantom as a common device, and phantom
85// configuration in .cfg file. This will not build (at least
86// on Visual Studio 2008) with the 3.1 version of OpenHaptics.
87// There will be problems with #include and library directories,
88// and then a failure to link due to undefined symbol. Use CMAKE
89// if you want to compile with a Phantom -- that version works
90// on VS2008 and 3.1 at least.
91//#define VRPN_USE_PHANTOM_SERVER
92
93//------------------------
94// Instructs vrpn to use SensAble's HDAPI rather than GHOST library.
95// Only used in conjuntion with VRPN_USE_PHANTOM_SERVER.
96// PLEASE SPECIFY PATH TO HDAPI IN NEXT SECTION IF YOU USE THIS.
97// Also, you need to go to the vrpn_phantom and vrpn_server projects
98// and remove the GHOST include directories from the include paths.
99// Yes, HDAPI fails if it even has them in the path (as so many other
100// things also fail). At least we're rid of them now. When you
101// uncomment it (to use GHOST), add the following to the include
102// directories for the vrpn_phantom project: $(SYSTEMDRIVE)\Program
103// Files\SensAble\GHOST\v4.0\include,$(SYSTEMDRIVE)\Program
104// Files\SensAble\GHOST\v4.0\external\stl,
105// On SGI, you need to uncomment the GHOST lines in the Makefile in
106// the server_src directory.
107#define VRPN_USE_HDAPI
108
109//------------------------
110// Instructs vrpn to use Ghost 3.1 instead of Ghost 3.4.
111// Only used in conjuntion with VRPN_USE_PHANTOM_SERVER.
112// PLEASE SPECIFY PATH TO GHOSTLIB IN NEXT SECTION IF YOU USE THIS
113// (This is expected to be used on systems where Ghost 4.0 is not
114// available, such as the SGI platform. If you are using this on
115// a Windows PC with Visual Studio, you will need to alter
116// server_src/vrpn_phantom.dsp to reference the Ghost 3.1 include
117// paths.)
118//#define VRPN_USE_GHOST_31
119
120//-----------------------
121// Instructs VRPN to use the high-performance timer code on
122// Windows, rather than the default clock which has an infrequent
123// update. At one point in the past, an implementation of this
124// would only work correctly on some flavors of Windows and with
125// some types of CPUs.
126// There are actually two implementations of the faster windows clock. The
127// original one, made by Hans Weber, checks the clock rate to see how fast the
128// performance clock runs (it takes a second to do this when the program first
129// calls vrpn_gettimeofday()). The second version by Haris Fretzagias relies on
130// the timing supplied by Windows. To use the second version, also define
131// VRPN_WINDOWS_CLOCK_V2.
132#define VRPN_UNSAFE_WINDOWS_CLOCK
133#define VRPN_WINDOWS_CLOCK_V2
134
135//-----------------------
136// Instructs VRPN library and server to include code that uses
137// the DirectX SDK. If you set this, you may to edit the
138// system configuration section below to point at the correct version
139// of DirectX. WARNING: With the August 2006 DirectX SDK, you
140// cannot link against the debug library in Visual Studio 6.0,
141// only the release. Hopefully, Visual Studio.NET doesn't have
142// this problem.
143// IMPORTANT! If you define this, you need to edit the Tools/Options
144// menu:
145// For Visual studio 6, use the Directories tab, and add the
146// include and lib paths to the TOP of the lists for all configurations.
147// For Visual studio .NET, add to the top of the Projects and Solutions/
148// VC++ Directories entry.
149// This will let the code find the right version when it compiles.
150//#define VRPN_USE_DIRECTINPUT
151//#define VRPN_USE_WINDOWS_XINPUT
152
153// The DirectInput-based zSight tracker requires ATL for smart pointers,
154// which sadly isn't everywhere (VC Express, MXE cross compiling, ...).
155//#define VRPN_HAVE_ATLBASE
156
157//-----------------------
158// Instructs VRPN library and server to include code that uses
159// the DirectShow SDK. If you set this, you may to edit the
160// system configuration section below to point at the correct version
161// of the Platform SDK. WARNING: With the August 2006 DirectX SDK, you
162// cannot link against the debug library in Visual Studio 6.0,
163// only the release. Visual Studio.NET doesn't have this problem.
164//#define VRPN_USE_DIRECTSHOW
165
166//-----------------------
167// Instructs the VRPN server to create an entry for the Adrienne
168// time-code generator. This is a device that produces time values
169// from an analog video stream so that events in the virtual world
170// can be synchronized with events on a movie. The Adrienne folder
171// should be located at the same level as the VRPN folder for the
172// code to find it.
173//#define VRPN_INCLUDE_TIMECODE_SERVER
174
175//-----------------------
176// Compiles the InterSense Tracker using the
177// InterSense Interface Libraries SDK (tested for version
178// 3.45) on windows. This should work with all Intersense trackers,
179// both the USB and the serial port versions. The files isense.h,
180// types.h and isense.c should be put in a directory called 'isense'
181// at the same level as the vrpn directory. The isense.dll should
182// be put either in Windows/system32 or in the location where the
183// executable lives or somewhere on the path.
184//#define VRPN_INCLUDE_INTERSENSE
185
186//-----------------------
187// Instructs VRPN library and server to include code that uses
188// the National Instruments Nidaq library to control analog outputs.
189// Later in this file, we also instruct the compiler to link with
190// the National Instruments libraries if this is defined. Either or
191// both of these can be defined, depending on which library you
192// need to use.
193//#define VRPN_USE_NATIONAL_INSTRUMENTS
194//#define VRPN_USE_NATIONAL_INSTRUMENTS_MX
195
196//-----------------------
197// Instructs VRPN library and server to include code that uses
198// the US Digital SEI/A2 library to control analog inputs from the
199// A2 absolute encoder.
200// Later in this file, we also instruct the compiler to link with
201// the US Digital library if this is defined. You also need to
202// define VRPN_USE_NATIONAL_INSTRUMENTS_MX above if you want to
203// use this.
204//#define VRPN_USE_USDIGITAL
205
206//-----------------------
207// Instructs VRPN to use the default room space transforms for
208// the Desktop Phantom as used in the nanoManipulator application
209// rather than the default world-origin with identity rotation.
210// Please don't anyone new use the room space transforms built
211// into VRPN -- they are a hack pulled forward from Trackerlib.
212#define DESKTOP_PHANTOM_DEFAULTS
213
214//------------------------
215// Instructs VRPN to use microscribe3D library to construct a unified
216// server
217//#define VRPN_USE_MICROSCRIBE
218
219//------------------------
220// Compiles the VRPN library with the PhaseSpace Tracker using the
221// PhaseSpace OWL API on Linux and Windows.
222//
223// In Linux:
224// The PhaseSpace header files (owl.h, etc) and libraries (libowlsock)
225// should be placed in the phasespace directory at the same level as
226// the vrpn folder. Also, PHASESPACE needs to be uncommented in the
227// server_src/Makefile so that the libraries are properly linked.
228// libowlsock.so will need to be present in the directory of the
229// final executable or in the default library path such as /usr/lib
230//
231// In Windows:
232// The PhaseSpace header files (owl.h, etc) should be placed in the
233// phasespace directory at the same level as the vrpn folder.
234// libowlsock.lib will need to be located there as well.
235// libowlsock.dll will need to be in the path or with the executable
236// at run time. Edit the path below to say where the .lib file
237// can be found.
238//
239//#define VRPN_INCLUDE_PHASESPACE
240
241//-----------------------
242// Instructs VRPN to use a DLL interface on Windows systems.
243// When using this, link with VRPNDLL.LIB (and VRPN.DLL) rather
244// than VRPN.LIB in user code. This is experimental and is
245// under development to enable C# and other languages to pull in
246// VRPN. This is only needed when trying to link VRPN with
247// languages other than C++ (and not even for Java). If you don't
248// have a good reason to, don't define it.
249// Not implemented for .so-based Unix systems.
250//#define VRPN_USE_SHARED_LIBRARY
251
252//------------------------
253// Instructs VRPN to use GPM Linux interface mouse interface.
254// WARNING: If you define this, then you must also edit the server_src
255// Makefile to include "-lgpm" into the SYSLIBS definition line for the
256// architecture you use this on. We had to change this because not all
257// Linux releases included this library.
258//#define VRPN_USE_GPM_MOUSE
259
260//------------------------
261// Instructs VRPN to use the Motion C API library to interface VRPN to
262// the their MotionNode tracker. Requires the shared library at run-time
263// to function. No external dependencies to build.
264//#define VRPN_USE_MOTIONNODE
265
266//------------------------
267// Instructs VRPN to compile code for the Nintendo Wii Remote controller,
268// getting access to it through the Wiiuse library in Windows and Linux.
269// Note that this requires installing a bunch of other stuff, and that some
270// bluetooth stacks cause people trouble. See the README file in the WiiUse
271// library for more info. Also note that the
272// WiiUse library is GPL, which is more restrictive than the VRPN public-
273// domain license, so check out its license file before building this driver
274// into your code. The original WiiUse library was abandoned and a new
275// fork by Ryan Pavlik is available at https://github.com/rpavlik/wiiuse.
276// To get the WiiUse library to compile on Visual Studio 2005 (apparently
277// not for VS 2008), you need to add the include path
278// to the driver developer kit (C:\WINDDK\3790.1830\inc\wxp) and the
279// library path to hid.lib (C:\WINDDK\3790.1830\lib\wxp\i386) to the
280// include and library directories in Visual Studio.
281// Also, edit the configuration below to point to the WiiUse include
282// file and library.
283// Note that the wiiuse.dll needs to be in the path when running a server
284// that uses WiiUse in Windows.
285//#define VRPN_USE_WIIUSE
286
287// Instructs VRPN to compile code to handle Hillcrest Labs' Freespace
288// devices such as the Loop, and FRCM. You will also need the libfreespace
289// library which is available at
290// http://libfreespace.hillcrestlabs.com/content/download.
291// There are prebuilt binaries for Windows, and source available that should
292// work on Windows, Linux or OS X. You will need to make sure the header files
293// and library are accessible to the compiler. libfreespace is released under
294// the LGPL and we (Hillcrest Labs) view static and dynamic linking as the same.
295// We (Hillcrest Labs) do not require code linked to libfreespace (statically or
296// dynamically) to be released under any particular license.
297//#define VRPN_USE_FREESPACE
298
299//------------------------
300// Instructs VRPN to include code for the Novint Falcon haptic device.
301// Access is provided through the libnifalcon library library on Windows,
302// MacOSX and Linux. This may require additional libraries for programming
303// USB devices. Please consult the corresponding homepages.
304//#define VRPN_USE_LIBNIFALCON
305
306//------------------------
307// Instructs VRPN to compile code to use Trivisio's Colibri inertial
308// tracker. You will also need the SDK, which is available at
309// http://www.trivisio.com/products/motiontracking/colibri#download
310// (tested on Windows). VRPN_TRIVISIOCOLIBRI_H and
311// VRPN_TRIVISIOCOLIBRI_LIB_PATH
312// below point to the default installation locations on Windows. Edit them
313// if installed elsewhere. Note that Trivisio.dll and pthreadVC2.dll need to be
314// in
315// the path when running the server on Windows
316//#define VRPN_USE_TRIVISIOCOLIBRI
317
318//------------------------
319// Instructs VRPN to attempt to use HID. If you don't have libusb installed
320// on Linux, you'll want to turn this off so that it doesn't fail to compile.
321// This should work fine on Windows, so we define it by default there.
322// For the Mac, let CMake configure this; the built-in Makefile doesn't know
323// how to compile with local HIDAPI, which we now need.
324// For Linux, you need to have HIDAPI (either local or otherwise) for this
325// to work, so this definition is not in by default there.
326#if defined(_WIN32)
327#if !defined(__MINGW__)
328#define VRPN_USE_HID
329#endif
330#endif
331#define VRPN_USE_HID
332
333//------------------------
334// Instructs VRPN to link in the source code to a local version of
335// hidapi to access HID devices. The source code for this project
336// is included as a git submodule under submodule/hidapi. To pull
337// this down if it is not present, use the commands:
338// 'git submodule init; git submodule update' from the vrpn directory.
339// If you have a system hidapi and you prefer to use it, then do not
340// define this here. Otherwise, define it so that VRPN will be able
341// to access HID devices.
342// Note that on Linux you will also need to have the libusb-1.0-0-dev
343// package installed so that we can compile the code. You
344// will also need to uncommment the SYSLIBS line for HID in the
345// server_src/Makefile for this to link.
346// On the Mac, this needs to be configured via CMake; the standard
347// Makefile doesn't know how to handle HIDAPI.
348#if !defined(__MINGW__) && !defined(__APPLE__)
349#define VRPN_USE_LOCAL_HIDAPI
350#endif
351#define VRPN_USE_LOCAL_HIDAPI
352
353//------------------------
354// Instructs VRPN to attempt to use LibUSB-1.0. This will compile and
355// link servers that use USB directly (as opposed to those that use it
356// through the HID interface).
357// See http://libusb.sourceforge.net for more on LibUSB-1.0.
358// Note that on Linux you will also need to have the libusb-1.0-0-dev
359// package installed so that we can compile the code. You
360// will also need to uncommment the SYSLIBS line for HID in the
361// server_src/Makefile for this to link.
362// Note that to compile on Windows you will need to have downloaded and
363// installed
364// the libusb.h file and libusb-1.0.lib files; the default location for
365// the library is C:Program Files\libusb-1.0 and for the include file
366// is in C:Program Files\libusb-1.0\libusb. To open a device on Windows, you
367// will need to have installed a driver that lets LibUSB open the
368// device. Generic HID devices and devices that use a WinUSB driver
369// should work without adding a driver. If you need to add a driver,
370// consider using the libUSB Zadig.exe program; do not do this for a
371// HID device or a device that has another driver, as it can prevent the
372// device from operating except through LibUSB.
373// Note that on Linux you will also need to have the libusb-1.0-0-dev
374// package installed so that we can compile the code.
375//#define VRPN_USE_LIBUSB_1_0
376
377// Instructs VRPN to compile code to handle JSON network messages.
378// This requires jsoncpp.
379// JSON Network (UDP) mesages are used by the vrpn widgets for Android,
380//#define VRPN_USE_JSONNET
381
382//------------------------
383// Instructs VRPN to compile code to use the Arrington Research
384// ViewPoint EyeTracker. You will also need to set VRPN_VIEWPOINT_H
385// and VRPN_VIEWPOINT_LIB_PATH below to point to the correct location
386// on your system. Note that the VRPN server and ViewPoint calibration
387// software must use the same copy of the VPX_InterApp.dll
388//#define VRPN_USE_VIEWPOINT
389
390//------------------------
391// Use DevInput devices.
392#if defined(linux) && !defined(__APPLE__)
393#define VRPN_USE_DEV_INPUT
394#endif
395
396//-------------------------
397// Use Linux kernel joystick support:
398// note that using this kernel header
399// makes the GPL apply to the server!
400#if defined(linux)
401#define VRPN_USE_JOYLIN
402#endif
403
404//------------------------
405// Instructs VRPN to compile code to use the Polhemus Developer
406// (PDI) library to enable opening several of their trackers using
407// this interface (the G4 was the original one this was written
408// for, but new versions are available for the Fastrak and Liberty).
409//#define VRPN_USE_PDI
410
411//------------------------------------------------------------------//
412// SYSTEM CONFIGURATION SECTION //
413// EDIT THESE DEFINITIONS TO POINT TO OPTIONAL LIBRARIES. THEY ARE //
414// USED BELOW TO LOCATE LIBRARIES AND INCLUDE FILES. //
415//------------------------------------------------------------------//
416
417#define VRPN_SYSTEMDRIVE "C:"
418
419#define VRPN_PHASESPACE_LIB_PATH "../../phasespace/"
420
421#define VRPN_WIIUSE_H "E:/borland/lib/wiiuse_v0.12_win/wiiuse.h"
422#define VRPN_WIIUSE_LIB_PATH "E:/borland/lib/wiiuse_v0.12_win"
423
424#if defined(VRPNDLL_EXPORTS) && !defined(VRPN_USE_SHARED_LIBRARY)
425#define VRPN_FREESPACE_LIB_PATH "../libfreespace/lib"
426#else
427#define VRPN_FREESPACE_LIB_PATH "../../libfreespace/lib"
428#endif
429
430#define VRPN_TRIVISIOCOLIBRI_H \
431 "C:/Program Files/Trivisio/Colibri/include/TrivisioColibri.h"
432#define VRPN_TRIVISIOCOLIBRI_LIB_PATH "C:/Program Files/Trivisio/Colibri/lib/"
433
434#define VRPN_VIEWPOINT_H "E:/borland/lib/ViewPoint 2.8.6.21/SDK/vpx.h"
435#define VRPN_VIEWPOINT_LIB_PATH "E:/borland/lib/ViewPoint 2.8.6.21/SDK/"
436
437#ifdef linux
438#define VRPN_HDAPI_PATH "/usr/lib64"
439#else
440#define VRPN_HDAPI_PATH VRPN_SYSTEMDRIVE "/Program Files/SensAble/3DTouch/lib/"
441#endif
442#define VRPN_HDAPI_UTIL_PATH \
443 VRPN_SYSTEMDRIVE "/Program Files/SensAble/3DTouch/utilities/lib/"
444#define VRPN_GHOST_31_PATH \
445 VRPN_SYSTEMDRIVE "/Program Files/SensAble/GHOST/v3.1/lib/"
446#define VRPN_GHOST_40_PATH \
447 VRPN_SYSTEMDRIVE "/Program Files/SensAble/GHOST/v4.0/lib/"
448
449#define VRPN_NIDAQ_PATH \
450 VRPN_SYSTEMDRIVE "/Program Files/National Instruments/NI-DAQ/Lib/"
451#define VRPN_NIDAQ_MX_PATH \
452 VRPN_SYSTEMDRIVE "/Program Files/National Instruments/NI-DAQ/DAQmx ANSI " \
453 "C Dev/lib/msvc/"
454#define VRPN_USDIGITAL_PATH VRPN_SYSTEMDRIVE "/Program Files/SEI Explorer/"
455
456#ifdef VRPN_USE_MPI
457#pragma comment(lib, VRPN_SYSTEMDRIVE "/Program Files/MPICH2/lib/mpi.lib")
458#endif
459
460#ifdef VRPN_USE_MODBUS
461#ifdef _DEBUG
462#pragma comment(lib, VRPN_SYSTEMDRIVE \
463 "/Program Files/usr/local/lib/libmodbusd.lib")
464#else
465#pragma comment(lib, \
466 VRPN_SYSTEMDRIVE "/Program Files/usr/local/lib/libmodbus.lib")
467#endif
468#endif
469
470// Load Adrienne libraries if we are using the timecode generator.
471// If this doesn't match where you have installed these libraries,
472// edit the following lines to point at the correct libraries. Do
473// this here rather than in the project settings so that it can be
474// turned on and off using the definition above.
475#ifdef VRPN_INCLUDE_TIMECODE_SERVER
476#pragma comment(lib, "../../Adrienne/AEC_DLL/AEC_NTTC.lib")
477#endif
478
479#ifdef VRPN_USE_LIBUSB_1_0
480#define VRPN_LIBUSB_PATH VRPN_SYSTEMDRIVE "/Program Files/libusb-1.0/"
481#endif
482
483//---------------------------------------------------------------//
484// DO NOT EDIT BELOW THIS LINE FOR NORMAL CONFIGURATION SETTING. //
485//---------------------------------------------------------------//
486
487// Use this macro in a file if it might be empty (compiling out completely)
488// to squash Visual Studio warning LNK4221.
489// Inspiration from
490// http://stackoverflow.com/questions/1822887/what-is-the-best-way-to-eliminate-ms-visual-c-linker-warning-warning-lnk422
491#ifdef _MSC_VER
492#define VRPN_SUPPRESS_EMPTY_OBJECT_WARNING() \
493 namespace { \
494 char vrpn_SuppressEmptyObjectDummy##__LINE__; \
495 }
496#else
497#define VRPN_SUPPRESS_EMPTY_OBJECT_WARNING()
498#endif
499
500// DirectInput include file and libraries.
501// Load DirectX SDK libraries and tell which version we need if we are using it.
502#ifdef VRPN_USE_DIRECTINPUT
503#define DIRECTINPUT_VERSION 0x0800
504#include <dinput.h>
505#endif
506
507// autolinking pragma only works/makes sense with MSVC
508#ifdef _MSC_VER // [
509
510// Load the library for WiiUse.
511#ifdef VRPN_USE_WIIUSE
512#ifdef _DEBUG
513#pragma comment(lib, VRPN_WIIUSE_LIB_PATH "/msvc/Debug/wiiuse.lib")
514#else
515#pragma comment(lib, VRPN_WIIUSE_LIB_PATH "/msvc/Release/wiiuse.lib")
516#endif
517#endif
518
519#ifdef VRPN_USE_FREESPACE
520#ifdef _DEBUG
521// #pragma comment(lib, VRPN_FREESPACE_LIB_PATH "/Debug/libfreespaced.lib")
522#pragma comment(lib, VRPN_FREESPACE_LIB_PATH "/Release/libfreespace.lib")
523#else
524#pragma comment(lib, VRPN_FREESPACE_LIB_PATH "/Release/libfreespace.lib")
525#endif
526#endif
527
528// Load VRPN Phantom library if we are using phantom server as unified server
529// Load SensAble Technologies GHOST library to run the Phantom
530// NOTE: The paths to these libraries are set in the Settings/Link tab of
531// the various project files. The paths to the include files are in the
532// Settings/C++/preprocessor tab.
533#ifdef VRPN_USE_PHANTOM_SERVER
534#ifdef VRPN_USE_HDAPI
535#pragma comment(lib, VRPN_HDAPI_PATH "hd.lib")
536#ifdef _DEBUG
537#pragma comment(lib, VRPN_HDAPI_UTIL_PATH "hdud.lib")
538#else
539#pragma comment(lib, VRPN_HDAPI_UTIL_PATH "hdu.lib")
540#endif
541#pragma comment(lib, VRPN_HDAPI_PATH "hl.lib")
542#else
543#ifdef VRPN_USE_GHOST_31
544#pragma comment(lib, VRPN_GHOST_31_PATH "GHOST31.lib")
545#else
546#pragma comment(lib, VRPN_GHOST_40_PATH "GHOST40.lib")
547#endif
548#endif
549#endif
550
551#ifdef VRPN_USE_DIRECTINPUT
552#pragma comment(lib, "dxguid.lib")
553// Newer versions of the SDK have renamed this dxerr.lib;
554// dxerr9.lib has also been said to work.
555#pragma comment(lib, "dxerr.lib")
556#pragma comment(lib, "dinput8.lib")
557#endif
558
559// Load National Instruments libraries if we are using them.
560// If this doesn't match where you have installed these libraries,
561// edit the following lines to point at the correct libraries. Do
562// this here rather than in the project settings so that it can be
563// turned on and off using the definition above.
564// NOTE: The paths to these libraries are set in the Settings/Link tab of
565// the various project files. The paths to the include files are in the
566// Settings/C++/preprocessor tab.
567#ifdef VRPN_USE_NATIONAL_INSTRUMENTS
568#pragma comment(lib, VRPN_NIDAQ_PATH "nidaq32.lib")
569#pragma comment(lib, VRPN_NIDAQ_PATH "nidex32.lib")
570#endif
571#ifdef VRPN_USE_NATIONAL_INSTRUMENTS_MX
572#pragma comment(lib, VRPN_NIDAQ_MX_PATH "NIDAQmx.lib")
573#endif
574
575// Load US Digital libraries if we are using them.
576// If this doesn't match where you have installed these libraries,
577// edit the following lines to point at the correct libraries. Do
578// this here rather than in the project settings so that it can be
579// turned on and off using the definition above.
580// NOTE: The paths to these libraries are set in the Settings/Link tab of
581// the various project files. The paths to the include files are in the
582// Settings/C++/preprocessor tab.
583#ifdef VRPN_USE_USDIGITAL
584#pragma comment(lib, VRPN_USDIGITAL_PATH "SEIDrv32.lib")
585#endif
586
587// Load Microscribe-3D SDK libraries
588// If this doesn't match where you have installed these libraries,
589// edit the following lines to point at the correct libraries. Do
590// this here rather than in the project settings so that it can be
591// turned on and off using the definition above.
592#ifdef VRPN_USE_MICROSCRIBE
593#pragma comment(lib, "armdll32.lib")
594#endif
595
596// Load Trivisio Colibri library
597#ifdef VRPN_USE_TRIVISIOCOLIBRI
598#pragma comment(lib, VRPN_TRIVISIOCOLIBRI_LIB_PATH "Trivisio.lib")
599#endif
600
601// Load Arrington Research ViewPoint EyeTracker library
602#ifdef VRPN_USE_VIEWPOINT
603#pragma comment(lib, VRPN_VIEWPOINT_LIB_PATH "VPX_InterApp.lib")
604#endif
605
606#ifdef VRPN_USE_LIBUSB_1_0
607#pragma comment(lib, VRPN_LIBUSB_PATH "libusb-1.0.lib")
608#endif
609
610#endif // ] _MSC_VER
611
612// This will be defined in the VRPN (non-DLL) project and nothing else
613// Overrides USE_SHARED_LIBRARY to get rid of "inconsistent DLL linkage"
614// warnings.
615#ifdef VRPNDLL_NOEXPORTS
616#undef VRPN_USE_SHARED_LIBRARY
617#endif
618
619// This will be defined in the VRPN (DLL) project and nothing else
620// Forces "USE_SHARED_LIBRARY independent of definition above so that the
621// DLL will build
622#if defined(VRPNDLL_EXPORTS) && !defined(VRPN_USE_SHARED_LIBRARY)
623#define VRPN_USE_SHARED_LIBRARY
624#endif
625
626// For client code, make sure we add the proper library dependency to the linker
627#ifdef _WIN32 // [
628#ifdef _MSC_VER // [
629#ifdef VRPN_USE_WINSOCK2
630#pragma comment(lib, "ws2_32.lib") // VRPN requires the Windows Sockets library.
631#else
632#pragma comment(lib, \
633 "wsock32.lib") // VRPN requires the Windows Sockets library.
634#endif
635#endif // ] _MSC_VER
636#ifdef VRPN_USE_SHARED_LIBRARY
637#ifdef VRPNDLL_EXPORTS
638#define VRPN_API __declspec(dllexport)
639#else
640#define VRPN_API __declspec(dllimport)
641#endif
642#else
643#define VRPN_API
644#endif
645#define VRPN_CALLBACK __stdcall
646#else // ] WIN32 [
647// In the future, other architectures may need their own sections
648#define VRPN_API
649#define VRPN_CALLBACK
650#endif // ] not WIN32
651
652#define VRPN_CONFIGURE_H
653#endif
654
655#else // VRPN_USING_CMAKE
656
657// When using CMake, we need to use the vrpn_Configure.h generated in the
658// build directory instead.
659
660//#pragma message "NOTE: File included \"vrpn_Configure.h\" from the source dir
661// even though this is a CMake build!"
662#ifndef VRPN_CONFIGURE_FORWARDING
663#define VRPN_CONFIGURE_FORWARDING
664#include VRPN_USING_CMAKE
665#undef VRPN_CONFIGURE_FORWARDING
666#else
667#error \
668 "Build system error: non-CMake vrpn_Configure.h being repeatedly/recursively included"
669#endif
670#endif