mirror of
https://github.com/AxioDL/boo.git
synced 2025-05-16 20:31:29 +00:00
Merge pull request #6 from RetroView/input-stubs
Added input device stubs
This commit is contained in:
commit
ac683bda7b
6
include/CInputDeferredRelay.hpp
Normal file
6
include/CInputDeferredRelay.hpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
#ifndef CINPUTDEFERREDRELAY_HPP
|
||||||
|
#define CINPUTDEFERREDRELAY_HPP
|
||||||
|
|
||||||
|
#include "IInputWaiter.hpp"
|
||||||
|
|
||||||
|
#endif // CINPUTDEFERREDRELAY_HPP
|
11
include/CInputRelay.hpp
Normal file
11
include/CInputRelay.hpp
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
#ifndef CINPUTRELAY_HPP
|
||||||
|
#define CINPUTRELAY_HPP
|
||||||
|
|
||||||
|
#include "IInputWaiter.hpp"
|
||||||
|
|
||||||
|
class CInputRelay : IInputWaiter
|
||||||
|
{
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // CINPUTRELAY_HPP
|
36
include/CQtOpenGLWindow.hpp
Normal file
36
include/CQtOpenGLWindow.hpp
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
#ifndef CQTOPENGLWINDOW_HPP
|
||||||
|
#define CQTOPENGLWINDOW_HPP
|
||||||
|
|
||||||
|
#include <QWindow>
|
||||||
|
#include <QOpenGLFunctions>
|
||||||
|
#include <ISurface.hpp>
|
||||||
|
|
||||||
|
class CQtOpenGLWindow : public QWindow, ISurface
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit CQtOpenGLWindow(QWindow *parent = 0);
|
||||||
|
CQtOpenGLWindow();
|
||||||
|
|
||||||
|
virtual void render();
|
||||||
|
|
||||||
|
virtual void initialize();
|
||||||
|
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void renderLater();
|
||||||
|
void renderNow();
|
||||||
|
|
||||||
|
protected:
|
||||||
|
bool event(QEvent *event) Q_DECL_OVERRIDE;
|
||||||
|
|
||||||
|
void exposeEvent(QExposeEvent *event) Q_DECL_OVERRIDE;
|
||||||
|
|
||||||
|
private:
|
||||||
|
bool m_update_pending;
|
||||||
|
bool m_animating;
|
||||||
|
|
||||||
|
QOpenGLContext *m_context;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // CQTOPENGLWINDOW_HPP
|
9
include/IInputWaiter.hpp
Normal file
9
include/IInputWaiter.hpp
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
#ifndef IINPUTWAITER_HPP
|
||||||
|
#define IINPUTWAITER_HPP
|
||||||
|
|
||||||
|
class IInputWaiter
|
||||||
|
{
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // IINPUTWAITER_HPP
|
5
include/inputdev/CCafeProPad.hpp
Normal file
5
include/inputdev/CCafeProPad.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef CCAFEPROPAD_HPP
|
||||||
|
#define CCAFEPROPAD_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // CCAFEPROPAD_HPP
|
5
include/inputdev/CDeviceFinder.hpp
Normal file
5
include/inputdev/CDeviceFinder.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef CDEVICEFINDER_HPP
|
||||||
|
#define CDEVICEFINDER_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // CDEVICEFINDER_HPP
|
5
include/inputdev/CDolphinSmashAdapter.hpp
Normal file
5
include/inputdev/CDolphinSmashAdapter.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef CDOLPHINSMASHADAPTER_HPP
|
||||||
|
#define CDOLPHINSMASHADAPTER_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // CDOLPHINSMASHADAPTER_HPP
|
5
include/inputdev/CDualshockPad.hpp
Normal file
5
include/inputdev/CDualshockPad.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef CDUALSHOCKPAD_HPP
|
||||||
|
#define CDUALSHOCKPAD_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // CDUALSHOCKPAD_HPP
|
5
include/inputdev/CGenericPad.hpp
Normal file
5
include/inputdev/CGenericPad.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef CGENERICPAD_HPP
|
||||||
|
#define CGENERICPAD_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // CGENERICPAD_HPP
|
5
include/inputdev/CRevolutionPad.hpp
Normal file
5
include/inputdev/CRevolutionPad.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef CREVOLUTIONPAD_HPP
|
||||||
|
#define CREVOLUTIONPAD_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // CREVOLUTIONPAD_HPP
|
32
libBoo.pri
32
libBoo.pri
@ -4,7 +4,18 @@ HEADERS += \
|
|||||||
$$PWD/include/boo.hpp \
|
$$PWD/include/boo.hpp \
|
||||||
$$PWD/include/IGraphicsContext.hpp \
|
$$PWD/include/IGraphicsContext.hpp \
|
||||||
$$PWD/include/ISurface.hpp \
|
$$PWD/include/ISurface.hpp \
|
||||||
$$PWD/include/IRetraceWaiter.hpp
|
$$PWD/include/CSurface.hpp \
|
||||||
|
$$PWD/include/IRetraceWaiter.hpp \
|
||||||
|
$$PWD/include/IInputWaiter.hpp \
|
||||||
|
$$PWD/include/CInputRelay.hpp \
|
||||||
|
$$PWD/include/CInputDeferredRelay.hpp \
|
||||||
|
$$PWD/include/inputdev/CDolphinSmashAdapter.hpp \
|
||||||
|
$$PWD/include/inputdev/CRevolutionPad.hpp \
|
||||||
|
$$PWD/include/inputdev/CCafeProPad.hpp \
|
||||||
|
$$PWD/include/inputdev/CDualshockPad.hpp \
|
||||||
|
$$PWD/include/inputdev/CGenericPad.hpp \
|
||||||
|
$$PWD/include/inputdev/CDeviceFinder.hpp \
|
||||||
|
$$PWD/src/inputdev/IHIDDevice.hpp
|
||||||
|
|
||||||
unix:!macx:HEADERS += \
|
unix:!macx:HEADERS += \
|
||||||
$$PWD/include/x11/CGLXContext.hpp
|
$$PWD/include/x11/CGLXContext.hpp
|
||||||
@ -17,18 +28,29 @@ win32:HEADERS += \
|
|||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
$$PWD/src/CSurface.cpp \
|
$$PWD/src/CSurface.cpp \
|
||||||
$$PWD/src/CRetraceWaiter.cpp
|
$$PWD/src/CRetraceWaiter.cpp \
|
||||||
|
$$PWD/src/CInputRelay.cpp \
|
||||||
|
$$PWD/src/CInputDeferredRelay.cpp \
|
||||||
|
$$PWD/src/inputdev/CDolphinSmashAdapter.cpp \
|
||||||
|
$$PWD/src/inputdev/CRevolutionPad.cpp \
|
||||||
|
$$PWD/src/inputdev/CCafeProPad.cpp \
|
||||||
|
$$PWD/src/inputdev/CDualshockPad.cpp \
|
||||||
|
$$PWD/src/inputdev/CGenericPad.cpp \
|
||||||
|
$$PWD/src/inputdev/CDeviceFinder.cpp
|
||||||
|
|
||||||
unix:!macx:SOURCES += \
|
unix:!macx:SOURCES += \
|
||||||
$$PWD/src/x11/CGLXContext.cpp
|
$$PWD/src/x11/CGLXContext.cpp \
|
||||||
|
$$PWD/src/inputdev/CHIDDeviceUdev.cpp
|
||||||
|
|
||||||
macx:SOURCES += \
|
macx:SOURCES += \
|
||||||
$$PWD/src/mac/CCGLContext.cpp
|
$$PWD/src/mac/CCGLContext.cpp
|
||||||
|
|
||||||
macx:OBJECTIVE_SOURCES += \
|
macx:OBJECTIVE_SOURCES += \
|
||||||
$$PWD/src/mac/CCGLCocoaView.mm
|
$$PWD/src/mac/CCGLCocoaView.mm \
|
||||||
|
$$PWD/src/inputdev/CHIDDeviceIOKit.mm
|
||||||
|
|
||||||
win32:SOURCES += \
|
win32:SOURCES += \
|
||||||
$$PWD/src/win/CWGLContext.cpp
|
$$PWD/src/win/CWGLContext.cpp \
|
||||||
|
$$PWD/src/inputdev/CHIDDeviceWin32.cpp
|
||||||
|
|
||||||
INCLUDEPATH += $$PWD/include
|
INCLUDEPATH += $$PWD/include
|
||||||
|
1
src/CInputDeferredRelay.cpp
Normal file
1
src/CInputDeferredRelay.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "CInputDeferredRelay.hpp"
|
1
src/CInputRelay.cpp
Normal file
1
src/CInputRelay.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "CInputRelay.hpp"
|
3
src/CQtOpenGLWindow.cpp
Normal file
3
src/CQtOpenGLWindow.cpp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
#include "CQtOpenGLWindow.hpp"
|
||||||
|
|
||||||
|
|
1
src/inputdev/CCafeProPad.cpp
Normal file
1
src/inputdev/CCafeProPad.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
9
src/inputdev/CDeviceFinder.cpp
Normal file
9
src/inputdev/CDeviceFinder.cpp
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
/*
|
||||||
|
* CDeviceFinder.cpp
|
||||||
|
* libBoo
|
||||||
|
*
|
||||||
|
* Created on 04/19/2015.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <stdio.h>
|
1
src/inputdev/CDolphinSmashAdapter.cpp
Normal file
1
src/inputdev/CDolphinSmashAdapter.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
1
src/inputdev/CDualshockPad.cpp
Normal file
1
src/inputdev/CDualshockPad.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
1
src/inputdev/CGenericPad.cpp
Normal file
1
src/inputdev/CGenericPad.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
1
src/inputdev/CHIDDeviceIOKit.mm
Normal file
1
src/inputdev/CHIDDeviceIOKit.mm
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
1
src/inputdev/CHIDDeviceUdev.cpp
Normal file
1
src/inputdev/CHIDDeviceUdev.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
1
src/inputdev/CHIDDeviceWin32.cpp
Normal file
1
src/inputdev/CHIDDeviceWin32.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
1
src/inputdev/CRevolutionPad.cpp
Normal file
1
src/inputdev/CRevolutionPad.cpp
Normal file
@ -0,0 +1 @@
|
|||||||
|
#include "IHIDDevice.hpp"
|
5
src/inputdev/IHIDDevice.hpp
Normal file
5
src/inputdev/IHIDDevice.hpp
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#ifndef IHIDDEVICE_HPP
|
||||||
|
#define IHIDDEVICE_HPP
|
||||||
|
|
||||||
|
|
||||||
|
#endif // IHIDDEVICE_HPP
|
@ -3,8 +3,8 @@
|
|||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
CCGLContext::CCGLContext()
|
CCGLContext::CCGLContext()
|
||||||
: m_majVersion(3),
|
: m_minVersion(3),
|
||||||
m_minVersion(3)
|
m_majVersion(3)
|
||||||
{
|
{
|
||||||
std::cout << "Hello from CGL" << std::endl;
|
std::cout << "Hello from CGL" << std::endl;
|
||||||
}
|
}
|
||||||
@ -58,3 +58,4 @@ int CCGLContext::blueDepth() const
|
|||||||
{
|
{
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
#endif
|
Loading…
x
Reference in New Issue
Block a user