sdk-core
v2026.11.05
PS2 SDK - core tier (build-critical EE/IOP modules)
Toggle main menu visibility
Loading...
Searching...
No Matches
draw_buffers.h
Go to the documentation of this file.
1
6
7
#ifndef __DRAW_BUFFERS_H__
8
#define __DRAW_BUFFERS_H__
9
10
#include <
tamtypes.h
>
11
13
#define TEXTURE_COMPONENTS_RGB 0
14
#define TEXTURE_COMPONENTS_RGBA 1
15
17
#define TEXTURE_FUNCTION_MODULATE 0
18
#define TEXTURE_FUNCTION_DECAL 1
19
#define TEXTURE_FUNCTION_HIGHLIGHT 2
20
#define TEXTURE_FUNCTION_HIGHLIGHT2 3
21
23
#define CLUT_STORAGE_MODE1 0
24
#define CLUT_STORAGE_MODE2 1
25
27
#define CLUT_NO_LOAD 0
28
#define CLUT_LOAD 1
29
#define CLUT_LOAD_COPY_CBP0 2
30
#define CLUT_LOAD_COPY_CBP1 3
31
#define CLUT_COMPARE_CBP0 4
32
#define CLUT_COMPARE_CBP1 5
33
34
typedef
struct
{
35
unsigned
char
width;
36
unsigned
char
height;
37
unsigned
char
components;
38
unsigned
char
function;
39
}
texinfo_t
;
40
41
typedef
struct
{
42
unsigned
int
address;
43
unsigned
int
width;
44
unsigned
int
height;
45
unsigned
int
psm;
46
unsigned
int
mask;
47
}
framebuffer_t
;
48
49
typedef
struct
{
50
unsigned
int
enable;
51
unsigned
int
method;
52
unsigned
int
address;
53
unsigned
int
zsm;
54
unsigned
int
mask;
55
}
zbuffer_t
;
56
57
typedef
struct
{
58
unsigned
int
address;
59
unsigned
int
width;
60
unsigned
int
psm;
61
texinfo_t
info;
62
}
texbuffer_t
;
63
64
typedef
struct
{
65
unsigned
int
address;
66
unsigned
int
psm;
67
unsigned
int
storage_mode;
68
unsigned
int
start;
69
unsigned
int
load_method;
70
}
clutbuffer_t
;
71
72
#ifdef __cplusplus
73
extern
"C"
{
74
#endif
75
77
extern
unsigned
char
draw_log2
(
unsigned
int
x);
78
80
extern
qword_t *
draw_framebuffer
(qword_t *q,
int
context,
framebuffer_t
*frame);
81
83
extern
qword_t *
draw_zbuffer
(qword_t *q,
int
context,
zbuffer_t
*zbuffer);
84
86
extern
qword_t *
draw_texturebuffer
(qword_t *q,
int
context,
texbuffer_t
*texbuffer,
clutbuffer_t
*clut);
87
89
extern
qword_t *
draw_clutbuffer
(qword_t *q,
int
context,
int
psm,
clutbuffer_t
*clut);
90
92
extern
qword_t *
draw_clut_offset
(qword_t *q,
int
cbw,
int
u,
int
v);
93
94
#ifdef __cplusplus
95
}
96
#endif
97
98
#endif
/* __DRAW_BUFFERS_H__ */
draw_log2
unsigned char draw_log2(unsigned int x)
Definition
draw.c:349
draw_framebuffer
qword_t * draw_framebuffer(qword_t *q, int context, framebuffer_t *frame)
Definition
draw_environment.c:33
draw_clut_offset
qword_t * draw_clut_offset(qword_t *q, int cbw, int u, int v)
Definition
draw_environment.c:95
draw_zbuffer
qword_t * draw_zbuffer(qword_t *q, int context, zbuffer_t *zbuffer)
Definition
draw_environment.c:45
draw_texturebuffer
qword_t * draw_texturebuffer(qword_t *q, int context, texbuffer_t *texbuffer, clutbuffer_t *clut)
Definition
draw_environment.c:57
draw_clutbuffer
qword_t * draw_clutbuffer(qword_t *q, int context, int psm, clutbuffer_t *clut)
Definition
draw_environment.c:77
clutbuffer_t
Definition
draw_buffers.h:64
framebuffer_t
Definition
draw_buffers.h:41
texbuffer_t
Definition
draw_buffers.h:57
texinfo_t
Definition
draw_buffers.h:34
zbuffer_t
Definition
draw_buffers.h:49
tamtypes.h
core
draw
include
draw_buffers.h
Generated by
1.18.0