PS2SDK
PS2 Homebrew Libraries
|
#include <tamtypes.h>
#include <draw_blending.h>
#include <draw_buffers.h>
#include <draw_dithering.h>
#include <draw_fog.h>
#include <draw_masking.h>
#include <draw_primitives.h>
#include <draw_sampling.h>
#include <draw_tests.h>
#include <draw_types.h>
#include <draw2d.h>
#include <draw3d.h>
Go to the source code of this file.
Macros | |
#define | DRAW_DISABLE 0 |
#define | DRAW_ENABLE 1 |
Functions | |
qword_t * | draw_setup_environment (qword_t *q, int context, framebuffer_t *frame, zbuffer_t *z) |
qword_t * | draw_clear (qword_t *q, int context, float x, float y, float width, float height, int r, int g, int b) |
qword_t * | draw_finish (qword_t *q) |
void | draw_wait_finish (void) |
qword_t * | draw_texture_transfer (qword_t *q, void *src, int width, int height, int psm, int dest, int dest_width) |
qword_t * | draw_texture_flush (qword_t *q) |
Draw library main functions
Definition in file draw.h.
qword_t * draw_setup_environment | ( | qword_t * | q, |
int | context, | ||
framebuffer_t * | frame, | ||
zbuffer_t * | z | ||
) |
Sets up the drawing environment based on the framebuffer and zbuffer settings
Definition at line 11 of file draw.c.
References ALPHA_CORRECT_RGBA32, ALPHA_EXPAND_NORMAL, BLEND_COLOR_SOURCE, draw_setup_environment(), GIF_FLG_PACKED, GIF_REG_AD, GS_PSM_16, GS_PSM_16S, GS_REG_ALPHA, GS_REG_CLAMP, GS_REG_COLCLAMP, GS_REG_DIMX, GS_REG_DTHE, GS_REG_FBA, GS_REG_FOGCOL, GS_REG_FRAME, GS_REG_PABE, GS_REG_PRMODECONT, GS_REG_SCISSOR, GS_REG_TEST, GS_REG_TEXA, GS_REG_XYOFFSET, and GS_REG_ZBUF.
Referenced by draw_setup_environment().
qword_t * draw_clear | ( | qword_t * | q, |
int | context, | ||
float | x, | ||
float | y, | ||
float | width, | ||
float | height, | ||
int | r, | ||
int | g, | ||
int | b | ||
) |
Clear the screen based on the screen's origin, width, and height using the defined color.
Definition at line 149 of file draw.c.
References draw_clear(), draw_rect_filled_strips(), GIF_REG_AD, GS_REG_PRMODE, GS_REG_PRMODECONT, and PRIM_OVERRIDE_ENABLE.
Referenced by draw_clear().
qword_t * draw_finish | ( | qword_t * | q | ) |
Signal that drawing is finished
Definition at line 189 of file draw.c.
References draw_finish(), GIF_FLG_PACKED, GIF_REG_AD, and GS_REG_FINISH.
Referenced by draw_finish().
void draw_wait_finish | ( | void | ) |
Wait until finish event occurs
Definition at line 201 of file draw.c.
References draw_wait_finish(), and GS_REG_CSR.
Referenced by draw_wait_finish().
qword_t * draw_texture_transfer | ( | qword_t * | q, |
void * | src, | ||
int | width, | ||
int | height, | ||
int | psm, | ||
int | dest, | ||
int | dest_width | ||
) |
Creates a dma chain filled with image information
Definition at line 224 of file draw.c.
References DMATAG_CNT, DMATAG_REF, draw_texture_transfer(), GIF_BLOCK_SIZE, GIF_FLG_PACKED, GIF_REG_AD, GS_PSM_16, GS_PSM_16S, GS_PSM_24, GS_PSM_32, GS_PSM_4, GS_PSM_4HH, GS_PSM_4HL, GS_PSM_8, GS_PSM_8H, GS_PSMZ_16, GS_PSMZ_16S, GS_PSMZ_24, GS_PSMZ_32, GS_REG_BITBLTBUF, GS_REG_TRXDIR, GS_REG_TRXPOS, and GS_REG_TRXREG.
Referenced by draw_texture_transfer().
qword_t * draw_texture_flush | ( | qword_t * | q | ) |
Flush the texture cache
Definition at line 209 of file draw.c.
References DMATAG_END, draw_texture_flush(), GIF_FLG_PACKED, GIF_REG_AD, and GS_REG_TEXFLUSH.
Referenced by draw_texture_flush().