Skip to content

Added missing OpenGL 4.0-4.6 functions to wrapper - #30

Merged
hazeycode merged 1 commit into
zig-gamedev:mainfrom
LukaTD:wrapper-40-to-46
Jan 31, 2026
Merged

Added missing OpenGL 4.0-4.6 functions to wrapper#30
hazeycode merged 1 commit into
zig-gamedev:mainfrom
LukaTD:wrapper-40-to-46

Conversation

@LukaTD

@LukaTD LukaTD commented Dec 31, 2025

Copy link
Copy Markdown
Contributor

Other notable changes:

  • added missing glVertexAttribLPointer and glGetVertexAttribLdv (OpenGL 4.1) to bindings,
  • implemented wrapper functions clearDepthf and depthRangef in OpenGL ES 1.0 section,
  • added missing fields to various already defined enums,
  • moved various inline definitions of parameter types to the section where types and enums are defined,
  • defined DrawArraysIndirectCommand and DrawElementsIndirectCommand, since definitions of them in bindings will likely be removed,
  • made DEBUGPROC a function type instead of it being a function pointer (makes arguments more readable).

* added missing `glVertexAttribLPointer` and `glGetVertexAttribLdv` (OpenGL 4.1) to bindings,
* implemented wrapper functions `clearDepthf` and `depthRangef` in OpenGL ES 1.0 section,
* added missing fields to various already defined enums,
* moved various inline definitions of parameter types to the section where types and enums are defined,
* defined `DrawArraysIndirectCommand` and `DrawElementsIndirectCommand`, since definitions of them in bindings will likely be removed,
* made `DEBUGPROC` a function type instead of it being a function pointer (makes arguments more readable).

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds missing OpenGL 4.0-4.6 function bindings to the wrapper library, with a focus on completing the OpenGL 4.1 support. The main changes include adding two missing vertex attribute functions and refactoring the DEBUGPROC type definition to be more idiomatic.

  • Added missing glVertexAttribLPointer and glGetVertexAttribLdv functions from OpenGL 4.1
  • Refactored DEBUGPROC from a function pointer type to a function type, with corresponding usage updates

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated no comments.

File Description
src/zopengl.zig Added loader calls for the two new OpenGL 4.1 vertex attribute functions
src/bindings.zig Defined function signatures for vertexAttribLPointer and getVertexAttribLdv, and refactored DEBUGPROC type definition with updated usages

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@LukaTD

LukaTD commented Jan 30, 2026

Copy link
Copy Markdown
Contributor Author

If there aren't and suggestions for changes, I think this should be merged.

@hazeycode
hazeycode merged commit 0c6df14 into zig-gamedev:main Jan 31, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants