|
wx_BGI_Graphics
Classic BGI-compatible graphics API with modern OpenGL extension API
|
Internal OpenGL state management and rendering passes for the BGI library. More...

Go to the source code of this file.
Namespaces | |
| namespace | bgi |
Functions | |
| void | bgi::glPassDestroy () |
| Release all GL objects (call before context is destroyed). | |
| void | bgi::glPassInit (int w, int h) |
| Initialise GL objects (shaders, VAO/VBO, page texture). | |
| void | bgi::glPassResetState () |
| Reset GL object handles to zero WITHOUT calling GL delete functions. | |
| void | bgi::glPassResize (int w, int h) |
| Resize the page texture to match a new canvas size. | |
| void | bgi::renderPageAsTexture (int w, int h, int vpW=-1, int vpH=-1) |
| Pass 1 — Upload the visual page buffer as an RGBA texture and draw a fullscreen quad. | |
| void | bgi::renderPageAsTextureAlpha (int w, int h, int vpW=-1, int vpH=-1) |
| Overlay pass — Upload the visual page buffer as an RGBA texture and composite it ON TOP of the current framebuffer contents using alpha blending. | |
| void | bgi::renderPageLegacyPoints (int w, int h, int vpW=-1, int vpH=-1) |
| Legacy per-pixel GL_POINTS path (kept for backward compat / diagnostics). | |
| void | bgi::renderSolidsGLPass (const PendingGlRender &pending, int w, int h, const LightState &light, const glm::mat4 &vp, const glm::vec3 &camPos, int vpX=0, int vpY=0) |
| Pass 2a — Draw Phong-lit solid triangles (flat and/or smooth shading) with depth test. | |
| void | bgi::renderWireframeGLPass (const PendingGlRender &pending, int w, int h, const glm::mat4 &vp, const glm::vec3 &camPos, int vpX=0, int vpY=0) |
| Pass 2b — Two-pass hidden-line wireframe with proper depth-buffer HSR. | |
| void | bgi::renderWorldLinesGLPass (const PendingGlRender &pending, int w, int h, const glm::mat4 &vp, int vpX=0, int vpY=0) |
| Pass 3 — Draw world-space line segments with depth test (hidden behind solids). | |
Internal OpenGL state management and rendering passes for the BGI library.
This module owns all GL object lifetimes (shaders, VAOs, VBOs, textures) and provides compositing passes called in order by both the GLFW standalone path (bgi_draw.cpp::flushToScreen) and the wx-embedded path (WxBgiCanvas::Render):
Thread safety: all functions must be called with the GL context current and bgi::gMutex already held by the caller.
Legacy path: call renderPageLegacyPoints() instead of renderPageAsTexture() to reproduce the old per-pixel GL_POINTS behaviour (for diagnostic use).