diff --git a/samples/depth_funcs_alpha_testing/main.c b/samples/depth_funcs_alpha_testing/main.c index 17fc005..60987d6 100644 --- a/samples/depth_funcs_alpha_testing/main.c +++ b/samples/depth_funcs_alpha_testing/main.c @@ -9,8 +9,11 @@ //$KOS_BASE/utils/texconv/texconv --in disk.png --format ARGB4444 --preview disk_preview.png --out disk.dtex +#ifdef __DREAMCAST__ extern uint8_t romdisk[]; KOS_INIT_ROMDISK(romdisk); +#endif + texture t; int blendActive = -1; /* floats for x rotation, y rotation, z rotation */ diff --git a/samples/mipmap/main.c b/samples/mipmap/main.c index fcefd2a..1aa0b6d 100644 --- a/samples/mipmap/main.c +++ b/samples/mipmap/main.c @@ -11,10 +11,9 @@ #include "GL/glext.h" #include "GL/glkos.h" +#ifdef __DREAMCAST__ extern uint8_t romdisk[]; KOS_INIT_ROMDISK(romdisk); - -#ifdef __DREAMCAST__ #define IMAGE_FILENAME "/rd/NeHe.bmp" #else #define IMAGE_FILENAME "samples/mipmap/romdisk/NeHe.bmp" diff --git a/samples/multitexture_arrays/main.c b/samples/multitexture_arrays/main.c index f104467..13e1d2e 100644 --- a/samples/multitexture_arrays/main.c +++ b/samples/multitexture_arrays/main.c @@ -21,6 +21,8 @@ #include "GL/glext.h" #ifdef __DREAMCAST__ +extern uint8_t romdisk[]; +KOS_INIT_ROMDISK(romdisk); #define IMAGE1_FILENAME "/rd/wp001vq.pvr" #define IMAGE2_FILENAME "/rd/FlareWS_256.pvr" #else @@ -122,9 +124,6 @@ void RenderCallback(GLuint texID0, GLuint texID1) { glDisableClientState(GL_VERTEX_ARRAY); } -extern uint8_t romdisk[]; -KOS_INIT_ROMDISK(romdisk); - int main(int argc, char **argv) { /* Notice we do not init the PVR here, that is handled by Open GL */ glKosInit(); diff --git a/samples/nehe08/main.c b/samples/nehe08/main.c index fb7ff6f..69e5863 100644 --- a/samples/nehe08/main.c +++ b/samples/nehe08/main.c @@ -26,6 +26,11 @@ blending. */ +#ifdef __DREAMCAST__ +extern uint8 romdisk[]; +KOS_INIT_ROMDISK(romdisk); +#endif + static GLfloat xrot; /* X Rotation */ static GLfloat yrot; /* Y Rotation */ static GLfloat xspeed; /* X Rotation Speed */ @@ -115,11 +120,6 @@ void draw_gl(void) { yrot += yspeed; } -#ifdef __DREAMCAST__ -extern uint8 romdisk[]; -KOS_INIT_ROMDISK(romdisk); -#endif - int main(int argc, char **argv) { #ifdef __DREAMCAST__ maple_device_t *cont; diff --git a/samples/paletted/main.c b/samples/paletted/main.c index bd7d4db..b6460e6 100644 --- a/samples/paletted/main.c +++ b/samples/paletted/main.c @@ -12,8 +12,10 @@ #include "GL/glu.h" #include "GL/glkos.h" +#ifdef __DREAMCAST__ extern uint8_t romdisk[]; KOS_INIT_ROMDISK(romdisk); +#endif /* floats for x rotation, y rotation, z rotation */ float xrot, yrot, zrot;