aboutsummaryrefslogtreecommitdiff
path: root/examples/system/dynlink/library/dll_common.h
blob: 6606bda4f84d81aeb062f7ca0c8af23912d32627 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/*
 * PSn00bSDK dynamic linker example (shared header)
 * (C) 2021 spicyjpeg - MPL licensed
 */

#ifndef __DLL_COMMON_H
#define __DLL_COMMON_H

#include <stdint.h>
#include <psxgpu.h>

/* Common structures shared by the main executable and DLLs */

#define OT_LEN     256
#define PACKET_LEN 16384

typedef struct {
	DISPENV  disp;
	DRAWENV  draw;
	uint32_t ot[OT_LEN];
	uint8_t  p[PACKET_LEN];
} Framebuffer;

typedef struct {
	Framebuffer db[2];
	int         db_active;
	uint8_t	    *db_nextpri;
} RenderContext;

#endif