aboutsummaryrefslogtreecommitdiff
path: root/examples/system/console/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'examples/system/console/main.c')
-rw-r--r--examples/system/console/main.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/examples/system/console/main.c b/examples/system/console/main.c
index 92df0a8..b4f91b4 100644
--- a/examples/system/console/main.c
+++ b/examples/system/console/main.c
@@ -21,7 +21,7 @@
*
*/
-#include <sys/types.h>
+#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -32,8 +32,6 @@
#include <psxgte.h>
#include <psxgpu.h>
#include <psxsio.h>
-#include "ball16c.h"
-
#define MAX_BALLS 1024
@@ -50,10 +48,10 @@
DISPENV disp;
DRAWENV draw;
-char pribuff[2][65536]; /* Primitive packet buffers */
-u_long ot[2][OT_LEN]; /* Ordering tables */
-char *nextpri; /* Pointer to next packet buffer offset */
-int db = 0; /* Double buffer index */
+char pribuff[2][65536]; /* Primitive packet buffers */
+uint32_t ot[2][OT_LEN]; /* Ordering tables */
+char *nextpri; /* Pointer to next packet buffer offset */
+int db = 0; /* Double buffer index */
/* Ball struct and array */
@@ -65,6 +63,8 @@ typedef struct {
BALL_TYPE balls[MAX_BALLS];
+/* Ball texture reference */
+extern const uint32_t ball16c[];
/* TIM image parameters for loading the ball texture and drawing sprites */
TIM_IMAGE tim;
@@ -104,7 +104,7 @@ void init() {
/* Upload the ball texture */
printf("Upload texture... ");
- GetTimInfo( (u_long*)ball16c, &tim ); /* Get TIM parameters */
+ GetTimInfo( ball16c, &tim ); /* Get TIM parameters */
LoadImage( tim.prect, tim.paddr ); /* Upload texture to VRAM */
if( tim.mode & 0x8 ) {