diff --git a/Libraries/LibWeb/WebGL/WebGLRenderingContextBase.idl b/Libraries/LibWeb/WebGL/WebGLRenderingContextBase.idl index 7e159e979c..d46141dcf1 100644 --- a/Libraries/LibWeb/WebGL/WebGLRenderingContextBase.idl +++ b/Libraries/LibWeb/WebGL/WebGLRenderingContextBase.idl @@ -46,7 +46,7 @@ interface mixin WebGLRenderingContextBase { undefined activeTexture(GLenum texture); undefined attachShader(WebGLProgram program, WebGLShader shader); - [FIXME] undefined bindAttribLocation(WebGLProgram program, GLuint index, DOMString name); + undefined bindAttribLocation(WebGLProgram program, GLuint index, DOMString name); undefined bindBuffer(GLenum target, WebGLBuffer? buffer); [FIXME] undefined bindFramebuffer(GLenum target, WebGLFramebuffer? framebuffer); [FIXME] undefined bindRenderbuffer(GLenum target, WebGLRenderbuffer? renderbuffer); diff --git a/Meta/Lagom/Tools/CodeGenerators/LibWeb/GenerateWebGLRenderingContext.cpp b/Meta/Lagom/Tools/CodeGenerators/LibWeb/GenerateWebGLRenderingContext.cpp index 2c015afbd3..560a51a462 100644 --- a/Meta/Lagom/Tools/CodeGenerators/LibWeb/GenerateWebGLRenderingContext.cpp +++ b/Meta/Lagom/Tools/CodeGenerators/LibWeb/GenerateWebGLRenderingContext.cpp @@ -590,7 +590,11 @@ public: continue; } if (parameter.type->is_string()) { - gl_call_arguments.append(ByteString::formatted("{}", parameter.name)); + function_impl_generator.set("parameter_name", parameter.name); + function_impl_generator.append(R"~~~( + auto @parameter_name@_null_terminated = null_terminated_string(@parameter_name@); +)~~~"); + gl_call_arguments.append(ByteString::formatted("{}_null_terminated.data()", parameter.name)); continue; } if (is_webgl_object_type(parameter.type->name())) {