ps2sdk
1.1
A collection of Open Source libraries used for developing applications on Sony's PlayStation 2® (PS2).
|
Go to the source code of this file.
Functions | |
int | graph_initialize (int fbp, int width, int height, int psm, int x, int y) |
int | graph_add_vsync_handler (int(*vsync_callback)()) |
void | graph_remove_vsync_handler (int callback_id) |
int | graph_get_field (void) |
void | graph_wait_hsync (void) |
int | graph_check_vsync (void) |
void | graph_start_vsync (void) |
void | graph_wait_vsync (void) |
int graph_add_vsync_handler | ( | int(*)() | vsync_callback | ) |
Add a vsync interrupt handler
Definition at line 29 of file graph.c.
References AddIntcHandler(), DIntr(), EIntr(), EnableIntc(), and INTC_VBLANK_S.
int graph_check_vsync | ( | void | ) |
Checks if a vertical sync event is currently generated.
Definition at line 85 of file graph.c.
References GS_REG_CSR.
int graph_get_field | ( | void | ) |
Definition at line 59 of file graph.c.
References GRAPH_FIELD_EVEN, GRAPH_FIELD_ODD, and GS_REG_CSR.
int graph_initialize | ( | int | fbp, |
int | width, | ||
int | height, | ||
int | psm, | ||
int | x, | ||
int | y | ||
) |
Initializes a default NTSC/PAL mode with default settings.
Definition at line 6 of file graph.c.
References GRAPH_ENABLE, graph_enable_output(), graph_get_region(), GRAPH_MODE_FIELD, GRAPH_MODE_INTERLACED, graph_set_bgcolor(), graph_set_framebuffer_filtered(), graph_set_mode(), graph_set_screen(), mode, x, and y.
Referenced by draw_init_env(), init_gs(), and main().
void graph_remove_vsync_handler | ( | int | callback_id | ) |
Remove a vsync interrupt handler
Definition at line 46 of file graph.c.
References DIntr(), DisableIntc(), EIntr(), INTC_VBLANK_S, and RemoveIntcHandler().
void graph_start_vsync | ( | void | ) |
Starts a vertical sync event and returns immediately.
Definition at line 92 of file graph.c.
References GS_REG_CSR.
void graph_wait_hsync | ( | void | ) |
Starts a horizontal sync event and waits
Definition at line 74 of file graph.c.
References GS_REG_CSR.
void graph_wait_vsync | ( | void | ) |
Starts a vertical sync event and waits.
Definition at line 99 of file graph.c.
References GS_REG_CSR.
Referenced by main(), render(), and run_demo().