2003-05-07 20:04:26 +00:00
|
|
|
#ifndef BOINC_GRAPHICS_API_H
|
|
|
|
#define BOINC_GRAPHICS_API_H
|
|
|
|
|
2003-05-07 23:42:17 +00:00
|
|
|
#include <stdio.h>
|
|
|
|
|
|
|
|
#ifdef BOINC_APP_GRAPHICS
|
|
|
|
#ifdef __APPLE_CC__
|
|
|
|
#include <OpenGL/gl.h>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef _WIN32
|
|
|
|
#include <windows.h>
|
|
|
|
#include <gl\gl.h> // Header File For The OpenGL32 Library
|
|
|
|
#include <gl\glu.h> // Header File For The GLu32 Library
|
|
|
|
#include <gl\glaux.h> // Header File For The Glaux Library
|
|
|
|
#endif
|
2003-05-07 20:04:26 +00:00
|
|
|
|
2003-05-07 23:42:17 +00:00
|
|
|
#ifdef HAVE_GL_LIB
|
|
|
|
#include <GL/gl.h>
|
|
|
|
#include "x_opengl.h"
|
|
|
|
#endif
|
|
|
|
#endif
|
2002-09-11 21:41:42 +00:00
|
|
|
|
2002-08-09 21:43:59 +00:00
|
|
|
struct GRAPHICS_INFO {
|
2002-08-05 00:29:34 +00:00
|
|
|
int xsize;
|
|
|
|
int ysize;
|
|
|
|
double refresh_period;
|
|
|
|
};
|
|
|
|
|
2002-09-17 21:54:59 +00:00
|
|
|
typedef struct GRAPHICS_INFO GRAPHICS_INFO;
|
|
|
|
|
2002-08-05 00:29:34 +00:00
|
|
|
struct APP_OUT_GRAPHICS {
|
|
|
|
};
|
2002-09-11 21:41:42 +00:00
|
|
|
|
2002-09-18 21:15:23 +00:00
|
|
|
int boinc_init_opengl();
|
|
|
|
int boinc_finish_opengl();
|
2002-10-31 00:13:50 +00:00
|
|
|
|
|
|
|
#ifdef BOINC_APP_GRAPHICS
|
|
|
|
GLvoid glPrint(GLuint font, const char *fmt, ...);
|
2003-02-14 18:47:26 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
GLenum InitGL(GLvoid);
|
|
|
|
GLenum ReSizeGLScene(GLsizei width, GLsizei height);
|
2003-02-19 18:55:07 +00:00
|
|
|
extern bool app_render(int xs, int ys, double time_of_day);
|
2003-03-03 18:46:06 +00:00
|
|
|
extern void app_init_gl(void);
|
2003-02-14 18:47:26 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
2002-10-31 00:13:50 +00:00
|
|
|
#endif
|
2003-05-07 20:04:26 +00:00
|
|
|
|
|
|
|
#endif
|