aboutsummaryrefslogtreecommitdiff
path: root/sokol_gfx.h
diff options
context:
space:
mode:
authorAndre Weissflog <floooh@gmail.com>2025-12-09 18:34:30 +0100
committerAndre Weissflog <floooh@gmail.com>2025-12-09 18:34:30 +0100
commita2fcc9b87734f3a7c1542a77ff460d7dd01ae8cd (patch)
tree3c8281553e8fd0419df10d52097f6792735d5914 /sokol_gfx.h
parentde5707bf01704bba5d1df37421252f36579e2e47 (diff)
sokol_gfx.h wgpu: remove redundant _sg_wgpu_copy_image_data wgpu_tex arg
Diffstat (limited to 'sokol_gfx.h')
-rw-r--r--sokol_gfx.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/sokol_gfx.h b/sokol_gfx.h
index 64d672d8..245dc47a 100644
--- a/sokol_gfx.h
+++ b/sokol_gfx.h
@@ -17739,10 +17739,10 @@ _SOKOL_PRIVATE void _sg_wgpu_copy_buffer_data(const _sg_buffer_t* buf, uint64_t
}
}
-_SOKOL_PRIVATE void _sg_wgpu_copy_image_data(const _sg_image_t* img, WGPUTexture wgpu_tex, const sg_image_data* data) {
+_SOKOL_PRIVATE void _sg_wgpu_copy_image_data(const _sg_image_t* img, const sg_image_data* data) {
_SG_STRUCT(WGPUTexelCopyBufferLayout, wgpu_layout);
_SG_STRUCT(WGPUTexelCopyTextureInfo, wgpu_copy_tex);
- wgpu_copy_tex.texture = wgpu_tex;
+ wgpu_copy_tex.texture = img->wgpu.tex;
wgpu_copy_tex.aspect = WGPUTextureAspect_All;
_SG_STRUCT(WGPUExtent3D, wgpu_extent);
for (int mip_index = 0; mip_index < img->cmn.num_mipmaps; mip_index++) {
@@ -17799,7 +17799,7 @@ _SOKOL_PRIVATE sg_resource_state _sg_wgpu_create_image(_sg_image_t* img, const s
return SG_RESOURCESTATE_FAILED;
}
if (desc->data.mip_levels[0].ptr) {
- _sg_wgpu_copy_image_data(img, img->wgpu.tex, &desc->data);
+ _sg_wgpu_copy_image_data(img, &desc->data);
}
}
return SG_RESOURCESTATE_VALID;
@@ -18575,7 +18575,7 @@ _SOKOL_PRIVATE void _sg_wgpu_append_buffer(_sg_buffer_t* buf, const sg_range* da
_SOKOL_PRIVATE void _sg_wgpu_update_image(_sg_image_t* img, const sg_image_data* data) {
SOKOL_ASSERT(img && data);
- _sg_wgpu_copy_image_data(img, img->wgpu.tex, data);
+ _sg_wgpu_copy_image_data(img, data);
}
// ██ ██ ██ ██ ██ ██ ██ █████ ███ ██ ██████ █████ ██████ ██ ██ ███████ ███ ██ ██████