| 2 |
|
#include <math.h> |
| 3 |
|
|
| 4 |
|
#include "Oni.h" |
| 5 |
– |
#include "Oni_Persistence.h" |
| 5 |
|
#include "Daodan_Utility.h" |
| 6 |
|
#include <GL/gl.h> |
| 7 |
|
#include <GL/glu.h> |
| 8 |
|
#include "Daodan_Win32.h" |
| 10 |
– |
#include "BFW_Utility.h" |
| 9 |
|
|
| 10 |
< |
#include "daodan_gl.h" |
| 11 |
< |
#include "oni_gl.h" |
| 10 |
> |
#include "Daodan_GL.h" |
| 11 |
> |
#include "Oni_GL.h" |
| 12 |
|
|
| 13 |
|
#define max_modes (104) // Dirty hack to add more resolutions, it really should only be 16 ^_^ |
| 14 |
|
#define builtin_modes (sizeof(daodan_reslist) / sizeof(M3tDisplayMode)) |
| 15 |
|
#define builtin_depths (sizeof(daodan_resdepths) / sizeof(short)) |
| 16 |
|
|
| 17 |
+ |
bool daodan_testmode(M3tDisplayMode mode); |
| 18 |
+ |
|
| 19 |
|
const M3tDisplayMode daodan_reslist[] = { |
| 20 |
|
{ 720 , 480, 0, 0 }, |
| 21 |
|
{ 720 , 576, 0, 0 }, |
| 51 |
|
short daodan_resdepths[] = { 32 }; |
| 52 |
|
DEVMODE orig_devmode, cur_devmode, new_devmode; |
| 53 |
|
|
| 54 |
+ |
/* Never called |
| 55 |
|
void init_daodan_gl() |
| 56 |
|
{ |
| 57 |
|
DDrStartupMessage("initalizing daodan gl"); |
| 70 |
|
memcpy(&cur_devmode, &orig_devmode, sizeof(orig_devmode)); |
| 71 |
|
memcpy(&new_devmode, &orig_devmode, sizeof(orig_devmode)); |
| 72 |
|
} |
| 73 |
+ |
*/ |
| 74 |
|
|
| 75 |
|
void update_cdmode() |
| 76 |
|
{ |
| 240 |
|
gl_gamma_ramp_valid = 1; |
| 241 |
|
} |
| 242 |
|
|
| 243 |
< |
if (gl_gamma_ramp_valid) |
| 243 |
> |
/*if (gl_gamma_ramp_valid) |
| 244 |
|
daodan_set_gamma(ONrPersist_GetGamma()); |
| 245 |
< |
else |
| 245 |
> |
else*/ |
| 246 |
|
DDrStartupMessage("gamma adjustment not supported"); |
| 247 |
|
|
| 248 |
|
if (!gl_platform_set_pixel_format(gl_eng->HDC)) |