mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-22 09:12:13 -05:00
LibWeb/WebGL: Implement deleteTexture
This commit is contained in:
parent
7b0c067f4d
commit
111c4495d9
Notes:
github-actions[bot]
2024-12-05 20:42:43 +00:00
Author: https://github.com/Lubrsi Commit: https://github.com/LadybirdBrowser/ladybird/commit/111c4495d92 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2791 Reviewed-by: https://github.com/gmta Reviewed-by: https://github.com/shannonbooth
2 changed files with 9 additions and 1 deletions
|
@ -82,7 +82,7 @@ interface mixin WebGLRenderingContextBase {
|
|||
undefined deleteProgram(WebGLProgram? program);
|
||||
[FIXME] undefined deleteRenderbuffer(WebGLRenderbuffer? renderbuffer);
|
||||
undefined deleteShader(WebGLShader? shader);
|
||||
[FIXME] undefined deleteTexture(WebGLTexture? texture);
|
||||
undefined deleteTexture(WebGLTexture? texture);
|
||||
|
||||
undefined depthFunc(GLenum func);
|
||||
undefined depthMask(GLboolean flag);
|
||||
|
|
|
@ -726,6 +726,14 @@ public:
|
|||
continue;
|
||||
}
|
||||
|
||||
if (function.name == "deleteTexture"sv) {
|
||||
function_impl_generator.append(R"~~~(
|
||||
auto handle = texture ? texture->handle() : 0;
|
||||
glDeleteTextures(1, &handle);
|
||||
)~~~");
|
||||
continue;
|
||||
}
|
||||
|
||||
Vector<ByteString> gl_call_arguments;
|
||||
for (size_t i = 0; i < function.parameters.size(); ++i) {
|
||||
auto const& parameter = function.parameters[i];
|
||||
|
|
Loading…
Reference in a new issue