freedesktop.glesv2
importlibGLESv2.so.2 — OpenGL ES 2.0/3.x through GLVND, built from source, with a C++23 module
import khronos.glesv2;
模組名讀自上游 src/glesv2.cppm 裡的 `export module` 宣告。
mcpp add freedesktop.glesv2@1.7.0
用法
來自本倉庫自己的測試專案 —— CI 真的編譯並執行過,不是為了網站寫的。
// The render half of the graphics stack: EGL hands out a context, GLES2 draws.
//
// Every FUNCTION and TYPE below comes from a module — `import khronos.egl;`
// and `import khronos.glesv2;`. The headers are included for the `EGL_*` and
// `GL_*` CONSTANTS only, which are macros and cannot be exported by a module.
//
// ─────────────────────────────────────────────────────────────────────────
// WHY THIS TEST EXISTS AND WHAT IT IS FOR
//
// "libGLESv2 exports 358 symbols" is not the claim worth making — a library
// built from the wrong dispatch table exports about that many too. The claim
// is that a program can get a context and DRAW, and the only honest way to
// check it is to draw and read the pixel back.
//
// So the file has two halves:
//
// * assertions that hold on ANY machine, including a CI runner with no GPU:
// the modules carry the API, the libraries are the ones this index built
// rather than the ecosystem payload's same-soname copies, and all of them
// route through ONE libGLdispatch;
// * a real render, gated on a DRM device being present (MCPP_RUN_DRM_DEVICE),
// because a runner has no /dev/dri at all.
// …
tests/examples/gl/tests/gl.cpp · 專案 tests/examples/gl
建置 · 上游資訊清單
- modules
khronos.glesv2- targets
GLESv2 (shared), glesv2 (lib)- language
c++23- manifest version
1.7.0- dependencies
freedesktop- 來源
https://raw.githubusercontent.com/mcpplibs/libglvnd/v1.7.0/mcpp/glesv2/mcpp.toml