diff options
| author | Andre Weissflog <floooh@gmail.com> | 2024-02-18 14:04:32 +0100 |
|---|---|---|
| committer | Andre Weissflog <floooh@gmail.com> | 2024-02-18 14:04:32 +0100 |
| commit | d2b206ca358f8499db2fd9c7cb6f3a60ae32b54f (patch) | |
| tree | c22a76916538647b565d59d13e7957adec890df0 /util | |
| parent | bfaccb35836005d70cd38eb3036774e1103795f5 (diff) | |
sokol_gfx.h: code cleanup around sg_begin_pass
- resolve defaults in sg_pass struct
- allow depth-buffer to be optional (todo: in all backends)
- metal: add config item to use command buffer with retained references
Diffstat (limited to 'util')
| -rw-r--r-- | util/sokol_gfx_imgui.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/util/sokol_gfx_imgui.h b/util/sokol_gfx_imgui.h index 242790c7..eed45e3a 100644 --- a/util/sokol_gfx_imgui.h +++ b/util/sokol_gfx_imgui.h @@ -2480,7 +2480,7 @@ _SOKOL_PRIVATE void _sgimgui_append_buffer(sg_buffer buf, const sg_range* data, } } -_SOKOL_PRIVATE void _sgimgui_begin_pass(const sg_pass* pass, const sg_pass_action* resolved_pass_action, void* user_data) { +_SOKOL_PRIVATE void _sgimgui_begin_pass(const sg_pass* pass, void* user_data) { sgimgui_t* ctx = (sgimgui_t*) user_data; SOKOL_ASSERT(ctx); sgimgui_capture_item_t* item = _sgimgui_capture_next_write_item(ctx); @@ -2489,10 +2489,9 @@ _SOKOL_PRIVATE void _sgimgui_begin_pass(const sg_pass* pass, const sg_pass_actio item->cmd = SGIMGUI_CMD_BEGIN_PASS; item->color = _SGIMGUI_COLOR_PASS; item->args.begin_pass.pass = *pass; - item->args.begin_pass.pass.action = *resolved_pass_action; } if (ctx->hooks.begin_pass) { - ctx->hooks.begin_pass(pass, resolved_pass_action, ctx->hooks.user_data); + ctx->hooks.begin_pass(pass, ctx->hooks.user_data); } } |