From: ljsebald <ljs...@us...> - 2024-01-29 04:14:05
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "UNNAMED PROJECT". The branch, master has been updated via 1d75c9e421f3453cdbe16bf91a39366d5f0be972 (commit) from 81329435db6b2c747ee1bde2d3359e78344e0b63 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 1d75c9e421f3453cdbe16bf91a39366d5f0be972 Author: Falco Girgis <gyr...@gm...> Date: Sun Jan 28 22:12:35 2024 -0600 Fixed Broken Direct Rendering Path (#1) * Update dr.h Fixed pvr_dr_init() to use new API changes for PVR direct rendering. Fixing direct rendering. Added wrapper around pvr_dr_finish() which is required to release the mutex held by plx_dr_init(). * Addressing review feedback. * Forgot a semicolon! * Apply suggestions from code review ----------------------------------------------------------------------- Summary of changes: include/dr.h | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/include/dr.h b/include/dr.h index 538e34b..1aebae3 100644 --- a/include/dr.h +++ b/include/dr.h @@ -3,6 +3,7 @@ dr.h Copyright (C) 2002 Megan Potter + Copyright (C) 2024 Falco Girgis */ @@ -27,11 +28,25 @@ typedef pvr_vertex_t plx_vertex_t; #define PLX_VERT PVR_CMD_VERTEX #define PLX_VERT_EOS PVR_CMD_VERTEX_EOL -#define plx_dr_init(a) pvr_dr_init(*a) -#define plx_dr_target(a) pvr_dr_target(*a) -#define plx_dr_commit(a) pvr_dr_commit(a) +static inline void plx_dr_init(plx_dr_state_t *state) { + pvr_dr_init((pvr_dr_state_t *)state); +} + +static inline plx_vertex_t *plx_dr_target(plx_dr_state_t *state) { + return (plx_vertex_t *)pvr_dr_target(*(pvr_dr_state_t*)state); +} + +static inline void plx_dr_commit(plx_vertex_t *vertex) { + pvr_dr_commit((pvr_vertex_t *)vertex); +} + +static inline void plx_dr_finish(void) { + pvr_dr_finish(); +} -#define plx_prim pvr_prim +static inline int plx_prim(void *data, int size) { + return pvr_prim(data, size); +} static inline void plx_scene_begin() { pvr_wait_ready(); hooks/post-receive -- UNNAMED PROJECT |