hachem.wtf
aboutsummaryrefslogtreecommitdiff
path: root/src/platform/opengl/opengl_renderer_api.cpp
diff options
context:
space:
mode:
authorhachem <im@hachem.wtf>2025-08-22 00:22:12 +0200
committerhachem <im@hachem.wtf>2025-08-22 00:22:12 +0200
commit0d4f5f665f2e4b735fb4f978acc6c8d4a16fcb5d (patch)
treedad79333f7026e19732fae0e35ca9dff8ea7ade4 /src/platform/opengl/opengl_renderer_api.cpp
parentd8ba57f6d45b9467520377ffcc1f453154d77430 (diff)
feat: frame exporting
Diffstat (limited to 'src/platform/opengl/opengl_renderer_api.cpp')
-rw-r--r--src/platform/opengl/opengl_renderer_api.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/platform/opengl/opengl_renderer_api.cpp b/src/platform/opengl/opengl_renderer_api.cpp
index bfb79ac..0012911 100644
--- a/src/platform/opengl/opengl_renderer_api.cpp
+++ b/src/platform/opengl/opengl_renderer_api.cpp
@@ -106,4 +106,10 @@ namespace Donut
glBindImageTexture(slot, texture_id, 0, GL_FALSE, 0,
read_only ? GL_READ_ONLY : GL_WRITE_ONLY, GL_RGBA8);
}
+
+ void OpenGLRendererAPI::read_pixels(uint32_t x, uint32_t y, uint32_t width, uint32_t height,
+ uint32_t format, uint32_t type, void* pixels)
+ {
+ glReadPixels(x, y, width, height, format, type, pixels);
+ }
};