Added: Resize Method
Changed: Moved attrListSgl and attrListDbl to this file ~g2k
This commit is contained in:
@@ -30,9 +30,12 @@ namespace OpenArena
|
|||||||
void SetOnInit(InitFunc function);
|
void SetOnInit(InitFunc function);
|
||||||
void SetOnResize(ResizeFunc function);
|
void SetOnResize(ResizeFunc function);
|
||||||
void SwapBuffers();
|
void SwapBuffers();
|
||||||
|
void Resize(GLsizei width, GLsizei height);
|
||||||
|
|
||||||
#ifdef __linux
|
#ifdef __linux
|
||||||
Display* display;
|
Display* GetDisplay();
|
||||||
|
|
||||||
|
private:
|
||||||
int screen;
|
int screen;
|
||||||
::Window window;
|
::Window window;
|
||||||
GLXContext hRC;
|
GLXContext hRC;
|
||||||
@@ -40,6 +43,7 @@ namespace OpenArena
|
|||||||
bool doubleBuffered;
|
bool doubleBuffered;
|
||||||
XF86VidModeModeInfo vidMode;
|
XF86VidModeModeInfo vidMode;
|
||||||
int x, y;
|
int x, y;
|
||||||
|
Display* display;
|
||||||
#endif
|
#endif
|
||||||
private:
|
private:
|
||||||
ResizeFunc OnResize;
|
ResizeFunc OnResize;
|
||||||
@@ -59,5 +63,9 @@ namespace OpenArena
|
|||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
|
LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef __linux
|
||||||
|
static int attrListSgl[] = {GLX_RGBA, GLX_RED_SIZE, 4, GLX_GREEN_SIZE, 4, GLX_BLUE_SIZE, 4, GLX_DEPTH_SIZE, 16, None};
|
||||||
|
static int attrListDbl[] = {GLX_RGBA, GLX_DOUBLEBUFFER, GLX_RED_SIZE, 4, GLX_GREEN_SIZE, 4, GLX_BLUE_SIZE, 4, GLX_DEPTH_SIZE, 16, None};
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user