51 lines
896 B
C
51 lines
896 B
C
#ifndef LINUX_VR_COMPOSITOR_H
|
|
#define LINUX_VR_COMPOSITOR_H
|
|
|
|
#include <openhmd.h>
|
|
|
|
#include <stdbool.h>
|
|
|
|
#define LVRC_API __attribute__ ((visibility ("default")))
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
//
|
|
// Instance
|
|
//
|
|
|
|
struct lvrcInstance;
|
|
|
|
LVRC_API struct lvrcInstance * lvrcCreateInstance(ohmd_device * hmd);
|
|
LVRC_API void lvrcDestroyInstance(struct lvrcInstance * state);
|
|
|
|
//
|
|
// Swap Chain
|
|
//
|
|
|
|
LVRC_API bool lvrcInitSwapChain(struct lvrcInstance * state, unsigned int width, unsigned int height, GLuint * textures);
|
|
LVRC_API bool lvrcReleaseSwapChain(struct lvrcInstance * state);
|
|
|
|
//
|
|
// Frame
|
|
//
|
|
|
|
LVRC_API bool lvrcBeginFrame(struct lvrcInstance * state);
|
|
LVRC_API bool lvrcEndFrame(struct lvrcInstance * state);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
|
|
#ifdef __egl_h_
|
|
# include "lvrc_EGL.h"
|
|
#endif // __egl_h_
|
|
|
|
#ifdef GLX_H
|
|
# include "lvrc_GLX.h"
|
|
#endif // GLX_H
|
|
|
|
#endif // LINUX_VR_COMPOSITOR_H
|