Removed osgWX and wxsgv from the repositry as it is intend to keep the core
distribution clean from GUI examples, these instead should live in the bazaar. This can better accomodate the many different types of viewer that users are developming.
This commit is contained in:
@@ -1,27 +0,0 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2001 Ben Discoe
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
|
||||
// The following symbol has a underscore suffix for compatibility.
|
||||
#ifndef OSGWX_EXPORT_
|
||||
#define OSGWX_EXPORT_ 1
|
||||
|
||||
#ifdef WIN32
|
||||
#pragma warning( disable : 4244 )
|
||||
#pragma warning( disable : 4251 )
|
||||
#pragma warning( disable : 4275 )
|
||||
#pragma warning( disable : 4786 )
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER) || defined(__CYGWIN__) || defined(__MINGW32__) || defined( __BCPLUSPLUS__)
|
||||
# ifdef OSGWX_LIBRARY
|
||||
# define OSGWX_EXPORT __declspec(dllexport)
|
||||
# else
|
||||
# define OSGWX_EXPORT __declspec(dllimport)
|
||||
#endif /* OSGWX_LIBRARY */
|
||||
#else
|
||||
#define OSGWX_EXPORT
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,39 +0,0 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2001 Ben Discoe
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
|
||||
#ifndef OSGWX_VERSION
|
||||
#define OSGWX_VERSION 1
|
||||
|
||||
#include <osgWX/Export>
|
||||
|
||||
|
||||
extern "C" {
|
||||
|
||||
/**
|
||||
* osgWXGetVersion() returns the library version number.
|
||||
* Numbering convention : osg_src-0.8.31 will return 0.8.31.
|
||||
*
|
||||
* This C function can be also used to check for the existence of the OpenSceneGraph
|
||||
* library using autoconf and its m4 macro AC_CHECK_LIB.
|
||||
*
|
||||
* Here is the code to add to your configure.in:
|
||||
\verbatim
|
||||
#
|
||||
# Check for the OpenSceneGraph (OSG) WX library
|
||||
#
|
||||
AC_CHECK_LIB(osg, osgWXGetVersion, ,
|
||||
[AC_MSG_ERROR(OpenSceneGraph WX library not found. See http://www.openscenegraph.org)],)
|
||||
\endverbatim
|
||||
*/
|
||||
extern OSGWX_EXPORT const char* osgWXGetVersion();
|
||||
|
||||
/**
|
||||
* getLibraryName_osgWX() returns the library name in human friendly form.
|
||||
*/
|
||||
extern OSGWX_EXPORT const char* osgWXGetLibraryName();
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,109 +0,0 @@
|
||||
//C++ header - Open Scene Graph - Copyright (C) 1998-2001 Ben Discoe
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
|
||||
#ifndef OSGWX_WXEVENTADAPTER
|
||||
#define OSGWX_WXEVENTADAPTER 1
|
||||
|
||||
#include <osgUtil/GUIEventAdapter>
|
||||
|
||||
#include <osgWX/Export>
|
||||
|
||||
namespace osgWX {
|
||||
|
||||
/** Class for adapting WX events so that they can be used as input to
|
||||
osgUtil::CameraManipulators.*/
|
||||
class OSGWX_EXPORT WXEventAdapter : public osgUtil::GUIEventAdapter
|
||||
{
|
||||
public:
|
||||
WXEventAdapter();
|
||||
virtual ~WXEventAdapter() {}
|
||||
|
||||
/** Get the EventType of the GUI event.*/
|
||||
virtual EventType getEventType() const { return _eventType; }
|
||||
|
||||
/** key pressed, return -1 if inappropriate for this event. */
|
||||
virtual int getKey() const { return _key; }
|
||||
|
||||
/** button pressed/released, return -1 if inappropriate for this event.*/
|
||||
virtual int getButton() const { return _button; }
|
||||
|
||||
/** window minimum x. */
|
||||
virtual int getXmin() const { return _Xmin; }
|
||||
|
||||
/** window maximum x. */
|
||||
virtual int getXmax() const { return _Xmax; }
|
||||
|
||||
/** window minimum y. */
|
||||
virtual int getYmin() const { return _Ymin; }
|
||||
|
||||
/** window maximum y. */
|
||||
virtual int getYmax() const { return _Ymax; }
|
||||
|
||||
/** current mouse x position.*/
|
||||
virtual int getX() const { return _mx; }
|
||||
|
||||
/** current mouse y position.*/
|
||||
virtual int getY() const { return _my; }
|
||||
|
||||
/** current mouse button state */
|
||||
virtual unsigned int getButtonMask() const { return _buttonMask; }
|
||||
|
||||
/** time in seconds of event. */
|
||||
virtual float time() const { return _time; }
|
||||
|
||||
/** static method for setting window dimensions.*/
|
||||
static void setWindowSize(int Xmin, int Ymin, int Xmax, int Ymax);
|
||||
|
||||
/** static method for setting button state.*/
|
||||
static void setButtonMask(unsigned int buttonMask);
|
||||
|
||||
/** method for adapting resize events. */
|
||||
void adaptResize(float t, int Xmin, int Ymin, int Xmax, int Ymax);
|
||||
|
||||
/** method for adapting mouse motion events whilst mouse buttons are pressed.*/
|
||||
void adaptMouseMotion(float t, int x, int y);
|
||||
|
||||
/** method for adapting mouse motion events whilst no mouse button are pressed.*/
|
||||
void adaptMousePassiveMotion(float t,int x, int y);
|
||||
|
||||
/** method for adapting mouse button pressed/released events.*/
|
||||
void adaptMouse(float t, class wxMouseEvent *event);
|
||||
|
||||
/** method for adapting keyboard events.*/
|
||||
void adaptKeyboard(float t,unsigned char key, int x, int y );
|
||||
|
||||
/** method for adapting frame events, i.e. iddle/display callback.*/
|
||||
void adaptFrame(float t);
|
||||
|
||||
void copyStaticVariables();
|
||||
|
||||
protected:
|
||||
EventType _eventType;
|
||||
int _key;
|
||||
int _button;
|
||||
int _Xmin,_Xmax;
|
||||
int _Ymin,_Ymax;
|
||||
int _mx;
|
||||
int _my;
|
||||
unsigned int _buttonMask;
|
||||
float _time;
|
||||
|
||||
// used to accumulate the button mask state, it represents
|
||||
// the current button mask state, which is modified by the
|
||||
// adaptMouse() method which then copies it to value _buttonMask
|
||||
// which required the mouse buttons state at the time of the event.
|
||||
static unsigned int _s_accumulatedButtonMask;
|
||||
|
||||
// used to store window min and max values.
|
||||
static int _s_Xmin;
|
||||
static int _s_Xmax;
|
||||
static int _s_Ymin;
|
||||
static int _s_Ymax;
|
||||
static int _s_mx;
|
||||
static int _s_my;
|
||||
};
|
||||
|
||||
} // namespace osgWX
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user