PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
draw_tests.h
Go to the documentation of this file.
1
6#ifndef __DRAW_TESTS_H__
7#define __DRAW_TESTS_H__
8
9#include <tamtypes.h>
10#include <draw_buffers.h>
11
12/*& Alpha Testing */
13#define ATEST_METHOD_ALLFAIL 0
14#define ATEST_METHOD_ALLPASS 1
15#define ATEST_METHOD_LESS 2
16#define ATEST_METHOD_LESS_EQUAL 3
17#define ATEST_METHOD_EQUAL 4
18#define ATEST_METHOD_GREATER_EQUAL 5
19#define ATEST_METHOD_GREATER 6
20#define ATEST_METHOD_NOTEQUAL 7
21
22#define ATEST_KEEP_ALL 0
23#define ATEST_KEEP_ZBUFFER 1
24#define ATEST_KEEP_FRAMEBUFFER 2
25#define ATEST_KEEP_ALPHA 3
26
28#define DTEST_METHOD_PASS_ZERO 0
29#define DTEST_METHOD_PASS_ONE 1
30
32#define ZTEST_METHOD_ALLFAIL 0
33#define ZTEST_METHOD_ALLPASS 1
34#define ZTEST_METHOD_GREATER_EQUAL 2
35#define ZTEST_METHOD_GREATER 3
36
37typedef struct {
38 unsigned char enable;
39 unsigned char method;
40 unsigned char compval;
41 unsigned char keep;
42} atest_t;
43
44typedef struct {
45 unsigned char enable;
46 unsigned char pass;
47} dtest_t;
48
49typedef struct {
50 unsigned char enable;
51 unsigned char method;
52} ztest_t;
53
54#ifdef __cplusplus
55extern "C" {
56#endif
57
59qword_t *draw_scissor_area(qword_t *q, int context, int x0, int x1, int y0, int y1);
60
62qword_t *draw_pixel_test(qword_t *q, int context, atest_t *atest, dtest_t *dtest, ztest_t *ztest);
63
65qword_t *draw_disable_tests(qword_t *q, int context, zbuffer_t *z);
66
68qword_t *draw_enable_tests(qword_t *q, int context, zbuffer_t *z);
69
70#ifdef __cplusplus
71}
72#endif
73
74#endif /* __DRAW_TESTS_H__ */
qword_t * draw_enable_tests(qword_t *q, int context, zbuffer_t *z)
Definition draw.c:135
qword_t * draw_scissor_area(qword_t *q, int context, int x0, int x1, int y0, int y1)
qword_t * draw_disable_tests(qword_t *q, int context, zbuffer_t *z)
Definition draw.c:120
qword_t * draw_pixel_test(qword_t *q, int context, atest_t *atest, dtest_t *dtest, ztest_t *ztest)