diff options
| author | John Wilbert M. Villamor <lameguy64@gmail.com> | 2021-07-01 08:45:46 +0800 |
|---|---|---|
| committer | John Wilbert M. Villamor <lameguy64@gmail.com> | 2021-07-01 08:45:46 +0800 |
| commit | 01fe30bd8bae59ab954751b08bcc1d158eff7edb (patch) | |
| tree | aa83e37f4e59207ec41b3d47796875755462c63f /examples/graphics/billboard | |
| parent | da79082d2c5e0dcbc899a359f6f49ec8cca90d66 (diff) | |
| download | psn00bsdk-01fe30bd8bae59ab954751b08bcc1d158eff7edb.tar.gz | |
Added int*_t and uint*_t variable types and updated type definitions in psxgpu and psxcd, to improve compatibility with code written for the official SDK.
Diffstat (limited to 'examples/graphics/billboard')
| -rw-r--r-- | examples/graphics/billboard/billboard.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/examples/graphics/billboard/billboard.c b/examples/graphics/billboard/billboard.c index bba5dda..ea98b28 100644 --- a/examples/graphics/billboard/billboard.c +++ b/examples/graphics/billboard/billboard.c @@ -2,7 +2,7 @@ * LibPSn00b Example Programs * * GTE Billboarding Sprites Example - * 2019 Meido-Tek Productions / PSn00bSDK Project + * 2019 - 2021 Meido-Tek Productions / PSn00bSDK Project * * Displays a bunch of sprites placed on the screen using 3D coordinates * that scale according to the distance from the screen. This is a quick @@ -16,10 +16,13 @@ * * Changelog: * + * May 10, 2021 - Variable types updated for psxgpu.h changes. + * * Sep 24, 2019 - Initial version. * */ +#include <sys/types.h> #include <stdio.h> #include <psxgpu.h> #include <psxgte.h> @@ -42,7 +45,7 @@ typedef struct { DISPENV disp; /* Display environment */ DRAWENV draw; /* Drawing environment */ - int ot[OT_LEN]; /* Ordering table */ + u_long ot[OT_LEN]; /* Ordering table */ char p[PACKET_LEN]; /* Packet buffer */ } DB; @@ -51,8 +54,8 @@ DB db[2]; int db_active = 0; char *db_nextpri; -extern int tim_image[]; -TIM_IMAGE tim; +extern u_long tim_image[]; +TIM_IMAGE tim; /* For easier handling of vertex indices */ typedef struct { @@ -224,7 +227,7 @@ void init() { /* Set screen depth (basically FOV control, W/2 works best) */ gte_SetGeomScreen( CENTERX ); - GetTimInfo(tim_image, &tim); + GetTimInfo( tim_image, &tim); LoadImage(tim.prect, tim.paddr); DrawSync(0); |
