LibGL: Change gl_tex_gen param to GLint

The singular form of `glTexGeni/f/d` only supports constants, not
floating point values as its parameter.
This commit is contained in:
Jelle Raaijmakers 2021-12-30 00:38:22 +01:00 committed by Andreas Kling
parent ab6a869f55
commit 8cf91a5ae5
3 changed files with 3 additions and 3 deletions

View file

@ -119,7 +119,7 @@ public:
virtual void gl_copy_tex_image_2d(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border) = 0;
virtual void gl_get_tex_parameter_integerv(GLenum target, GLint level, GLenum pname, GLint* params) = 0;
virtual void gl_rect(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2) = 0;
virtual void gl_tex_gen(GLenum coord, GLenum pname, GLdouble param) = 0;
virtual void gl_tex_gen(GLenum coord, GLenum pname, GLint param) = 0;
virtual void gl_tex_gen_floatv(GLenum coord, GLenum pname, GLfloat const* params) = 0;
virtual void present() = 0;

View file

@ -2733,7 +2733,7 @@ void SoftwareGLContext::gl_rect(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble
gl_end();
}
void SoftwareGLContext::gl_tex_gen(GLenum coord, GLenum pname, GLdouble param)
void SoftwareGLContext::gl_tex_gen(GLenum coord, GLenum pname, GLint param)
{
APPEND_TO_CALL_LIST_AND_RETURN_IF_NEEDED(gl_tex_gen, coord, pname, param);
RETURN_WITH_ERROR_IF(m_in_draw_state, GL_INVALID_OPERATION);

View file

@ -132,7 +132,7 @@ public:
virtual void gl_copy_tex_image_2d(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border) override;
virtual void gl_get_tex_parameter_integerv(GLenum target, GLint level, GLenum pname, GLint* params) override;
virtual void gl_rect(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2) override;
virtual void gl_tex_gen(GLenum coord, GLenum pname, GLdouble param) override;
virtual void gl_tex_gen(GLenum coord, GLenum pname, GLint param) override;
virtual void gl_tex_gen_floatv(GLenum coord, GLenum pname, GLfloat const* params) override;
virtual void present() override;