libdragon
Loading...
Searching...
No Matches
rdpq_debug.h
Go to the documentation of this file.
1
8#ifndef LIBDRAGON_RDPQ_DEBUG_H
9#define LIBDRAGON_RDPQ_DEBUG_H
10
11#include <stdbool.h>
12#include <stdint.h>
13#include <stdio.h>
14
15#ifdef __cplusplus
16extern "C" {
17#endif
18
20typedef struct surface_s surface_t;
22
49
53void rdpq_debug_stop(void);
54
70void rdpq_debug_log(bool show_log);
71
112void rdpq_debug_log_msg(const char *str);
113
143
156void rdpq_debug_install_hook(void (*hook)(void *ctx, uint64_t* cmd, int cmd_size), void* ctx);
157
175bool rdpq_debug_disasm(uint64_t *buf, FILE *out);
176
183int rdpq_debug_disasm_size(uint64_t *buf);
184
196char* rdpq_debug_disasm_cc(uint64_t cc64);
197
198#ifdef __cplusplus
199}
200#endif
201
202#endif
void rdpq_debug_install_hook(void(*hook)(void *ctx, uint64_t *cmd, int cmd_size), void *ctx)
Install a custom hook that will be called every time a RDP command is processed.
int rdpq_debug_disasm_size(uint64_t *buf)
Return the size of the next RDP commands.
Definition rdpq_debug.c:458
void rdpq_debug_start(void)
Initialize the RDPQ debugging engine.
void rdpq_debug_stop(void)
Stop the rdpq debugging engine.
void rdpq_debug_log(bool show_log)
Show a full log of all the RDP commands.
surface_t rdpq_debug_get_tmem(void)
Acquire a dump of the current contents of TMEM.
char * rdpq_debug_disasm_cc(uint64_t cc64)
Disassemble a RDP combiner command.
Definition rdpq_debug.c:474
bool rdpq_debug_disasm(uint64_t *buf, FILE *out)
Disassemble a RDP command.
Definition rdpq_debug.c:809
void rdpq_debug_log_msg(const char *str)
Add a custom message in the RDP logging.
A surface buffer for graphics.
Definition surface.h:140