Skip to content

Commit

Permalink
sokol_gfx.h gl: fix wrong cast in glTexImage*Multisample() calls
Browse files Browse the repository at this point in the history
  • Loading branch information
floooh committed Nov 17, 2024
1 parent 15b6dde commit eefc84e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sokol_gfx.h
Original file line number Diff line number Diff line change
Expand Up @@ -8531,7 +8531,7 @@ _SOKOL_PRIVATE sg_resource_state _sg_gl_create_image(_sg_image_t* img, const sg_
const GLenum gl_type = _sg_gl_teximage_type(img->cmn.pixel_format);
#if defined(SOKOL_GLCORE)
if (msaa) {
glTexImage2DMultisample(gl_img_target, img->cmn.sample_count, (GLint)gl_internal_format,
glTexImage2DMultisample(gl_img_target, img->cmn.sample_count, gl_internal_format,
mip_width, mip_height, GL_TRUE);
} else {
glTexImage2D(gl_img_target, mip_index, (GLint)gl_internal_format,
Expand All @@ -8558,7 +8558,7 @@ _SOKOL_PRIVATE sg_resource_state _sg_gl_create_image(_sg_image_t* img, const sg_
#if defined(SOKOL_GLCORE)
if (msaa) {
// NOTE: only for array textures, not actual 3D textures!
glTexImage3DMultisample(gl_img_target, img->cmn.sample_count, (GLint)gl_internal_format,
glTexImage3DMultisample(gl_img_target, img->cmn.sample_count, gl_internal_format,
mip_width, mip_height, mip_depth, GL_TRUE);
} else {
glTexImage3D(gl_img_target, mip_index, (GLint)gl_internal_format,
Expand Down

0 comments on commit eefc84e

Please sign in to comment.